Turn Off Monitor
Krunner Plugins
Score 71%
Description:

This simple desktop file allows you to "turn off" the monitor (put it into sleep mode) as well as turning off the backlight if you own a laptop.

To install follow these instructions:
If you want it to be an icon in a panel:
- Open the folder where you downloaded the TurnOffMonitor.desktop file
- Drag the file to the panel

If you want it to behave like a regular program that you can call from krunner (Alt+F2):
- Right click the "Application Launcher" widget (the K icon in your panel) and select "Menu Editor"
- Drag the TurnOffMonitor.desktop file to the category you choose.

If when you download the file it opens up in a new window on your browser instead of downloading to your computer, try the "Save page as..." option in your browser and save it somewhere where you can find it. Then follow the instructions above.

[size=1]If you found this useful, please vote![/size]

DigitalCookieMonster

1 year ago

For those of you that are on KDE5, here's the shell script to lock your screen and also turn off your monitors.


#!/bin/sh
loginctl lock-session

sleep 0.5
xset dpms force off



To use this, open up notepad, copy the above code and then save it as KDE5lock.sh. Pick any name you want, just make sure it has the .sh as the file extension. Give it the permission to be executed throuh Dolphin or your prefered file manager and then either put it somewhere you can easily click on, or connect it to a keybaord shortcut. (Meta+L) is my personal preference.

Report

DigitalCookieMonster

1 year ago

edit:

Use this instead, there's no .5 second delay between the screen locking and the monitor being turned off.


#!/bin/sh
sleep 0.5
loginctl lock-session
xset dpms force off

Report

TranquilWaters

6 years ago

exactly what I needed, thanks!

+1

Report

ilpianista

7 years ago

How to lock the screen too?

Report

Sciamano72

8 years ago

Simple and useful. Thanks!

Report

C

tog000

8 years ago

I'm glad you liked it :D!

Report

panzi

8 years ago

I made a similar thing. I wrote a tiny shell script:
#!/bin/sh
sleep 0.5
xset dpms force off

And assigned it to a global hotkey ("Pause"). The sleep is needed because hitting any key turns the monitor on again and without the sleep somehow the keypress for the hotkey itself turned the monitor on again.

Report

C

tog000

8 years ago

Yes, thats exactly how this works, i had almost the exact same script before and i assigned it a shortcut, just how you did it. But, from a user point of view, I think its easier to add it to the menu using the "Menu Editor" and once there you can configure a shortcut to launch it and that can be done graphically.
One could also create the shortcut directly using [i]khotkeys[i], but you should make sure the script never changes place, and i found that after every "cleanup" some things would stop working because I deleted the scripts... Adding it to the menu, moves the desktop file inside the .local folder, where its virtually impossible to accidentally delete it.
Glad you liked it, and yes, we are running the same code, different launcher :D

Report

C

tog000

8 years ago

Yes, thats exactly how this works, i had almost the exact same script before and i assigned it a shortcut, just how you did it. But, from a user point of view, I think its easier to add it to the menu using the "Menu Editor" and once there you can configure a shortcut to launch it and that can be done graphically.
One could also create the shortcut directly using khotkeys, but you should make sure the script never changes place, and i found that after every "cleanup" some things would stop working because I deleted the scripts... Adding it to the menu, moves the desktop file inside the .local folder, where its virtually impossible to accidentally delete it.
Glad you liked it, and yes, we are running the same code, different launcher :D

Report

nicovai

8 years ago

I find this a great idea. I think it would be even better if you make a plasmoid out of it, so that one can have a "Turn off
monitor" button on the desktop.

Greetings!

Report

C

tog000

8 years ago

Thanks nicovai! I'm glad you liked it!
If you want it to live on your desktop, try dragging the .desktop file to the desktop! An icon will appear (thats what I call KDE4 goodness!), that you can resize and do the same things you would to a plasmoid.
There was a "turn off screen and suspend" plasmoid that I used for a while, but it was a little obtrusive to my taste because you couldn't make it smaller than 200x100px, so I opted to use this approach.

Hope you can make it work the way you intend it.
Thanks!

Report

product-maker 6 23

File (click to download) Version Description Filetype Packagetype License Downloads Date Filesize OCS-Install DL
Details
version
1.0
updated Dec 31 2009
added Dec 31 2009
downloads today
0
page views today 0