Chinese System FAQ

by Jean Zhou
Last updated: 9/26/98


  1. How to use Chinese System on Owlnet
    1. Get an Owlnet account
    2. Subscribe to RCSC listserv
    3. Register rcssc
  2. What programs are available?
    1. Viewing
      1. Viewing Chinese on Netscape
      2. Viewing news on tin / viewing documents on gopher
      3. Viewing documents using ChiRk
    2. Editing
      1. Chpower
      2. CXterm
      3. Cvi
    3. Printing
      1. Cnprint
      2. Using gb2ps
      3. Using chpower
    4. Font conversion
    5. Summary of programs
  3. Why does ___ not work?
    1. Why does Chinese files show gibberish?
    2. Why does cnprint not printing my file?
    3. Why does cxterm say "method not found"?
    4. Why does cxterm/chpower has so few inputting methods?
    5. Why does Netscape/gopher/tin shows gibberish?
    6. Why does cxtermb5, cxtermjis, cxtermks not working?
    7. Why does PINE not allowing me to edit Chinese email?
    8. Why is my question not in this guide?
  4. How do I ___? (Advanced questions)
    1. How do I setup Chinese System on my machine
      1. Get Chinese programs
      2. Get Chinese fonts
    2. How do I setup Chinese System on my PC/Mac?
    3. How do I change the current rcssc setup?
    4. How do I get to know more about the programs?
    5. How do I get to know more about inputting methods?
    6. How do I get more programs?
    7. How do I get more fonts?
  5. Miscellaneous
    1. Notes on maintaining RCSSC Owlnet Chinese System
    2. Other Programs on the Net
    3. Chinese/Japanese/Korean (CJK) Support Notes


  1. How to use Chinese System on Owlnet.
    1. Get an Owlnet account

      To apply for an account, you can sit down at any workstation (should be present in all Owlnet labs) and log in as user "apply", and follow the instructions. You can also use Netscape and connect to:

      http://apply.rice.edu

      If you encounter any trouble during application process, you should goto the information desk at Mudd 103 ask for assistance.

    2. Subscribe to RCSC listserv

      Send an email to listserv@listserv.rice.edu, in the body of your message, type:

      subscribe RCSC Your Name

      You should get an automated reply message about listserv, it includes information on how to post messages to the listserv, how to unsubscribe, and other listserv commands. Please save this message for future reference.

    3. Register rcssc

      Login to any Owlnet workstation, type "register rcssc" at the prompt. For the setup to work, you will need to quit the session, and login again. If you have any questions or suggestions, please email to rcssc@rice.edu, or post it to RCSC@listserv.rice.edu.


  2. What programs are available?

    1. Viewing

      1. Viewing Chinese on Netscape

        After you registered rcssc, your font path will be set automatically every time you login. To view Chinese on Netscape, you will need to select the correct fonts: Tradition Chinese (BIG5), Traditional Chinese (EUC-TW), or Simplified Chinese (GB). You can set the fonts by clicking "Options" on the menu bar, and select "Document Encoding".

      2. Viewing news on tin / viewing documents on gopher

        First, you should start cxterm by typing "cxterm" at your prompt. Then type "hztty" so you can view HZ documents (these documents has lines begin with ~{ and ends in ~}. To read news, start tin; to enter gopher, start gopher.

        You can also view any documents with cxterm. There are 4 varieties of cxterm, they are:

        	cxterm		(GB, HZ)
        	cxtermb5	(BIG5)
        	cxtermjis	(JIS, Japanese)
        	cxtermks	(KSC, Korean)
        

      3. Viewing documents using ChiRk

        Your fonts will not be setup correctly when you are on X-Terminals. If your console shows the following message, you are on an X-Terminal:

        X Error of failed request:  BadValue (integer parameter out of range for operation)
          Major opcode of failed request:  51 (X_SetFontPath)
          Value in failed request:  0x0
          Serial number of failed request:  4
          Current serial number in output stream:  6
        

        That means you cannot view Chinese documents normally. Right now there is no prefect solution to this. Chirk allows you to view Chinese documents (no Japanese or Korean). To start chirk, type "chirk the_name_of_document" and a window will appear. Instructions on how to use chirk are shown on the bottom of the popup window.

    2. Editing

      1. Chpower

        Chpower is an easy-to-use X-Windows editing program. To start chpower, type "chpower" at your prompt. You will see a box with 4 Chinese words. "New" opens new document, "old" opens an existing document, "in" pops up an input screen, "out" lets you exist chpower. This program has translation features and several additional utilities. You should be able to use it by exploring the menu bars.

        A note on choosing font: Font types (Format->Character...) are short handed, the first few alphabetic letters mean:

        	s	song ti
        	fs	fangsong ti
        	m	ming ti
        	k	kai ti
        	h	hei ti
        	b5s	big5 song ti
        	b5k	big5 kai ti
        	b5m	big5 ming ti
        	jis	japanese
        	ksf	korean
        

        The next 2 numerical letters indicates the pixel size of the fonts. It could be either 16 or 24. 24 will show up more nicely if you scale up your characters.

        The last 1 letter indicates if the font is simplified or not:

        	j	jian ti (simplified)
        	f	fan ti  (non-simplified)
        

        Currently, only Chinese characters show up correctly on screen. If you are editing Japanese or Korean, it is recommended that you use cxterm.

      2. CXterm

        You may start cxterm by typing "cxterm" at your prompt. If you need to edit HZ document, "hztty" command must be entered. The function keys F1-F10 are used to select entry method, Shift-Function Key also selections method. F3 allows you change input configuration. Pinyin method is F6, or Shift-F4 for tuned pinyin. Escape key lets you quit inputting Chinese and input ASCII letters. All selections are shown on the bottom of the screen, you can press the numbers to select the word, or use "." to see more selections, and "," back up previous screen of selections. Spacebar automatically selects the "1" word.

        There are 4 flavor of cxterm:

        	cxterm		(GB, HZ)
        	cxtermb5	(BIG5)
        	cxtermjis	(JIS, Japanese)
        	cxtermks	(KSC, Korean)
        

      3. Cvi

        This is a Chinese equivalent for vi. You must first start cxterm. and then type "cvi" at your prompt. There are 5 alternative to cvi:

        	celvis		chinese vi
        	cvi		same as celvis
        	cview		file read-only, start at control mode
        	cedit		start at edit mode
        	cex		chinese ex
        

    3. Printing

      1. Cnprint

        This program prints the Chinese files. Since Owlnet default for printer is (null), you will need the following options to print:

        -q=laserps: System PS print command = 'laserps'

        The "-t" option might also be useful if you don't want time printed. For more information on using cnprint, type "cnprint -h", or "man cnprint", or read /home/rcssc/doc/cnprint.help.

      2. Using gb2ps

        Gb2ps changes Chinese files to postscript files, which can than be printed using "lpr" or "enscript" command. gb2ps automatically prints a title page for HXWZ, to suppress this, you will need to use the "-t" option. You can do font and page formatting with gb2ps, for more information, please read /home/rcssc/doc/gb2ps.help.

      3. Using chpower

        You could also use chpower's print command to print any document. You will need to specify the printing command. The command is found at File->Print....

    4. Font conversion

      Chpower has builtin font conversion, which is under "Convert" menu. Other conversion utilities include:

      	b2g		big5 -> gb
      	g2b		gb -> big5
      	hc		(same as b2g and g2b)
      	gb2hz		gb -> hz
      	hz2gb		hz -> gb
      	gb2ps		gb -> ps
      

      You will need to use chpower to convert Japanese and Korean files.

    5. Summary of programs

      Here is a list of programs currently under rcssc:

      	CXterm		safe cxterm, installs proper fonts
      	b2g		big5 -> gb
      	cedit		cvi, start at edit mode
      	celvis		cvi
      	cex		chinese ex
      	chirk		chinese viewer
      	chpower		chinese x-win editor
      	cnprint		chinese printing
      	cvi		chinese vi (cvi)
      	cview		cvi, read-only mode
      	cxterm		chinese xterm, gb font
      	cxtermb5	chinese xterm, big5 font
      	cxtermjis	chinese xterm, jis font (japanese)
      	cxtermks	chinese xterm, ksc font (korean)
      	g2b		gb -> big5
      	gb2hz		gb -> hz
      	gb2ps		gb -> ps
      	hc		b2g, g2b
      	hz2gb		hz -> gb
      	hztty		enable hz
      	virec		restores file for cvi
      

      cvi, celvis, cedit, cview, cex currently are not supported on SGI machines. All other commands are supported on SunOS, Solaris, and SGI.

      It is strongly recommended to read man page and documentation of each program. To view man page, type "man programname". Some programs does not have man pages, and have documentation under /home/rcssc/doc/. To get a short help, "program -h" lists a summary of options. If anything still does not work, please email to rcssc@rice.edu, or post to RCSC@listserv.rice.edu.


  3. Why does ___ not work?

    1. Why does Chinese files show gibberish?

      First of all, you must be on a Workstation, not X-Terminals. As a general rule, all computers in library which is not Mac and there is no camera on top is a X-Terminal. All machines in Ryon 102, Physics Lab, Mechanical Engineering Lab, Abecrombie Lab, and Mudd Unix Tutorial Room are work stations.

      Secondly, you should not run the program if you are rlogined or telneting to Owlnet. This usually cause a font problem, and sometimes you could get around the problem by typing the following command when you enter x-windows:

      xset +fp tcp/fonts.rice.edu:7000

      This command sometimes fails. If you only need to read documents, use chirk instead, see II.a.3.

    2. Why does cnprint not printing my file?

      You need to specify the print command using the following option:

      -q=laserps: System PS print command = 'laserps'.

      On Owlnet, the system printer is set to (null) by default, which causes the problem.

      You could preview your file by first converting it to postscript file using the "-w -o outfilename" option. The postscript file will be large though.

    3. Why does cxterm say "method not found"?

      A possible cause for this problem is that you rlogined or are telneting to Owlnet. The cxterm methods are called "dictionaries" and the base directory to these dictionaries (usually dict/) must be found on your current machine. If you want to use cxterm, you may copy the directory /home/rcssc/dict/ to your machine, and add it to your path. A environment vairable called HZINPUTDIR must be set to that base directory. On csh or tcsh, type:

      	setenv HZINPUTDIR /the/directory
      

      On sh, you need to type the following commands:

      	set HZINPUTDIR=/the/directory
      	export HZINPUTDIR
      

      Note you don't need to copy /jis and /ks directories if you only need to read Chinese files. For more questions on setting up your Chinese environment, please refer to IV.c.

    4. Why does cxterm/chpower has so few inputting methods?

      This is the same as the above question. Refer to III.c.

    5. Why does Netscape/gopher/tin shows gibberish?

      First check if the program is running on Owlnet, also check if you are rlogined or are telneting to Owlnet. If one or both answers to the above two questions are yes, refer to III.a.

      Second check if you selected the correct language on Netscape. To select language, follow Options->Document Encoding->select the language. Note you must select gb if you are reading GB files, and also for BIG5 and EUC-TW. You should know what language the file you are reading.

      On cxterm, check if you typed "hztty". HZ files usually appear as gibberish if you forget to issue this command. It is a good idea to start hztty whenever you start cxterm, so you can read both gb and hz files. The following command is suggested:

      cxterm -e hztty &

    6. Why does cxtermb5, cxtermjis, cxtermks not working?

      CXterm is the one running when you say "cxterm". CXterm is a safe version of cxterm and automatically selects the fonts. You will want to issue CXterm before you execute cxtermb5, cxtermjis, or cxtermks to set the fonts correctly. It is recommended that you start cxterm iconized at every login, even if you don't use it. That will make sure the fonts are correctly setup.

    7. Why does PINE not allowing me to edit Chinese email?

      The main problem with this version of PINE (v3.96) is that it does not understand GB inputs. It is encouraged that you used HZ environment from start (ie, type "hztty" after CXterm started) since it could understand both HZ and GB fonts. If you are in HZ environment, you should be able to edit Chinese email as normal, starting and ending each line with ~{ and ~}.

      If you need to use GB, you will need to change the file .pinerc under your home directory. The following lines are affected:

      # Specifies the program invoked by ^_ in the Composer, # or the "enable-alternate-editor-implicitly" feature. editor=
      Change the "editor=" line to the following:
      editor=pico
      DO NOT CHANGE ANY OTHER LINES unless you know what you are doing. Now when you need to edit a Chinese mail, after you typed in the name and subject line, press "Ctrl-Shift-Dash" in the body of the mail (after the dashed line), which means press "Control", "Shift" and "-" keys at the same time, shorthanded to ^_. Then edit email as a normal file, and press Ctrl-X (press "Control" and "X" key together) to exit out of editor, and SAVE the file if asked. The file saved is a temporary file and will be deleted once the email is sent.

    8. Why is my question not in this guide?

      Well, this is only a general guide, intended for starters. If you encounter a problem, please email to rcssc@rice.edu, or post it to RCSC@listserv.rice.edu. You problem could be other people's problem too, and if we don't get questions, we assume everyone knows how to use the programs, and the programs are running perfectly. If you just entered Rice University, or you do not feel comfortable with computers, and may be the terminology sounds too unfamiliar, please read Owlnet's page:

      http://riceinfo.rice.edu/Computer/Facilities/Owlnet/


  4. How do I ___? (Advanced questions)

    1. How do I setup Chinese System on my machine?

      You will need to do two things.

      1. Get Chinese programs

        You may copy (file transfer) rcssc's program to your own computer, as long as you don't use it for commercial purpose. You may also download softwares from internet. Some places to look are:

        http://www.ifcss.org/software/cnapps/index.html
        http://www.ifcss.org/ftp-pub/software/

        You many get files end if .tar.gz, or .tar.Z, or .tgz. These files are tar files and/or gzipped files. You will need to issue the following commands to unpack the program:

        	gunzip filename
        	tar -xvf gunziped_filename
        

        Most programs are large and requires lots of space. Some packages come with binary file which you can immediately execute, but most require you to make it. You will need to edit Immakefile or Makefile if neccesary. As a general rule, ALWAYS read README, README.1st, and INSTALL. Follow instructions in those files. Compiling requires lots of space and take some time. This is not recommended unless you know exactly what you are doing. If you want to tryout certain programs, email to rcssc@rice.edu, or post to RCSC@listserv.rice.edu. Someone will evaluate the program and add to rcssc's program list if possible. Also you may want to ask around, especially some Chinese computer friends of yours, because probably they already tried it and can let you link/copy/run their program, or give you a good idea what to expect.

      2. Get Chinese fonts

        You may need to install some fonts, maybe even some fancy fonts not on Owlnet.

        If you copied fonts from rcssc, it is strongly recommended that you put it under your xfonts/ directory. Several kinds of files are recognized as font files, like .bdf and .pcf files. When you've done copying, you must run the following command to make the xfonts/ directory looks like a font directory to the system:

        	mkfontdir /your/font/directory (or "mkfontdir ." if in it)
        

        A file called "fonts.dir" will be created. DO NOT edit this file. In this file, the first line says how many fonts there are in the directory, and all other lines are the names of fonts. Note these names maybe long, you will need to create a fonts.alias file with the following format for each line:

        	short_name	font_name_in_fonts.dir
        

        Certain programs only recognize certain aliases, you will need to consult the program's README or INSTALL file. It is a good idea to copy rcssc's fonts.alias file.

        Chpower and cnprint both require HBF files, they will not appear in fonts.dir or fonts.alias. Cnprint also requires a "cnprint.cmd" in the font directory. See documentation on cnprint.

        Every time you enter x-windows. the following command is required for the system to load your fonts:

        	xset +fp /you/font/directory
        

        You should study the following files:

        	/home/rcssc/Xsetup.all
        	/home/rcssc/xfonts/0.README
        	/home/rcssc/xfonts/README
        	/home/rcssc/xfonts/HBF.txt
        

        If you want to obtain more fonts, some places to start are:

        http://www.ifcss.org/software/cnapps/fonts.html
        http://www.ifcss.org/ftp-pub/software/fonts/

        The files might be gzipped and/or tarred, follow the procedures listed in IV.a.1. Some font files are only available in HBF format, but you can change it to bdf or pcf by using the program hbftopcf. The program can be found at:

        http://www.ifcss.org/ftp-pub/software/fonts/utils/hbf.tar.gz

        There is a command "bdftopcf" which translates bdf files to pcf files.

        If you have additional fonts on Owlnet, please let us know so we can link to it and everyone can use it. Font files take a lot of space and it is a good idea to ask around to see if the font is already available. "xlsfonts" command will give a list of current fonts on the system.

    2. How do I setup Chinese System on my PC/Mac?

      The procedure are different from Unix and are much easier. Look at:

      http://www.ifcss.org/software/cnapps/index.html
      http://www.ifcss.org/ftp-pub/software/

      and download the files you want. PC programs are generally zipped and you will need to pkunzip it. pkunzip.exe can be found at:

      http://www.ifcss.org/ftp-pub/software/dos/utils/pkunzip.exe

      Mac files may end in .hqx, .sit, or .bin. These are packed for macintosh and most machines unpack it for you automatically. If not, you can get the program from Mudd's Software Distribution Center.

      When unpacked, the binary programs should be ready to run. Some programs may need some additional font files, please follow directions in README.1st, README, or INSTALL files.

      The following is a list of programs that are most popular.

      Chinese Star (CStar)
      Reported to have the best font display.
      RichWin for Internet
      Supports most fonts.
      Twin Bridge
      Unlimited time free demo.
      NJ Star
      Automatic font switching.

    3. How do I change the current rcssc setup?

      You may drop rcssc by typing "drop rcssc" at your prompt. Study /home/rcssc/Xsetup.all and modify it to suit your needs. /home/rcssc/dict/CXterm.ad can be appended to your .Xresources file and modified. If you only need to modify a few lines in CXterm, you can add it to your .Xresources file, your additions will take precedence. You may also link to rcssc, please do not use hard links, use "ln -s" command instead. Cnprint needs cnprint.cmd to work, it is located at /home/rcssc/xfonts/cnprint.cmd. You need to take a look at /home/rcssc/setup/environment to setup the correct environment variables.

    4. How do I get to know more about the programs?

      Refer to II.e.

    5. How do I get to know more about inputting methods?

      Practice and Play. There are also several files out on internet, start looking at http://www.ifcss.org/ftp-pub/software/data/, and ftp://ftp.ifcss.org/pub/act/archive/input/.

    6. How do I get more programs?

      See IV.a.1.

    7. How do I get more fonts?

      See IV.a.2.


  5. Miscellaneous

    1. Notes on maintaining RCSSC Owlnet Chinese System

      Check http://www.ifcss.org/ftp-pub/software/ for updates on software each year. Read news:rice.owlnews.general to get information on Owlnet updates, especially hardware. Right now Solaris is running SunOS version programs, if an update make it impossible, or libraries get too old, new compilation is needed (ie, more disk quota).

      Read /home/rcssc/setup/README for setup information.

      Remember every change in setup/, dict/, xfonts/, c-bin/, bin/, and man/ affect everyone enrolled in rcssc.

    2. Other Programs on the Net

      Font Conversion

    Please direct all questions and suggestions to:
    rcssc@rice.edu