Index Click this button to go to the index for this section.


Japanese(5)

NAME

Japanese, japanese - Introduction to Japanese language support

DESCRIPTION

There are two national standards that specify the Japanese character sets used for information interchange. The JIS X0201 standard specifies a single-byte character set that consists of Roman letters and Katakana characters. The JIS X0208 standard specifies a primary set of Japanese ideographic characters. The operating system supports both standards with coded character sets (codesets), locales, device, and other kinds of system files. Codesets There are several codesets available to support Japanese. The following list describes both the codesets and the strings that represent the codesets in the names of locales, codeset converters, or both: DEC Kanji, deckanji See deckanji(5) for more information about the DEC Kanji codeset. Japanese EUC (Extended UNIX Code), eucJP See eucJP(5) for more information about the Japanese EUC codeset. Super DEC Kanji, sdeckanji See sdeckanji(5) for more information about the Super DEC Kanji codeset. Shift JIS, SJIS The Shift JIS encoding format is identical to the Microsoft code-page (cp932) format used on PC systems. Therefore, you can use codeset converters whose names contain SJIS to convert data to and from cp932 format. See shiftjis(5) for more information about the Shift JIS codeset. JIS KANJI (JIS7 or JIS8) JIS KANJI characters can be either JIS7 (representing characters in 7- bit bytes) or JIS8 (representing characters in 8-bit bytes). Depending on the kana input value, the string that represents the JIS7 codeset in a codeset converter name is either jis7, JIS7, or jiskanji7. JIS KANJI codesets are supported only for conversion operations as indicated by the following table. These codesets are not supported by locales or for direct input and output. ________________________________________________________ Codeset Codeset Conversion Terminal Code Conversion ________________________________________________________ jis7 Y Y jiskanji7 Y N jis8 N Y ________________________________________________________ See jiskanji(5) for more information about JIS KANJI codesets, stty(1) for information about terminal code conversion, and iconv_intro(5) for information about codeset conversion. ISO 2022-JP, iso2022JP The ISO 2022-JP codeset is supported only for codeset conversion. It is not supported by locales, for terminal code conversion, or for direct input and output. See ISO-2022-JP(5) for more information about the ISO 2022-JP codeset. Extended ISO 2022-JP, iso2022JPext The ISO 2022-JPext codeset (which is an extended version of ISO 2022- JP) is supported only for codeset conversion. It is not supported by locales, for terminal code conversion, or for direct input and output. See ISO-2022-JP(5) for more information about the Extended ISO 2022-JP codeset. UCS and UTF formats: UCS-2, UCS-4, ucs4, and UTF-8 These encoding formats are supported only through locales or codeset converters, not for terminal code conversion or for direct input and output. See Unicode(5) for more information about UCS-2, UCS-4, and UTF-8. Locales The following list specifies Japanese locales for Japan and the codesets they support: ja_JP.deckanji, for DEC Kanji ja_JP.eucJP, for Japanese EUC ja_JP.sdeckanji, for Super DEC Kanji ja_JP.SJIS, for Shift JIS The ja_JP.deckanji@ucs4 and ja_JP.SJIS@ucs4 locale variants also exist for applications that need to convert file data in deckanji and SJIS format to UCS-4 process code to perform certain character-classification operations. You can use the locale command (see locale(1)) to display the names of locales installed on your system. See i18n_intro(5) for information on setting locale. In a windows environment, you also need to set the session language. The way you do this depends on which windows environment you are using: · In the Common Desktop environment (CDE), use the Language menu accessed from the login window Options button. · In the DECwindows environment, use the Language Option dialog box invoked from the Session Manager's Options menu. Japanese-Specific Character Properties The Japanese locales (including the @ucs4 variants) define the following properties (or classes) for characters: ascii Characters for which the isascii() function returns a nonzero (TRUE) value english English-language characters as defined by the System V Multi- National Language Specification (MNLS) gaiji User-defined and vendor-defined characters (UDCs and VDCs) ideogram Ideographic characters as defined by the System V Multi-National Language Specification (MNLS) jdigit Digit characters as defined by JIS X0208 jhankana Katakana characters and the voiced, semivoiced, and prolonged sound marks as defined by JIS X0201 jhira Hiragana characters as defined by JIS X0208 jisx0201 All printable characters as defined by JIS X0201 jisx0201r All printable, right-hand side characters as defined by JIS X0201 jisx0208 All printable characters as defined by JIS X0208 jisx0212 All printable characters as defined by JIS X012 jkanji Kanji characters as defined by JIS X0208 and JIS X0212, the Kanji iteration mark as defined in JIS X 0208, and the Han-numeral zero as defined by JIS X0208 jkata Katakana characters as defined by JIS X0201 and JIS X0208; the voiced, semivoiced, and prolonged sound marks as defined by JIS X0208 and JIS X0201; the Katakana iteration marks as defined by JIS X0208 jparen Kana bracket characters as defined by JIS X0201 and the parentheses characters as defined by JIS X0208 jspace The space character as defined by JIS X0208 line Line-drawing characters as defined by JIS X0208 number Numbers as defined by the System V Multi-National Language Specification (MNLS) paren Parentheses and other paired symbols as defined by JIS X0201 and JIS X0208 phonogram Phonograms as defined by the System V Multi-National Language Specification (MNLS) special Special characters as defined by the System V Multi-National Language Specification (MNLS) udc User-defined characters vdc Vendor-defined characters These properties supplement the ones specified by the XSH standard. Refer to locale(4), wctype(3), and iswctype(3) for general information about how characters are assigned properties in locales and how applications test characters for supplemental properties. Keyboards, Servers, and Input Methods The operating system supports the following Japanese keyboards: LK201-AJ A Japanese version of the LK201 keyboard. LK401-AJ A Japanese version of the LK401 keyboard. LK401-JJ A Japanese version of the LK401 keyboard. This model provides JIS layout and special keys for Japanese input methods. LK401-BJ A Japanese version of the LK401 keyboard. This model provides ANSI layout and special keys for Japanese input methods. LK421-AJ A Japanese version of the LK421 keyboard. This model does not have special keys for Japanese input methods. LK421-JJ A Japanese version of the LK421 keyboard. This model provides UNIX layout and special keys for Japanese input methods. LK97W-AJ A Japanese version of the LK97W keyboard. This model has special keys for Japanese input methods. PCXAJA-JJ A Japanese version of the PC keyboard. This model has special keys for Japanese input methods. For the Motif environment, the operating system provides the dxjim input server to support Japanese input methods. Refer to the dxjim(1X) reference page for more information. You can start this input server with the following command: % /usr/bin/X11/dxjim & The input server must be running before you start the application window where you enter Japanese characters. There are two main mechanisms for entering Japanese characters: · Kana input, for entering Kana characters The Kana input mechanism is provided by the firmware of Japanese video terminals (see the Japanese Terminals section). · Input methods, for entering two-byte Kanji characters, Kana characters, letters, and symbols defined in JIS X0208. Input methods allow characters to be entered and converted to other characters. The four input methods are as follows: Romaji-to-Kanji Kana-to-Kanji Internal Code JIS Ku-ten Code In the Motif environment, you must load a Japanese key mapping table (keymap) that is appropriate for your keyboard. See keyboard(5) for information on loading a keymap. All the Japanese keyboards and keymaps support locking-shift mode switching. In other words, you can enter English characters in the Mode Switch Off state and Kana characters in the Mode Switch On state. The keys used to toggle the input mode differ according to whether you are using a Japanese VT terminal or, in the Motif environment, the keymap that has been loaded. · For Japanese VT terminals, press the Compose key · In the Motif environment: -- For LK201-J* keymaps, hold down the Compose key and press the Space bar -- For other Japanese keymaps, press the Compose, or Comp, key if there is one. Otherwise, press the right Ctrl key. These keys are defaults and can be changed by the user. For operation within a Motif environment, the operating system provides the dxjim input server, which must be started before any window where Japanese input methods are used. Use the following command to start this server: % /usr/bin/X11/dxjim & Japanese Terminals The operating system supports the VT282-J, VT382-J, and VT383-J terminals for Japanese. Running DECwindows Motif Applications X or Motif applications require non-ASCII fonts to display Japanese characters. Therefore, you must set the font path appropriately before starting an application that displays Japanese characters. An application can find Japanese fonts in either of the following directories: · /usr/i18n/lib/X11/fonts/decwin/75dpi, for low resolution display · /usr/i18n/lib/X11/fonts/decwin/100dpi, for high resolution display Before you start a Japanese application, use the following command to check the font path: % xset q If one of the directories in the preceding list is not in the font path, the following example shows how to add the directory. You can substitute 100dp for 75dpi if you want high resolution display. % xset +fp /usr/i18n/lib/X11/decwin/75dpi/ % xset fp rehash After ensuring that the font path is set correctly and that the dxjim input server is running (see the section on input devices, servers, and methods), you can use the following steps to start a Japanese application: 1. If you have not already made the desired language setting, then: a. Choose Language from the Option menu. b. Select the Japanese language that you want the application to use. The available Japanese language options reflect the different codesets supported by Japanese locales, as follows: Japanese This language option is equivalent to Japanese (EUC). Japanese (DEC Kanji) Japanese (EUC) Japanese (Super DEC Kanji) Japanese (Shift JIS) c. Press the OK button. 2. Choose the application you want to start from the Application menu. Printers The operating system supports the following Japanese printers. The associated print filter is noted in parentheses following the printer name. · Japanese dot-matrix printers LA84-J (la84of) LA86-J (la86of) LA90-J (la90of) LA280-J (la280of) · Japanese graphic line printers LA380-J (la380of) · Japanese laser printers LN03-J (ln03jaof) LN05-J (ln05jaof) · Japanese PostScript printers LN82R (ln82rof) PostScript fonts for Japanese printers are printer resident. To print Japanese text on generic PostScript printers, you can customize a print filter to convert Japanese bitmap fonts to PostScript font encoding. Refer to wwpsof(8) for more information. See i18n_printing(5) for a general discussion of printer support options.

EXAMPLES

This section shows the steps in the DECwindows environment to set up Japanese language support, start the DECterm application, display a reference page translated to Japanese, and toggle input mode to Japanese. 1. Make sure that the font path includes either the 75dpi or 100dpi directory that contains fonts for Asian languages: % xset q If neither /usr/i18n/lib/decwin/75dpi/ nor /usr/i18n/lib/decwin/75dpi/ is included in the display, add one of them to the font path. For example: % xset +fp /usr/i18n/lib/decwin/75dpi/ % xset fp rehash 2. If it is not already running, start the dxjim input server: % /usr/bin/X11/dxjim & 3. Choose Keyboard from the Option menu 4. In the the Keyboard Options dialog box, select the keymap most appropriate for your keyboard. Then click on the Apply and OK buttons. 5. Choose Language from the Option menu, select one of the Japanese language optons in the Language Options dialog box, and click on the OK button 6. Create a new DECterm window by choosing DECterm from the Application menu. 7. Display the ls(1) reference page: % man ls 8. By default, your input mode allows you to type English characters. To enter Japanese Kana characters, toggle the input mode to Japanese by pressing the Compose or right Ctrl key or (for LK201 keymaps) by holding down the Compose key while pressing the space bar.

SEE ALSO

Commands: asort(1), locale(1), lp(1), lpr(1), dxjim(1X), xset(1X), lpd(8), lprsetup(8) Files: printcap(4) Others: code_page(5), deckanji(5), eucJP(5), i18n_intro(5), i18n_printing(5), iconv_intro(5), iso2022jp(5), jiskanji(5), keyboard(5), l10n_intro(5), sdeckanji(5), shiftjis(5), Unicode(5)