<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.returnofreckoning.com/index.php?action=history&amp;feed=atom&amp;title=API%3ALabelSetTextAlign</id>
	<title>API:LabelSetTextAlign - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.returnofreckoning.com/index.php?action=history&amp;feed=atom&amp;title=API%3ALabelSetTextAlign"/>
	<link rel="alternate" type="text/html" href="https://wiki.returnofreckoning.com/index.php?title=API:LabelSetTextAlign&amp;action=history"/>
	<updated>2026-10-18T19:24:20Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.11</generator>
	<entry>
		<id>https://wiki.returnofreckoning.com/index.php?title=API:LabelSetTextAlign&amp;diff=30557&amp;oldid=prev</id>
		<title>Maintenance script: UI Lua API import (WAR 1.4.8)</title>
		<link rel="alternate" type="text/html" href="https://wiki.returnofreckoning.com/index.php?title=API:LabelSetTextAlign&amp;diff=30557&amp;oldid=prev"/>
		<updated>2026-10-16T19:46:29Z</updated>

		<summary type="html">&lt;p&gt;UI Lua API import (WAR 1.4.8)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{LuaApi|group=Label}}&lt;br /&gt;
Sets how the text in a Label is aligned.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
LabelSetTextAlign(labelName, alignment)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Arguments ==&lt;br /&gt;
;labelName : &amp;lt;code&amp;gt;string&amp;lt;/code&amp;gt; – Name of a Label window.&lt;br /&gt;
;alignment : &amp;lt;code&amp;gt;string&amp;lt;/code&amp;gt; – One of &amp;lt;code&amp;gt;&amp;quot;left&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;top&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;center&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;right&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;leftcenter&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;rightcenter&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;bottom&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;bottomleft&amp;quot;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;quot;bottomright&amp;quot;&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
Nothing.&lt;br /&gt;
&lt;br /&gt;
== Details ==&lt;br /&gt;
* The stock XML uses the same names in the &amp;lt;code&amp;gt;textalign&amp;lt;/code&amp;gt; attribute of Label elements.* Any other string raises the &amp;#039;&amp;#039;Invalid alignment type&amp;#039;&amp;#039; error and leaves the alignment unchanged.&lt;br /&gt;
* After a valid alignment is set, the label&amp;#039;s text is laid out again.&lt;br /&gt;
* The function needs at least two arguments and only reads the last two.&lt;br /&gt;
&lt;br /&gt;
== Errors ==&lt;br /&gt;
* &amp;lt;code&amp;gt;Error in function call &amp;#039;LabelSetTextAlign&amp;#039;: Window %s does not exist&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;Error in function call &amp;#039;LabelSetTextAlign&amp;#039;: Window %s is not a Label&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;Error in function call &amp;#039;LabelSetTextAlign&amp;#039;: Invalid alignment type %s in window %s&amp;lt;/code&amp;gt; (alignment string, then label name)&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
From &amp;lt;code&amp;gt;eatemplate_unitframes/source/targetunitframe.lua&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
LabelSetTextAlign (windowName..&amp;quot;TierLabel&amp;quot;, &amp;quot;rightcenter&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
From &amp;lt;code&amp;gt;ea_guildwindow/source/guildwindowtabprofile.lua&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
LabelSetTextAlign( &amp;quot;GWProfileMOTDText&amp;quot;, &amp;quot;center&amp;quot; )&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[API:LabelSetText|LabelSetText]]&lt;br /&gt;
* [[API:LabelSetWordWrap|LabelSetWordWrap]]&lt;/div&gt;</summary>
		<author><name>Maintenance script</name></author>
	</entry>
</feed>