Originally Posted by gmarco
Later I'll try to understand how to make a left justified button text :-)
|
Code:
button:GetFontString():SetJustifyH("LEFT")
However, depending on the template used, you may need to adjust the font string's points as well. For example, if the font string is anchored by its CENTER point to the button's CENTER point, left-aligning the text will make it start in the center of the button, so you'd need to do something like this:
Code:
local fontstring = button:GetFontString()
fontstring:ClearAllPoints()
fontstring:SetPoint("LEFT", button, 8, 0)
fontstring:SetPoint("RIGHT", button, -8, 0)
fontstring:SetJustifyH("LEFT")