Responsive text container?

Hi

I want to make put a gui text inside a chat bubble in my game, i want chat bubble is resized according to the length of the text.

But i’m struggling to find what is the size of the gui text as gui.get_size always returns the size that is set on the editor

Is there a method to find the real size of the gui text node when the length of the text is changed?

Thank you

Yes, you want resource.get_text_metrics(): API reference (resource)

1 Like