The Korean Solaris operating environment supports printing Korean output through the following types of printing facilities:
Line printer containing built-in Korean fonts
PostScript-based printer containing built-in scalable fonts
Any PostScript-based printer for bitmap printing
The system administrator installs printer(s) as described in the printer product documentation. Users can then print Korean text using procedures described in this chapter.
Follow the printer documentation supplied by the manufacturer for physically connecting the printer. Then use the following instructions.
For the Korean Solaris operating environment to run a line printer, the printer must recognize at least one of the appropriate code sets:
Completion code, also called Wansung (Korean EUC, based on KS C 5601)
Combination code, also called Johap (either KS C 5601-1987-3 or KS C 5601-1992-3)
N-byte code
A printer that does not support EUC needs filters that convert EUC files for printing. For example, the following command sequence tells LP, the print service, that printer lp1 accepts only Packed (the KS C 5601-1987 version of Combination code) format files.
# lpadmin -p lp1 -v /dev/ttya -I PACK # accept lp1 # enable lp1 |
The following command sequence tells LP that printer lp1 accepts only Johap (the KS C 5601-1992 version of Combination code) format files.
# lpadmin -p lp1 -v /dev/ttya -I JOHAP # accept lp1 # enable lp1 |
The above command lines also install printer lp1 on port ttya. See the lpadmin(1) man page for more information.
An lpfilter command line such as the following can be used to print files whose formats are not supported by the printer:
# lpfilter -f filter-name -F pathname |
The above command tells LP that a converter called filter-name (for example comptopack) is available through the filter description file named pathname. The content of pathname can be as follows:
Input types: simple Output types: PACK Command: comptopack |
The above filter takes default type file input and converts it to Packed format by using comptopack.
Input types: simple Output types: JOHAP Command: wansungtojohap |
The above filter takes the default type file input and converts it to Johap format using wansungtojohap.
To print an EUC file, use the following command:
system% lp euc-filename |
To print a Packed format file, use the following command:
system% lp -T PACK PACK-filename |
To print a Johap format file, use the following command:
system% lp -T JOHAP JOHAP-filename |
To print a ko.UTF-8 file to an EUC printer, type the following commands:
The first line converts the file to an EUC file. The output will be missing any characters that are not defined in EUC.
system% iconv -f ko_KR-UTF-8 -t ko_KR-euc ko.UTF-8_filename >euc-filename system% lp euc-filename |
The first line converts the file to a Johap file.
system% iconv -f ko_KR-UTF-8 -t ko_KR-johap92 ko.UTF-8_filename >johap92-filename system% lp johap92-filename |
To print Korean characters using a PostScript-based printer, a Korean Solaris software application must have the Korean Solaris xetops utility to print EUC files or xutops to print files in the ko.UTF-8 locale.
The xetops and xutops utilities produce bitmapped graphics as printed images. Korean Solaris software includes the xetops and xutops utilities so any system can print Korean text on a PostScript printer.
xetops handles files in the ko locale
xutops handles files in the ko.UTF-8 locale
Using xetops and xutops is described in Korean Solaris User's Guide, in the chapter "Korean Printing Facilities," and in the xetops(1) and xutops(1) man pages.
A typical command line for printing a file named filename containing Korean characters with xetops, would be as follows:
system% pr filename | xetops | lp |
The syntax for xutops is similar:
system% pr filename | xutops | lp |
Make filename the name of the file to print. This file can contain ASCII/English characters as well as Korean.