Types of Automatic Layout Groups

When a UI object has an automatic layout group component attached to it, all of its children will be aligned, resized, and positioned based on the parameters of the layout component. There are three automatic layout group options: Horizontal Layout Group, Vertical Layout Group, and Grid Layout Group.

The following screenshot shows three panels (represented by gray rectangles), each with six UI image children (represented by the black rectangles): the first panel has a Horizontal Layout Group component, the second panel has a Vertical Layout Group component, and the third panel has a Grid Layout Group component:

Automatic Layout Groups Example 1 in the Chapter3Text Scene

From the preceding screenshot, you ...

Get Mastering UI Development with Unity now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.