################################################################# # # # XCIN version 2.1c Package. # # # # Modified from xcin-2.1b.tar.gz package. # # (original author: Edward Der-Hua Liu, Taiwan) # # # # by Tung-Han Hsieh (March, 1997) # # Physics Dept., National Taiwan University. # # Email: thhsieh@twclx.phys.ntu.edu.tw # # # ################################################################# << Thank You >> Thanks to Mr. Edward Der-Hua Liu and others who developed the xcin system. With the wonderful program, we can do a lot of operation with Chinese under X-window in the UN*X world. As time goes on, more and more people use it, and more and more comments appear. The package upgraded with time but it seems that the install process is not convenient and self-consistent. These confuse a lot of people, especially for new users in the UN*X world. We often see the `Big FAQs' about xcin such as `how can I install the Chinese fonts' or `the cj2cin command not found' or `the crxvt terminal is too big!!' or something appears in the newsgroup again and again. In fact, such problems are easy to modify. Beasuse I really like this program and feel that I may do something to improve this package, so I try my best to re-write the Makefiles of this package to try to solve these troubles. This comes the `xcin-2.1c' project. I used to get a lot of helpness from others when I was new, and I am really thankful to those for their suggestions. I treat this project as a pratice of programming in the Linux operating system, and I really hope that these efforts will really make the program nicer and help the new users to install and use it. In the world of Free Software, in principle, we cannot expect any supports from any organization or software company. Actually we are the end-users, but I beleive that we are also the designers, the programmers. We really own the program and we have the ability to upgrade it, to improve it. Hence, I try to do this project, and I am glad to do this, and find that I can learn a lot from doing this. If anyone has comments or suggents about my modification, please mail to me. I hope that everyone who is interesting in improving the xcin package could work together. I believe that with our works, this package will have much more progress in the near future. Finally, I should thank to everyone who used to encourage me and suggest me to do this project. Especially thanks to Cd Chen (cdchen@linux.ntcic.edu.tw) for his help on alpha-test and contribu- tions on the documentations of this package. And, thank you very much for your using and supporting for this xcin-2.1c package. << The Structure >> I modified the xcin system to be the following structer: 1. xcin-2.1c/Makefile: The Main Makefile of the xcin package. There are full of options in it. One can edit this file easily by changing these options to fit his/her requirement to install xcin. 2. xcin-2.1c/xcin/: There contains the xcin Chinese-input server, and a module `cli_xcin.o' which contains a set of interface functions used by the xcin client. 3. xcin-2.1c/crxvt/: The xcin client, a modified X-window rxvt terminal. There are also some resource files in the `xcin-2.1c/crxvt/rc' directory. 4. xcin-2.1c/input_tabs/: There contains a `source' directory. In that directory, there are three kinds of transformation program which transforms the ETen Chinese-input-method tables, and a set of `tsin table generator', and finally a keyboard mapping table generator. The transformation program generally creat the `.cin' format tables from ETen, then use the `cin2tab' utility to transform them to the `.tab*' format. All the `.cin' and `.tab*' tables will be written to the `xcin-2.1c/input_tabs' directory, not in the source directory. And all the tables in the `xcin-2.1c/input_tabs' will be installed by the installation process, not only for the ETen-transformed tables. Therefore, if you can get your favorate Chinese input-method table (with the .cin format), you can put it into that directory, and the install process will install it automatically. 5. xcin-2.1c/fonts/: Similar to the xcin-2.1c/input_tabs directory, there is also a `source' directory in it. There contains the et2bdf utility, which can transform all kinds of ETen fonts for xcin, such as vga8x15, vga12x24, et15, et24m, and so on. Of course you can still get other fonts (with the `.pcf' format) from internet, and put them in the xcin-2.1c/fonts directory. Then the install process will install all of the fonts in that directory automatically. 6. xcin-2.1c/doc/: There are a set of documentations. I try to divide these documents in two kinds: one is for the users when they are going to install the xcin package, and the other is served as the run-time documentation. The second kind will be installed into your system by the install process, if you like, but the first kind will not. After installation, the xcin package will be in the following file systems: 1. Main binary: xcin, crxvt In one of your seach path. Default is `/usr/local/bin' 2. Fonts: English fonts(vga*), Chinese fonts(et*, taipei*, ...) By default, the English fonts will be in the `/usr/X11/lib/fonts/misc' directory. The Chinese fonts will be in the '/usr/X11/lib/fonts/chinese' directory. 3. Tables, Utilities and Documentations: There includes all the Chinese-input-method tables, tsin input-method tables, keyboard mapping tables, and some utilities such as cli_xcin.o, et2bdf, cin2tab, tsin utilities, and others. By defaults, they will be installed to `/usr/local/lib/xcin'. The documentations will be installed to `/usr/local/lib/xcin/doc'. << To Install >> Because in this version, one can decide freely what he/she want to install and what he/she doesn't want just by changing the options of the Makefile to be `yes' or `no', so there may be a problem that `At least what should I choose to "yes" such that I can have a complete xcin system?' Well, the answer depends on what you actually need. But at least you should have the following installed: 1. Binaries: xcin, crxvt. 2. Chinese fonts: at least one 8x16 (or 8x15) font, and one 12x24 font. 3. Input Methods: at least the `pho.tab' table. And others are up-to-you. Note that currently we still cannot provide the Chinese fonts and input-method tables directly with the package because of the problem of CopyRight. In this version you still have to have a ETen system installed, then the xcin install process will convert the fonts and tables from it. If you don't have the ETen system, make sure that you should get the required Chinese pcf fonts and input-method tables by other means. As I know, the Chinese fonts can be found from internet, such as ftp://linux.cis.nctu.edu.tw or other ftp sites. To install the xcin package, go through the following steps: 1. Edit the `xcin-2.1c/Makefile' to suit your needs. In that file, there are short descriptions for each option which you can edit. Make sure that for some options only the two words `yes' and `no' are allowed, and be careful that you should only type the three characters `yes' or two characters `no' exactly. The white spaces behind them are not allowed. If you don't have the ETen system, make sure that you should let the variable `XCIN_ETPATH' to be empty. 2. Copy all the extra .pcf Chinese fonts into xcin-2.1c/fonts dir., and copy all the extra .cin Chinese input-method tables into xcin-2.1c/input_tabs dir. 3. To be the root, under the X-window environment, type: make make install 4. Edit your /etc/XF86Config, add your Chinese font path into the Section "Files". 5. Install completely! You can see what you have installed in the xcin-2.1c/filelist file. Now you can re-start the X-window, and enjoy. If you want to make additional change in the xcin-2.1c/Makefile or want to re-compile the package, be sure to type `make clean' before `make; make install'. Note: If you have additional fonts or tables in the xcin-2.1c/fonts or xcin-2.1c/input-tabs directories, be sure to backup them befor e you type `make veryclean'. Because that action will clean all the files in those directories. << Quick Start >> If you are a new user for the xcin system, the following informa- tion may help you to get the idea to run the system. Now you have finished the installation, and re-start the X-window. you can now open a xterm, and execute the following command: crxvt & Then you will see a rxvt like terminal appeared. By default, the crxvt will search for 8x16 as its English font, and the et15 as its Chinese font. If you don't have the et15.pcf font, you will see an error message as "crxvt: can't access font et15" appeared and the exe- cution fails, then you should provide a option to tell crxvt to find the other fonts to use. For example, if you have a taipeik20, and you want crxvt to use the 10x20 English font, you can use: crxvt -fnb5 taipeik20 -font 10x20 & Beside these, there are still a lot of options for crxvt, and you can see the `man rxvt' for the detailed description about those options. Now you can start the xcin. Just type xcin & then you see some messages appeared, but where is the xcin window? Just let the crxvt be the foreground window, and press Ctrl+Space. See? the xcin window appears, and if you switch back to the English input mode by press Ctrl+Space again, the xcin window will disappear. Note that only the xcin client can use xcin, i.e., only when the crxvt becomes the foreground, then you can press Ctrl+Space to call xcin back because currently you only have crxvt to be the client of xcin. Similarly, by default the xcin use the et24m as its Chinese font and the 12x24 as its English font. If you don't have et24m, you can type: xcin -fnb5 taipeik24 & to use the taipeik24 font. By default, xcin will have the pho-input- method (Ctrl+Alt+3) and the tsin-input-method (Ctrl+Alt+6). If you want to use other input-methods, such as cj-input-emthod, you can use the command: xcin -in1 cj.tab & Then in addition to the pho-input-method, there will be a cj-input- method as you press Ctrl+Alt+1. Finally, you can integrate the xcin & crxvt to your X-win system. For example, you may complain that everytime you should type such a complicated command to start the xcin & crxvt. In fact, you can add these commands into your Window Manager source file such that every time you enter the X-window, the Window Manager will start them auto- matically. For example, if you use fvwm95-2, you can add two lines in the $HOME/.fvwm2rc95 files in the `AddToFunc "InitFunction"' section: + Exec crxvt -fnb5 taipeik20 -font 10x20 & + Exec xcin -in1 cj.tab -fnb5 taipeik24 & and then re-start the X-window. All will be OK! If you want to type Chinese words directly under the crxvt shell prompt, you should execute some commands before doing this: For bash: (in the $HOME/.profile or /etc/profile) set convert-meta off set output-meta on stty pass8 stty cs8 -istrip export LC_CTYPE=ISO-8859-1 For csh or tcsh: (in the $HOME/.cshrc or /etc/csh.cshrc or /etc/csh.login) stty pass8 stty cs8 -istrip setenv LC_CTYPE ISO-8859-1 Note: In some FAQs in the internet, they often recommand that you should also set the environment variable `LANG=C'. But after some test I find that if you set the `LANG=C' variable, the `man' and `elm' will work a little funny. In fact, you don't need to set `LANG=C' and the Chinese typing directly under the crxvt shell prompt still works fine. If you need additional information, please refer to the documents installed with xcin package and the corresponding man pages. << Change Logs >> Here I made some changes from xcin-2.1b package: 1. Rearrange the directory structer. 2. Write a new Makefile for installation, and modify the Makefiles and Imakefiles in each directory to suit the Main Makefile. 3. Rearrange the original documentations. 4. Set the default fonts of xcin to be et24m, 12x24. Change the $HOME/xcin_dir to $HOME/.xcin_dir for tsin-input-method. Modify the input-table search path to support the full path name. 5. The font choice style of xcin changes. Thanks to vvvv.bbs@bbs.cis.nctu.edu.tw 6. Set the default fonts of crxvt to be et15, 8x16. 7. Add utilities installation (such as cin2tab, et2bdf, ....) 8. Combine the original ETen fonts transformation program to a single program: et2bdf. 9. The original rc dir has been temperary removed. I hope that these changes actually make the xcin package nicer. If you have any comments or suggestions, it is welcome to mail to me. My email address is: thhsieh@twclx.phys.ntu.edu.tw Enjoy!! Tung-Han Hsieh