mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
This is sort of an odd request, and I don't know if it's conveniently possible. But I'd like to know if there's some way to script a sticky window to the channel window?
My idea is to have some radio boxes that's always fixed in the bottom right corner (Moved dynamically as window expands etc) (The options themselves are static) and check the radio box on each input. This would allow me to create hidden messages to higher ranks using " /msg @#Channel Message " very easily.
I can do the script itself, assuming it's possible to make a sticky window like this. I just need to know what I'm supposed to work with.
For now I'm using a menu in the channel for it, which works just fine. But if possible I'd like to upgrade it.
Cheers!


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Joined: Apr 2014
Posts: 191
B
Vogon poet
Offline
Vogon poet
B
Joined: Apr 2014
Posts: 191
To have window with radio boxes etc, you need /dialog
To make it sticky to the channel window, you need on active event.
To make it fixed in the bottom right corner, you need $window() position to manipulate it.

Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Splendid! I'll get right on that!
Thanks a bunch. I'll see if I run into any trouble along the way.


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Yeah, definitely stumbled onto some trouble.
I can not for the life in me figure out how to work with /window and $window...
Here's what I have right now
Code:
dialog Message {
  size -1 -1 65 80
  title $chr(32)
  option notheme
  radio "Ops", 1, 2 0 100 20
  radio "HalfOps", 2, 2 20 100 20
  radio "Voice", 3, 2 40 100 20
  radio "All", 4, 2 60 100 20
}

on *:dialog:Message:sclick:1-4: writeini modes.ini disq status $did($dname, $did).text
on *:dialog:Message:init:0: { did -c $dname 4 | writeini modes.ini disq status all }

on 1:ACTIVE:*: { 
  if (# == #nillen) && ($network == Rizon) { if (!$dialog(message)) { /dialog -mn message message } } 
  else { if ($dialog(message)) { /dialog -c message message } }
}
As you can see, it's not much. And what I'm getting is a small window with the options I'd like pop up each time I enter channel #nillen, this window goes to focus so I have to click the chat window once again to be able to type. And I have to move the centered dialog each time as well.
Any help with this would be greatly appreciated!


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Joined: Apr 2014
Posts: 191
B
Vogon poet
Offline
Vogon poet
B
Joined: Apr 2014
Posts: 191
To make chat windows goes to fokus, you use /window -a $active.

To make dialog windows sit nicely at the corner, you use /dialog -s name x y w h
To determine x y w h, you need $window().dx dy dw dh, $dialog().cw ch and play some math with those values to get correct position.

Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Again, thank you Blessing. I'll play around with this when I come back home on monday, hopefully I'll get it right at the first try. Thanks a lot mate! smile


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net

Link Copied to Clipboard