public sealed class DockingWorkspaceThe docked arrangement, the panels in it, and the presets it can be put back to.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
What DockingHost deliberately does not do. The host knows about panels by id, splits, tabs and a serialisable arrangement, and nothing about where a panel's contents come from or what "the Shading layout" is — which is right for a control in Vixen.Ui. This is the editor's half: a registry of what can be shown, lazy construction, named presets, and one place that saves.
⚠ Applying a layout creates the panels it names, in that order. DockingHost.AddPanel leaves a panel the arrangement already places where the arrangement put it, so registering after loading is what makes a restored layout come back as it was — and doing it the other way round drops everything into the first group.
Fields and properties (6)
public DockingHost HostThe control showing the arrangement.
public IReadOnlyList<PanelDescriptor> PanelsWhat can be shown, in the order it was registered.
public IReadOnlyCollection<string> PresetsThe named arrangements, in no particular order.
public string DefaultPresetWhich preset Reset goes back to.
public Func<string, bool>? ResolveAsked to register a panel a saved arrangement names and nothing declared.
public bool CanFloatActiveWhether FloatActive would do anything.
Events (1)
public Action<DockingWorkspace>? ChangedRaised after anything changes the arrangement.
Methods (19)
public DockingWorkspace(UiElement host)Builds a docking host into an element.
public PanelDescriptor Register(PanelDescriptor descriptor)Declares a panel.
public PanelDescriptor Register(string id, StringId title, Action<DockPanel> build)Declares a panel from its parts.
public bool Unregister(string id)Takes a panel out of the registry, closing it if it is open.
public bool IsOpen(string id)Whether a panel is currently in the arrangement.
public DockPanel? Open(string id)Shows a panel, building it the first time.
public bool Close(string id)Takes a panel out of the arrangement.
public void Toggle(string id)Shows a panel if it is hidden and hides it if it is shown.
public bool Select(string id)Brings a panel to the front of its group.
public bool CloseActive()Closes the panel the user is in.
public bool CycleTab(int delta)Moves to the next or previous tab of the group the user is in.
public bool FloatActive()Takes the panel the user is in out into a window of its own.
public void AddPreset(string name, Func<DockLayout> layout)Declares a named arrangement.
public bool RemovePreset(string name)Takes a named arrangement out.
public bool Apply(string name)Shows a named arrangement.
public bool Reset()Puts the arrangement back to DefaultPreset.
public string Save()The arrangement as YAML.
public void Load(string yaml)Shows a saved arrangement, building the panels it names.
public void Show(DockLayout layout)Applies an arrangement and opens what it names.
Used by (19)
- ChromeFixtureVixen.Editor.Ui.Tests
- ConsolePanelTestsVixen.Editor.App.Tests
- DiagnosticsModuleVixen.Editor.Diagnostics
- DropIntoSceneTestsVixen.Editor.App.Tests
- EditorApplicationVixen.Editor.App
- EditorModeTestsVixen.Editor.App.Tests
- EditorModesVixen.Editor.Ui
- EditorSessionVixen.Editor.Testing
- EditorShellVixen.Editor.Ui
- EditorShellTestsVixen.Editor.Ui.Tests
- LoadingTestsVixen.Editor.Plugin.Tests
- MilestoneE3TestsVixen.Editor.App.Tests
- MilestoneE5TestsVixen.Editor.App.Tests
- ModeTestsVixen.Editor.Ui.Tests
- PanelBehaviourTestsVixen.Editor.App.Tests
- SelectionTestsVixen.Editor.App.Tests
- TerrainPanelTestsVixen.Editor.App.Tests
- ViewportTestsVixen.Editor.App.Tests
- WorkspaceTestsVixen.Editor.Ui.Tests