mIRC Home    About    Download    Register    News    Help

Print Thread
#139149 11/01/06 06:07 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
Quote:

/window [-abBcCdeEfg[N]hikl[N]mnoprRsvwxz] [-tN,..,N] [+bdeflLmnstx] <@name> [x y [w h]] [/command] [popup.txt] [font [size]] [iconfile [N]]


What I mean is /window [-abBcCdeEfg[N]hikl[N]mnoprRsvwxz] [-tN,..,N] [+bdeflLmnstx] <@name|wid> [x y [w h]] [/command] [popup.txt] [font [size]] [iconfile [N]]

I'll elaborate:

/window -a #chan

lets say #chan's wid is 7 ($chan(#chan).wid)

/window -a 7

Last edited by Jigsy; 11/01/06 07:46 PM.
#139150 13/01/06 12:31 AM
D
DaveC
DaveC
D
And along with it a method to get the $activewid since duplicate named windows you cant tell which one is active.

#139151 13/01/06 02:41 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
Theres always $window($scid($activecid).active).wid or $chan(#).wid ... but I like your idea :P

Last edited by Jigsy; 13/01/06 04:09 PM.
#139152 13/01/06 02:55 PM
Joined: Jan 2003
Posts: 2,125
Q
Hoopy frood
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,125
This won't work. There is only one active window each time (mirc doesn't store the last active window for each CID, which seems to be what you think $scid(N).active returns). And the problem is mainly with DCC windows, where you can have two or more windows with the same name on the same "connection": $active returns the name, so you don't know which one it is.

There is currently no way to get around this limitation, so $activewid is indeed necessary.

Last edited by qwerty; 13/01/06 02:58 PM.
#139153 13/01/06 03:49 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
What about $wid?

Quote:

$wid
Returns window id for current script.

Last edited by Jigsy; 13/01/06 04:08 PM.
#139154 13/01/06 03:54 PM
Joined: Feb 2004
Posts: 2,014
F
Hoopy frood
Hoopy frood
F
Joined: Feb 2004
Posts: 2,014
$wid only works when issuing a command from the command line (editbox)

I can't help to think that you didn't really pay attention to that thread in the Scripts & Popups forum initiated by greeny, where you even participated yourself. All of this has been covered already.

Put this in your remotes:

on *:open:=: echo -a $wid

And initiate a few times //dcc chat $me, it will always echo 1 (if you issue it in the first server window), regardless of which window you issue it from. In other words, it will echo the $wid of the server window where you issue this in.

Of course your little alias will work, you don't even need it, you can type //echo -a $wid that will work fine because as stated, you are issuing a command from that window.


#139155 13/01/06 04:18 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
I see your point ...

#139156 20/01/06 02:23 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
another nice thing would be Status Window support

/window -n #chan minimizes #chan

so /window -n Status or /window -n Network should minimize the status window.

#139157 20/01/06 02:39 PM
Joined: Feb 2004
Posts: 2,014
F
Hoopy frood
Hoopy frood
F
Joined: Feb 2004
Posts: 2,014
That already exists.

//window -n "status window"

#139158 20/01/06 03:27 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
ahhh ...

I didn't know about that blush

#139159 28/01/06 09:28 PM
Joined: Nov 2004
Posts: 823
J
Hoopy frood
Hoopy frood
J
Joined: Nov 2004
Posts: 823
$lactivewid would also be nice ...

... This is my coded version, it still has the same sort of DCC problem though so its sort of on the same lines of $activewid.

Code:
on *:active:*:{
  var %x = 0
  while (%x &lt; $scon(0)) {
    inc %x 1
    if (%x == $lactivecid) {
      scon %x
      set %lactivewid = $window($lactive).wid
    }
  }
}

alias lactivewid { return %lactivewid }

Last edited by Jigsy; 28/01/06 10:20 PM.

Link Copied to Clipboard