Create panels for customizing your UI, sucessor to eePanels

Wiki and FAQ

Sample Scripts

OnClick now provides a pressed and released variable you can check for.

if pressed then
  -- do mouse down actions
elseif released then
  -- do mouse up actions

This means your script will get called twice when someone clicks the panel.

Here is a youtube link to a video Tutorial

Ive created an Example Texture Pack.

This example pack is just a template. If you want to use it as a storage spot for your art, look at the read me file for directions on usage.

You must login to post a comment. Don't have an account? Register to get one!

  • Avatar of kagaro kagaro May 05, 2012 at 19:37 UTC - 0 likes

    OnUpdate was fixed to use the variable named elsapsed in r403, the OnSizechanged was fixed in r404 and Ive tagged a new release

  • Avatar of Choonster Choonster May 05, 2012 at 15:51 UTC - 0 likes

    For those wondering what the names of the various arguments to the scripts are (like I was earlier), I've looked at the function that sets up the scripts and written them below.

    self is always the panel's frame.

    • OnEvent: self, event, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10
      • event is the name of the event that fired, arg1-arg10 are the arguments it supplied.

    • OnUpdate: self, elapsed
      • elapsed is the number of seconds since the last OnUpdate was fired.

    • OnClick: self, button
      • button is the name of the mouse button that clicked the panel. This will usually be LeftButton, RightButton or MiddleButton for the first three mouse buttons or ButtonN (where N is some number) for mouse buttons 4+.
      • pressed and released will be true or false (nil) depending on whether the script was triggered by a mouse down or mouse up hardware event. These variables are mentioned on the main page itself, but I thought I'd put them here anyway.
      • It's worth noting that this actually uses the OnMouseUp/OnMouseDown handlers of the frame (because frames don't have OnClick handlers), so it doesn't count as a hardware event for functions that require one (e.g. SetCurrentTitle)

    • OnSizeChanged: self, width, height
      • width and height are the new width/height of the panel.
      • These were previously in the wrong order, but were fixed in r404.

    • OnLoad: self, kgPanels
      • kgPanels is the AddOn's main table.

    • OnShow, OnHide, OnEnter, OnLeave and OnReceiveDrag all have self as their only argument.
    Last edited Jun 15, 2012 by Choonster: Updated with Kagaro's r403/r404 changes.
  • Avatar of kagaro kagaro Apr 14, 2012 at 21:33 UTC - 0 likes


  • Avatar of victorcillo victorcillo Apr 11, 2012 at 17:21 UTC - 0 likes

    Kagaro, you put the script for OnClick, has an error and confusion can lead people to not have much idea of ​​programming, if you can change elsif - elseif, will be better, I think I broke his brain was not working because your script when I gave him to copy - paste XD

    P. D. I hope my comment did not offend you friend

  • Avatar of victorcillo victorcillo Apr 10, 2012 at 02:01 UTC - 0 likes

    @palthis: Go

    If possible make a panel button has an effect, I've done this:


    if pressed then

    self:SetWidth(190) self:SetHeight(55)

    elseif released then

    self:SetWidth(200) self:SetHeight(60)


    Last edited Apr 10, 2012 by victorcillo
  • Avatar of victorcillo victorcillo Apr 10, 2012 at 01:56 UTC - 0 likes

    hello, my name is victor, sorry for my bad English.

    I use almost KgPanels since it was created, I have much knowledge of programming but I'm learning through Kagaro, I put a screenshot of my UI KgPanels totally made ​​by using many of the scripts present on this forum and other pages, if someone want to know as I have done any of the parts that make up that let me know by private message or just putting it here.

  • Avatar of palthis palthis Nov 22, 2011 at 06:48 UTC - 0 likes

    Is it possible to simulate a button using a panel and pressed effect?

  • Avatar of begothprincess begothprincess Nov 09, 2011 at 15:27 UTC - 0 likes

    Hi I got KG panels a long time ago and i loved the concept how ever i am not good at using photo shop. I am wondering if anyone might be able to help me create a panel. I have an img. that i want to use. Its based off the new darkmoon fair art. If you can help me do it please send me a message.

  • Avatar of HashBrownJM HashBrownJM Nov 06, 2011 at 19:03 UTC - 0 likes

    Hi all. Took a long break from WoW, finally getting back into it, and there's something I had on my old UI that I can't remember how to recreate (because it required a little bit of code in the kgPanels config menu).

    Essentially, I have three separate kgPanels that fit behind my Grid frames. One is sized for a 5-man party, one for a 10-man raid, and the other for a 25-man raid. I know there's something you can put in each of those frames's config that'll only make them show up for the appropriate party size.

    So, for example, if I'm soloing, none of them show. As soon as I enter a party, the 5-man one appears. If I join a raid, 10-man, or if it's 25, 25-man. So on and so forth.

    Does anyone know what I need to put in? It's two fields (I'll have to look up which), but it was something like scan party, then IF members are >2 and <11, show.



  • Avatar of OneWhoSighs OneWhoSighs Sep 18, 2011 at 12:38 UTC - 0 likes

    Hi, I've been using kgpanels as a border for my target unit frame. I'm currently using the script given from the sample scripts page and there appears to be a delay when I select/deselect a target. Is there a way to reduce to remove this delay? Thanks.


Date created
Sep 16, 2008
Last update
Jul 19, 2016
Development stage
  • enUS
  • frFR
  • koKR
  • zhCN
All Rights Reserved
Curse link
Reverse relationships
Recent files
  • A: r438 for 7.0.3 Jul 19, 2016
  • A: r437 for 6.2.0 Jun 23, 2015
  • A: r436 for 6.1.0 Feb 24, 2015
  • R: 1.20 for 6.0.2 Oct 24, 2014
  • R: 1.19 for 6.0.2 Oct 17, 2014