|
slvr Newbie
Joined: 14 Dec 2007 Posts: 1
|
Posted: Fri Dec 14, 2007 9:35 am
How to check if connection is active + window events |
As it's my first post - let me start with congrats for this great piece of software :)
And now a few questions...
1) Is there any possibility for a script to check if a window's connection is active or not?
2) Are more in-built events planned for CMUD? I'm interested in window-specific stuff like "window gets focus", "window is resized" etc.
3) How can you retrieve window properties, like number of lines / columns it can display etc.
Thanks for any help!
slvr |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Fri Dec 14, 2007 4:05 pm |
1. The easiest way is to use the onConnect and onDisconnect events to set a variable. The only way to do it without using those events is to check %ctime, if it has a value delay for a little over a second and see if the value has changed. The new version also allows detecting the programming icon's color state which can be used as factor.
2. I am not sure how many new events Zugg plans to provide as part of the future mapper and database rewrites. I am quite certain that windows messages are pretty much right out.
3. Take a look at all the things in the %pref function. There is some stuff there in there about window size, but I think it is in pixels. Columns displayed depends on the font and text size which actually can be changed individually on each line. |
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
|
|
|