Open main menu
Home
Random
Log in
Settings
About AddOn Studio
Disclaimers
AddOn Studio
Search
Editing
WoW:API GameTooltip SetText
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{widgetmethod}} SetText("text"[, red, green, blue[, alpha[, textWrap]]]) Sets the text of the tooltip. == Arguments == :;"text" : string - The text of the new tooltip. Variable can be used inplace of a string. :;red : Optional - number range 0 to 1 - red color value for text string :;green : Optional - number range 0 to 1 - green color value for text string :;blue : Optional - number range 0 to 1 - blue color value for text string :;alpha : Optional - number range 0 to 1 - specifies the opacity of text. Default is 1. :;textWrap : Optional - {{api|boolean|t=t}} - 'true' to wrap the text string to fit the tooltip box. Default is 'false'. == Returns == :none == Example == GameTooltip:SetText("This is my awesome tooltip!", 0.5, 0.5, 0.5, 0.75, 1) Would result in a semi transparent, greyish colored tooltip that would probably be wrapped to a second line due to the textWrap flag and its length. == Details == When using the flag the tooltip width is set at a preset size (about the size of the ability tooltips on spells.). Long tooltips will go off the side of the screen if this is not set. Alternatively you can simply use a "\n" in the "text" arg to force a new line. If optional parameters are not specified the text defaults to Gold color, Full Opaque, and NON-wrapped.
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Api
(
edit
)
Template:Apinav
(
edit
)
Template:Editlink
(
edit
)
Template:Tocright
(
edit
)
Template:Widget
(
edit
)
Template:Widgetmethod
(
edit
)