Vertical Layout Group auto expand when children's height is greater than container
Is there a way to auto expand the vertical layout group when child layout elements have exceeded the height of the gameobject with the vertical layout group component?
Answer by shell123 · Jul 20, 2017 at 01:31 AM
Add ContentSizeFitter component to the gameobject with VerticalLayoutGroup and set the contentsizefitter's "Vertical fit" to preferred size.
It forces the child allignment to middle center though; how to make it upper center?
Change the pivot on the Rect Transform and it will expand accordingly. Pivot at the top will expand from the bottom, bottom will expand from the top, and center will expand equally from top and bottom.
Your answer
Follow this Question
Related Questions
UI layout suddenly changed, not sure how to get it back 0 Answers
How to place a property underneath some other properties (property drawer of serialized object)? 1 Answer
Issues with layout after building 0 Answers
How to make child of layout group always fit the screen size and be placed side by side? 1 Answer