Class · inherits Instance
GetTextBoundsParams
Use with TextService.GetTextBoundsAsync to measure the size of text.
About GetTextBoundsParams
Pass this instance to TextService.GetTextBoundsAsync to measure the
size of text.
Properties 5
Font
: Datatype.FontTheFontof the text being measured.The
Fontof the text being measured. Corresponds to theTextLabel.FontFaceproperty on text objects.Not to be confused with
Font. This is an object that you can create usingFont.new.RichText
: booleanDetermines whether the measured text is interpreted using rich text markup.Determines whether the text being measured is interpreted using rich text markup. Corresponds to the
TextLabel.RichTextproperty on text objects.By default, the value is
false, meaning theGetTextBoundsParams.Textstring is measured verbatim. When set totrue, rich text formatting tags in the string are parsed rather than measured as literal characters, so the returned bounds reflect the styled text.Size
: floatThe size of the text being measured.The size of the text that is being measured. Corresponds to the
TextLabel.TextSizeproperty.Text
: stringThe text being measured.Width
: floatThe width of the container for line breaking.The width of the container for line breaking. By default, the value is 0, which means no line breaking will be performed. You can set it to the width of the container that you'll be putting the text into.
GetTextBoundsParams also has every member of Instance. Deprecated and Roblox-only members are hidden.
Reference text from the Roblox Creator Documentation, licensed CC BY 4.0, reorganized by rbxtoolshub.com · Studio 0.743.0.7431133.