Skip to main content

TreeView Class

Package: GHIElectronics.Endpoint.UI
Namespace: GHIElectronics.Endpoint.UI

Hierarchical list. Nodes are added imperatively via TreeView.AddNode with a depth value: codegen walks the tree and emits one AddNode call per visible node.

public class TreeView : Widget

Constructors​

TreeView(Widget parent)​

public TreeView(Widget parent)

Create a tree view inside parent.

ParameterTypeDescription
parentWidgetContaining widget.

Methods​

AddNode(int depth, bool isExpanded, bool hasChildren, string header)​

public void AddNode(int depth, bool isExpanded, bool hasChildren, string header)

Append a visible node at the given indent level.

ParameterTypeDescription
depthintIndent depth, 0-based (0 = root level).
isExpandedboolWhether this node currently shows its children (visual only; the caller feeds the children themselves).
hasChildrenboolWhether to draw an expand/collapse chevron.
headerstringRow text; null is treated as empty.

Clear()​

public void Clear()

Remove every node.