Ubuntu – Make “super/window” as compose key in Ubuntu

keyboardkeyboard-layoutthinkpad

Somehow on my new X230t Lenovo Thinkpad, Ubuntu 13.10 only lets me have the following options as the compose key:

Right Alt, Right Ctrl, Left Alt, Right Win, Menu, Caps Lock

I really don't care for Unity's functions using Super. I would like to set this as my compose key. Is there any way to manage this?

UPDATE: This solution had been working like a charm for me, until today when Ubuntu did a fateful update. I looked at the d-conf editor for the entry below. It still shows compose:lwin as an option. But Left Window is no longer available as an option in the keyboard settings. Any suggestions? (I am using Ubuntu 14.04 now)

Best Answer

You can do this through the dconf-editor. If you do not already have it installed, you can install it with:

sudo apt-get install dconf-editor

Navigate to org >> gnome >> desktop >> input-sources

Click in the setting, xkb-options and add 'compose:lwin' inside the square brackets. The single quotes are required.

If other options are already there, the order does not matter; but separate the options with a comma: 'compose:lwin','other:option'

For those who looks for a command line solution (without installing dconf-editor) you can use:

$ dconf read /org/gnome/desktop/input-sources/xkb-options 
@as []

This will tell you the current state of the key. Now you can insert your own:

dconf write /org/gnome/desktop/input-sources/xkb-options ['compose:lwin']

This command as above worked fine for me, but @bryce reports that he needed double quotes, as in:

dconf write /org/gnome/desktop/input-sources/xkb-options "['compose:lwin']"
Related Question