Re: tk inactive and screensavers



Ralf Fassel wrote:
Tk 8.5 introduces the 'tk inactive' subcommand which according to
http://wiki.tcl.tk/20078 "This can be used to do things like
preventing a screensaver from kicking in".

Has anybody succeeded in doing so? Im my experience, when running
Xscreensaver as separate process on Linux (fvwm2 on qopensuse 10.2),
calling "tk inactive reset" does not prevent the screensaver from
activating.

The ultimate goal is to turn off the screensaver when specific events
happen, and hopefully platform-independent. Any ideas?

R'

Unfortunately Xscreensaver I don't believe uses the
libXss/MIT-SCREEN-SAVER by default that Tk uses.

"========================================================================
* First we wait until the keyboard and mouse become idle for the
specified
* amount of time. We do this in one of three different ways:
periodically
* checking with the XIdle server extension; selecting key and mouse
events
* on (nearly) all windows; or by waiting for the MIT-SCREEN-SAVER
extension
* to send us a "you are idle" event."


To quote from the xscreensaver.man:
"mitSaverExtension (class Boolean)
This resource controls whether the MIT-SCREEN-SAVER
server extension will be used to decide whether the user is idle.
However, the default for this resource is false, because even if this
extension is available, it is flaky (and it also makes the fade option
not work properly.) Use of this extension is strongly discouraged.
Support for it will probably be removed eventually."


So you're probably dealing with a case where XScreenSaver is doing its
business by waiting for input. From what I recall XScreenSaver listens
for CreateNotify events, and select ButtonPress and KeyPress input from
the entire tree of windows for every client.

Most X servers as far as I know don't have XIdle, so that's what leads
me to suspect this. I wish they would report the bugs in
MIT-SCREEN-SAVER and fix them, rather than everyone in the X community
working around bugs all the time, and propagating them.


George
.