KMFL Installation Instructions

Note: The numbered instructions below are largely out of date and are included here for historical reasons. The hardest part about getting KMFL working is getting SCIM up and running. Good instructions for this can be found on the SCIM site at http://www.scim-im.org/wiki/documentation. Many distros now have SCIM available. However some manual configuration is still required to get SCIM to start when X starts.

The KMFL downloads for each distro now contain installation scripts which hopefully make the installation of KMFL/SCIM easier. The scripts will check to see if a useable version of SCIM is installed and if not, install one. The scripts will also set up X to run SCIM when a user logs on and will configure SCIM to work with KFML.

Once SCIM/KMFL is up and running, keyboards can be installed by copying a compiled keyboard (*.kmfl) or the keyboard source (*.kmn) to the ~/.scim/kmfl directory (you may have to create this directory). The icon for the keyboard should be copy to ~/.scim/kmfl/icons/. There is also a kmfl keyboard management section in the scim-setup utility. Right-click on the scim tray icon and select setup. Then select the kmfl entry under the imengine section. This will list the currently installed keyboards and allow you to add and delete keyboards. Be aware that deleting a keyboard will delete the compiled keyboard file and the icon. When adding a keyboard, the compiled keyboard file and the keyboard icon must be in the same source directory. The kmfl imengine setup will copy the files to ~/.scim/kmfl/ and ~/.scim/kmfl/icons/. You will have to log out and back in again in order for the new keyboards to be loaded.

  1. Install SCIM. SCIM Files can be downloaded from http://sourceforge.net/projects/scim. Some distros may also already have SCIM available. SCIM Debs for Ubuntu Hoary can be found at http://everybody.good-day.net/~ikuya/ubuntu/5.04/.If a package is not available for your distro, then you will have to install from source until a package appropriate to your system is produced (see below for install from source). Note, kmfl-0.6 and later requires scim version 1.2.2 or later. SCIM 0.9.1 is currently shipping with SuSE 9.1 which is not compatible with the KMFL SuSE rpms.

  2. Install kmflcomp, libkmflcomp (debian only), libkmfl, and scim-kmfl_imengine

    (For SuSE 9.x ignore steps 3-6 and do step 7)

  3. Edit .bash_profile in your home directory and add the following lines:

GTK_IM_MODULE=scim

XMODIFIERS=@im=SCIM

export GTK_IM_MODULE XMODIFIERS

  1. Use the "locale" command to check your current locale settings.

Change you locale to a UTF-8 locale if you are not currently using a UTF-8 locale. Fedora Core 2 (1 too?) and SuSE 9.1 (others?) already use UTF-8 encodings so nothing additional should be required with these distro.

On Debian or Gentoo systems, add the following line to the top of .bash_profile in your home directory:

LANG=en_US.UTF-8

On Mandrake systems, edit or modify .i18n in your home directory The follow is a sample .i18n for the en_US.UTF-8 locale:

LANG=en_US.UTF-8

LC_ADDRESS=en_US.UTF-8

LC_TELEPHONE=en_US.UTF-8

LC_PAPER=en_US.UTF-8

LC_CTYPE=en_US.UTF-8

LC_MONETARY=en_US.UTF-8

LC_NUMERIC=en_US.UTF-8

LC_MEASUREMENT=en_US.UTF-8

LC_IDENTIFICATION=en_US.UTF-8

LC_TIME=en_US.UTF-8

LC_NAME=en_US.UTF-8

LC_MESSAGES=en_US.UTF-8

LC_COLLATE=en_US.UTF-8

You will have to logout and login again for the changes to take affect.

For other distros, check the documentation for instructions on setting up a UTF-8 locale.

  1. If you are not running under the en_US.UTF-8 locale, then the scim configuration needs to be modified to support your locale.

Edit /etc/scim/global and add or modify the following line

/SupportedUnicodeLocales = en_US.UTF-8,en_CA.UTF-8

en_CA.UTF-8 should be replaced with the locale under which you are running.

  1. Setup scim to autostart when starting X as follows:

create a file called "startscim" somewhere in your home directory (I would recommend ~/bin) with the following contents:

#!/bin/sh

export SCIM_PANEL_SOCKET_ADDRESS=local:/tmp/scim-panel-socket-$DISPLAY

/usr/bin/scim -d

Make the file executable with the following command (for example):

chmod 700 ~/bin/startscim

***Note the SCIM_PANEL_SOCKET_ADDRESS setting allows more than one X session to be run by a same user on a system. For example I often run a regular X session as well as a VNC session. Without the about setting, scim-panel-gtk will not run on the second session.

  1. KDE

Create a link in ~/.kde/Autostart to the file you created above. For example:

ln -s ~/bin/startscim ~/.kde/Autostart/

  1. Gnome

  1. Bring up the Sessions options.

Mandrake:

Click on "Foot/System/Configuration/Gnome/Advanced/Sessions" menu item.

Fedora:

Click on "Redhat/Preferences/Sessions" menu item.

Gentoo:

Click on "Applications/Desktop Preferences/Advanced/Sessions" menu item.

  1. Click on the "Startup Programs" tab and then click on the "Add" button.

  1. Browse to the location where you created "startscim”, click on "startscim”, click on "Ok”, and click on "Ok” again.

  1. For SuSE 9.x, ignore steps 3-6. Instead, create a .xim file in your home directory with the following contents:

    #!/bin/sh
    export GTK_IM_MODULE=scim
    export XMODIFIERS=@im=SCIM
    export SCIM_PANEL_SOCKET_ADDRESS=local:/tmp/scim-panel-socket-$DISPLAY
    /usr/bin/scim -d

  2. Log out and log back in again for the above settings to take affect.

  3. For kmfl to work with KDE/QT apps, the QT XIM input style needs to be set to "On The Spot". You can set this up with qtconfig. Run qtconfig, select the "Interface" tab, and change the XIM input style to "On The Spot".

At this point, you should be able to bring up an application, for example gedit, hit ctrl-space to turn on scim and select a keyboard.

As of kmfl-0.6 keyboards do not have to be precompiled before they are usable. Kmfl will compile the keyboards on the fly.

Home