0

On a tablet running 19.04, the keyboard backlight automatically turns off after a period of inactivity. I'd like to have that same function on my desktop.

The following script allows me to manually control the backlight:

xset led on
gsettings set org.gnome.desktop.a11y.keyboard mousekeys-enable true
sleep 1
gsettings set org.gnome.desktop.a11y.keyboard mousekeys-enable false

This turns the backlight on, then due to a bug with Ubuntu caused by running the xset command, I have to enable, then disable Mouse Keys to prevent the numpad from running as a mouse emulator. An identical script would need to be run to turn the backlight off, with the only difference being xset led off.

What I'd like to do is to take this script, and have it run after a certain period of inactivity. Is there an existing function running in the background that I could add such a script so? If not, what would be the simplest way to create something that achieves the desired results?

hiigaran
  • 6,843

0 Answers0