module
CrShader::ShaderEditorIntegration
Overview
============================================================================= ShaderEditorIntegration - Hooks CrShader Directly into Godot's "Shader Editor"
Extended Modules
Defined in:
crshader/editor/shader_editor_integration.crInstance Method Summary
- #active_editors : Hash(String, CrShaderTabEditor)
- #cleanup! : Void
- #compile_all_project_crshaders!(project_root : String | Nil = nil) : Int32
-
#current_tab_is_crshader? : Bool
Returns true if the currently selected Shader Editor tab is a
.crshaderresource. -
#discover_project_crshaders(project_root : String | Nil = nil) : Array(String)
Discovers all project
.crshaderfiles asres://paths. -
#ensure_toolbar_controls! : Void
Injects the
🔮 CRShadermenu and contextualEdit .crshader Sourcebutton into Godot's Shader Editor bar. -
#find_companion_crshader(compiled_res_path : String) : String | Nil
Maps any generated
.gdshader/.gdshaderinc/.glslpath back to its authoring.crshaderpath! -
#locate_godot_shader_editor! : Bool
Locates Godot 4.8's built-in "Shader Editor" dock (
EditorDock/WindowWrapper), its left-handItemList, top menuHBoxContainer, and right-handTabContainer. -
#open_shader(path_or_res : String | CrShader::CRShader, host_plugin : Godot::Object | Nil = nil) : CrShaderTabEditor | Nil
Opens a
.crshaderfile (orCRShaderresource) directly inside Godot's "Shader Editor" tab and returns its mountedCrShaderTabEditor. -
#reveal_shader_editor_dock!(host_plugin : Godot::Object | Nil = nil) : Void
Raises and focuses Godot's built-in "Shader Editor" bottom dock.
- #save_all_open_shaders! : Void
- #shader_dock : Godot::Control | Nil
-
#sync_shader_tabs! : Void
Inspects Godot's
Shader Editoropen tabs and upgrades any.crshaderTextShaderEditorslot in-place withCrShaderTabEditor, plus updates the contextualEdit .crshaderbutton! -
#trigger_native_new_shader_menu! : Bool
Triggers Godot's native
File -> New Shader...(Ctrl+N) menu action in the Shader Editor. - #valid_ctrl?(ctrl : Godot::Object | Nil) : Bool
Instance Method Detail
Returns true if the currently selected Shader Editor tab is a .crshader resource.
Discovers all project .crshader files as res:// paths.
Injects the 🔮 CRShader menu and contextual Edit .crshader Source button into Godot's Shader Editor bar.
Maps any generated .gdshader / .gdshaderinc / .glsl path back to its authoring .crshader path!
Locates Godot 4.8's built-in "Shader Editor" dock (EditorDock / WindowWrapper),
its left-hand ItemList, top menu HBoxContainer, and right-hand TabContainer.
Opens a .crshader file (or CRShader resource) directly inside Godot's "Shader Editor" tab
and returns its mounted CrShaderTabEditor.
Raises and focuses Godot's built-in "Shader Editor" bottom dock.
Inspects Godot's Shader Editor open tabs and upgrades any .crshader TextShaderEditor slot
in-place with CrShaderTabEditor, plus updates the contextual Edit .crshader button!