Comment 12 for bug 1802138

Revision history for this message
In , Chris Bainbridge (chris-bainbridge) wrote :

> With the patch: 1 second delay, then a black screen
> Without the patch: black screen immediately

slock will always show a black screen but is the monitor actually turned off with DPMS - my monitor shows "Entering power save mode" when this happens and turns off the back light.

Try this: in a terminal type "xset dpms force off" and press and hold the enter key for one second before releasing it. The key press event will cause the execution of the xset command, but then the release event will wake the monitor back up. The same happens with the ctrl-alt-delete shortcut.

> Of course if you can link to others complaining about the issue

http://www.shallowsky.com/linux/x-screen-blanking.html
http://askubuntu.com/questions/38776/trigger-screensaver-off-monitor
https://wiki.archlinux.org/index.php/Display_Power_Management_Signaling
http://ubuntuforums.org/showthread.php?t=1317747&page=4
http://unix.stackexchange.com/questions/4466/screen-turns-on-automatically-xset-dpms-force-off

The explanation:

"You're using it manually from command line or xset is binded to some keyboard shortcut? On my brother laptop this command was binded to some keys and after that monitor was turned off and on again, because when he was releasing key next event was emitted. Turning it off after quick sleep solved problem: perl -e 'select(undef,undef,undef,.1)' && xset dpms force off - this perl expression do sleep for 0.1 sec."

The timeout has to be longer than the delay between a person pressing the enter key and then releasing it.