Create a new node slot and optionally place a node within.
Create a new slot and place a node in it.
Create a new empty slot.
Remove the assigned node from the slot.
Change the node in the slot.
Swap contents of the two slots.
NodeSlot defines its own styles, which will only apply to the slot itself, not the contents. Most of the styling options will have no effect, but padding and margin will.
Node placed in the slot.
Node core constructor parameters, to be passed from node to node.
Represents a node's layout
Node core constructor parameters, to be passed from node to node.
This node defines a single style, style, which also works as a default style for all other nodes. However, rather than for that, the purpose of this style is to define the convention of style being the node's default, idle style.
Tree data for the node. Note: requires at least one draw before this will work.
Layout for this node.
If true, this node will be removed from the tree on the next draw.
If true, mouse focus will be disabled for this node, so mouse signals will "go through" to its parents, as if the node wasn't there. The node will still detect hover like normal.
Minimum size of the node.
Get the current theme.
Set the theme.
Check if the node is hidden.
Set the visibility
Show the node.
Hide the node.
Disable this node.
Enable this node.
Toggle the node's visibility.
Remove this node from the tree before the next draw.
Check if this node is hovered.
Check if this node is disabled.
Checks if the node is disabled, either by self, or by any of its ancestors. Updated when drawn.
Queue an action to perform within this node's branch.
Recalculate the window size before next draw.
Draw this node as a root node.
Switch to the previous or next focused item
Switch focus towards a specified direction.
Draw this node at the specified location from within of another (parent) node.
Recalculate the minimum node size and update the minSize property.
Ditto
Draw this node.
Check if the node is hovered.
Get the current style.
import fluid; NodeSlot!Label slot1, slot2; // Slots can be empty, with no node inside auto root = vspace( label("Hello, "), slot1 = nodeSlot!Label(.layout!"fill"), label(" and "), slot2 = nodeSlot!Label(.layout!"fill"), ); // Slots can be assigned other nodes slot1 = label("John"); slot2 = button("Jane", delegate { // Slot contents can be swapped with a single call slot1.swapSlots(slot2); }); // Slots can be reassigned at any time slot1 = label("Joe"); // Their values can also be removed slot1.clear();
A "node slot" node, which displays the node given to it. Allows safely swapping nodes in the layout by reference, even during drawing. Useful for creating tabs and menus.
Because NodeSlot does not inherit from T, it uses the single-parameter overload of simpleConstructor.