Menu
Lumberyard
Developer Guide (Version 1.11)

UILayoutGridComponent

Controls grid layout characteristics.

UiLayoutGridBus

Services messages for the UiLayoutGridComponent.

GetCellSize

Returns, in pixels, the size of a child element.

Syntax

Copy
AZ::Vector2 GetCellSize()

GetHorizontalOrder

Returns the horizontal order for the layout.

Syntax

Copy
eUiHorizontalOrder GetHorizontalOrder()

Following are possible values for eUiHorizontalOrder.

Copy
enum eUiHorizontalOrder { eUiHorizontalOrder_LeftToRight, eUiHorizontalOrder_RightToLeft };

GetPadding

Returns, in pixels, the padding inside the edges of the element.

Syntax

Copy
UiPadding GetPadding()

Following are the attributes for UiPadding.

Copy
class UiPadding { int left; int right; int top; int bottom; };

GetSpacing

Returns, in pixels, the spacing between child elements.

Syntax

Copy
AZ::Vector2 GetSpacing()

GetStartingDirection

Returns the starting direction for the layout.

Syntax

Copy
eUiLayoutGridStartingDirection GetStartingDirection()

Following are possible values for eUiLayoutGridStartingDirection.

Copy
enum eUiLayoutGridStartingDirection { eUiLayoutGridStartingDirection_HorizontalOrder, eUiLayoutGridStartingDirection_VerticalOrder };

GetVerticalOrder

Returns the vertical order for the layout.

Syntax

Copy
eUiVerticalOrder GetVerticalOrder()

Following are possible values for eUiVerticalOrder.

Copy
enum eUiVerticalOrder { eUiVerticalOrder_TopToBottom, eUiVerticalOrder_BottomToTop };

SetCellSize

Sets the size of a child element to the specified number of pixels.

Syntax

Copy
void SetCellSize(AZ::Vector2 size)

SetHorizontalOrder

Sets the horizontal order for the layout.

Syntax

Copy
void SetHorizontalOrder(eUiHorizontalOrder order)

For possible values for eUiHorizontalOrder, see GetHorizontalOrder.

SetPadding

Sets the padding inside the edges of the element to the specified number of pixels.

Syntax

Copy
void SetPadding(UiPadding padding)

For possible values for UiPadding, see GetPadding.

SetSpacing

Sets the spacing between child elements to the specified number of pixels.

Syntax

Copy
void SetSpacing(AZ::Vector2 spacing)

SetStartingDirection

Sets the starting direction for the layout.

Syntax

Copy
void SetStartingDirection(eUiLayoutGridStartingDirection direction)

For possible values for eUiLayoutGridStartingDirection, see GetStartingDirection.

SetVerticalOrder

Sets the vertical order for the layout.

Syntax

Copy
void SetVerticalOrder(eUiVerticalOrder order)

For possible values for eUiVerticalOrder, see GetVerticalOrder.

On this page: