A simple plugin for the xfce4 panel
that add's an icon to the selected panel and when clicking it enables/disables
the monitor blanking and computer suspension. This way, if the blanking is disabled, neither the screen saver neither the lock on monitor
will turn on.
It's perfect for working, watching some Youtube videos or needing the desktop fully ON regardless not inserting input.
Tested with Xubuntu 18, 20, 22 and Mint xfce 21.
Click on the panel launcher icon to set on/off the screen blinking. When clicking, the app checks the current state of the monitor blinking and reverse it. So, if it's enable, then disables it and viceversa.
All the operations are done by the finalSaver.py
script that calls differents subprocess
to enable/disable the settings via xset s
commands and xfconf-query
The icon reflects the state of the monitor:
- black moon: no-blanking, the screen saver won't turn on and the computer won't go to slee modep.
- yellow moon: blanking, the screen saver will turn on if activated and computer will go to sleep mode.
The script doesn't care if the screen saver is enabled or not, neither it's existence.
It uses xset s
commands to be compatible with every xfce4 desktopt regardless the screensaver
app or the version of xfce
.
In addition, it turns on/off the Presentation Mode
, if exists, in the Power Management to disable
it's settings. This way the computer won't turn off, go to sleep mode and so on. If the query doesn't exist (for example in Mint xfce 21), prints an error if console is activated.
Download the zip and decompress wherever. Then, run the script setup.py
. If the desktop has more than
one panel a screen will show up asking for the panel to show the icon. Once chosen, the script continues
without interaction.
The setup.py
will copy all the data to HOME/.local/share/blankonoff . This includes the code in the zip,
the icons and a .desktop
file.
To remove, use the remove menu from the panel.
- The "xset s XX" does not share the state between sessions. There is a launcher on
$HOME/.config/autostart
that callsstart.py
, checks the state and enables/disables the blanking, saving, etc. For some reason, the launcher located in$HOME/.config/autostart
should have theConsole=true
property to work properly. I don't really know why, but I guess there's something to do with thesubprocess.run()
.
Check LISCENSE.md on this repository.
The icons used are from https://www.reshot.com
- On Icon: Sligtly modified to be bigger. This is the base of the off icon too (v.1.1) https://www.reshot.com/free-svg-icons/item/moon-RA2V5ZSDFE/
- Original Off Icon (v.1.0): https://www.reshot.com/free-svg-icons/item/moon-crescent-SD4ENBAV8K/
License for the icons.