Adding touchpad gestures (to gnome edition)

Having touchpad gestures enhances the gnome experience greatly. I think it would be nice to include them.

In gnome, it can be implemented in two ways:

  1. gnome shell extension

This option is extremely simple and works pretty okay. However, it only works in a wayland session and has very limited configuration.

  1. libinput-gestures (and gesture-manager)

This option is more complicated and has possibly more overhead, but is extremely flexible. It allows binding arbitrary commands to gestures, has more gestures than the shell extension and can be used with xorg and also outside gnome.

I think we could include one of these in the gnome profile. Not necessarily enabled, because it would be unnecessary overhead for people who don't have the hardware for it. But installed and preconfigured.

@Ste74, what do you think about this?

1 Like

maybe someone can make a tutorial (for the Wiki) ?

i am using libinput-gestures with some help i had configured it.
but the gesture-manager i dont know all the possible commands.

or is there an overview of all commands?

It let's you bind arbitrary commands, so possible commands = all Linux commands. If you mean an overview of gnome shell action commands, then the libinput-gestures default configuration file has exhaustive examples you can use with gesture-manager. Gesture-manager is just a GUI frontend to libinput-gestures

1 Like

I think this is the best approach if we continue to offer as primary Xorg version.. let me play with this.. never used the gesture and now you put me curiosity :stuck_out_tongue_winking_eye:

EDIT: @Chrysostomus how to configure this ? :thinking:

Install llibinput-gestures and gesture-manager from aur. Add your user to input group. Maybe log out and back in. Start gesture-manager. /etc/libinput-gestures.conf has some ideas you can bind to different gestures.

Here are some things I use gestures for:

Three finger swipes to left, right and up are alt+arrow keys. This lets me navigate my browser history or file manager with gestures. 3 fingers down opens the gnome shell overlay. Command is

dbus-send --session --type=method_call --dest=org.gnome.Shell /org/gnome/Shell org.gnome.Shell.Eval string:'Main.overview.toggle();'

4 finger swipes up and down switch workspaces with these commands:

_internal ws_up
_internal ws_down

4 finger swipes left and right do tab and tab+shift. These let me swap window when pressing alt and browser tabs when I press ctrl. It is not perfect, but it has worked ok.


I find 4 finger swipes hard work :smiley:

You can also use xdotool to call up predefined shorcuts e.g.

Sorry to revive an old post but to get this properly working, you'll need to add your user to the input group:

sudo usermod -aG input username

And then logout/reboot. I couldn't get this to work until I tailed journalctl.

Another tip: I have much better results using --delay 0 for xdotool when doing ctrl+alt+Up/Down mappings.

1 Like

when i input the command:
sudo usermod -aG input username

i get result:
Usage: usermod [options] LOGIN

some help please

That "username" was meant to be %username%, like vkrstev. The name of the user you want to add to the group, your username, obviously.

yes, obviously. that was not the problem. I added my self to the "input" group. that did the trick.

sudo gpasswd -a username groupname

anyway, thanx for the lightning fast reply. I appreciate it.

You're welcome. But the syntax is wrong, it should be sudo usermod -aG input vkrstev.

Thank you very much for the command; been looking for it so badly. I am a total noob here, so where can i find the command to trigger show all apps?

Google, and thou shalt receive :slightly_smiling_face:

1 Like

thanks a lot.. :sweat_smile:

Forum kindly sponsored by