<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://addonstudio.org/mw1/index.php?action=history&amp;feed=atom&amp;title=WoW%3ATooltip_pseudo_code</id>
	<title>WoW:Tooltip pseudo code - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://addonstudio.org/mw1/index.php?action=history&amp;feed=atom&amp;title=WoW%3ATooltip_pseudo_code"/>
	<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;action=history"/>
	<updated>2026-05-22T08:39:17Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6043&amp;oldid=prev</id>
		<title>Move page script: Move page script moved page Tooltip pseudo code to WoW:Tooltip pseudo code without leaving a redirect</title>
		<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6043&amp;oldid=prev"/>
		<updated>2023-08-15T04:49:00Z</updated>

		<summary type="html">&lt;p&gt;Move page script moved page &lt;a href=&quot;/wiki/WoW:Tooltip_pseudo_code&quot; title=&quot;WoW:Tooltip pseudo code&quot;&gt;Tooltip pseudo code&lt;/a&gt; to &lt;a href=&quot;/wiki/WoW:Tooltip_pseudo_code&quot; title=&quot;WoW:Tooltip pseudo code&quot;&gt;Tooltip pseudo code&lt;/a&gt; without leaving a redirect&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 04:49, 15 August 2023&lt;/td&gt;
				&lt;/tr&gt;
&lt;!-- diff cache key addonstu_asmw2:diff::1.12:old-6039:rev-6043 --&gt;
&lt;/table&gt;</summary>
		<author><name>Move page script</name></author>
	</entry>
	<entry>
		<id>https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6039&amp;oldid=prev</id>
		<title>Bear at 00:21, 18 May 2020</title>
		<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6039&amp;oldid=prev"/>
		<updated>2020-05-18T00:21:12Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 00:21, 18 May 2020&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{uitech}}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{uitech}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Tooltips are notoriously difficult to handle in WoW UI code. This page contains Lua-style pseudo code that attempts to represent the behaviour and interaction of various GameTooltip widget methods. (Currently it&amp;#039;s not complete, yet to include details about line-wrapping behaviour). See [[UIOBJECT GameTooltip]] for notes about GameTooltips. See [[Widget API]] for a reference list about GameTooltip methods and their uses.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Tooltips are notoriously difficult to handle in WoW UI code. This page contains Lua-style pseudo code that attempts to represent the behaviour and interaction of various GameTooltip widget methods. (Currently it&amp;#039;s not complete, yet to include details about line-wrapping behaviour). See [[UIOBJECT GameTooltip]] for notes about GameTooltips. See [[Widget API]] for a reference list about GameTooltip methods and their uses.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Note&amp;#039;&amp;#039;&amp;#039;: This is not actual working Lua code, you can&amp;#039;t copy/paste it. It is a representation of what the game&amp;#039;s engine does internally, to help understand tooltips&amp;#039; behaviour. No such Lua code actually exists anywhere.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Note&amp;#039;&amp;#039;&amp;#039;: This is not actual working Lua code, you can&amp;#039;t copy/paste it. It is a representation of what the game&amp;#039;s engine does internally, to help understand tooltips&amp;#039; behaviour. No such Lua code actually exists anywhere.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key addonstu_asmw2:diff::1.12:old-6042:rev-6039 --&gt;
&lt;/table&gt;</summary>
		<author><name>Bear</name></author>
	</entry>
	<entry>
		<id>https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6042&amp;oldid=prev</id>
		<title>WoWWiki&gt;Egingell: Fixed an oversight (tooltip:AppendText), I know it&#039;s just psudo code, but it just didn&#039;t look right.</title>
		<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6042&amp;oldid=prev"/>
		<updated>2007-06-30T09:52:36Z</updated>

		<summary type="html">&lt;p&gt;Fixed an oversight (tooltip:AppendText), I know it&amp;#039;s just psudo code, but it just didn&amp;#039;t look right.&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 09:52, 30 June 2007&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l95&quot;&gt;Line 95:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 95:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;    &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;    &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   function AppendText(text, etc)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   function &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;tooltip:&lt;/ins&gt;AppendText(text, etc)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       AddToFirstLine(text)    -- Appends the text to the first line&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       AddToFirstLine(text)    -- Appends the text to the first line&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       self:Show()&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       self:Show()&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key addonstu_asmw2:diff::1.12:old-6041:rev-6042 --&gt;
&lt;/table&gt;</summary>
		<author><name>WoWWiki&gt;Egingell</name></author>
	</entry>
	<entry>
		<id>https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6041&amp;oldid=prev</id>
		<title>WoWWiki&gt;Mikk: {{uitech}}, formatting...</title>
		<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6041&amp;oldid=prev"/>
		<updated>2006-06-17T09:02:33Z</updated>

		<summary type="html">&lt;p&gt;{{uitech}}, formatting...&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 09:02, 17 June 2006&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{uitech}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Tooltips are notoriously difficult to handle in WoW UI code. This page contains Lua-style pseudo code that attempts to represent the behaviour and interaction of various GameTooltip widget methods. (Currently it&amp;#039;s not complete, yet to include details about line-wrapping behaviour). See [[UIOBJECT GameTooltip]] for notes about GameTooltips. See [[Widget API]] for a reference list about GameTooltip methods and their uses.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Tooltips are notoriously difficult to handle in WoW UI code. This page contains Lua-style pseudo code that attempts to represent the behaviour and interaction of various GameTooltip widget methods. (Currently it&amp;#039;s not complete, yet to include details about line-wrapping behaviour). See [[UIOBJECT GameTooltip]] for notes about GameTooltips. See [[Widget API]] for a reference list about GameTooltip methods and their uses.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Note&amp;#039;&amp;#039;&amp;#039;: This is not actual working Lua code, you can&amp;#039;t copy/paste it. It is a representation of what the game&amp;#039;s engine does internally, to help understand tooltips&amp;#039; behaviour. No such Lua code actually exists anywhere.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Note&amp;#039;&amp;#039;&amp;#039;: This is not actual working Lua code, you can&amp;#039;t copy/paste it. It is a representation of what the game&amp;#039;s engine does internally, to help understand tooltips&amp;#039; behaviour. No such Lua code actually exists anywhere.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l124&quot;&gt;Line 124:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 128:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;       end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category: UI Technical Details]]&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key addonstu_asmw2:diff::1.12:old-6040:rev-6041 --&gt;
&lt;/table&gt;</summary>
		<author><name>WoWWiki&gt;Mikk</name></author>
	</entry>
	<entry>
		<id>https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6040&amp;oldid=prev</id>
		<title>WoWWiki&gt;Legorol: Pseudo code of GameTooltip methods</title>
		<link rel="alternate" type="text/html" href="https://addonstudio.org/mw1/index.php?title=WoW:Tooltip_pseudo_code&amp;diff=6040&amp;oldid=prev"/>
		<updated>2006-01-23T20:26:06Z</updated>

		<summary type="html">&lt;p&gt;Pseudo code of GameTooltip methods&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Tooltips are notoriously difficult to handle in WoW UI code. This page contains Lua-style pseudo code that attempts to represent the behaviour and interaction of various GameTooltip widget methods. (Currently it&amp;#039;s not complete, yet to include details about line-wrapping behaviour). See [[UIOBJECT GameTooltip]] for notes about GameTooltips. See [[Widget API]] for a reference list about GameTooltip methods and their uses.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note&amp;#039;&amp;#039;&amp;#039;: This is not actual working Lua code, you can&amp;#039;t copy/paste it. It is a representation of what the game&amp;#039;s engine does internally, to help understand tooltips&amp;#039; behaviour. No such Lua code actually exists anywhere.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039; (Valid for patch 1.10) &amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
  -- Hiding a tooltip&amp;#039;s parent causes tooltip:ClearTooltip() to be called&lt;br /&gt;
  -- Showing a tooltip&amp;#039;s parent causes tooltip:Show() to be called&lt;br /&gt;
  &lt;br /&gt;
  tooltip = {&lt;br /&gt;
      owner = nil;&lt;br /&gt;
      anchor = nil;&lt;br /&gt;
      fading = nil;&lt;br /&gt;
      numLines = 0;&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  -- Note: this function is not accessible via the Widget API, only available internally&lt;br /&gt;
  function tooltip:ClearTooltip()&lt;br /&gt;
      self.owner = nil;&lt;br /&gt;
      self.fading = nil;&lt;br /&gt;
      self:ClearLines();&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:SetOwner(owner, anchor)&lt;br /&gt;
      self:Hide()&lt;br /&gt;
      self:ClearAllPoints();&lt;br /&gt;
      &lt;br /&gt;
      self.owner = owner;&lt;br /&gt;
      self.anchor = anchor;&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:SetX(info)&lt;br /&gt;
      if (not self.owner) then&lt;br /&gt;
          self:Hide();&lt;br /&gt;
          return;&lt;br /&gt;
      end&lt;br /&gt;
  &lt;br /&gt;
      -- Note: CheckValidity() varies slightly between SetX methods&lt;br /&gt;
      -- * Empty Bag slots are considered invalid&lt;br /&gt;
      -- * Empty Inventory are considered invalid&lt;br /&gt;
      -- * Empty Actions *are* considered valid, and therefore clear the lines of the tooltip&lt;br /&gt;
      -- details on others not researched...&lt;br /&gt;
      if (CheckValidity(info)) then&lt;br /&gt;
          self:ClearLines();&lt;br /&gt;
          FillInTooltipData(info);    -- Fill in TextLeftX and TextRightX fontstrings&lt;br /&gt;
          self.numLines = NumberOfFilledInLines();&lt;br /&gt;
          if (self.numLines &amp;gt; 0) then&lt;br /&gt;
              self:Show();&lt;br /&gt;
          end&lt;br /&gt;
      end&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:Show()&lt;br /&gt;
      if (not self.owner) then&lt;br /&gt;
          MakeTooltipNotShown();    -- Hides the tooltip, IsShown returns 0.&lt;br /&gt;
          return;&lt;br /&gt;
      end&lt;br /&gt;
      &lt;br /&gt;
      if (self.numLines &amp;gt; 0) then&lt;br /&gt;
          if (self.anchor ~= &amp;quot;ANCHOR_NONE&amp;quot;) then&lt;br /&gt;
              self:ClearAllPoints();&lt;br /&gt;
              SetPointsBasedOnAnchor(anchor);    -- Call SetPoint appropriate to the anchoring&lt;br /&gt;
          elseif (NoAnchorPointExists())    -- Check if any points have been set yet&lt;br /&gt;
              -- Note that this SetPoint with the infinite x-offset is responsible for making a tooltip&lt;br /&gt;
              -- &amp;quot;hidden&amp;quot; in the sense of not appearing on-screen, despite both IsVisible/IsShown returning 1.&lt;br /&gt;
              -- It also causes the tooltip to appear corrupt on screen if SetPoint is explicitly called on&lt;br /&gt;
              -- it with anything other than &amp;quot;TOPLEFT&amp;quot; after this, because of conflicting Points constraints.&lt;br /&gt;
              -- In all cases the tooltip&amp;#039;s fontstrings can still be read properly.&lt;br /&gt;
              self:SetPoint(&amp;quot;TOPLEFT&amp;quot;, UIParent, 1.#INF, 0);&lt;br /&gt;
          end&lt;br /&gt;
          LayoutTooltip();    -- Resize tooltip based on shown fontstrings&lt;br /&gt;
          MakeTooltipShown();    -- Shows the tooltip, IsShown returns 1&lt;br /&gt;
          self.fading = nil;&lt;br /&gt;
      else&lt;br /&gt;
          self.owner = nil;&lt;br /&gt;
          MakeTooltipNotShown();    -- Hides the tooltip, IsShown returns 0&lt;br /&gt;
      end&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:Hide()&lt;br /&gt;
      self:ClearTooltip();&lt;br /&gt;
      MakeTooltipNotShown();    -- Hides the tooltip, IsShown returns 0&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:FadeOut()&lt;br /&gt;
      self.fading = true;&lt;br /&gt;
      GraduallyStartFadingOutTooltip();&lt;br /&gt;
      if (TimeIsUp() and self.fading) then&lt;br /&gt;
          self:Hide();&lt;br /&gt;
      end&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function AppendText(text, etc)&lt;br /&gt;
      AddToFirstLine(text)    -- Appends the text to the first line&lt;br /&gt;
      self:Show()&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:AddLine(text, etc)&lt;br /&gt;
      AddExtraLine(text, etc);    -- Fills out the next TextLefti and show it&lt;br /&gt;
      self.numLines = self.numLines + 1;&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:AddDoubleLine(data)&lt;br /&gt;
      AddExtraLineLeftRight(data);    -- Fills out the next TextLefti and TextRighti and show them&lt;br /&gt;
      self.numLines = self.numLines + 1;&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:ClearLines()&lt;br /&gt;
      for i=1, MAX do&lt;br /&gt;
          tooltipTextLefti:Hide();&lt;br /&gt;
          tooltipTextLefti:SetText(nil);&lt;br /&gt;
          tooltipTextRighti:Hide();&lt;br /&gt;
      end&lt;br /&gt;
      self.numLines = 0;&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:NumLines()&lt;br /&gt;
      return self.numLines;&lt;br /&gt;
  end&lt;br /&gt;
  &lt;br /&gt;
  function tooltip:IsOwned(frame)&lt;br /&gt;
      if (frame == self.owner) then&lt;br /&gt;
          return 1;&lt;br /&gt;
      end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
[[Category: UI Technical Details]]&lt;/div&gt;</summary>
		<author><name>WoWWiki&gt;Legorol</name></author>
	</entry>
</feed>