How do I set "focus follows mouse" in Ubuntu-Mate 20.04LTS?

I read several past entries about "focus follows mouse" in these pages, but I could not find an answer that helped me. Many answers are for older versions, and others are for Ubuntu flavors other than Mate. These previous answers list tools and programs to do this which I could not find in Ubuntu-Mate menus.

In had expected to be able to do this using Mate Tweak, but it does not even mention mouse focus one way or another.

Please help.


On Ubuntu MATE this option is controlled by Window Preferences MATE Control Center applet.
You can launch it using GUI or mate-window-properties command.

The option is named Select windows when the mouse moves over them:

MATE Window Preferences in Ubuntu MATE

You may also want to use two other checkboxes to get needed behavior (Unselect windows when the mouse leaves them and Raise selected windows after an interval).

The following value combinations exist:

Select… Unselect… Raise… Resulting focus mode Resulting auto-raise
[ ] disabled disabled click false
[v] [ ] [ ] sloppy false
[v] [v] [ ] mouse false
[v] [ ] [v] sloppy true
[v] [v] [v] mouse true

For details about terminology check the related mate-desktop/marco/doc/how-to-get-focus-right.txt documentation.

In short:

Focus method Invariant
click The window on top is focused
sloppy If the mouse is in a window, then it is focused; if the mouse is not in a window, then the most recently used window is focused.
mouse If the mouse is in a non-DESKTOP window, then it is focused; otherwise, the designated "no_focus_window" is focused

References:

  • mate-control-center/capplets/windows/mate-window-properties.c
  • mate-control-center/capplets/windows/window-properties.ui