diff options
Diffstat (limited to 'scene/2d/position_2d.cpp')
-rw-r--r-- | scene/2d/position_2d.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/scene/2d/position_2d.cpp b/scene/2d/position_2d.cpp index 8bccf117fd..e37407ceb3 100644 --- a/scene/2d/position_2d.cpp +++ b/scene/2d/position_2d.cpp @@ -33,11 +33,14 @@ #include "core/engine.h" #include "scene/resources/texture.h" +const float DEFAULT_GIZMO_EXTENTS = 10.0; + void Position2D::_draw_cross() { float extents = get_gizmo_extents(); - draw_line(Point2(-extents, 0), Point2(+extents, 0), Color(1, 0.5, 0.5)); - draw_line(Point2(0, -extents), Point2(0, +extents), Color(0.5, 1, 0.5)); + // Colors taken from `axis_x_color` and `axis_y_color` (defined in `editor/editor_themes.cpp`) + draw_line(Point2(-extents, 0), Point2(+extents, 0), Color(0.96, 0.20, 0.32)); + draw_line(Point2(0, -extents), Point2(0, +extents), Color(0.53, 0.84, 0.01)); } Rect2 Position2D::_edit_get_rect() const { |