getLayoutProperty
info
A Widget Control that every widget shares. In the examples below, widgetID is the name (ID) you gave the widget on the canvas, and scripts access it as widgetID.member.
Reads a layout-related property value from a widget. It covers the same targets as setLayoutProperty — widget meta properties, or placement properties inside a parent.
- Parameters
name(string): the name of the layout property to read
- Returns:
any- the property value. Returnsnullwhen no property with that name exists.
Example
const v = imgID.getLayoutProperty("visible");
const f = imgID.getLayoutProperty("flex");
warning
Placement properties such as flex and top only hold a value when they match the widget's parent container type. When they don't, the call returns null.