Class ScyllaEditorTheme
Applies the shared Scylla UI Toolkit theme to a window a module builds for itself.
Inherited Members
Namespace: Scylla.Core.Editor
Assembly: ScyllaCore.Editor.dll
Syntax
public static class ScyllaEditorTheme
Remarks
Editor UI deriving from ScyllaToolWindowBase,
ScyllaEditorBase or ScyllaWizardWindowBase is themed
already and does not need this. It exists for the rarer case of a module building a
bare EditorWindow, typically a dropdown or a popup, where those base classes are
the wrong shape because they also build a toolbar, a content pane and a status bar.
The loader behind it stays internal to this assembly deliberately: it resolves the shipped package path from the calling assembly, so a copy compiled into a module would look for its stylesheets in the wrong package and quietly find nothing. One named entry point across the boundary is preferable to widening Core's editor internals to every module that ever wants a popup.
Not to be confused with ScyllaEditorStyles, which is the IMGUI
GUIStyle collection and has nothing to do with stylesheets.
Methods
Apply(VisualElement)
Loads the shared stylesheets onto a root element and keeps them matched to the skin.
Declaration
public static void Apply(VisualElement root)
Parameters
| Type | Name | Description |
|---|---|---|
| VisualElement | root | The root element to theme. Ignored when |
Remarks
Call once, on the root of a window's visual tree, from CreateGUI. A module's
own stylesheet is added afterwards by the caller so it wins over the shared one.
Also installs the watcher that swaps the theme variant when the user switches between the light and dark Editor skins with the window already open.