diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-08-06 00:25:55 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-06 00:25:55 +0200 |
commit | 3249b7d40d448b5bdb0ec6b3ca82dcf6dbbc6b09 (patch) | |
tree | 589de86ae2c4a91bcc6593e9e3a21256f9d8869d /scene/gui | |
parent | bd833f8e06da9d2eccc57f9cc632c46cfa57d963 (diff) | |
parent | 7869ea236e8fd87e5a64d5301ecdfd4a9a8b664d (diff) |
Merge pull request #63859 from Rindbee/fix-hue-slider-incorrectly-rotated
Fix Hue slider incorrectly rotated 90 degrees in ColorPicker
Diffstat (limited to 'scene/gui')
-rw-r--r-- | scene/gui/color_mode.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/gui/color_mode.cpp b/scene/gui/color_mode.cpp index af78d67e5a..ebd86e0937 100644 --- a/scene/gui/color_mode.cpp +++ b/scene/gui/color_mode.cpp @@ -159,7 +159,7 @@ void ColorModeHSV::slider_draw(int p_which) { } else if (p_which == 0) { Ref<Texture2D> hue = color_picker->get_theme_icon(SNAME("color_hue"), SNAME("ColorPicker")); slider->draw_set_transform(Point2(), -Math_PI / 2, Size2(1.0, 1.0)); - slider->draw_texture_rect(hue, Rect2(Vector2(margin * -2, 0), Vector2(slider->get_size().x, margin)), false, Color(1, 1, 1), true); + slider->draw_texture_rect(hue, Rect2(Vector2(margin * -2, 0), Vector2(margin, size.x)), false); return; } else { Color s_col; @@ -306,7 +306,7 @@ void ColorModeOKHSL::slider_draw(int p_which) { } else if (p_which == 0) { Ref<Texture2D> hue = color_picker->get_theme_icon(SNAME("color_hue"), SNAME("ColorPicker")); slider->draw_set_transform(Point2(), -Math_PI / 2, Size2(1.0, 1.0)); - slider->draw_texture_rect(hue, Rect2(Vector2(margin * -2, 0), Vector2(slider->get_size().x, margin)), false, Color(1, 1, 1), true); + slider->draw_texture_rect(hue, Rect2(Vector2(margin * -2, 0), Vector2(margin, size.x)), false); return; } else { Color s_col; |