UIElement:parent
Returns this element’s parent, if any.
Usage
ui_element:parent()
Returns
| Name | Type | Description |
|---|---|---|
parent_element | UIElement | nil | Parent element or nil. |
Examples
local popup = crystal.Overlay:new();
local title = popup:add_child(crystal.Text:new());
assert(title:parent() == popup);