|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
Any way you can make "mirc" understand you resize the program? not to confuse with minimize..
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Feb 2009
Posts: 133
Vogon poet
|
Vogon poet
Joined: Feb 2009
Posts: 133 |
WorldDMT
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Do you mean having it save the size for future use, or so you have access to what size it is in a script? If you want to save the size, you can save the window position (also size) from the mIRC icon in the top left (Position > Save).
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Jan 2007
Posts: 1,156
Hoopy frood
|
Hoopy frood
Joined: Jan 2007
Posts: 1,156 |
Is there a way to tell with an identifier if mirc becomes resized?
I dont think so. You should be able to get mirc's dimensions. Cant remember the identifier. So you could save those and then check to see if they changed.
|
|
|
|
Joined: Nov 2006
Posts: 1,559
Hoopy frood
|
Hoopy frood
Joined: Nov 2006
Posts: 1,559 |
You should be able to get mirc's dimensions. Cant remember the identifier. $window(-2).w /.h $window(N/@name) Returns properties for a window.
[...]
Note: You can also get the .w and .h properties by specifying: -1 for the width and height of the screen, -2 for the main mIRC window, and -3 for the MDI window where all other windows inside mIRC are displayed. Maybe something like: ; adjust delay (= load) acc. to your need
alias startresizecheck { .timerresizecheck -om 0 20 resizecheck }
alias -l resizecheck {
if ($hget(rsc,main)) {
if ($v1 != $window(-2).w $window(-2).h) {
hadd rsc main $v2
ECHO -sgt main window resized to $v2
}
}
else hadd -m rsc main $window(-2).w $window(-2).h
}
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
Thnx Horstl! I test your code and see if i can do something with it
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
The script running ok, just got one problem from it, firefox flicker allot when i running that script, resize don't have any trigger in mirc it self? or somthing i can use to check without a running timer?
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Other than manually checking, a timer is the only way to automatically see if it was resized. If you explained why you want to know if it's resized, there may be a better method to do whatever you're trying to do.
As for FF flickering, that script shouldn't cause it to flicker from looking at it. It only checks every 20 seconds. Even if it checked every second, it shouldn't make FF flicker.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Jul 2006
Posts: 4,150
Hoopy frood
|
Hoopy frood
Joined: Jul 2006
Posts: 4,150 |
It only checks every 20 seconds. Even if it checked every second, it shouldn't make FF flicker. it's milisecond, not second, running a code every 20ms can cause a slow down on mirc, but shouldn't affect firefox
Last edited by Wims; 15/04/10 11:57 AM.
#mircscripting @ irc.swiftirc.net == the best mIRC help channel
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Sorry, missed seeing the -m. But, I agree, even in ms, it shouldn't make FF flicker, though I would have to test it to make certain.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
It moving my lagbar to the upper right corner, and i think it's when it check the lagbar the flicker appear. Moving it cos not everyone using the same resolution as me. And it also moving the lagbar if mirc is resized ..
Last edited by sparta; 15/04/10 12:46 PM.
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Try changing the timer so it's not triggered as often. 250-500 ms should be good enough.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Jul 2006
Posts: 4,150
Hoopy frood
|
Hoopy frood
Joined: Jul 2006
Posts: 4,150 |
You need to be clearer, why are you talking about firefox ? Why are you talking about a lagbar ? It seem you have a problem with your script, the code isn't related to firefox, nor to a lagbar. And I'm sure the delay in the timer isn't the problem, running this timer with a 1 ms delay is still not a problem.
#mircscripting @ irc.swiftirc.net == the best mIRC help channel
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
I'm sure his script is slow and that's why it's causing issues because it is being run so often. That's why I said to cut down how much the script is run.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
I running it every sec, and not using -m switch at all, and i dont think its slow. dialog based lagbar that show my lag, and moving if i rezize mirc, thats all it does.
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Jan 2007
Posts: 1,156
Hoopy frood
|
Hoopy frood
Joined: Jan 2007
Posts: 1,156 |
You asked for a script to tell when your mirc was resized. All it does is tell whether its resized. It doesn't resize mirc. It wouldn't do anything to your lagbar script.
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
OP
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
alias lagbar-loc {
if ($dialog(lagsbar)) {
dialog -s lagsbar $calc($window(-2).w - 180 + $window(0,1).x) $calc($window(0).y + 37) 155 -7
}
}
And when i resize mirc this litle code keep the dialog "lagsbar" in the right corner, and same goes if you using different resolution.
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
|