View Single Post
05-07-12, 04:42 PM   #3
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,336
Originally Posted by venoabyss View Post
Code:
<Button name="$parentButtonRoster" inherits="UIPanelButtonTemplate" text="Roster">
		<Anchors>
			<Anchor point="BOTTOMLEFT">
				<Offset>
					<AbsDimension x="12" y="16"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Scripts>
			<OnClick>GRShowRoster(); </OnClick>
		</Scripts>
	</Button>
I'm not seeing <Size> tags to define the width and height.

It's up to the programmer to decide which route to take when setting up buttons. XML and Lua methods are both viable. From a design standpoint, XML was made for static buttons and templates that are created on load and Lua was to offer a way to create UI objects dynamically as needed. As the Lua method is completely capable of phasing out the XML method entirely, many programmers now solely use Lua for creating these objects.
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)

Last edited by SDPhantom : 05-07-12 at 04:52 PM.
  Reply With Quote