Switching the keyboard layout

There is currently no graphical tool to switch the keyboard layout in Xubuntu. To do this, you will need to edit the file /etc/X11/xorg.conf.

[Warning]

Be warned that this is an important file for the system and you should be careful with it. You will need administrative privileges to edit it (Cf. the section called “Root And Sudo”). It is recommended to make a backup of this file before editing it:

sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.BACKUP

Find the section that looks like this:

Section "InputDevice" Identifier "Generic Keyboard" Driver "keyboard" Option "CoreKeyboard" Option "XkbRules" "xorg" Option "XkbModel" "pc104" Option "XkbLayout" "us" EndSection

Change "us" to whatever language code you prefer. Next, type this from a terminal:

setxkbmap <language_code>

That's it.

[Tip]

If you enter more than one language code, e.g. "us,de" for US-American and German layout, you can easily switch between these two with the the XKB Layout Switcher Plugin panel plugin.