Your Ad Here

KDE-Improve Your Lock Screen Button!

Written by Matt on February 17, 2008 – 9:36 am -

    Most Linux users will probably admit to having a “Lock Screen” button. Why? Because it is very useful to be able to slide your pointer to the top right of your screen and click a button before stepping out of the room for a few moments. Although both KDE and Gnome have an “applet” for locking the screen, creating a custom one will be more efficient. Even when you lock the screen, the monitor still stays on, and probably will for at least a few hours. By creating your own button, you can turn off your monitor and lock the screen at the exact same time! Right click one of your panels, click on Add Application to Panel–>Add Non-KDE Application. Add whatever Button title, Icon, and Description, but for the Executable, place this:

sleep 1 && xset dpms force off && kdesktop_lock -forcelock 

Posted in KDE |
View blog reactions

4 Comments to “KDE-Improve Your Lock Screen Button!”

  1. Matt Says:

    WOW, nice tip!!! Works a treat. :D

  2. Linux Guy Says:

    Hmmm…so the “sleep 1″ is there to make sure you’ve stopped moving your mouse before putting the screen to sleep. Great idea but here’s my 2-cent patch:

    kdesktop_lock -forcelock &This makes sure you can confirm that your screen locked and that it won’t fail to lock just because xset decides to have a hiccup.

  3. Linux Guy Says:

    Okay…my code got butchered…let’s try this again:

    kdesktop_lock -forcelock \&\& \{ sleep 5\; xset dpms force off\; \}

  4. Linux Guy Says:

    Just ignore the slashes above ;- )

Leave a Comment