Difference between revisions of "Sprite:getLayoutInfo"

From GiderosMobile
(Created page with "__NOTOC__ '''<translate>Available since</translate>:''' Gideros 2018.9<br/> '''<translate>Class</translate>:''' Sprite<br/> === <translate>Descri...")
 
m (Text replacement - "</source>" to "</syntaxhighlight>")
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
__NOTOC__
 
__NOTOC__
'''<translate>Available since</translate>:''' Gideros 2018.9<br/>
+
'''Available since:''' Gideros 2018.9<br/>
'''<translate>Class</translate>:''' [[Special:MyLanguage/Sprite|Sprite]]<br/>
+
'''Class:''' [[Sprite]]<br/>
=== <translate>Description</translate> ===
+
 
<translate><br />
+
=== Description ===
<br /></translate>
+
Returns computed placement value according to Gideros layout system.
<source lang="lua">
+
<syntaxhighlight lang="lua">
 
(table) = Sprite:getLayoutInfo()
 
(table) = Sprite:getLayoutInfo()
</source>
+
</syntaxhighlight>
=== <translate>Return values</translate> ===
+
 
'''<translate>Returns</translate>''' (table) <translate>Table of layout information.</translate><br/>
+
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<br/>
 +
 
 +
{{Sprite}}

Latest revision as of 14:33, 13 July 2023

Available since: Gideros 2018.9
Class: Sprite

Description

Returns computed placement value according to Gideros layout system.

(table) = Sprite:getLayoutInfo()

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