blob: 79f58c3cd55b8973708a458eb6efdaddcd9c870e [file] [log] [blame]
{ "type": "class",
"qname": "spark.layouts.TileLayout",
"baseClassname": "spark.layouts.supportClasses.LayoutBase"
,
"description": "The TileLayout class arranges layout elements in columns and rows of equally-sized cells. The TileLayout class uses a number of properties that control orientation, count, size, gap and justification of the columns and the rows as well as element alignment within the cells. <p>Per-element supported constraints are <code>percentWidth</code> and <code>percentHeight</code>. Element's minimum and maximum sizes are always be respected and where possible, an element's size is limited to less then or equal of the cell size.</p> <p>When not explicitly set, the <code>columnWidth</code> property is calculated as the maximum preferred bounds width of all elements and the <code>columnHeight</code> property is calculated as the maximum preferred bounds height of all elements.</p> <p>When not explicitly set, the <code>columnCount</code> and <code>rowCount</code> properties are calculated from any explicit width and height settings for the layout target, and <code>columnWidth</code> and <code>columnHeight</code>. In case none is specified, the <code>columnCount</code> and <code>rowCount</code> values are picked so that the resulting pixel area is as square as possible.</p> <p> The measured size is calculated from the <code>columnCount</code>, <code>rowCount</code>, <code>columnWidth</code>, <code>rowHeight</code> properties and the gap sizes.</p> <p>The default measured size, when no properties were explicitly set, is as square as possible area and is large enough to fit all elements.</p> <p>In other cases the measured size may not be big enough to fit all elements. For example, when both <code>columnCount</code> and <code>rowCount</code> are explicitly set to values such that <code>columnCount</code> &#42; <code>rowCount</code> &lt; element count.</p> <p>The minimum measured size is calculated the same way as the measured size but it's guaranteed to encompass enough rows and columns along the minor axis to fit all elements.</p> <p>The <code>&lt;s:TileLayout&gt;</code> tag inherits all of the tag attributes of its superclass and adds the following tag attributes:</p> <pre>\\n &lt;s:TileLayout\\n <strong>Properties</strong>\\n columnAlign=&quot;left&quot;\\n columnWidth=&quot;NaN&quot;\\n horizontalAlign=&quot;justify&quot;\\n horizontalGap=&quot;6&quot;\\n orientation=&quot;rows&quot;\\n requestedColumnCount=&quot;-1&quot;\\n requestedRowCount=&quot;-1&quot;\\n rowAlign=&quot;top&quot;\\n rowCount=&quot;-1&quot;\\n rowHeight=&quot;NaN&quot;\\n verticalAlign=&quot;justify&quot;\\n verticalGap=&quot;6&quot;\\n padding=&quot;0&quot;\\n /&gt;\\n </pre>",
"tags": [
{ "tagName": "mxml",
"values": [""]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"members": [
{ "type": "method",
"qname": "spark.layouts.TileLayout",
"namespace": "",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Constructor.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": []}
,
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "horizontalGap",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Horizontal space between columns, in pixels.",
"tags": [
{ "tagName": "see",
"values": ["#verticalGap", "#columnAlign"]},
{ "tagName": "default",
"values": ["6"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "verticalGap",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Vertical space between rows, in pixels.",
"tags": [
{ "tagName": "see",
"values": ["#horizontalGap", "#rowAlign"]},
{ "tagName": "default",
"values": ["6"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "int",
"qname": "columnCount",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Contain the actual column count.",
"tags": [
{ "tagName": "see",
"values": ["#rowCount", "#columnAlign"]},
{ "tagName": "default",
"values": ["-1"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "int",
"qname": "requestedColumnCount",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Number of columns to be displayed. <p>Set to -1 to allow the TileLayout to determine the column count automatically.</p> <p>If the <code>orientation</code> property is set to <code>TileOrientation.ROWS</code>, then setting this property has no effect In this case, the <code>rowCount</code> is explicitly set, and the container width is explicitly set. </p>",
"tags": [
{ "tagName": "see",
"values": ["#columnCount", "#columnAlign"]},
{ "tagName": "default",
"values": ["-1"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "int",
"qname": "rowCount",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "The row count.",
"tags": [
{ "tagName": "see",
"values": ["#requestedRowCount", "#columnCount"]},
{ "tagName": "default",
"values": ["-1"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "int",
"qname": "requestedRowCount",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Number of rows to be displayed. <p>Set to -1 to remove explicit override and allow the TileLayout to determine the row count automatically.</p> <p>If the <code>orientation</code> property is set to <code>TileOrientation.COLUMNS</code>, setting this property has no effect. in this case, <code>columnCount</code> is explicitly set, and the container height is explicitly set.</p>",
"tags": [
{ "tagName": "see",
"values": ["#rowCount", "#rowAlign"]},
{ "tagName": "default",
"values": ["-1"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "columnWidth",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Contain the actual column width, in pixels. <p>If not explicitly set, the column width is determined from the width of the widest element. </p> <p>If the <code>columnAlign</code> property is set to <code>&quot;justifyUsingWidth&quot;</code>, the column width grows to the container width to justify the fully-visible columns.</p>",
"tags": [
{ "tagName": "see",
"values": ["#rowHeight", "#columnAlign"]},
{ "tagName": "default",
"values": ["NaN"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "rowHeight",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "The row height, in pixels. <p>If not explicitly set, the row height is determined from the maximum of elements' height.</p> If <code>rowAlign</code> is set to &quot;justifyUsingHeight&quot;, the actual row height increases to justify the fully-visible rows to the container height.",
"tags": [
{ "tagName": "see",
"values": ["#columnWidth", "#rowAlign"]},
{ "tagName": "default",
"values": ["NaN"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "padding",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The minimum number of pixels between the container's edges and the edges of the layout element.",
"tags": [
{ "tagName": "default",
"values": ["0"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "paddingLeft",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The minimum number of pixels between the container's left edge and the left edge of the layout element.",
"tags": [
{ "tagName": "default",
"values": ["0"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "paddingRight",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The minimum number of pixels between the container's right edge and the right edge of the layout element.",
"tags": [
{ "tagName": "default",
"values": ["0"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "paddingTop",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Number of pixels between the container's top edge and the top edge of the first layout element.",
"tags": [
{ "tagName": "default",
"values": ["0"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "paddingBottom",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Number of pixels between the container's bottom edge and the bottom edge of the last layout element.",
"tags": [
{ "tagName": "default",
"values": ["0"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "horizontalAlign",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Specifies how to align the elements within the cells in the horizontal direction. Supported values are <code>HorizontalAlign.LEFT</code>, <code>HorizontalAlign.CENTER</code>, <code>HorizontalAlign.RIGHT</code>, <code>HorizontalAlign.JUSTIFY</code>. <p>When set to <code>HorizontalAlign.JUSTIFY</code> the width of each element is set to the <code>columnWidth</code>.</p>",
"tags": [
{ "tagName": "default",
"values": ["<code>HorizontalAlign.JUSTIFY</code>"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "verticalAlign",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Specifies how to align the elements within the cells in the vertical direction. Supported values are <code>VerticalAlign.TOP</code>, <code>VerticalAlign.MIDDLE</code>, <code>VerticalAlign.BOTTOM</code>, <code>VerticalAlign.JUSTIFY</code>. <p>When set to <code>VerticalAlign.JUSTIFY</code>, the height of each element is set to <code>rowHeight</code>.</p>",
"tags": [
{ "tagName": "default",
"values": ["<code>VerticalAlign.JUSTIFY</code>"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "columnAlign",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Specifies how to justify the fully visible columns to the container width. ActionScript values can be <code>ColumnAlign.LEFT</code>, <code>ColumnAlign.JUSTIFY_USING_GAP</code> and <code>ColumnAlign.JUSTIFY_USING_WIDTH</code>. MXML values can be <code>&quot;left&quot;</code>, <code>&quot;justifyUsingGap&quot;</code> and <code>&quot;justifyUsingWidth&quot;</code>. <p>When set to <code>ColumnAlign.LEFT</code> it turns column justification off. There may be partially visible columns or whitespace between the last column and the right edge of the container. This is the default value.</p> <p>When set to <code>ColumnAlign.JUSTIFY_USING_GAP</code> the <code>horizontalGap</code> actual value increases so that the last fully visible column right edge aligns with the container's right edge. In case there is only a single fully visible column, the <code>horizontalGap</code> actual value increases so that it pushes any partially visible column beyond the right edge of the container. Note that explicitly setting the <code>horizontalGap</code> property does not turn off justification. It only determines the initial gap value. Justification may increases it.</p> <p>When set to <code>ColumnAlign.JUSTIFY_USING_WIDTH</code> the <code>columnWidth</code> actual value increases so that the last fully visible column right edge aligns with the container's right edge. Note that explicitly setting the <code>columnWidth</code> property does not turn off justification. It only determines the initial column width value. Justification may increases it.</p>",
"tags": [
{ "tagName": "see",
"values": ["#horizontalGap", "#columnWidth", "#rowAlign"]},
{ "tagName": "default",
"values": ["ColumnAlign.LEFT"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "rowAlign",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Specifies how to justify the fully visible rows to the container height. ActionScript values can be <code>RowAlign.TOP</code>, <code>RowAlign.JUSTIFY_USING_GAP</code> and <code>RowAlign.JUSTIFY_USING_HEIGHT</code>. MXML values can be <code>&quot;top&quot;</code>, <code>&quot;justifyUsingGap&quot;</code> and <code>&quot;justifyUsingHeight&quot;</code>. <p>When set to <code>RowAlign.TOP</code> it turns column justification off. There might be partially visible rows or whitespace between the last row and the bottom edge of the container. This is the default value.</p> <p>When set to <code>RowAlign.JUSTIFY_USING_GAP</code> the <code>verticalGap</code> actual value increases so that the last fully visible row bottom edge aligns with the container's bottom edge. In case there is only a single fully visible row, the value of <code>verticalGap</code> increases so that it pushes any partially visible row beyond the bottom edge of the container. Note that explicitly setting the <code>verticalGap</code> does not turn off justification, but just determines the initial gap value. Justification can then increases it.</p> <p>When set to <code>RowAlign.JUSTIFY_USING_HEIGHT</code> the <code>rowHeight</code> actual value increases so that the last fully visible row bottom edge aligns with the container's bottom edge. Note that explicitly setting the <code>rowHeight</code> does not turn off justification, but determines the initial row height value. Justification can then increase it.</p>",
"tags": [
{ "tagName": "see",
"values": ["#verticalGap", "#rowHeight", "#columnAlign"]},
{ "tagName": "default",
"values": ["RowAlign.TOP"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "orientation",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Specifies whether elements are arranged row by row or column by column. ActionScript values can be <code>TileOrientation.ROWS</code> and <code>TileOrientation.COLUMNS</code>. MXML values can be <code>&quot;rows&quot;</code> and <code>&quot;columns&quot;</code>.",
"tags": [
{ "tagName": "default",
"values": ["TileOrientation.ROWS"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "useVirtualLayout",
"namespace": "public",
"bindable": [],
"details": ["override"],
"deprecated": {},
"description": "A container can hold any number of children. However, each child requires an instance of an item renderer. If the container has many children, you might notice performance degradation as you add more children to the container. <p>Instead of creating an item renderer for each child, you can configure the container to use a virtual layout. With virtual layout, the container reuses item renderers so that it only creates item renderers for the currently visible children of the container. As a child is moved off the screen, possible by scrolling the container, a new child being scrolled onto the screen can reuse its item renderer. </p> <p>To configure a container to use virtual layout, set the <code>useVirtualLayout</code> property to <code>true</code> for the layout associated with the container. Only DataGroup or SkinnableDataContainer with layout set to VerticalLayout, HorizontalLayout, or TileLayout supports virtual layout. Layout subclasses that do not support virtualization must prevent changing this property.</p> <p><b>Note: </b>The BasicLayout class throws a run-time error if you set <code>useVirtualLayout</code> to <code>true</code>.</p> <p>When <code>true</code>, layouts that support virtualization must use the <code>target.getVirtualElementAt()</code> method, rather than <code>getElementAt()</code>, and must only get the elements they anticipate will be visible given the value of <code>getScrollRect()</code>.</p> <p>When <code>true</code>, the layout class must be able to compute the indices of the layout elements that overlap the <code>scrollRect</code> in its <code>updateDisplayList()</code> method based exclusively on cached information, not by getting layout elements and examining their bounds.</p> <p>Typically virtual layouts update their cached information in the <code>updateDisplayList()</code> method, based on the sizes and locations computed for the elements in view.</p> <p>Similarly, in the <code>measure()</code> method, virtual layouts should update the target's measured size properties based on the <code>typicalLayoutElement</code> and other cached layout information, not by measuring elements.</p> <p>Containers cooperate with layouts that have <code>useVirtualLayout</code> = <code>true</code> by recycling item renderers that were previously constructed, but are no longer in use. An item is considered to be no longer in use if its index is not within the range of <code>getVirtualElementAt()</code> indices requested during the container's most recent <code>updateDisplayList()</code> invocation.</p>",
"tags": [
{ "tagName": "default",
"values": ["false", "false"]},
{ "tagName": "see",
"values": ["#getScrollRect()", "#typicalLayoutElement", "#getScrollRect()", "#typicalLayoutElement"]},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5", "Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4", "Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0", "3.0"]} ]},
{ "type": "method",
"qname": "calculateDropIndex",
"namespace": "protected",
"bindable": [],
"details": ["override"],
"deprecated": {},
"description": "",
"tags": [
{ "tagName": "inheritDoc",
"values": []},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "int",
"params": [{ "name": "x", "type": "Number"},
{ "name": "y", "type": "Number"}]}
,
{ "type": "method",
"qname": "calculateDropIndicatorBounds",
"namespace": "protected",
"bindable": [],
"details": ["override"],
"deprecated": {},
"description": "",
"tags": [
{ "tagName": "inheritDoc",
"values": []},
{ "tagName": "playerversion",
"values": ["Flash 10", "AIR 1.5"]},
{ "tagName": "productversion",
"values": ["Flex 4"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "org.apache.royale.geom.Rectangle",
"params": [{ "name": "dropLocation", "type": "spark.layouts.supportClasses.DropLocation"}]}
]
}