Difference between revisions of "Sprite:getLayoutInfo"

From GiderosMobile
m (Text replacement - "<source" to "<syntaxhighlight")
Line 5: Line 5:
 
=== Description ===
 
=== Description ===
 
Returns computed placement value according to Gideros layout system.
 
Returns computed placement value according to Gideros layout system.
<source lang="lua">
+
<syntaxhighlight lang="lua">
 
(table) = Sprite:getLayoutInfo()
 
(table) = Sprite:getLayoutInfo()
 
</source>
 
</source>

Revision as of 15:31, 13 July 2023

Available since: Gideros 2018.9
Class: Sprite

Description

Returns computed placement value according to Gideros layout system. <syntaxhighlight lang="lua"> (table) = Sprite:getLayoutInfo() </source>

The returned table can contain the following fields:

  • startx: the 0-based index of the column the child was placed into
  • starty: the 0-based index of the row the child was placed into
  • width: the width of the child
  • height: the height of the child
  • weightx: the horizontal weight of the child
  • weighty: the vertical weight of the child
  • minWidth (table): minimum width
  • minHeight (table): minimum height

Return values

Returns (table) table of layout information