5

I recently discovered the compose key. It's wonderful to type Compose-> and get a Unicode right-arrow (→).

I know I can add my own, but where can I find a complete chart of the defaults?


The largest list I could find is this one at freedesktop.org. However, it seems imperfect too: For example, it lists a combination ComposeFU as producing "reversed hand with middle finger extended", which—quite disappointingly—doesn't work for me…

Is there somewhere these are stored on my actual live system?

8

You can find the compose table used by your system at the same place programs do: it's a text file. To locate it, you can run something like

strace xterm -e true 2>&1 | grep -i compose

For example, the relevant lines on Debian wheezy are:

open("/home/gilles/.XCompose", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/X11/locale/compose.dir", O_RDONLY) = 5
open("/usr/share/X11/locale/en_US.UTF-8/Compose", O_RDONLY) = 5

This demonstrates several things:

  • To define your own table, put it in the file ~/.XCompose. Actually, you can override this location by setting the environment variable XCOMPOSEFILE.
  • The location of the system table is listed in /usr/share/X11/locale/compose.dir. This file can list different tables for different locales.

ComposeFU is a recent addition, the corresponding character is itself a recent addition to Unicode.

  • Dang, I forgot strace existed. Great detective work. Thank you! – Anko Oct 30 '14 at 0:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.