aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLoic Guegan <manzerbredes@mailbox.org>2022-02-17 10:29:59 +0100
committerLoic Guegan <manzerbredes@mailbox.org>2022-02-17 10:29:59 +0100
commitbc5536356905e011afe719967f5e69c20a3cbbd3 (patch)
tree108158333228e080d1217ce6a494487551d18f3c
parentcba432b023d3aba5cebc7a04afec3c94d8cac972 (diff)
Debug move icons
-rw-r--r--src/components/MoveTable.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/components/MoveTable.cpp b/src/components/MoveTable.cpp
index f6ce64a..42280eb 100644
--- a/src/components/MoveTable.cpp
+++ b/src/components/MoveTable.cpp
@@ -105,7 +105,7 @@ std::uint32_t MoveTable::UpdateMoves(CGEHalfMove *m, std::uint32_t line,
if (m->move.size() > 0) {
char c = m->move[0];
if (!(c == 'a' || c == 'b' || c == 'c' || c == 'd' || c == 'e' ||
- c == 'f' || c == 'O' || c == '0')) {
+ c == 'f' || c == 'g' || c == 'h' || c == 'O' || c == '0')) {
e.text = m->move.substr(1, m->move.size());
if (c == 'N') {
img.prop |= Property::Knight;
@@ -190,8 +190,7 @@ std::uint32_t MoveTable::DrawComment(CGEHalfMove *m, std::uint32_t line,
const char &indent_black) {
// Show three dots
if (!m->IsBlack) {
- DRAW_DOTS(status->MarginBarWidth +
- status->MoveWidth * (indent + 1) +
+ DRAW_DOTS(status->MarginBarWidth + status->MoveWidth * (indent + 1) +
((indent + 1) / 2 * status->MarginBarWidth),
status->MoveHeight * line);
}
@@ -237,8 +236,7 @@ std::uint32_t MoveTable::DrawVariations(CGEHalfMove *m, std::uint32_t line,
const char &indent_black) {
// Show three dots next to move if white turn
if ((m->variations.size() == 0) && !m->IsBlack) {
- DRAW_DOTS(status->MarginBarWidth +
- status->MoveWidth * (indent + 1),
+ DRAW_DOTS(status->MarginBarWidth + status->MoveWidth * (indent + 1),
status->MoveHeight * line);
}
// Show button on the right side of the move
@@ -266,8 +264,7 @@ std::uint32_t MoveTable::DrawVariations(CGEHalfMove *m, std::uint32_t line,
{
Element e;
e.prop = Property::Rectangle | Property::Button;
- e.x = (status->MarginBarWidth +
- status->MoveWidth * indent) +
+ e.x = (status->MarginBarWidth + status->MoveWidth * indent) +
status->MoveWidth - std::ceil(status->MoveHeight / 2) -
std::ceil(status->MoveHeight / 4);
e.y = (status->MoveHeight * (line + 1)) +