Fontstring sizing or something else?
I am trying to create simple frame that displays text. I definitely made the containing frame wide enough to fit the string but it is still wrapping. The string is multiline (will have multiple \n).
Code:
raidLockoutFrame = CreateFrame("ScrollFrame", "NITRaidLockoutFrame", UIParent, "TooltipBorderedFrameTemplate"); I've looked for solutions, tested word wrapping on the fontstring itself (does not work), and the GetWidth function returns 220 for the string (and I am setting the parent frame width to 400). Any help out there? |
Lua Code:
Adjust numbers to suit. If the string itself has new line characters (\n) they will need to be stripped out: Code:
raidLockoutFrame.text:SetText(gsub(CreateLockoutText(), "\n", " ")) |
Ahh - I missed SetSize (was looking for SetWidth/SetHeight).
Thanks! |
You can use :SetWidth() and :SetHeight() instead of :SetSize(). But you didn't actually give your fontstring a width and height. Just your frame.
|
All times are GMT -6. The time now is 12:19 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI