user22411435
user22411435

Reputation:

Text Wrapping Is Changing When I Press Play Unity(Closed)

So I'm making a game with text as the diolauge and I turn off overflow in the tmp settings. And when I press play it just turns back on again I have some images as example. And I tried restarting unity but that didn't work.

Before Play

After Play

Upvotes: 0

Views: 153

Answers (2)

Manoj Pranav J
Manoj Pranav J

Reputation: 1

I get this solution in Issue Tracker: "This behavior is by design as the child Placeholder and Text objects are controlled by the parent InputField object.

For instance, if the Line type is set to Single Line, then wrapping is disabled. If the Line type is set to Multi Line Newline then wrapping is enabled."

Just change parent input field as multi line!

Upvotes: 0

user22411435
user22411435

Reputation:

I fixed it on my own! I just had to use GetComponent().enableWordWrapping = true; in the start method!

Upvotes: 1

Related Questions