Well I'm positive the OnEvent handler can be set after the load process and I'm not sure what other issues you're having, but here's a suggestion for script handling:
It would be nice to see a simpler way of tying scripts to frames. Maybe have a GUI (or Waterfall category) where users can choose to set frame handlers like OnUpdate or OnEnter from a dropdown box, and then have a text box appear where they can input the script to tie to that handler. And have an "Add Event" button, which makes 2 text boxes appear, one for the event name and the other for the script tied to that event. After applying any script it is added to a list for the frame and the user can choose to add or delete from there.
Just a though. Would definitely make eePanels2 and awesome panel addon.
Edit: Very nice work so far by the way. You've managed to fix everything I thought was wrong with eePanels1 (mainly the config) and even added some new things for us to toy around with. /praise
-- Create a function to resize the eePanel when the hooked frame is resized
function THIS_Hook:OnSizeChanged(frame, ...)
THIS:SetWidth(frame:GetWidth())
THIS:SetHeight(frame:GetHeight())
end
Now that I really tested this, I noticed that this method makes the panel resize to 100% of the frame's size. Is there a way to keep the panel's defined size (which could be 90% or 120% of the frame)?
Edit: Either I'm reading this wrong or you're mistaken. I just created a new frame, registered all events to it, and set an OnEvent script handler with :SetScript from the chatbox, so it was obviously long after any addons loaded, and it worked just fine. What problem are you having setting OnEvent scripts with the frames?
It's entirely possible that I'm wrong. I didn't spend too much time messing with it. If you have an example script that works, please share it.
Quote from JaedxRapture »
It would be nice to see a simpler way of tying scripts to frames. Maybe have a GUI (or Waterfall category) where users can choose to set frame handlers like OnUpdate or OnEnter from a dropdown box, and then have a text box appear where they can input the script to tie to that handler. And have an "Add Event" button, which makes 2 text boxes appear, one for the event name and the other for the script tied to that event. After applying any script it is added to a list for the frame and the user can choose to add or delete from there.
I thought about doing that. However, there might be times you simply want to run a script once when the frame is loaded, or you want to hook into another function (like the auto-resize script).
Your parent isn't set to UIParent? If it's set to UIParent, and the width is 100%, it'll stretch across the entire screen.
To flip the gradient, simply swap the background color and gradient color (and their alphas/opacities).
I got it to work. I had the border parent'd to eePanelGuideFrame1 since that was the output when I did the getfocus macro so I changed it to eePanel1 and it all works again.
Ok so I have another problem now. I'm trying to flip the gradient and no matter what I set the background gradient color to it always comes out black.
By default, Background is Black, 100% opacity. Gradient is white(?) with 0% opacity.
If you want to switch it, put your Background at 0% (you can change the color, too, if you like - you need to do this if you don't want it fully transparent) and change the gradient to black with 100% opacity.
Ok im having some problems with gradiants with eePanel2 it seems to make one end darker than the other take a look im rebuilding my old ui to work with eePanels 2 anyone got any ideas how i can fix this?
I just noticed the thread today, wow you're getting me horny to get home and try it out.
eePanels is in my eyes one of the best addons ever made, even tho it doesn't directly have impact on your game performance, but the addons is just so open and so super customizable, which is the guy for hardcore UI designers. I love tweaking my UI, which means I'm a HUGE fan of eePanels. I never replied in the eePanel(1) thread as just expect my 'thx'-comment to get blured out in the masses of of replies - so here it goes! Thanks a lot EE, for making this amazing mod.
Also the new LUA scripting sounds amazingly nice, which is exactly what I wanted.
Edit: Either I'm reading this wrong or you're mistaken. I just created a new frame, registered all events to it, and set an OnEvent script handler with :SetScript from the chatbox, so it was obviously long after any addons loaded, and it worked just fine. What problem are you having setting OnEvent scripts with the frames?
It's entirely possible that I'm wrong. I didn't spend too much time messing with it. If you have an example script that works, please share it.
Setting the OnEvent handler, I ran this in the chat frame and had no problems. Results came up immediately.
/run f=CreateFrame("Frame");f:RegisterAllEvents();f:SetScript("OnEvent",function(event) UIErrorsFrame:AddMessage(event) end);
*I think I messed up the args on the function, I think the first arg is the frame that triggered it, so the script I used would have been (this,event), but I honestly don't remember.
Quote from Evil Elvis »
Quote from JaedxRapture »
It would be nice to see a simpler way of tying scripts to frames. Maybe have a GUI (or Waterfall category) where users can choose to set frame handlers like OnUpdate or OnEnter from a dropdown box, and then have a text box appear where they can input the script to tie to that handler. And have an "Add Event" button, which makes 2 text boxes appear, one for the event name and the other for the script tied to that event. After applying any script it is added to a list for the frame and the user can choose to add or delete from there.
I thought about doing that. However, there might be times you simply want to run a script once when the frame is loaded, or you want to hook into another function (like the auto-resize script).
Ok im having some problems with gradiants with eePanel2 it seems to make one end darker than the other take a look im rebuilding my old ui to work with eePanels 2 anyone got any ideas how i can fix this?
Back Ground Colour
R 0.329
G 0.364
B 0.552
Back Ground Gradiant Colour
R 1
G 1
B 1
Have you played with the alpha settings? Did you flip the colors correctly? (for the right panel, you need the background color set as the gradient color and the gradient color as the background color)
edit: it works exactly the same way as eePanels1 did.
Ok im having some problems with gradiants with eePanel2 it seems to make one end darker than the other take a look im rebuilding my old ui to work with eePanels 2 anyone got any ideas how i can fix this?
Back Ground Colour
R 0.329
G 0.364
B 0.552
Back Ground Gradiant Colour
R 1
G 1
B 1
Have you played with the alpha settings? Did you flip the colors correctly? (for the right panel, you need the background color set as the gradient color and the gradient color as the background color)
edit: it works exactly the same way as eePanels1 did.
did everything exactly as i did before with eePanels1 ill have a fiddle around with it in a bit again
It would be nice to see a simpler way of tying scripts to frames. Maybe have a GUI (or Waterfall category) where users can choose to set frame handlers like OnUpdate or OnEnter from a dropdown box, and then have a text box appear where they can input the script to tie to that handler. And have an "Add Event" button, which makes 2 text boxes appear, one for the event name and the other for the script tied to that event. After applying any script it is added to a list for the frame and the user can choose to add or delete from there.
Just a though. Would definitely make eePanels2 and awesome panel addon.
Edit: Very nice work so far by the way. You've managed to fix everything I thought was wrong with eePanels1 (mainly the config) and even added some new things for us to toy around with. /praise
Now that I really tested this, I noticed that this method makes the panel resize to 100% of the frame's size. Is there a way to keep the panel's defined size (which could be 90% or 120% of the frame)?
edit: lol nvm. :P
x)
It's entirely possible that I'm wrong. I didn't spend too much time messing with it. If you have an example script that works, please share it.
I thought about doing that. However, there might be times you simply want to run a script once when the frame is loaded, or you want to hook into another function (like the auto-resize script).
I got it to work. I had the border parent'd to eePanelGuideFrame1 since that was the output when I did the getfocus macro so I changed it to eePanel1 and it all works again.
Ok so I have another problem now. I'm trying to flip the gradient and no matter what I set the background gradient color to it always comes out black.
If you want to switch it, put your Background at 0% (you can change the color, too, if you like - you need to do this if you don't want it fully transparent) and change the gradient to black with 100% opacity.
2007/08/30 21:14:30-557-x1]: eePanels2\core.lua:1943: attempt to index field 'profile' (a nil value)
---
same error as i have.
Oops. Fixed.
Nice work on the updates :) Keep up ur awsome work EE!
Back Ground Colour
R 0.329
G 0.364
B 0.552
Back Ground Gradiant Colour
R 1
G 1
B 1
eePanels is in my eyes one of the best addons ever made, even tho it doesn't directly have impact on your game performance, but the addons is just so open and so super customizable, which is the guy for hardcore UI designers. I love tweaking my UI, which means I'm a HUGE fan of eePanels. I never replied in the eePanel(1) thread as just expect my 'thx'-comment to get blured out in the masses of of replies - so here it goes! Thanks a lot EE, for making this amazing mod.
Also the new LUA scripting sounds amazingly nice, which is exactly what I wanted.
Oooh, I can't wait to test it - thanks again.
Setting the OnEvent handler, I ran this in the chat frame and had no problems. Results came up immediately.
/run f=CreateFrame("Frame");f:RegisterAllEvents();f:SetScript("OnEvent",function(event) UIErrorsFrame:AddMessage(event) end);
*I think I messed up the args on the function, I think the first arg is the frame that triggered it, so the script I used would have been (this,event), but I honestly don't remember.
There is an OnLoad handler. =)
Have you played with the alpha settings? Did you flip the colors correctly? (for the right panel, you need the background color set as the gradient color and the gradient color as the background color)
edit: it works exactly the same way as eePanels1 did.
did everything exactly as i did before with eePanels1 ill have a fiddle around with it in a bit again
Try copy&pasting the right chat frames background color and gradient color to the panel.
I quit wow and then this comes out?!
God dammit!