diff options
| author | Yuri Roubinsky <chaosus89@gmail.com> | 2019-10-03 17:30:18 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-10-03 17:30:18 +0300 |
| commit | 409ec8bd1e92135e57cfe28cc75ec0bc6c062ca8 (patch) | |
| tree | 8ca0d5de50eae831909dd202bcd5b508b33d242e /editor | |
| parent | d66cce0215fe2f963ecf35c2176f4c89ef793ac5 (diff) | |
| parent | b11d15d5c3299d15db20ed4f8318a2be5f9d2ff0 (diff) | |
Merge pull request #32512 from Chaosus/vs_texture_uv
Makes Texture and TextureUniform in visual shaders to use UV by default
Diffstat (limited to 'editor')
| -rw-r--r-- | editor/plugins/visual_shader_editor_plugin.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp index 2e20e068d7..c962751c7a 100644 --- a/editor/plugins/visual_shader_editor_plugin.cpp +++ b/editor/plugins/visual_shader_editor_plugin.cpp @@ -665,6 +665,15 @@ void VisualShaderEditor::_update_graph() { label->set_text(name_left); label->add_style_override("normal", label_style); //more compact hb->add_child(label); + + if (vsnode->get_input_port_default_hint(i) != "" && !port_left_used) { + + Label *hint_label = memnew(Label); + hint_label->set_text("[" + vsnode->get_input_port_default_hint(i) + "]"); + hint_label->add_color_override("font_color", get_color("font_color_readonly", "TextEdit")); + hint_label->add_style_override("normal", label_style); + hb->add_child(hint_label); + } } } |