mIRC Home    About    Download    Register    News    Help

Print Thread
#80208 22/04/04 05:48 PM
Joined: Apr 2004
Posts: 7
O
oak Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
O
Joined: Apr 2004
Posts: 7
- $Window should handle hwnd's, ex.: $window(hwnd).sbtext
- there'd be a $activehwnd identifier (self-explained) and a +h flag to /window, which makes the command reffer to a hwnd instead of a window name
- the highlight (.sbcolor) should work even if the switchbar isn't shown

Why? Using hwnds is more trustable than calling them by the window name


IRCalf
#80209 22/04/04 06:38 PM
Joined: Jun 2003
Posts: 195
N
Vogon poet
Offline
Vogon poet
N
Joined: Jun 2003
Posts: 195
the major problem with that is in getting the window handle.

you use window names for the simply fact that when a window is created you cant specify a window handle but you can specify a window name.

/window @blah

In that construct theres no way to know what the window handle is as its assigned by windows (the OS) itself. You could in turn use $window(@blah).hWnd but that just seems like more work for each window opened.

For windows such as channels and query's i dont see such a large issue (maybe more so with quuery's) since hte channel windows name wont change at all.

For custom windows the name may never change or it may but thats entirely up to you and your script so if the name is at all unreliable then its pretty much your doing.

Of course you could write your own alias such as /CreateWindow that when used as an identifier returns the window handle and then another alias to loop thruogh all windows and return the name of the matching handle (for calls in other window related aliases events etc..) but i think that would just be extra steps that really isnt needed.

I like the idea however for non mIRC related windows. For example if you had a window handle to a listbox it would be nice to be able to use it in a /aline or some other list related commands. smile

P.S
alias activehwnd return $window($active).hwnd

Im not usually one for the "You can script it" excuse but in this case i dont think its all that much (a few words in remotes?)

Have Fun

Last edited by Narusegawa_Naru; 22/04/04 06:42 PM.

Have Fun smile
#80210 22/04/04 07:21 PM
Joined: Apr 2004
Posts: 7
O
oak Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
O
Joined: Apr 2004
Posts: 7
yes, there's no problem when using it in the mirc editor, those problems appears when you're handling mirc windows with dlls (and that's what im doing), btw what i did is working, but i needed to use mirc whiles, and it's laggy as hell


IRCalf
#80211 22/04/04 08:10 PM
Joined: Jun 2003
Posts: 195
N
Vogon poet
Offline
Vogon poet
N
Joined: Jun 2003
Posts: 195
oh i misunderstood you then. i thought you meant to be used inside mIRC.

I have several functions i use with my dll's for name->handle conversion and vice versa. namely HwndFromName and NameFromHwnd they will take into affect things such as /renwin and so on.

Might i ask what it is your doing perhaps i can help a bit?


Have Fun smile
#80212 22/04/04 08:23 PM
Joined: Apr 2004
Posts: 7
O
oak Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
O
Joined: Apr 2004
Posts: 7
Don't care about that, i've done everything, thanks smile
There's just one thing that f*cked me up, the .sbcolor prop doesn't work if the switchbar isn't shown, so everything i did with this is wrong and i'll need to do again and it wouldn't become perfect as i thought it could be
my work: IRCalf switchbar


IRCalf

Link Copied to Clipboard