Thread Tools Display Modes
04/04/14, 02:54 AM   #1
Gillymead
 
Gillymead's Avatar
Join Date: Mar 2014
Posts: 5
Smile XML - Creating and Customizing 'Frames'

Hi,

I'm completely new to creating anything with LUA and XML. I have some JavaScript/CSS/HTML experience but that's about it. Apologies if this post is in the wrong place or I've missed similar threads.

I followed the MyFirstAddon tutorial, which was quite useful, and decided I'd start trying to 'skin up' the frame for the content a bit more. Presumably the inherits="ZO_ThinBackdrop" attribute is controlling the current look/style of the frame the counter appears in, as well as mouse actions against it?

Anyway, I've been trying to do something really simple, change the colour and alpha of the background of the frame, but failing pretty miserably.

Think I tried using an attribute of centerColor="990000" or something similar to add a dark red background, but didn't seem to get anywhere. I played around with a couple of other things too.

Can anyone give me a starter for ten here?

Cheers,
Gillymead
  Reply With Quote
04/09/14, 04:55 PM   #2
jokerfwb
Join Date: Mar 2014
Posts: 8
Hey as much of a beginner as you but I have been able to get done what you were doing. You have to add open the BACKDROP attribute up and and add <AnchorFill />. Like this.
Code:
<Backdrop name="$(parent)BG"  centerColor="adadad" alpha="0.8">
            <AnchorFill />
             <Edge edgeSize="0" />
</Backdrop>
Igonore the edgeSize for some reason I am getting a background with the adadad color but it has a 5 or so pixel edge around it.
  Reply With Quote
04/09/14, 10:59 PM   #3
Mrwhitepantz
Join Date: Apr 2014
Posts: 7
Originally Posted by jokerfwb View Post
Hey as much of a beginner as you but I have been able to get done what you were doing. You have to add open the BACKDROP attribute up and and add <AnchorFill />. Like this.
Code:
<Backdrop name="$(parent)BG"  centerColor="adadad" alpha="0.8">
            <AnchorFill />
             <Edge edgeSize="0" />
</Backdrop>
Igonore the edgeSize for some reason I am getting a background with the adadad color but it has a 5 or so pixel edge around it.
Sorry to hi-jack, but by any chance do you know how to set the background to be a separate image? rather than just a color fill?
  Reply With Quote
04/09/14, 11:04 PM   #4
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 648
http://wiki.esoui.com/Controls#BackdropControl

/edit: that's how to do it in the Lua. There's a way, too, for in the XML, where you set the texture through the Center child.
http://wiki.esoui.com/UI_XML#Backdrop
  Reply With Quote

ESOUI » Developer Discussions » Lua/XML Help » XML - Creating and Customizing 'Frames'


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off