blob: 681aee17fa8b4d5dc3f337a54599db99d74fea51 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
#pragma once
#include <string>
#include <vector>
namespace cgeditor {
/**
* @brief Move (mainlines and variations) displayed in the editor
*
*/
class CGEHalfMove {
public:
CGEHalfMove();
CGEHalfMove(CGEHalfMove *parent);
CGEHalfMove(const std::string &move);
/// @brief CUrrent move number
std::uint16_t Number;
/// @brief Current move value
std::string move;
/// @brief Current NAG
std::string nag;
/// @brief Comment linked to the move
std::string comment;
CGEHalfMove *MainLine;
CGEHalfMove *Parent;
bool IsBlack;
/// @brief Says if variations of that move must be drawn
bool Folded = false;
/// @brief Says if this move must be drawn
bool Hide = false;
/// @brief Variations of the move
std::vector<CGEHalfMove *> variations;
/// @brief Remove a move from the MainLine and/or variations
void RemoveChild(CGEHalfMove *m);
};
} // namespace cgeditor
|