Quantcast
WoWInterface - View Single Post - LitePanels - An art framework
View Single Post
04-13-11, 04:19 AM   #310
undert819
A Kobold Labourer
 
undert819's Avatar
Join Date: Apr 2011
Posts: 1
Hi,man. I've just get to know this Addon.And I think I'll like it.
But here's some questions I want to ask:
I used to use the code down here as a single Addon ,to creat a button that shows or hide some UIforms.(Like LUI)
Code:
local Minimaphide = CreateFrame("Button", "Minimaphide", UIParent);
Minimaphide:SetWidth(32); Minimaphide:SetHeight(32); Minimaphide:SetPoint("TOPRIGHT",0,-16);
Minimaphide:RegisterForClicks("AnyUp");
Minimaphide:SetScript("OnClick", function() MinimapButton_OnClick() end)
Minimaphide:SetTexture("interface\\AddOns\\LitePanels\\media\\buttontex.tga")
Minimaphide:SetVertexColor (1,1,1,1)
        
function MinimapButton_OnClick()
if (Minimap:IsVisible()) then
HideUIPanel(Minimap);
Minimaphide:SetAlpha(0)
else
ShowUIPanel(Minimap);
Minimaphide:SetAlpha(1)
end
end
Now ,I want to creat a whole new out look with LitePanles.
I want to know if I can add this in to layout.lua of LitePanles.
If it will do , where shall I add?

above this:
Code:
lpanels:CreateLayout("Load For All", {
......
or above this:
Code:
    {
     name = "LT_MM",parent["Minimap"]
     strata = "BACKGROUND", level = 1,
        anchor_to ["TOPRIGHT"],
        anchor_from ["TOPRIGHT"],
        x_off = 0, y_off =-16,
        width = 128, height = 128,
        bg_color = "0 0 0",
        bg_alpha [1],
        gradient = "H",
        gradient_alpha [0],
        tex_file ["interface\\AddOns\\LitePanels\\media\\MiniMap.tga"],
        mouse [true],
        },
Please help !
  Reply With Quote