How to use (the good version of) Caffeine to inhibit the screensaver when designated apps are running

Screen-savers in Linux are a pain, in my experience.

I always install Caffeine, which works great to kill the screen-saver when ever any programs I have designated are running. However, in my opinion, the latest version of Caffeine is rubbish, and so I always use this version:

It will ask if you want to save it or run it directly in Gdebi. It doesn't matter which. But, you might want to save it first so that if you ever reinstall your system, you do not have to go looking for it on the Internet again. In any event, install it with Gdebi.

After installing it, immediately open a terminal and type:

sudo apt-mark hold caffeine

This will stop UM from trying to subsequently "upgrade" Caffeine to the latest version

Following installation, you will find Caffeine in Applications/Accessories

Having once started Caffeine, it should then subsequently load automatically as an indicator at every login on your main top panel.

To use it, click on "preferences" on the indicator.

It should look like this:

You will see I already have some entries in mine. To add an entry, use the "add" button. Usually, all it requires is to type in the name of the application. However, occasionally (as with Chromium browser, for example), this does not work. In which case, with Chromium open, go to your system monitor (this can be found in Applications/System Tools/Mate System Monitor) and look for anything in the "process" tab that has "chromium" in the name of the process. If it has sub-processes, you should ideally pick the top level process. See below:

Whatever you see written there, copy this exactly in the "add" dialog in Caffeine. This should do the trick in allowing Caffeine to detect when Chromium (or any other designated process) is running. When it does detect it, Caffeine, will stop all screen-savers. When you close the designated application, Caffeine will then automatically re-allow the screen-saver to operate.


Nice write up. Thanks for sharing.

I personally find the built in applet works best for me.
with the applet lives along side all your other indicators and is a simple one click on / one click off

I like to have more control over when the screen saver kicks in / and or powers off but anyway

Right click on panel> add to panel
and pick
Inhibit Applet

Simple one click

Thanks For the right up @stevecook172001 I will add this to my notes for future endeavors.

I’d normally use caffeine as well. However, I noticed that if you have “Dim display while idle” set, caffeine doesn’t prevent the dimming. Do you have a solution for that by any chance?

So right now I’m using the inbuilt inhibit panel as well, only have this small cosmetic issue with it but else it works fine.