Is there any way to keep the Y value the same as the X value (UIGridLayout)

Hi! I’m currently using a UIGridLayout to display some frames together.
I want 4 items on each row so I have set the CellSize X Scale value to 0.25. What I would like to know if there’s any way to set each frame’s Y size to have the same size X so that the frames are square and not rectangular.

Current settings for the UIGridLayout.

Current system makes the boxes rectangular due to incorrect scaling.
image

Many thanks! :slight_smile:

Add a UIAspectRatioConstraint inside of the grid elements and it overrides the size set by the UIGridLayout.

2 Likes

Ah, fantastic! Added the constraint and seems to be working like a charm. Cheers!

1 Like