Right-click on Apple’s PowerBook and (K)Ubuntu Linux

Apple’s PowerBook built-in touchpad has no middle or right mouse button. Under Mac OS X, right-click is simulated by holding down the Control key and then clicking. However, this doesn’t work on (K)Ubuntu Linux.

Googling around, I found that, by default, the F11 key is mapped to a mouse middle-click while the F12 key is mapped to a mouse right-click.

It is also possible to change this behavior by editing /etc/sysctl.conf and mapping dev/mac_hid/mouse_button2_keycode and dev/mac_hid/mouse_button3_keycode to their corresponding key scan codes. The scan code for a key can be retrieved by running

sudo showkey

then pressing the key or keys for which the scan codes are to be printed. To exit, press Control-D.

2 Comments so far

  1. Emily on August 19th, 2006

    That’s good, yet double dutch to me! (I don’t even know single dutch!) But keep posting all these short cuts you find on the old Apple, you never know, ONE day it might come in useful!

    E x

  2. Andy on August 22nd, 2006

    Well, it’s something that I’ve been trying to replicate but failed – luckily Google comes to rescue!! I’m REALLY grow into the Mac OS X – it’s a beautiful platform and I’m actually using my Powerbook more and more than my Linux desktop!! 🙂

Leave a Reply