User avatar
scruss
Posts: 3212
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Using the Compose key for special characters: a brief guide

Sat May 11, 2013 2:49 pm

I was a bit disappointed that one of the neater features you get for free with Linux is ignored in most of the tutorials and setup guides. This will not stand!

Linux (and hence Raspbian) supports a ‘Compose’ key, which allows you to type characters not on your keyboard. Simple accented characters are a bit like the old typewriter overtyping trick where you could sort-of put an umlaut over a letter u with ‘u backspace "’. On your Raspberry Pi, you can type the correct character with ‘Compose " u’ to get ‘ü’. It works in a limited way on the text console (even though raspi-config warns you that it won't) but works best under LXDE. You can type loads of accented characters (like éôłç), local characters (such as ßæðþ), currencies (£€¢), maths symbols (÷×°) and fancy punctuation (—…“”¡¿«»). There are many more.

Setting up the Compose key: In raspi-config, go to the configure_keyboard section. Wade through a few pages of options until you get to the Compose key section. Choose a key that you're otherwise not using — you might have Alt Gr, or a right-side Windows™ key, or something else. Keep the rest of the keyboard options the same, and exit raspi-config. You now have a working Compose key.

Using the Compose key: In the text console (the texty bit you see after booting), the Compose key is limited to a small selection of accented characters. Under LXDE (or whatever GUI you're using) it's fully supported pretty much everywhere.

Compose key sequences: Perhaps the clearest reference guide is GtkComposeTable - Community Ubuntu Documentation, but there are many others.

(I wrote more details here: Compose yourself, Raspberry Pi!)

Hope this helps.
 Stewart
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

Return to “Beginners”