Ubuntu 8.04 Hardy Touchpad “Tap zones”

I’ll also write a little bit about using “Tap zones” in Ubuntu after installing that on my notebook. The “original” article for Fedora 9 with some more background information can be found here. By default Ubuntu already has some configuration for the touchpad in /etc/X11/xorg.conf. So we’ll just have to add a few lines. Type in a terminal:

$ gksudo gedit /etc/X11/xorg.conf

Locate the following section:

Section “InputDevice”
Identifier    “Synaptics Touchpad”
Driver        “synaptics”
Option        “SendCoreEvents”    “true”
Option        “Device”        “/dev/psaux”
Option        “Protocol”        “auto-dev”
Option        “HorizEdgeScroll”    “0”
EndSection

Add the lines with RTCornerButton and LBCornerButton to the section so you’ll get something like this:

Section “InputDevice”
Identifier    “Synaptics Touchpad”
Driver        “synaptics”
Option        “SendCoreEvents”    “true”
Option        “Device”        “/dev/psaux”
Option        “Protocol”        “auto-dev”
Option        “HorizEdgeScroll”    “0”
Option        “RTCornerButton” “6”    # right top corner
Option        “LBCornerButton” “7”    # left bottom corner

EndSection

Watch out with copy/pasting this from this blog as it might change the quotes (“) to something that’s not going to work, so retype the quotes if you notice that the quotes looks different from the other sections!

Logout and login again and change the Compiz settings using gconf-editor. Type, again in a terminal:

$ gconf-editor

Walk to /apps/compiz/general/allscreens/options. Look for minimize_window_button and set it to Button7. Also look for toggle_window_maximized_button and set it to Button6.

That’s all 🙂

Synaptics “tap zones” and Compiz window events in Fedora

In Windows it is possible to configure a Synpatics touchpad to have “tap zones”. Tap zones are the four corner areas of a touchpad. It is a nice idea to link these corners to certain (window manager) events. In case you use Compiz (the fancy 3D effect window manager) it’s not so hard to do (if you know how to edit /etc/X11/xorg.conf and know how to play with gconf-editor. I try to use default stuff as much as possible, we won’t be installing gsynaptics or enabling the insecure SHMConfig or using crazy complex Compiz configuration tools or even worse installing third party RPMs. We will be using gconf-editor though.

The basic idea is to make these corners emulate mouse buttons after which you can use the Compiz configuration (or any other window manager I assume) to link them to certain events. What I’ll be doing here is link the right top area to a toggling maximize/unmaximize of the window under the pointer and the lower bottom area for minimizing the window under the pointer.

I’m using Fedora 9, but it should also work in other distributions.

We’ll start with the dreadful /etc/X11/xorg.conf configuration changes:

Section “InputDevice”
Identifier  “Synaptics Touchpad”
Driver      “synaptics”
Option      “TapButton1” “1”    # one finger equals left click
Option      “TapButton2” “2”    # two fingers equals middle click
Option      “TapButton3” “3”    # three fingers equals right click
Option      “RTCornerButton” “6”    # right top corner
Option      “LBCornerButton” “7”    # left bottom corner
EndSection

We enable tapping, and link the RightTop area to button 6 and the LeftBottom area to button 7. We use these high numbers here as button 4 and 5 are associated with scrolling in case you have an external mouse.

InputDevice    “Synaptics TouchPad” “CorePointer”

to the “ServerLayout” section of /etc/X11/xorg.conf. So far so good, now we start with modifying the Compiz configuration. For this we need gconf-editor which unfortunately is not installed by default in Fedora.

yum install gconf-editor   # (as root)

You can run this tool from a terminal and walk to /apps/compiz/general/allscreens/options. Look for minimize_window_button and set it to Button7. Also look for toggle_window_maximized_button and set it to Button6.

Update: while you’re at it. Using a touch pad in combination with the “scale” Compiz plugin that shows all the running applications next to each other is very annoying. By moving to the top right corner it is very easy to trigger this “scale” plugin. This can be disabled in gconf-editor as well. Go to /apps/compiz/plugins/scale/allscreens/options and set initiate_edge to Disabled. In case you want to for example use the LeftTop zone of the touch pad for this you can set initiate_button to Button8 and configure LTCornerButton in /etc/X11/xorg.conf in the same way as LB and RT before.

Make sure Compiz is enabled or it might not work. In case you don’t or can’t use Compiz you might want to look into mouse button binding for Metacity or whatever other window manager you are running.

As you can all see, Linux *is* user friendly, it’s just selective about who it’s friends are. For some more great stories see the Linux Hater’s Blog.

New laptop…

I’m looking for a new laptop now that Dell refunded my money for the Vostro 1500. I found the HP/Compaq 6710b which seems interesting and is certified to run “SuSe Linux Enterprise Desktop 10”. An Intel Core 2 Duo T8100, 1x2GB DDR2, 160GB hard disk, 15.4″ 1280×800 WXGA screen, TPM chip (yeah), Fingerprint reader, Intel X3100 video, Intel 3945 wireless, card reader and a battery that lasts for 5 hours (this is nice). This week you’ll get a free “docking station” that will give a DVI port which is always useful in case you want to connect a bigger screen 🙂

It would of course be nicer to have all this with a 13″ screen for mobility reasons, but that will cost much more than a 15″ screen unfortunately. Another option would be to buy a desktop system and wait for a small UMPC like the Asus Eee PC 900, but those will probably be relatively expensive if you look at the current prices for the “old” model.