Currently working on a pretty epic system, the only problem I have right now is getting the size of the text of a text label.
I could just use TextSize, but when a TextLabel uses TextScaled that simply wont work.
I’ve tried using TextBounds, but I am unsure as to how I could actually use it lol.
How I’ve used it is that I use TextBounds.Y which most of the time gives you the text size, but when the text goes onto another line it doesnt give the size, cause well thats not how that works.
I am working on a system to make TextLabels have TextShadow, by just making a textlabel that contains most of the properties the original TextLabel has.
Cloning the text wont work, and sometimes the text has a UITextSizeConstraint, of which things also get silly goofy.
This gives the exact same result of TextBounds, except the Y value it returns always gives me the FontSize I provided. I may be doing something wrong? But Im unsure.
You most likely restricted the function to the current boundaries of the TextLabel. The fourth argument often confuses people that way—myself included. Input a Vector2 whose vertical axis is unlimited (math.huge). GetTextSize will tell you how to reformat the boundary to accomodate for the text on the vertical axis
It always gives me (168, 14), which the 14 part isnt an accurate size so Im not sure if I gotta do some math or something, but yeah thats what I’ve got!