input method names

The set of input methods available depends on which locales have been installed and what input methods those locales provide. The name of the input method usually corresponds to the locale. For example, the Greek Input Method is named el_GR, which is the same as the locale for the Greek language spoken in Greece.

When there is more than one input method for a locale, any secondary input method is identified by a modifier that is part of the locale name. For example, the French locale, as spoken in Canada, has three input methods, the default and two alternative methods. The input method names are:

Input method name Description
fr_CA Default input method
fr_CA@im=alt Alternative input method
fr_CA.im__64 64-bit input method

The fr portion of the locale represents the language name (French), and the CA represents the territory name (Canada). The @im=alt string is the modifier portion of the locale that is used to identify the alternative input method. All modifier strings are identified by the format @im=Modifier.

Because the input method is a loadable object module, a different object is required when running in the 64-bit environment. In the 64-bit environment, the input method library automatically appends __64 to the name when searching for the input method. In the preceding example, the name of the input method would be fr_CA.im__64.

It is possible to name input methods without using the locale name. Because the libIM library does not restrict names to locale names, the calling application must ensure that the name passed to libIM can be found. However, applications should request only modifier strings of the form @im=Modifier and that the user's request be concatenated with the return string from the setlocale (LC_CTYPE,NULL) subroutine.