Posts Tagged ‘LCD’

Locking the screen, turning off the LCD backlighting

Sunday, March 8th, 2009

I just concocted a shell-script to lock the desktop and shut down the back lighting on my LCD screen. Very nice for preserving the life of flat-screens :D

#!/bin/sh
gnome-screensaver-command --lock
sleep 1
xset dpms force off

I was wholly expecting the screen to stay “dead” even after having begun using the mouse again, but it just lit up, and presented me with the password screen. Very nice!

In case it wouldn’t have, I’d have just entered the password, popped up a terminal (shortcuts for the win) and either entered xset dpms force on, or have prepared a script to do it for me. In any case, very nice. Now I just need to figure out how to bind Ctrl+Meta+l to execute that script…

Update:

And the answer came after two prayers to the great god of eternal knowledge (Google) ;D