Input Japanese using UIM (English)
From ArchWiki
This page explains how to get the Japanese input to work using UIM.
Written from a system with Gnome, people using other environments may skip/adapt commands.
Contents |
[edit] Installation
[edit] Anthy
First we need to install Anthy :
# pacman -S anthy
[edit] UIM
[edit] Using pacman
Pull down the necessary things with a :
# pacman -S uim
GTK users will have to generate the immodules file :
$ gtk-query-immodules-2.0 /usr/lib/gtk-2.0/2.10.0/immodules/im-uim.so > ~/.immodules
[edit] Compiling from source
Here are the steps I followed to get it to work with Gnome using the sources from the official site :
- Get uim from the UIM download page
- Extract the files
- In the extracted files' folder do :
$ ./configure --prefix=/opt/uim $ make # make install
remove or change the prefix if you're not happy with it but then you'd need to adapt paths and commands written below
Link to uim libraries :
# echo "/opt/uim/lib" >> /etc/ld.so.conf # /sbin/ldconfig
Generate the immodules file :
$ gtk-query-immodules-2.0 /opt/uim/lib/gtk-2.0/2.10.0/immodules/im-uim.so > ~/.immodules
You might consider updating your PATH so you can run uim related applications easily, for instance :
export UIM_HOME=/opt/uim PATH=$UIM_HOME/bin:$PATH
[edit] Setting the environment variables
In your ~/.xprofile file add :
export GTK_IM_MODULE='uim' export GTK_IM_MODULE_FILE=~/.immodules export QT_IM_MODULE='uim' uim-xim & export XMODIFIERS=@im='uim'
[edit] UIM preferences
You can configure uim preferences by running :
$ uim-pref-gtk
which brings forth a GUI.
You can run uim-xim or logout/login to test your settings.
Provided everything went well you should be able to input Japanese in X.
お疲れ様です!
[edit] Useful literature
http://code.google.com/p/uim/wiki/OfficialUserDocument
http://en.wikibooks.org/wiki/Uim