UIElement:set_relative_position
Advanced
Sets this element’s position relative to its parent top-left corner.
When implementing custom Wrapper / Container elements, you have to call this method on their children from Wrapper:arrange_child / Container:arrange_children .
Usage
ui_element:set_relative_position(left, right, top, bottom)
Arguments
| Name | Type | Description |
|---|---|---|
left | number | Position of the element’s left edge relative to its parent left edge. |
right | number | Position of the element’s right edge relative to its parent left edge. |
top | number | Position of the element’s top edge relative to its parent top edge. |
bottom | number | Position of the element’s bottom edge relative to its parent top edge. |