Quantcast
LitePanels - An art framework - Page 6 - WoWInterface
Thread Tools Display Modes
11-29-09, 05:09 AM   #101
enagic
A Murloc Raider
AddOn Compiler - Click to view compilations
Join Date: Nov 2009
Posts: 4
Okay I got it down, but I really wanna avoid working on it luls.
I wanna copy your panel in the first one, but it keeps having me copying numbers. Could you post another one?
  Reply With Quote
11-29-09, 05:37 AM   #102
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by enagic View Post
I wanna copy your panel in the first one, but it keeps having me copying numbers. Could you post another one?
Edited post.
  Reply With Quote
11-29-09, 02:08 PM   #103
enagic
A Murloc Raider
AddOn Compiler - Click to view compilations
Join Date: Nov 2009
Posts: 4
Thanks, so if I wanna move it, do you have any addons that tell you the X and Y offset in-game? It might help
  Reply With Quote
11-30-09, 01:15 AM   #104
Ferous
Sheer Sense of Doom
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 863
Originally Posted by Katae View Post
I don't know of addons that that will do that, I'd like to know this as well.
Aye me too I have to move, reload, then go back to .lua move, reload :P
  Reply With Quote
11-30-09, 01:41 AM   #105
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Here's a simple macro I just wrote for the x-y coords of the cursor.

Code:
/script local x,y=GetCursorPosition() local scale=UIParent:GetEffectiveScale() print(format(" x=%d y=%d",x/scale,y/scale))
  Reply With Quote
11-30-09, 03:58 AM   #106
Lordyfrb
A Cliff Giant
AddOn Author - Click to view addons
Join Date: Apr 2008
Posts: 71
Hi just wondering if its possible to set a standand text format for all texts applied to my layout?

i.e. So when I changed the standard text formatting all my texts change.
  Reply With Quote
11-30-09, 04:08 AM   #107
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by Lordyfrb View Post
Hi just wondering if its possible to set a standand text format for all texts applied to my layout?

i.e. So when I changed the standard text formatting all my texts change.
Easy, just create variables for your font at the beginning of your layout config, ie:

Code:
local text = {
  font = "Interface\\AddOns\\Path\\to\\font.ttf",
  size = 16,
  color = "1 1 1",
  -- etc
}

-- and for your text configs:
text = { font = text.font, size = text.size, color = text.color }

Last edited by Katae : 11-30-09 at 04:28 AM. Reason: \\
  Reply With Quote
11-30-09, 04:23 AM   #108
Lordyfrb
A Cliff Giant
AddOn Author - Click to view addons
Join Date: Apr 2008
Posts: 71
Thanks for your quick reply, I'm gonna work on that now.
  Reply With Quote
11-30-09, 11:40 AM   #109
Tandurin
A Fallenroot Satyr
Join Date: Apr 2009
Posts: 25
Is there anyway I can make my panels say 1% of from the edges of the screen, with a standard issue width and height for a panel.
  Reply With Quote
11-30-09, 06:56 PM   #110
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by Tandurin View Post
Is there anyway I can make my panels say 1% of from the edges of the screen, with a standard issue width and height for a panel.
If you're anchoring to the edge of the screen, you can set your x_off or y_off to "1%" and it will move the panels 1% of your screen height/width. You can also set your panel's height or width to "98%" and that will account for the 1% on both ends.
  Reply With Quote
12-01-09, 01:14 AM   #111
Tandurin
A Fallenroot Satyr
Join Date: Apr 2009
Posts: 25
Thanks for your reply!
  Reply With Quote
12-02-09, 10:58 AM   #112
Tandurin
A Fallenroot Satyr
Join Date: Apr 2009
Posts: 25
HI there again!

I've been trying to figure out what's wrong but I can't find anything. :S But somehow the code just doesn't work.

Here's a link to what I have: http://pastebin.com/m78ff171b
  Reply With Quote
12-02-09, 11:03 AM   #113
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by Tandurin View Post
Here's a link to what I have: http://pastebin.com/m78ff171b
Fixed some things here, at the bottom.

Last edited by Katae : 12-02-09 at 11:53 AM.
  Reply With Quote
12-02-09, 11:14 AM   #114
Tandurin
A Fallenroot Satyr
Join Date: Apr 2009
Posts: 25
Wow that was fast!
Thank you very much! I'll go try it out right now.
  Reply With Quote
12-02-09, 07:15 PM   #115
Ferous
Sheer Sense of Doom
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 863
Hey there katae, I hve a question. How would I go about adding a script to a panel and having an onclick so i can click it ingame for it to do something i.e.

Code:
/script ToggleHelpFrame()
Added to the panel? Thanks in advanced and im sorry but i have no idea how to go about doing this :O

-Ferous
  Reply With Quote
12-02-09, 08:21 PM   #116
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by Ferous View Post
How would I go about adding a script to a panel and having an onclick so i can click it ingame for it to do something
Use the OnClick attribute:
Code:
OnClick = function(self, button)
    if button == "LeftButton" then
        -- do something
    elseif button == "RightButton" then
        -- do something else
    end
end
You can also check for modifiers with IsShiftKeyDown() or IsAltKeyDown().
  Reply With Quote
12-03-09, 06:48 PM   #117
Ferous
Sheer Sense of Doom
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 863
zomg i got it thanks!

Code:
{	name = "help", 
			anchor_to = "CENTER", 
			width = "20", 
			height = "20",
			bg_color = {0,0,0}, 
			OnClick = function(self, button)
				if button == "LeftButton" then
					ToggleHelpFrame()
				end
			end
		},
Its so easy lol I had put script "togglehelpframe()" but then realized its already a script... get rid of script lol thanks again >.> Im still learning.

kk having problem adding text for some reason? :O

Here is the link its kinda long didn't want to make post big

http://snipt.org/pnok

Last edited by Ferous : 12-03-09 at 06:54 PM.
  Reply With Quote
12-03-09, 08:29 PM   #118
Katae
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Jun 2007
Posts: 208
Originally Posted by Ferous View Post
kk having problem adding text for some reason? :O

Here is the link its kinda long didn't want to make post big

http://snipt.org/pnok
You missed a comma after the OnClick function
  Reply With Quote
12-03-09, 09:19 PM   #119
Ferous
Sheer Sense of Doom
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 863
oh hahah its always the little things :P

Thanks again katae
  Reply With Quote
12-04-09, 12:31 AM   #120
Ferous
Sheer Sense of Doom
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 863
Just an update to show you what I did Katae

http://i47.tinypic.com/2uxxst1.jpg

? is GM and help and ! is achievements I couldn't figure out how to toggle the QuestLogFrame >.>
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » Released AddOns » LitePanels - An art framework

Thread Tools
Display Modes

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