summaryrefslogtreecommitdiff
path: root/editor/editor_themes.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2017-05-23 08:42:52 +0200
committerGitHub <noreply@github.com>2017-05-23 08:42:52 +0200
commita77e53b0a554d9f5b56122445e8215e2584488ce (patch)
tree4a6d644ac403e31e71249440b5f08650e330531e /editor/editor_themes.cpp
parentab938a930f865196983dc0554533f66bc71c43a1 (diff)
parentde9fb136b14909c2cfd4018e8f68395011802f47 (diff)
Merge pull request #8872 from volzhs/editor-theme-lineedit
Fix disabled style of LineEdit
Diffstat (limited to 'editor/editor_themes.cpp')
-rw-r--r--editor/editor_themes.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/editor/editor_themes.cpp b/editor/editor_themes.cpp
index b88474e2c3..1d73192f76 100644
--- a/editor/editor_themes.cpp
+++ b/editor/editor_themes.cpp
@@ -293,12 +293,13 @@ Ref<Theme> create_editor_theme() {
// LineEdit
Ref<StyleBoxFlat> style_lineedit = make_flat_stylebox(dark_color_1, 4, 4, 4, 4);
style_lineedit->set_border_size(1 * EDSCALE);
- style_lineedit->set_light_color(light_color_1);
- style_lineedit->set_dark_color(light_color_1);
+ style_lineedit = change_border_color(style_lineedit, light_color_1);
Ref<StyleBoxFlat> style_lineedit_disabled = style_lineedit->duplicate();
- style_lineedit_disabled->set_bg_color(light_color_2);
+ style_lineedit_disabled->set_bg_color(light_color_1);
+ Ref<StyleBoxFlat> style_lineedit_focus = change_border_color(style_lineedit, highlight_color);
+ style_lineedit_focus->set_draw_center(false);
theme->set_stylebox("normal", "LineEdit", style_lineedit);
- theme->set_stylebox("focus", "LineEdit", change_border_color(style_lineedit, highlight_color));
+ theme->set_stylebox("focus", "LineEdit", style_lineedit_focus);
theme->set_stylebox("read_only", "LineEdit", style_lineedit_disabled);
// TextEdit