diff options
author | Yuri Sizov <yuris@humnom.net> | 2021-08-03 21:48:17 +0300 |
---|---|---|
committer | Yuri Sizov <yuris@humnom.net> | 2021-08-03 22:13:32 +0300 |
commit | d3e413c6594c1bb84651901e1ce011ab79c6afec (patch) | |
tree | c23ecb9a0653b7765e4859c11c3b28b057335e42 | |
parent | ebdfe259c1125991c7dd57cf2ed64a3805b20fa1 (diff) |
Fix the editor theme application for the Mono build log
-rw-r--r-- | editor/editor_themes.cpp | 3 | ||||
-rw-r--r-- | modules/mono/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs | 14 |
2 files changed, 15 insertions, 2 deletions
diff --git a/editor/editor_themes.cpp b/editor/editor_themes.cpp index f0cc1530ab..0d714065e3 100644 --- a/editor/editor_themes.cpp +++ b/editor/editor_themes.cpp @@ -155,6 +155,7 @@ void editor_register_and_generate_icons(Ref<Theme> p_theme, bool p_dark_theme = ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#8da5f3", "#3d64dd"); // 2D ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#4b70ea", "#1a3eac"); // 2D Dark ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#8eef97", "#2fa139"); // Control + ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#ffdd65", "#ca8a04"); // Node warning // Rainbow ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#ff4545", "#ff2929"); // Red @@ -229,7 +230,6 @@ void editor_register_and_generate_icons(Ref<Theme> p_theme, bool p_dark_theme = exceptions.insert("StatusError"); exceptions.insert("StatusSuccess"); exceptions.insert("StatusWarning"); - exceptions.insert("NodeWarning"); exceptions.insert("OverbrightIndicator"); } @@ -1045,6 +1045,7 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) { theme->set_icon("tab", "TextEdit", theme->get_icon("GuiTab", "EditorIcons")); theme->set_icon("space", "TextEdit", theme->get_icon("GuiSpace", "EditorIcons")); theme->set_color("font_color", "TextEdit", font_color); + theme->set_color("font_readonly_color", "LineEdit", font_readonly_color); theme->set_color("caret_color", "TextEdit", font_color); theme->set_color("selection_color", "TextEdit", selection_color); diff --git a/modules/mono/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs b/modules/mono/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs index ed69c2b833..897f1b2822 100644 --- a/modules/mono/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs +++ b/modules/mono/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs @@ -11,6 +11,7 @@ namespace GodotTools.Build { public BuildOutputView BuildOutputView { get; private set; } + private MenuButton buildMenuBtn; private Button errorsBtn; private Button warningsBtn; private Button viewLogBtn; @@ -131,7 +132,7 @@ namespace GodotTools.Build var toolBarHBox = new HBoxContainer {SizeFlagsHorizontal = (int)SizeFlags.ExpandFill}; AddChild(toolBarHBox); - var buildMenuBtn = new MenuButton {Text = "Build", Icon = GetThemeIcon("Play", "EditorIcons")}; + buildMenuBtn = new MenuButton {Text = "Build", Icon = GetThemeIcon("Play", "EditorIcons")}; toolBarHBox.AddChild(buildMenuBtn); var buildMenu = buildMenuBtn.GetPopup(); @@ -177,5 +178,16 @@ namespace GodotTools.Build BuildOutputView = new BuildOutputView(); AddChild(BuildOutputView); } + + public override void _Notification(int what) + { + base._Notification(what); + + if (what == NotificationThemeChanged) { + buildMenuBtn.Icon = GetThemeIcon("Play", "EditorIcons"); + errorsBtn.Icon = GetThemeIcon("StatusError", "EditorIcons"); + warningsBtn.Icon = GetThemeIcon("NodeWarning", "EditorIcons"); + } + } } } |