kgPanels

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
end

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 midgetmage55 midgetmage55 Jul 19, 2009 at 06:51 UTC - 0 likes

    Yeah i spent about an hour trying everything i could think of to get them to show up in an actual panel. Eventually i just moved the files to a new folder. Opened my graphics editor and re-saved them without making any changes short of the names of the files (removed any capitalization basically) and importing them again to the addon. Not sure why but it worked.

    My only guess is there is something in my saved variables causing the issue. And being that i have roughly 20 saved layouts deleting it wasnt much of an option. Suffice to say everything is working now.

    I have a back up of my WTF folder from 3 or so days ago. I may experiment with it and see if i can track the problem down.

    Will post back if i find anything.

    "I like it when I see a flower or a tuft of grass growing through a crack in the pavement. Its so fucking heroic!" - George Carlin

  • Avatar of kagaro kagaro Jul 18, 2009 at 16:29 UTC - 0 likes

    Wierd Midgetmage55, if it shows up im the preivew then it did correctly load. Have you tried setting the background type settings i.e. None?

  • Avatar of midgetmage55 midgetmage55 Jul 18, 2009 at 04:41 UTC - 0 likes

    Running in to an oddity. I'm adding some background textures to my library and they show up on mouse over just fine. When i go to add them to a panel however nothing appears. I just get the standard panel. Changing color, opacity or anything else works as you would expect with the exception of the art not showing. It only happens to one specific set of textures. And for all versions of them. The rest of them work as intended.

    I'm certain the textures are set up properly for showing in game as i can load them in a copy of eepanels 2 i still have around for some reason.

    I made sure that im up to the current version before posting.

    Any ideas?

    EDIT: Just did a test and if i tile the image i can at least see it but as soon as i turn off tiling it disappears again.

  • Avatar of kagaro kagaro Jul 13, 2009 at 17:26 UTC - 0 likes

    try adjusting the alpha channel Schimmy

    Strawb parent teh panel to the unit frame in question and it should hide when the unit frame hides

  • Avatar of Strawb Strawb Jul 12, 2009 at 23:55 UTC - 0 likes

    I was wondering if any of you could help me.

    I need a script that will remove a backdrop for my unitframe when I have no target and show the backdrop when I have a target. I have tried a few of the commands on the sample scripts site, but I can't seem to get any of them to work. Please help me.

  • Avatar of Schimmy Schimmy Jun 09, 2009 at 17:14 UTC - 0 likes

    I am trying to create my own UI (with some help with art) and I am getting stuck. If you look at the left side of the UI you will notice that it is transparent and very dark. On the right side I have color added but it shows behind the dragon, which I am trying to avoid. I would like the free flying dragon on the left with the brightness of the dragon on the right. Is this possible? http://www.maryandjon.com/images/dragonui.gif

  • Avatar of johnsmithblu johnsmithblu Jun 08, 2009 at 10:46 UTC - 0 likes

    /print GetMouseFocus():GetName()

    DEAD USEFUL when trying to attach panels to (sorry for my lack of terminology) "things".

  • Avatar of photekk photekk Jun 03, 2009 at 01:21 UTC - 0 likes

    Could you guys help me with a simple script for kgPanels. I want to create a panel to "frame" the party name plates/portraits for when I'm in a group. I saw in your example scripts that you have this, however it isn't working for me (I copied and pasted exactly as it was posted):

    Adjusting Panels based on Raid or 5 Main party In each Panel set the OnLoad script

    self:RegisterEvent("PLAYER_ENTERING_WORLD") self:RegisterEvent("PARTY_MEMBERS_CHANGED") self:RegisterEvent("RAID_ROSTER_UPDATE")

    Then in each Panel OnEvent script:

    local pmems = GetNumPartyMembers() local rmems = GetNumRaidMembers() if (pmems < 1 and rmems < 1) or (pmems > 0 and pmems < 6 and rmems < 6) then self:Hide() else self:Show() end

    Has anyone gotten this to work? Are there any other modifications I have to use with this script for it to work - all I did was create a new panel, entered in the OnLoad and OnEvent script and tested it by entering a party - no panel :(

    Help!

  • Avatar of kagaro kagaro May 25, 2009 at 15:24 UTC - 0 likes

    to detect in your in a raid or party

    local inRaid = UnitInRaid("player")
    local inParty = UnitInParty("player")
    
    if inRaid and GetNumRaidMembers() > 9 then
       -- in 10 man raid
    elseif inRaid and GetNumRaidMembers() > 20 then
       -- in 20 man raid
    elseif inParty and GetNumPartyMembers() > 4 then
       -- in a 5 man party
    end
    

    Thats the general gist of it, the numbers to check for are up to you.

    to Check for a your pet

    local hasPet = UnitExists("pet")
    
  • Avatar of Arrowsong Arrowsong May 24, 2009 at 02:06 UTC - 0 likes

    What I'm after includes a few "variables". Somewhat difficult to explain. I use SimpleThreatMeter. I have made a set of panels to "frame" it. I cannot parent nor anchor to it. So, using scripts I would like to have the panel show during the following events.

    1. In combat + 2. In party / raid (with or without pet active) 3. Not in party / raid WITH pet active.

    and just always hide ooc. Here is what I have so far but this is lacking the party/raid check and has me somewhat baffled...

    OnLoad if select(2, UnitClass("player")) == "HUNTER" then self:RegisterEvent("PLAYER_REGEN_ENABLED") self:RegisterEvent("PLAYER_REGEN_DISABLED") end self:Hide()

    OnEvent if event == "PLAYER_REGEN_ENABLED" then self:Hide() elseif event == "PLAYER_REGEN_DISABLED" and UnitExists("pet") then self:Show() end

    Thanks for the help. Since I've been getting better at Kgpanels, I'm only loving it more and more. Thanks for the help.

    - Arrowsong

Facts

Date created
Sep 16, 2008
Category
Last update
Oct 24, 2014
Development stage
Release
Language
  • enUS
  • frFR
  • koKR
  • zhCN
License
All Rights Reserved
Curse link
kgPanels
Reverse relationships
1
Downloads
1,837,872
Recent files
  • R: 1.20 for 6.0.2 Oct 24, 2014
  • R: 1.19 for 6.0.2 Oct 17, 2014
  • A: r433 for 6.0.2 Oct 17, 2014
  • A: r432 for 6.0.2 Oct 17, 2014
  • R: 1.18 for 5.4.8 Oct 14, 2014

Authors