# HG changeset patch # User Sebastien Jodogne # Date 1622027295 -7200 # Node ID fe402c678d18de36d4cd28200128a2a5f3af7474 # Parent 101e7e0079d5ab51b29aecbbd6afe5074f61456b improved color theme for annotations diff -r 101e7e0079d5 -r fe402c678d18 OrthancStone/Sources/Scene2D/AnnotationsSceneLayer.cpp --- a/OrthancStone/Sources/Scene2D/AnnotationsSceneLayer.cpp Tue May 25 20:21:14 2021 +0200 +++ b/OrthancStone/Sources/Scene2D/AnnotationsSceneLayer.cpp Wed May 26 13:08:15 2021 +0200 @@ -47,6 +47,16 @@ static const char* const VALUE_CIRCLE = "circle"; static const char* const VALUE_SEGMENT = "segment"; +#if 0 +static OrthancStone::Color COLOR_PRIMITIVES(192, 192, 192); +static OrthancStone::Color COLOR_HOVER(0, 255, 0); +static OrthancStone::Color COLOR_TEXT(255, 0, 0); +#else +static OrthancStone::Color COLOR_PRIMITIVES(0x40, 0x82, 0xad); +static OrthancStone::Color COLOR_HOVER(0x40, 0xad, 0x79); +static OrthancStone::Color COLOR_TEXT(0x4e, 0xde, 0x99); +#endif + namespace OrthancStone { @@ -65,8 +75,8 @@ int depth) : modified_(true), parentAnnotation_(parentAnnotation), - color_(192, 192, 192), - hoverColor_(0, 255, 0), + color_(COLOR_PRIMITIVES), + hoverColor_(COLOR_HOVER), isHover_(false), depth_(depth) { @@ -781,7 +791,7 @@ segment_(AddTypedPrimitive(new Segment(*this, p1, p2))), label_(AddTypedPrimitive(new Text(that, *this))) { - label_.SetColor(Color(255, 0, 0)); + label_.SetColor(COLOR_TEXT); UpdateLabel(); } @@ -900,7 +910,7 @@ arc_(AddTypedPrimitive(new Arc(*this, start, middle, end))), label_(AddTypedPrimitive(new Text(that, *this))) { - label_.SetColor(Color(255, 0, 0)); + label_.SetColor(COLOR_TEXT); UpdateLabel(); } @@ -1046,7 +1056,7 @@ circle_(AddTypedPrimitive(new Circle(*this, p1, p2))), label_(AddTypedPrimitive(new Text(that, *this))) { - label_.SetColor(Color(255, 0, 0)); + label_.SetColor(COLOR_TEXT); UpdateLabel(); }