P
P
Pavel2018-06-02 12:00:30
Unity
Pavel, 2018-06-02 12:00:30

How to disable padding for a VecticalLayoutGroup element?

I have a gameObject on which hangs a Vertical Layout Group like this with settings.
The group includes 2 elements: Image and Text. For the text, I need to set the indentation, otherwise it looks crooked.
But when I set the text indent - it is set for Image.
It was decided to throw a LayoutElement component on the Image with such settings (such a large width is used for clarity), but as you can see on the screenshot, the width is not set quite as expected.
Tell me a possible solution to the problem: how can I make a separate indent for the text, or disable the indent for Image.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Daniil Basmanov, 2018-06-03
@youkerni

Put the text in a container and indent there.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question