Change CUI panel height based on character count?Solved
Hello,

I am working on somthing at the moment and have encountered a issue I haven't faced yet. I have a panel as the background and the text is parented to the panel. The idea is, when the text gets to long it starts a new line in which I need to expand the anchor on the panel until the text is seen. I have everything working, just needa figure out how to detect when the text has reached the end. Any help is great, thanks!

P.S. I have already thought about a fixed char count, although every char count will be different so its hard to go off that and would cause inconsistancy.

Example:
https://gyazo.com/1ae6f38d116aa77ece6d5b1fcba05aca

Thanks!
I think that is something Rust developers should consider adding

You can make your box size based on letters inside

1 letter size is ~1.5 offset "pixel" in height and ~0.75 pixel in length

Example:
Size 7 letter will require box with ~sizes of 10 and 5

5ba216a6d7f65.png Orange

You can make your box size based on letters inside

1 letter size is ~1.5 offset "pixel" in height and ~0.75 pixel in length

Example:
Size 7 letter will require box with ~sizes of 10 and 5

What do you mean by "letters"? Letter as in character?
TravisButts
What do you mean by "letters"? Letter as in character?

Yeah, i mean character :)

5ba216a6d7f65.png Orange

You can make your box size based on letters inside

1 letter size is ~1.5 offset "pixel" in height and ~0.75 pixel in length

Example:
Size 7 letter will require box with ~sizes of 10 and 5

I am confused on how you are getting these numbers, are they made up? If so, how would I get these numbers?

Locked automatically