Scaling text to fit in GUI node [SOLVED]

This has probably been asked already, but I couldn’t find it. I have a text node with a background box node and I want the text to fit inside the box without cutting it off or changing the box size. How would I go about doing that? I thought about using gui.set_scale to change the scale of the text, but I’m not great at math and my best attempts didn’t quite work for every input. Any suggestions?

Try something like this.

1 Like

Works great! Thanks!

1 Like