WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   AddOn Help/Support (https://www.wowinterface.com/forums/forumdisplay.php?f=3)
-   -   !beautycase and grid (https://www.wowinterface.com/forums/showthread.php?t=43003)

h9rst 03-10-12 04:27 PM

!beautycase and grid
 
hello,is there a way to add borders to grid with beautycase?
i always became errors...

can anyone help me?
and i have 1 question.
is there an bag addon with sorting function that i can "skin" with beautycase?



(sorry for my english,im from germany)

Phanx 03-10-12 10:53 PM

I don't know about Beautycase, but here is the code I use to add borders to Grid in my UI; since Neal based Beautycase on the border code I posted years ago anyway, it shouldn't be too hard to modify it:

Code:

local function noop() end

local function Grid_SetBackdropBorderColor(f, r, g, b, a)
        if a and a == 0 then
                f:SetBorderColor()
        else
                f:SetBorderColor(r, g, b)
        end
end

local function Grid_AddBorder(f)
        if not f.SetBorderColor then
                f:SetBorderSize(0.1)
                PhanxBorder.AddBorder(f)
                f.SetBackdropBorderColor = Grid_SetBackdropBorderColor
                f.SetBorderSize = noop
        end
end

for frame in pairs(GridFrame.registeredFrames) do
        Grid_AddBorder(_G[frame])
end

local o = GridFrame.RegisterFrame
GridFrame.RegisterFrame = function(self, f)
        o(self, f)
        Grid_AddBorder(f)
end

The "PhanxBorder.AddBorder(f)" line is the one you would need to change to call the Beautycase function that adds a border to a frame.

h9rst 03-11-12 05:30 AM

First thank you for youre reply.
i changed PhanxBorder.AddBorder(f) to CreateBorderLight(f)
but now it gave me following error "attempt to index global 'GridFrame' (a nil value)"

What i am doing wrong?

Aftermathhqt 03-11-12 05:41 AM

Quote:

Originally Posted by h9rst (Post 253645)
First thank you for youre reply.
i changed PhanxBorder.AddBorder(f) to CreateBorderLight(f)
but now it gave me following error "attempt to index global 'GridFrame' (a nil value)"

What i am doing wrong?


Put CreateBorder(frame, .....) In GridFrame.lua Line 189.

Put ColorBorder(self, color.r, color.g, color.b) In GridFrame.lua Line 609.

Put ColorBorder(self, .25, .25, .25) In GridFrame.lua 695.

h9rst 03-11-12 06:13 AM

thanks works like a charm.
but now a got anther problem.
grid dosnt show me de incoming heal layer in the health bar =X

Aftermathhqt 03-11-12 06:16 AM

Quote:

Originally Posted by h9rst (Post 253648)
thanks works like a charm.
but now a got anther problem.
grid dosnt show me de incoming heal layer in the health bar =X

no idea ;x dont use grid anymore

h9rst 03-11-12 06:25 AM

i have tryed any option but i dosnt work :D
now i did a text2 area and put there inc heal.not perfekt but better than nothing ;-)
can u advise me a good bag addon with sort function?

Phanx 03-11-12 05:17 PM

The code I posted does not require any modifications to any Grid files. You just need to run it after Grid has loaded. The simplest way to do that would be to put it in a separate addon with Grid listed as a dependency in its TOC file.

def9 03-12-12 10:05 AM

Quote:

Originally Posted by h9rst (Post 253651)
can u advise me a good bag addon with sort function?

AadiBags is my personal favorite.

h9rst 03-12-12 12:22 PM

Quote:

Originally Posted by def9 (Post 253687)
AadiBags is my personal favorite.

thanks,but now i use bagnon and skinned it.
but its not realy done,got a little problem :D

def9 03-12-12 10:32 PM

Ok to quote the Bagnon FAQ.

Bagnon works perfectly fine with other add ons such as BankStack.


All times are GMT -6. The time now is 05:04 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI