Noob question #47:
I have an addon that incorporates checkboxes. They work just fine. But now I want to change the text color of their tooltip and prompt strings to GameFontNormal. More generally, I would really like to learn more about the various font methods and how and when to use them.
Anyway, here’s my code:
local box = CreateFrame("CheckButton",
"OPTIONS_damageBtn",
f,
"ChatConfigCheckButtonTemplate")
box:SetPoint("TOPLEFT", xPos, yPos )
local toolTipText = "Report threat generated by each party member."
local promptText = "Threat metrics by party member?"
box.tooltip = toolTipText
_G[box:GetName().."Text"]:SetText( promptText )
local reportDamageDetails = false
box:SetChecked( reportDamageDetails )
...
What I would like to do is change the color of 'toolTipText" and “promptText” from white to GameFontNormal. I can do what I want to do using escape sequences, but I need to learn how to use the APIs. To this end, I’ve been experimenting with the various font methods but am not quite sure of what I’m doing.
I would really appreciate any advice.
Thanks,