PcoWSkbVqDnWTu_dm2ix
Collapse Sidebar

TextWrapped

TextLabel

bool

When enabled, this property will render text on multiple lines within a TextLabel|GUI element’s space so that TextLabel/TextBounds will never exceed the GuiBase2d/AbsoluteSize of the UI element.

This is achieved by breaking long lines of text into multiple lines. Line breaks will prefer whitespace; should a long unbroken word exceed the width of the element, that word will be broken into multiple lines.

If further line breaks would cause the vertical height of the text (the Y component of TextLabel/TextBounds) to exceed the vertical height of the element (the Y component of GuiBase2d/AbsoluteSize), then that line will not be rendered at all.


Code Samples


Long Text Wrapping

This code sample demonstrates TextWrap by spelling out a long chunk of text progressively. If the text doesn’t fit, it turns a different color.