Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

locale(1)

lp(1)

lpr(1)

xset(1X)

lpd(8)

lprsetup(8)

printcap(4)

code_page(5)

i18n_intro(5)

i18n_printing(5)

iconv_intro(5)

l10n_intro(5)

TACTIS(5)

Unicode(5)

Wototo(5)

Thai(5)  —  Macro Packages and Conventions

NAME

Thai, thai − Introduction to Thai language support

DESCRIPTION

TIS 620-2533 is the Thai national standard that defines a primary set of graphic characters for information interchange. The operating system supports this standard with coded character set (codeset), locale, device, and other kinds of system files. 

Codesets

The operating system provides the following codeset for Thai. 

TACTIS (Thai API Consortium/Thai National Standard)
The string that represents this codeset in locale and other system files is TACTIS. For more information, see the TACTIS(5)reference page. 

Locales

The operating system supports the following Thai locale for Thailand:

th_TH.TACTIS

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. 

Input Devices, Servers, and Methods

The operating system supports one Thai terminal, the VT382-T. 

The operating system supports the LK201, LK401, and PCXAL keyboards for the Thai language.  Thai characters are printed on the keys of the following models:

LK201-T
LK401-T
PCXAL-T

There are several methods used to input Thai characters. The following list briefly describes both Thai input methods and the way English characters are entered on Thai keyboards:

       •Thai Character Input

Non-graphic Thai characters and English characters map to the same set of keys.  When input mode is set to on, users can enter the Thai characters.  When input mode is set to off, users can enter English characters. 

       •Hex Input

Thai characters are entered by typing their hexadecimal code values. 

       •Special Thai Character Input

Graphic characters defined in the TIS 620-2533 standard map to certain keys on Thai keyboards and these characters are entered by pressing those keys. 

For the VT382-T terminal, Thai input mode is provided by terminal firmware. 

In the DECwindows Motif environment, Thai input methods do not require an input server to be running. However, you must load a Thai keymap before starting an application window. Use the following steps to load a keymap:

     1.Choose Keyboard from the Session Manager’s Option menu. 

     2.In the Keyboard Option dialog box, select an appropriate option for Thai. 

     3.If Thai characters are not printed on your keyboard, you can click on the Edit Keycaps... button to start a window that displays the keyboard layout. If the keys in this display do not already show characters in the selected language, move the cursor over the keys to see how characters have been mapped to your keyboard. 

There are seven Thai characters that are not included in the supported keymaps or corresponding layouts. You must enter these characters by using Hex Input or Special Thai Character Input. 

The Thai VT terminal and DECwindows Motif keymaps support locking-shift mode switching to toggle between English and Thai character input. English characters can be entered in the Mode Switch Off state and Thai characters in the Mode Switch On state. Use one of the following key sequences to toggle the Mode Switch state:

For the VT382-T terminal, press Compose
For LK201 keyboards, press Compose+Space
For LK401 keyboards, press Compose
For PCXAL keyboards, press Right Ctrl

These keys are defaults; you can change them to be other keys. 

Running DECwindows Motif Applications

X or Motif applications require non-ASCII fonts to display Thai characters.  Therefore, you must set the font path appropriately before starting an application that displays Thai characters. An application can find Thai 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 Thai 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 appropriate keymap is loaded (see the section on input devices, servers, and methods), you can use the following steps to start a Thai application:

     1.If you have not already made the desired language setting, then:

     1.Choose Language from the Option menu. 

     2.Select the Thai language that you want the application to use. 

Both of the following Thai language options are equivalent; they reflect the only codeset and locale supported for Thai:

Thai
Thai (TACTIS)

     3.Press the OK button. 

     2.Choose the application you want to start from the Application menu. 

Printers

The operating system supports the following Thai printers. The associated print filter is noted in parentheses following the printer name. 

Epson LQ1050+ (thailpof)
The Epson LQ1050+ is a 24-pin dot matrix printer.

DEClaser 1152 (dl1152wrof)
The DEClaser 1152 is a PostScript printer that uses a font-faulting technique to download fonts from the system disk.

DEClaser 5100, model LN09-HD (dl5100wrof)
The DEClaser 5100 is a PostScript printer that uses a built-in font disk.

For more information on setting up and configuring these printers, refer to the i18n_printing(5) and lprsetup(8) reference pages. 

In the desktop publishing (DTP) environment for Thai, it is necessary to implement above vowel and tonemark characters that are not defined in the TIS 620-2555 standard set of graphic characters. These supplementary characters provide the text morphing that appears in printed Thai text. 

Currently, there is no standard way to implement text morphing. Therefore, the rules used by the dl1152w and dl5100w print filters are proprietary and supported only by Thai fonts that are supplied by Digital. If your site installs Thai fonts from other vendors, be sure to verify printed output carefully before making the Thai printer queue generally available. 

To enable text morphing in printed output, specify the tm option on the −A flag of the lpr command (see lpr(1). 

Codeset Conversion

The following codeset converters are available for Thai:

       •cp874_UCS-2 (PC code-page format to UCS-2)

       •cp874_UCS-4 (PC code-page format to UCS-4)

       •cp874_UTF-8 (PC code-page format to UTF-8)

       •UCS-2_cp874 (UCS-2 to PC code-page format)

       •UCS-4_cp874 (UCS-4 to PC code-page format)

       •UTF-8_cp874 (UTF-8 to PC code-page format)

For more information about codeset converters, see the iconv_intro(5) reference page. For information on PC code pages, see code_page(5). For information on UCS-2, UCS-4, and UTF-8, see Unicode(5). 

Note

Character encoding in the TACTIS codeset is identical to character encoding in the UCS-2, UCS-4, and UTF-8 codesets. Therefore, you can use data converted from Thai code-page format to UCS-2, UCS-4, or UTF-8 when the locale setting is th_TH.TACTIS. 

SEE ALSO

Commands: locale(1), lp(1), lpr(1), xset(1X), lpd(8), lprsetup(8)

Files: printcap(4)

Others: code_page(5), i18n_intro(5), i18n_printing(5), iconv_intro(5), l10n_intro(5), TACTIS(5), Unicode(5), Wototo(5)

Writing Software for the International Market

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026