Little hacks I found useful and may need to refer to again later, cos it’s all so easy to forget. Raspberry Pi stuff is in its own page.

Invert Screen Colors

(to overcome dark mode madness)

sudo apt-get install xcalib then use xcalib -i -a

Add keyboard shortcut:
Menu: open keyboard > shortcuts > custom shortcuts. Add a new shortcut (with the “+” button). The command should be “xcalib -i -a” or “/usr/bin/xcalib -i -a

Linux Mint change notifications duration

The actual time on screen for transient notifications is hardcoded on /usr/share/cinnamon/js/ui/messageTray.js. Luckily it’s a plain text javascript file so amenable to end user tweaking (after making a backup and with elevated privileges)

The hard-coded values are near the start of the file and look like this. Time is in seconds.


NOTIFICATION_TIMEOUT is the default timeout

NOTIFICATION_CRITICAL_TIMEOUT_WITH_APPLET is used if the notification is flagged by the sending app as CRITICAL and the notification applet is present. If the applet is absent critical notifications won’t timeout.

So if you wanted to tweak
Make a back up

sudo cp /usr/share/cinnamon/js/ui/messageTray.js /usr/share/cinnamon/js/ui/messageTray.js.original

Open the file with elevated privileges

xed admin:///usr/share/cinnamon/js/ui/messageTray.js

Once tweaked and saved restart Cinnamon with Ctrl-Alt-Esc

Remove lock screen and logout from Cinnamon menu

  • Make a local copy of the menu applet: cp -r /usr/share/cinnamon/applets/ ~/.local/share/cinnamon/applets
  • open the original: xed ~/.local/share/cinnamon/applets/
  • // comment out everything in //Lock screen and //Logout button all the way down to the next //
  • Save the file and close the text editor.
  • Restart Cinnamon with Ctrl-Alt-Esc.