Locale and Keyboard Layouts
The locale is all the settings related to localization, like GUI/applications language, time, currency etc. In Manjaro you can set the preferred locale settings using Manjaro Settings Manager GUI application. Sometimes, because of complicated setups and often after some user mistakes, you might not be able to have the correct settings for each user. Below you will see how you can check and set properly your configuration manually.
Keyboard layouts are treated separately from the locale configuration and are divided in GUI (Xorg) and Console, although they are controlled by one utility,
localectl(in systemd installations).
In Linux systems all locales are available for installation, they just need to be enabled and generated. The settings are configured initially system-wide, but it is possible to override them per user-session.
Check your current system settings (type in terminal)
Check which are already available for usage (generated)
Example output :
$ locale -a C el_GR.utf8 en_US.utf8 POSIX
If your locale is not listed, you must edit /etc/locale.gen and uncomment yours.
# zh_SG.UTF-8 UTF-8 # zh_TW BIG5 # zh_TW.EUC-TW EUC-TW zh_TW.UTF-8 UTF-8 # zu_ZA ISO-8859-1
You may want to uncomment all the variations of your country code "zh_TW" to use them as fallbacks for some programs they might use them. Then, generate them with this command
Now you can set the system locale with this
sudo localectl set-locale LANG=zh_TW.UTF-8
The setting is saved in the system file /etc/locale.conf.
If all preferred locale various settings consist of the same value, you only need
If there are different values, you need to add only the different than
Here is a sample
LANG=zh_TW.UTF-8 LANGUAGE=zh_TW:en_AU LC_ADDRESS=en_AU.UTF-8 LC_IDENTIFICATION=en_AU.UTF-8 LC_MEASUREMENT=en_AU.UTF-8 LC_MONETARY=en_AU.UTF-8 LC_MESSAGES=zh_TW.UTF-8 LC_NAME=en_AU.UTF-8 LC_NUMERIC=en_AU.UTF-8 LC_PAPER=en_AU.UTF-8 LC_TELEPHONE=en_AU.UTF-8 LC_TIME=en_AU.UTF-8
LANGUAGE parameter maybe read by some applications for translations. It's format is a little different than the rest. It works in a way of a fallback language list, meaning you can add more than one language code, separated by a semi-colon (
The system locale settings can be overridden for a user that wants a different setting variation, by creating (or editing if it already exists) this file
Add any user specific locale settings as bellow.
LANG=zh_TW.UTF-8 LANGUAGE=zh_TW:en_AU LC_MESSAGES=zh_TW.UTF-8 LC_CTYPE=zh_TW.UTF-8
If you need to change the basic
LANGparameter value, you need to unset LANG first. This can be gracefully done by adding in
unset LANG source /etc/profile.d/locale.sh
Special input methods
While I am not proficient on this subject, you may add/set any required (from some relevant tutorial) parameters in
$HOME/.xprofile with the export command.
export XMODIFIERS=@im=gcin export GTK_IM_MODULE=gcin export QT_IM_MODULE=gcin export XIM_MODULE=gcin
/etc/vconsole.conf holds information on your keyboard layout and the font displayed in the TTY - the physical console.
Find available fonts and keymaps for your language (example for Greek):
ls -1 /usr/share/kbd/consolefonts | grep gr ls -1 /usr/share/kbd/keymaps/i386/qwerty | grep gr
Tip (Archwiki): For European based languages written in Latin/Greek letters you can use
eurlatgrfont, it includes a broad range of Latin/Greek letter variations as well as special characters.
Here is a sample setup for danish keyboard and the Terminus font.
Non-English Keyboard Layouts
If you are using non-default settings or non-English layout for your Keyboard, use this command without
sudo, changing to your preferred layouts (check here)
localectl --no-convert set-x11-keymap us,gr pc105 , grp:alt_shift_toggle
The above example is for English-Greek standard layouts, with Alt+Shift swithing. For selecting your options use the below commands
localectl list-x11-keymap-models, list-x11-keymap-layouts, \ list-x11-keymap-variants [LAYOUT], list-x11-keymap-options
[Man-page] List available X11 keymap models, layouts, variants and options, useful for configuration with set-keymap. The command list-x11-keymap-variants optionally takes a layout parameter to limit the output to the variants suitable for the specific
An alternative command/method is this, which you may add it to a session autostart mechanism.
setxkbmap -model pc104 -layout us,gr -variant , option grp:alt_shift_toggle
man setxkbmap for detailed instructions.
Permanent user settings
A problem may happen with Suspend/Sleep (depending your session/DE), because during sleep, X stops and starts on wake up again. To avoid such issues, it may help to make the settings permanent for your user account, by adding that command in your home folder
In a real multi-user system with several user locales, this should be applied at
.xprofile), so that every new user has individual session settings.
In systems where these settings are the same for all accounts, it is sufficient to run the
localectlcommand once, which writes the settings in
Other Considerations (i.e. DM, DE...)
Manjaro Settings Manager (MSM)
MSM has a Language (Locale Settings) configuration section, which affects system-wide environment variables. It edits
/etc/locale.conf with at least (for the Greek locale)
and with any custom settings per type, selected in the Detailed Settings tab
On the above example, this is the result:
LANG=el_GR.UTF-8 LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
Plasma uses its own locale files on user session. You can easily override system settings, using the System Settings ==> Regional Settings module.
- Create your preferred language in the Language tab.
- Add more languages, if you need them.
- Set the preferred order
- Fine-tune specific settings, as well. In the Format tab, you may specify a region that matches your need for the below settings (Numbers, Time etc), and/or enable Detailed Settings, to change specific options
- Logout and login to see the changes.
Plasma creates/edits two files to adapt your custom/user settings. For the above example, this is the result:
==> ~/.config/plasma-locale-settings.sh export LC_NUMERIC=el_GR.UTF-8 export LC_TIME=el_CY.UTF-8 export LC_MONETARY=el_GR.UTF-8 export LC_MEASUREMENT=el_GR.UTF-8 export LC_COLLATE=C export LANGUAGE=el:en_US ==> ~/.config/plasma-localerc [Formats] LC_COLLATE=C LC_MEASUREMENT=el_GR.UTF-8 LC_MONETARY=el_GR.UTF-8 LC_NUMERIC=el_GR.UTF-8 LC_TIME=el_CY.UTF-8 useDetailed=true [Translations] LANGUAGE=el:en_US
Note to TLP3 members-experienced users: Please add your findings about how DMs and DEs handle locale and keyboard layout configuration here
If you have followed the above guide and still have issues, there are possibilities of other files conflicting. Xorg, GDM and Plasma may have overriden your settings. The Archlinux wiki for Locale and Keyboard Layout is alawys the more updated place to look for a solution and of course the Manjaro Forum is always the more welcoming community.
Archlinux wiki is an ultimate source of Linux related information.
Just remember that Arch is not Manjaro so please ask Manjaro questions in the Manjaro forum.
This guide was originally written at wiki.manjaro.org and extended in time.