Vertical Text

How to place each characters of text vertically?
I saw that it is done by setting width to 0.
But this solution breaks preferred width and height,and auto size.

How about that?

string txt = "Hello World";
txt = string.Join("\n", txt.ToCharArray());
Debug.Log(txt);

What is your expectation in terms of the preferred width being when the text is all vertical?

Does PreferredWidth become the width of the widest characters?

Then does PreferredHeight become sort of what normal horizontal layout preferredwidth would have been?

Vertical Text Layout is certainly possible but having this work with Auto-size and preferred values is a different story.

Yeah,PreferredWidth is set to widest character’s width,and PreferredHeight is set to sum of these characters and padding.