Software applications Tips and Tricks

Multitouch Trackpads on luna

Adding multitouch gesture support to luna

Multitouch gestures are why I prefer a trackpad to a mouse. I’m constantly swiping back and forth between workspaces or swiping to move back a page in a web browser. It really makes moving around on the computer a lot easier. I take it for granted, and when I’m on a computer that doesn’t have gesture support I drive myself crazy attempting to go back in Firefox by swiping my. It’s such an ingrained habit that I do it without even thinking about it, so I try to add gesture support to a system whenever I can.

luna doesn’t come with multi-touch gesture support installed, but it can be added. There are three options: ginn, touchegg and xSwipe. Each is an application that reads your finger movements on the trackpad and translates those movements into keyboard commands. For example, you can set a four finger swipe from right to left to trigger the shortcut super+right. This allows you to change workspaces.

All three options can be installed on luna, but only ginn is available through the software center. Technically touchegg is in the software center too, but that version doesn’t work. If you want to try touchegg then you’ll have to compile it yourself. xSwipe you’ll have to install yourself, but it’s a perl script and doesn’t require any compiling. I’ve installed and configured all three, and while they all do the same thing they do it with varying degrees of success. Below you can read about all three, but if you don’t care about the differences and just want to install something that works then skip to the section on xSwipe.


Ginn looks to be the most promising. You can set up several different input types: swipes, pinches, taps and clicks. This means you can have different actions for a three finger swipe and and three finger pinch, tap and click, and you can have a whole different set of actions for four finger and five finger gestures. Plus you can set global gestures and application specific gestures, giving you different gestures in Firefox than you have in Gimp.

That’s a lot of shortcuts built into the trackpad, maybe too many. One downside to ginn is the complexity of the settings file. Its just one giant file with a bunch of code. Its fairly simple to understand, but you could spend hours getting everything just how you want it. Of course you could keep it simple, just set up a couple of gestures, but its still not an easy setup. You have to set sensitivity and if the action should trigger while you’re making the gesture or once you’re done. This is an important decision. I set up a three finger swipe to move back a page in a web browser. That has to be set to act when the gesture is finished. If it does the action while I’m doing the gesture then it will continue to repeat the action till I stop. Instead of going back one page the browser will go back two or three. It’s very inaccurate.

The problem I had with ginn was that triggering an action on finish didn’t work. It read the gesture but never triggered the action. I found a bug report on the issue, so maybe it will be fixed at some point. For now though, it isn’t a good candidate for everyday use. If you want to check it out it can be installed from the Software Center or install via the terminal with the following command.

sudo apt-get install ginn

The configuration file is /etc/ginn/wishes.xml


Touchegg can be compiled following the directions on their site. Functionally it is a lot like ginn, but only triggers actions once. This prevents accidentally going back a half dozen web pages or skipping past the workspace you wanted to switch too. Configuring it is also easier. There is a GUI available here. It does a great job of helping users set up gestures.

The issue with touchegg is it only gave me about a 60%-70% success rate at reading gestures and triggering actions. I found myself repeating gestures quite a bit. It simply wasn’t consistent enough for everyday use, but I only tested it on an Apple Magic Trackpad. Maybe it would have more success on a different trackpad.


That leaves xSwipe. Unfortunately xSwipe is limited compared to ginn or touchegg. It focuses on swiping, vertical or horizontal, and on multi-finger clicks. There is no support for pinching, rotating or tapping, and there are no application specific gestures. You can’t add as many gestures with xSwipe, but the ones you add work. Having more options is great, but having the gestures work consistently is better.

To download and extract xSwipe open the terminal and run the following command.

cd && wget && unzip && mv xSwipe-e39800f21c1c33f38c3794d367d657f355296356 xSwipe && rm

In order for it to work you need to install libx11-guitest-perl

sudo apt-get install libx11-guitest-perl

and you need to enable SHMConfig for your trackpad. If you already have a synaptics conf file then open it up and check your trackpad section for the line:

Option "SHMConfig" "on"

If you have it great. If not add it.

If you don’t already have a conf file create one via the terminal.

sudo mkdir /etc/X11/xorg.conf.d
sudo nano /etc/X11/xorg.conf.d/60-synaptics.conf

A blank document will open in the terminal. Paste in the following.

Section "InputClass"
Identifier "touchpad"
Driver "synaptics"
MatchDevicePath "/dev/input/event*"
MatchIsTouchpad "on"
Option "Protocol" "event"
Option "SHMConfig" "on"
  • ctrl+x to close nano
  • y to save changes
  • enter to verify name/location.
  • reboot

You can run xSwipe now by entering this command in terminal.

perl ~/xSwipe/

Test out swiping with four fingers or three fingers in your favorite browser. Once you’ve decided its a bit slow to respond or you want to change a gesture to a different action go back to the terminal and hit ctrl + c to quit xSwipe.

Make xSwipe more responsive

  1. Open xSwipe folder in your home folder.
  2. Open
  3. Locate “my $baseDist = 0.1;”
  4. Adjust 0.1 lower to increase xSwipe response time. Mine is set to 0.03

Configuring gestures

Open eventKey.cfg.  Look for “’pantheon’=>{“. You’ll see settings for 2, 3, 4, 5 finger swipes and edge swipes. The individual commands look something like this:

right => "LAL/LEF", # alt + left

This means when swiping right xSwipe will execute keyboard codes for alt+left. The “#alt + left” is meaningless. It just interprets the LAL/LEF to human speak. If you want to change the gesture to trigger alt+right then you’d change “LAL/LEF” to “LAL/RIG”. For a complete list of key codes used in xSwipe see here.

I changed my eventKey to:

  • 4 finger left and right swipes changes between workspaces
  • 4 finger up down and show apps/ show windows
  • 3 finger left and right is forward and back in chrome/firefox/midori
  • 3 fingers up down show guake/ minimize app (minimize requires keyboard shortcut to be set to super+h. The default command didn’t work on my system, so I just changed it.)

To use these settings open eventKey.cfg and replace the pantheon section with this one:

       press    =>    "default",
    swipe3 =>{
       right    =>     "LAL/LEF",     # alt + left
       left     =>     "LAL/RIG",     # alt + right
       down     =>     "LSK/h",       # supr + h
       up       =>     "F12",         # F12
       press    =>     "LAL/F7",      # alt + F7
       right    =>     "LSK/LEF",     # super + left
       left     =>     "LSK/RIG",     # super + right
       down     =>     "LSK/a",       # super + a
       up       =>     "LSK/w",       # super + w
       press    =>     "F12",         # F12
      right     =>     "LAL/RIG",     # alt + right
      left      =>     "LAL/LEF",     # alt + left
      down      =>     "LCT/LAL/DOW", # ctrl + alt + down
      up        =>     "LCT/LAL/UP",  # ctrl + alt + up
      press     =>     "LAL/F7",      # alt + F7
      right     =>     "LCT/TAB",     # ctrl + tab
      left      =>     "LSH/LCT/TAB", # shift + ctrl + tab
       down     =>     "LAL/F4",      # alt + F4
       up       =>     "LCT/LAL/t",   # ctrl + alt + t
       down     =>      "LAL/F4",     # alt + F4
       up       =>      "LCT/LAL/t",  # ctrl + alt + t

Now for the last thing, hiding the xSwipe folder and launching xSwipe on boot.

  1. To hide the folder simply rename it to “.xSwipe”.
  2. To launch on boot open System Settings and go to Startup Applications
  3. Click Add
  4. Use xSwipe for the name and comment.
  5. Use “perl /home/user_name/.xSwipe/” for the command.

*Be sure to change “user_name” to your user name.

On your next reboot xSwipe will load in the background. If you use a bluetooth trackpad you’ll want to make sure it activates before you log in. xSwipe doesn’t work if your tackpad connects after xSwipe is launched.

About the author


1 Comment

Click here to post a comment


January 2022

Recent Posts

RSS Windows Process

  • Samsung Galaxy Note 7 June 20, 2016
    Samsung Galaxy Note 7   Samsung’s camp is abuzz with activity, with the imminent launch of the next-generation Samsung Galaxy Note to be just a few months away. There is much exciting news going around the internet that the anticipated Galaxy Note 7 is poised to change possibly the smartphone game and bring it to […]
  • LG G5 Specifications And Features March 19, 2016
    LG G5 Specifications And Features We’re at last seeing a genuinely premium LG leader, which is a pleasant change from plastic the organization typically utilizes, and less said in regards to that cowhide upheld LG G4 which is the better. It gauges 149.4 x 73.9 x 7.7mm, keeping in mind this telephone won’t be bended […]
  • Phantom 4 March 13, 2016
    5 Upgrades In Phantom 4 That Will Rock Your Flying Experience Today there are more than 7000 drones. But nothing has caught the attention of filmmakers and videographers like the phantom 4. Phantom 4 is an improvement of phantom 3. And it has cool features that will make you have nice experience in the skyline. […]
  • Huawei P9 Specs And Review March 5, 2016
    Huawei P9 Specs And Review Smartphones are no two ways about it what every present individual needs. This is a direct result of the limits that they can regulate making it less requesting despite for associations to be run right from the handsets. There are unmistakable brands offering phones with varied value. Huawei is one […]
  • The New Search Engine Optimization 2016 March 1, 2016
    The New Search Engine Optimization 2016 With another year behind us and a begin to a new year, companies are taking a gander at what is the best Search Engine Optimization SEO they can use to accomplish results in 2016. 2016 certifications to be very much an overwhelming time as far as search engine optimization […]
  • How to Dual Boot Windows 10 alongside Windows 8 February 25, 2016
    How to Dual Boot Windows 10 alongside Windows 8 Microsoft succeeded in making a colossal interest for their new working framework. It without a doubt is inventive, element rich and exquisite than each other ancestor. Haven’t you moved up to Windows 10 yet? We all realize that new form of anything is superior to anything […]
  • Mobile World Congress 2016 February 25, 2016
    Mobile World Congress 2016 Mobile World Congress, or MWC to its companions, is the biggest portable exchange show of the year. It’s the place we’ve seen a portion of the greatest handset dispatches in the course of recent years and 2016 has been the same. The show began with a blast, with a major Sunday […]
  • iPhone 7 Release Date: News And Rumors About Features And Specs February 20, 2016
    iPhone 7 Release Date: News And Rumors About Features And Specs Glancing back at Apple’s conventions in revealing new iPhone models, the iPhone 7 is most likely set to discharge in the fall this year. The past adaptations, iPhone 6s and 6s Plus, appeared on September 9 a year ago and hit stores on September […]
  • Google Seo Tools Help To Optimize Your Website February 19, 2016
    Google Seo Tools Help To Optimize Your Website   1- Google Search First SEO tool that is not others it’s Google Search Engine the reason more then other tools it shows lot of things like Competitors of our targeted Keyword. We can Find out What are the things that can make our Web Page Getting […]
  • Website Ranking 40 February 18, 2016
    Website Ranking Website Ranking is used by Google and all other search engines to display it’s search results for each search query. We know rank is the only way to sort out huge amount of data depends upon some priority. So, Each and every search engines are used some own algorithms, ranking factors and formulas […]