Skip to main content

Tree

Tree Widget API

Properties

Tree

WidgetHasChildrenHasState
Tree.Tree: Iris.Tree

A collapsable container for other widgets, to organise and hide widgets when not needed. The state determines whether the child widgets are visible or not. Clicking on the widget will collapse or uncollapse it.

hasChildren: true
hasState: true
Arguments = {
    Text: string,
    SpanAvailWidth: boolean? = false, -- the tree title will fill all horizontal space to the end its parent container.
    NoIndent: boolean? = false -- the child widgets will not be indented underneath.
}
Events = {
    collapsed: () -> boolean,
    uncollapsed: () -> boolean,
    hovered: () -> boolean
}
State = {
    isUncollapsed: State<boolean>? -- whether the widget is collapsed.
}

CollapsingHeader

WidgetHasChildrenHasState
Tree.CollapsingHeader: Iris.CollapsingHeader

The same as a Tree Widget, but with a larger title and clearer, used mainly for organsing widgets on the first level of a window.

hasChildren: true
hasState: true
Arguments = {
    Text: string
}
Events = {
    collapsed: () -> boolean,
    uncollapsed: () -> boolean,
    hovered: () -> boolean
}
State = {
    isUncollapsed: State<boolean>? -- whether the widget is collapsed.
}
Show raw api
{
    "functions": [],
    "properties": [
        {
            "name": "Tree",
            "desc": "A collapsable container for other widgets, to organise and hide widgets when not needed. The state determines whether the child widgets are visible or not. Clicking on the widget will collapse or uncollapse it.\n\n```lua\nhasChildren: true\nhasState: true\nArguments = {\n    Text: string,\n    SpanAvailWidth: boolean? = false, -- the tree title will fill all horizontal space to the end its parent container.\n    NoIndent: boolean? = false -- the child widgets will not be indented underneath.\n}\nEvents = {\n    collapsed: () -> boolean,\n    uncollapsed: () -> boolean,\n    hovered: () -> boolean\n}\nState = {\n    isUncollapsed: State<boolean>? -- whether the widget is collapsed.\n}\n```\n    ",
            "lua_type": "Iris.Tree",
            "tags": [
                "Widget",
                "HasChildren",
                "HasState"
            ],
            "source": {
                "line": 669,
                "path": "lib/API.lua"
            }
        },
        {
            "name": "CollapsingHeader",
            "desc": "The same as a Tree Widget, but with a larger title and clearer, used mainly for organsing widgets on the first level of a window.\n\n```lua\nhasChildren: true\nhasState: true\nArguments = {\n    Text: string\n}\nEvents = {\n    collapsed: () -> boolean,\n    uncollapsed: () -> boolean,\n    hovered: () -> boolean\n}\nState = {\n    isUncollapsed: State<boolean>? -- whether the widget is collapsed.\n}\n```\n    ",
            "lua_type": "Iris.CollapsingHeader",
            "tags": [
                "Widget",
                "HasChildren",
                "HasState"
            ],
            "source": {
                "line": 696,
                "path": "lib/API.lua"
            }
        }
    ],
    "types": [],
    "name": "Tree",
    "desc": "Tree Widget API\n    ",
    "source": {
        "line": 641,
        "path": "lib/API.lua"
    }
}