Unlock Multi-Touch Gestures in Xubuntu

Unlock Multi-Touch Gestures in Xubuntu

Table of Contents

One feature I’ve grown to appreciate since using macOS, elementary OS, and GNOME 4x is multi-touch gestures for switching workspaces. When I returned to Xubuntu, I encountered roadblocks that prevented my favorite feature from being added to Xfce. By disabling the Synaptics driver and installing Touchégg, you can enable Magic Trackpad support to unlock multi-touch gestures in Xubuntu.

Replacing Synaptics with libinput

Xubuntu ships with the Synaptics driver for improved laptop touchpad support. Synaptics is an X11 input driver specifically for touchpad support, but it directly interferes with libinput in Xfce. libinput is a Wayland- and X11-compatible input driver with improved touchpad support and is a key component for Touchégg. If Synaptics is present, it takes precedence over libinput, so it has to be removed to continue.

An additional benefit of removing Synaptics is that it doesn’t support the Apple Magic Trackpad 2 at all. When it’s installed, you cannot move your cursor; you can only right-click. Uninstall Synaptics to make the Magic Trackpad work in Xubuntu!

Uninstall Synaptics

Removing the driver is trivially easy. Open up a terminal and issue the following command:

sudo apt remove xserver-xorg-input-synaptics

After removing the driver, restart your system. Once you’re up and running, your touchpad should have a bit more life in it! With the Synaptics driver out of the way, libinput can take over and enable Touchégg.

Reinstall Synaptics (if needed)

If you need to reinstall the Synaptics driver for some reason, enter the following into your terminal and then reboot. Synaptics will be reinstalled, but Touchégg will not function correctly.

sudo apt install xserver-xorg-input-synaptics

Install Touchégg for Multi-Touch Gestures

Touchégg runs in the background and translates touchpad gestures into actions. Once configured, you can use three- or four-finger gestures to switch workspaces, resize or rearrange windows, or even run custom commands.

To install Touchégg on Xubuntu, follow the Ubuntu instructions below. Note that you will find touchegg in the Ubuntu repositories, but it is an older version and won’t behave as expected.

sudo add-apt-repository ppa:touchegg/stable
sudo apt update
sudo apt install touchegg

Restart your computer, and the daemon will run in the background.

Install Touché to Configure Touchégg

Touché has an easy-to-understand interface with options for Swipe, Pinch, and Tap gestures.
Touché has an easy-to-understand interface with options for Swipe, Pinch, and Tap gestures.

Touché is the desktop companion application for configuring Touchégg. It’s available on FlatHub so the next step will be to enable Flatpak on Xubuntu. We’re doing it all right here, right now.

Install Flatpak support in Xubuntu

Following the Ubuntu setup instructions on flathub.org, run the following commands in a Terminal.

# Install Flatpak
sudo apt install flatpak

# Install the GNOME Software Flatpak plugin (optional)
sudo apt install gnome-software-plugin-flatpak

# Add the Flathub repository
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

Restart your computer again, and you’ll be ready to install Flatpaks.

Install Touché from Flathub

Final step! Click the Install button on Flathub or install from the Terminal:

flatpak install flathub com.github.joseexposito.touche

Configure Your Touchpad Gestures

You’ll find Touché in the application menu. Launch it and add your global and per-application gestures! Remember that Xubuntu is configured with a single workspace, so gestures to Switch desktop will fail until you add some additional workspaces. You can do this from Xubuntu’s Workspaces settings.

From the Workspaces application, you can add however many workspaces you want. Go wild!
From the Workspaces application, you can add however many workspaces you want. Go wild!

Wrapping Up

After roughly a year’s hiatus, I’m finally getting back into Xubuntu and Xfce development. Adding the multi-touch workspace gestures makes the transition much smoother. I hope this guide is helpful for others wanting to use Xubuntu but are hesitant to use it without its modern desktop features. Look forward to more updates in the near future!

comments powered by Disqus

Related Posts

Xfce Screensaver 0.1.4 Released

Xfce Screensaver 0.1.4 Released

Xfce Screensaver 0.1.4 has been released, featuring numerous performance improvements and an improved low-power resource footprint.

Read More
MenuLibre Now Available for Ubuntu 12.10

MenuLibre Now Available for Ubuntu 12.10

Good news! MenuLibre, your favorite application menu editor, is now available for Ubuntu 12.10 “Quantal Quetzal”.

Read More
Xubuntu 18.04 "Bionic Beaver" Released

Xubuntu 18.04 "Bionic Beaver" Released

Xubuntu 18.04 LTS has been released and will be supported for three years. Check out the visual tour to see the latest updates in action.

Read More