summaryrefslogtreecommitdiff
path: root/editor/plugins/visual_shader_editor_plugin.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2020-07-28 21:44:30 +0200
committerGitHub <noreply@github.com>2020-07-28 21:44:30 +0200
commit7a31baf3b9dc066fb15af8aa4f90193df3615226 (patch)
tree3d51a4112a4d95efb9613675a9712595cf856d88 /editor/plugins/visual_shader_editor_plugin.cpp
parent8c6c9e017e362b57a8a1cae7a08a994995dfeaa6 (diff)
parent69d1c48b73122f34187d952a08f2a7eb82fd2403 (diff)
Merge pull request #40800 from briansemrau/fix-shader-comment-highlighting
Fixed Shader editor single-line comment highlight
Diffstat (limited to 'editor/plugins/visual_shader_editor_plugin.cpp')
-rw-r--r--editor/plugins/visual_shader_editor_plugin.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp
index 660d994f67..0af2b120bd 100644
--- a/editor/plugins/visual_shader_editor_plugin.cpp
+++ b/editor/plugins/visual_shader_editor_plugin.cpp
@@ -887,7 +887,7 @@ void VisualShaderEditor::_update_graph() {
expression_syntax_highlighter->set_symbol_color(symbol_color);
expression_syntax_highlighter->set_function_color(function_color);
expression_syntax_highlighter->add_color_region("/*", "*/", comment_color, false);
- expression_syntax_highlighter->add_color_region("//", "", comment_color, false);
+ expression_syntax_highlighter->add_color_region("//", "", comment_color, true);
expression_box->set_text(expression);
expression_box->set_context_menu_enabled(false);
@@ -1756,7 +1756,7 @@ void VisualShaderEditor::_notification(int p_what) {
syntax_highlighter->set_function_color(function_color);
syntax_highlighter->clear_color_regions();
syntax_highlighter->add_color_region("/*", "*/", comment_color, false);
- syntax_highlighter->add_color_region("//", "", comment_color, false);
+ syntax_highlighter->add_color_region("//", "", comment_color, true);
error_text->add_theme_font_override("font", get_theme_font("status_source", "EditorFonts"));
error_text->add_theme_color_override("font_color", get_theme_color("error_color", "Editor"));