LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   disabling screensaver during monitor poweroff (https://www.linuxquestions.org/questions/linux-software-2/disabling-screensaver-during-monitor-poweroff-590694/)

dhaus111 10-09-2007 11:22 PM

disabling screensaver during monitor poweroff
 
Hello all. What I'm looking to do seems pretty simple, but I haven't fully accomplished my goal. I like to run the electric sheep screensaver (which is pretty sweet by the way) during brief periods of inactivity, after a while I like the monitor to completely shut off, like at night. However electric sheep doesn't need to run all night long and slowly inch my cpu towards an early demise. I binded (bound?)

Code:

xset dpms force off
as a key on my keyboard for when I want to manually turn off the monitor (I'm on a laptop by the way, with no power button). I'm not 100% sure if this is the command gnome-screensaver executes after its triggered time, but either way, electric sheep runs in the bg. Does anyone know any way to stop this from happening?

I've gotten as far as

Code:

killall gnome-screensaver && xset dpms force off
that is fine and it does the job, but obviously kills gnome-screensaver until i restart or decided to manually start it again, which I'd never remember to do, nor do I want to remember.

anybody got any suggestions? I'm sure there is some way I can use scripting to acomplish this, maybe to capture a mouse movement event to automatically restart gnome-screensaver?

Any insight would be great
thanks all

dhaus111 10-11-2007 08:17 PM

?
 
anybody.....?

matthewg42 10-11-2007 08:40 PM

Maybe you can do this via the DBUS interface? I'm a KDE user and KDE apps use DCOP for (I think) the same sort of thing. In the case of DCOP, it is possible to control KDE apps using the command-line dcop program. I am not certain, but I imagine there is a similar thing for gnome programs that support DBUS.

A short search found this document, which documents the DBUS interface for gnome-screensaver. I didn't try to read it. Good luck :)


All times are GMT -5. The time now is 05:39 PM.