Class TreeLayoutBarPlugin
- Namespace
- Whim.TreeLayout.Bar
- Assembly
- Whim.TreeLayout.Bar.dll
This plugin contains the tree layout engine widget for the IBarPlugin.
public class TreeLayoutBarPlugin : IPlugin
- Inheritance
-
TreeLayoutBarPlugin
- Implements
- Inherited Members
Remarks
Create a new instance of the TreeLayoutBarPlugin class.
Constructors
TreeLayoutBarPlugin(ITreeLayoutPlugin)
This plugin contains the tree layout engine widget for the IBarPlugin.
public TreeLayoutBarPlugin(ITreeLayoutPlugin plugin)
Parameters
plugin
ITreeLayoutPlugin
Remarks
Create a new instance of the TreeLayoutBarPlugin class.
Properties
Name
whim.tree_layout.bar
public string Name { get; }
Property Value
PluginCommands
The commands and keybinds for this plugin. These are registered during PreInitialize().
public IPluginCommands PluginCommands { get; }
Property Value
Remarks
Keybindings can be overridden by the user using SetKeybind(string, IKeybind).
Methods
CreateComponent()
Create the tree layout engine bar component.
public BarComponent CreateComponent()
Returns
LoadState(JsonElement)
Load the plugin's state from
state
.public void LoadState(JsonElement state)
Parameters
state
JsonElement- The plugin's state.
Remarks
State is loaded after PostInitialize() and the user's configuration has been loaded.
Thus, be careful on how you interact with the user's configuration.
PostInitialize()
This method is to be called by the plugin manager.
Initializes the plugin after the rest of the IContext has been initialized.
Put things which rely on the rest of the context here.
public void PostInitialize()
PreInitialize()
This method is to be called by the plugin manager.
Initializes the plugin before the IContext has been initialized.
Put things like event listeners here or adding proxy layout engines
(see AddProxyLayoutEngine(ProxyLayoutEngineCreator)).
public void PreInitialize()
SaveState()
Save the plugin's state as a JsonElement.
public JsonElement? SaveState()
Returns
- JsonElement?
- The plugin's state.