Category Archives: Ubuntu & Debian

Japanese Input in Ubuntu 12.04 to 13.04

There are various ways to enable Japanese input to some degree in Ubuntu 12.04, 12.10 and 13.04*. Instead of temporarily changing the keyboard layout, the use of an input method editor (IME for short) is far more effective; changing phonetically spelt Latin characters (Rōmaji) directly into the corresponding Kana and Kanji.

Installing the relevant language and IME packages

Firstly, we need to install the required language packages for Japanese. This can be done through the Language Support utility; however, this program can be avoided entirely by installing the required packages using the following terminal command:

sudo apt-get install language-pack-ja language-pack-gnome-ja

After successful installation of the language packages, it is time to install a relevant input method editor. Anthy is a commonly-used IME for Japanese input on Unix-based systems and it conveniently works with the input method framework IBus. If the Language Support utility has been previously installed, IBus will have likely been included with it; regardless, it can be installed or updated alongside Anthy with the following terminal command:

sudo apt-get install ibus ibus-gtk anthy ibus-anthy

Configuring IBus for Japanese Anthy Input

With all the required packages installed, IBus can be started as a background daemon process; but, it also needs to be configured to use Anthy in its accompanying GUI interface. To start IBus and open the configuration window, use the command:

ibus-daemon -d && ibus-setup

When the window opens click the ‘Input Method’ tab and tick the checkbox ‘Customise active input methods.’ Select ‘Japanese -> Anthy’  on the drop-down menu, ‘Select an input method.’ Finally, click the Add button.

Next, the IBus process needs to run on each boot; this is fairly simple to resolve, either set the Ibus daemon to run on start-up – Google is your friend here – or set the IBus as the default input method using this command:


A lovely GUI will pop-up. Click OK and then a new window will ask if you want to change the current user configuration. Click Yes and select the ‘ibus’ radio button, followed by OK again. Click the OK button on the final summary window and hey presto, the configuration has been updated. At last, to start using the new configuration simply restart the computer – more advanced users can just restart their X server.

The End Result

Assuming the above is completed without a hitch, it will now be possible to swap between Japanese and the system’s standard input, on the fly, by using the Ctrl + Space shortcut. While typing in Japanese, remember to use the shortcut F7 to swap from Hiragana to Katakana. The Space bar is used to cycle through other forms, like the related Kanji.

こううん! | コウーン! | 幸運!

* This method should work for 13.04; however, it may not. I have yet to test it from a fresh install.

Mouse Keys in Ubuntu 12.04

Weirdly, on the iteration of Ubuntu numbered 12.04, someone decided to remove a few settings by default in the system settings menu. The accessibility feature, Mouse Keys, is still present under ‘System Settings -> Universal Access.’ However, without the removed options, it is no longer possible to easily change the acceleration of the mouse. Ironically, this defeats the point of having Mouse Keys as an option at all as the default values make the mouse dreadfully slow, cumbersome, and ultimately quite unusable.

How to configure the acceleration of Mouse Keys in Ubuntu 12.04

A quick way of fixing this predicament is to install the xkbset package; which allows the configuration of the XKEYBOARD extension. Open up a terminal window and type the following to install the xkbset package:

sudo apt-get install xkbset

When the above package is installed, a simple one-line command can then be used to configure the acceleration like the one below:

xkbset ma [delay] [interval] [time to max] [max speed] [curve]

For those new to command-line interfaces, the brackets need to be replaced by a numerical value – tailored to your own taste. I have recently used the following for my configuration; mess with the numbers until it best suits you.

xkbset ma 60 10 10 20 10

Final Notes

Now that you have made mouse keys usable, other accessibility options can be tweaked using the same package too. For the curious, simply use the following command to discover other helpful tweaks and features:

xkbset help