v12i082: kterm - kanji xterm, Part01/18

mleisher at NMSU.Edu mleisher at NMSU.Edu
Wed May 8 12:32:56 AEST 1991


Submitted-by: mleisher at NMSU.Edu
Posting-number: Volume 12, Issue 82
Archive-name: kterm/part01

This is the "official" posting of kterm 4.1.2.

Kterm 4.1.2 supports:

   o  Display of Chinese, Japanese, and Korean text in a number of
      different encodings.

   o  Tab and newline preservation in selections.

   o  Compound Text for the 94^N code sets.

   o  ANSI color sequences.

   o  Multi-byte character set word selection.


Tab and newline preservation don't always work correctly when copying
between different editors and different kterm sessions.  The
performance will vary depending on the editor used.

Support for the JIS X0201 part of DEC Kanji has been removed until I
can verify that this support does not conflict with vt102 escape
sequences.  If you would like the patch for the DEC/JIS X0201 support,
please send me email.


The compilation and intallation instructions are in the INSTALL file,
and the README file covers some technical details of Chinese,
Japanese, and Korean encodings.

Extra installation notes:

1. kterm should compile cleanly using gcc 1.39 (at least on Sun's).

2. One of the files in kterm, charproc.c, is a very large file that I
   haven't broken up yet.  When you compile, you may need to specify a
   tmp directory for your C compiler using the "-temp=<dir>" notation
   if your compiler supports it, or the TMPDIR environment variable if
   your compiler checks for it.  This will only be needed if your
   current tmp directory is too small to compile this file.

   Gcc encountered no space problems when compiling.

3. There are three files in this distribution that contain 8-bit code:
   b2g.table, g2b.table, and n2ks.table.  They have been encoded using
   a program called btoa to avoid uuencode problems through EBCDIC
   sites.

   btoa is available from a number of sites.  You can use archie to
   find the nearest location of the btoa code, or you can ftp it from:
   crl.nmsu.edu:pub/misc/btoa.tar.Z  [128.123.1.14]

There is still a bug in one of the color sequence interpretations
(resetting to the default color) that I haven't tracked down yet, so
if someone finds a fix, I'd love to hear from them.

kterm 4.1.2 is also available from these anonymous ftp sites:
crl.nmsu.edu:pub/misc/kterm-4.1.2.tar.Z  [128.123.1.14]
export.lcs.mit.edu:contrib/kterm-4.1.2.tar.Z  [18.30.0.238]
kum.kaist.ac.kr:pub/unix/Xstuffs/kterm-4.1.2.tar.Z  [137.68.1.65]

Please send bug reports, enhancements, fixes, etc. to
mleisher at nmsu.edu.

Sat May  4 16:27:30 MDT 1991
-----------------------------------------------------------------------------
mleisher at nmsu.edu                      "I laughed.
Mark Leisher                                I cried.
Computing Research Lab                          I fell down.
New Mexico State University                        It changed my life."
Las Cruces, NM                     - Rich [Cowboy Feng's Space Bar and Grille]


#!/bin/sh
# This is kterm-4.1.2, a shell archive (produced by shar 3.49)
# To extract the files from this archive, save it to a file, remove
# everything above the "!/bin/sh" line above, and type "sh file_name".
#
# made 05/04/1991 23:15 UTC by mleisher at nmsu.edu
# Source directory /tmp_mnt/home/nikita2/X11R4/contrib/clients
#
# existing files will NOT be overwritten unless -c is specified
#
# This is part 1 of a multipart archive                                    
# do not concatenate these parts, unpack them in order with /bin/sh        
#
# This shar contains:
# length  mode       name
# ------ ---------- ------------------------------------------
#   4315 -rw-rw-r-- kterm-4.1.2/INSTALL
#   3276 -rw-rw-r-- kterm-4.1.2/Imakefile
#   7899 -rw-rw-r-- kterm-4.1.2/KTerm.ad
#    780 -rw-rw-r-- kterm-4.1.2/KTerm.tmpl
#  10613 -rw-rw-r-- kterm-4.1.2/Makefile
#   8007 -rw-rw-r-- kterm-4.1.2/README
#  52929 -rw-rw-r-- kterm-4.1.2/TekPrsTbl.c
#    652 -rw-rw-r-- kterm-4.1.2/Tekparse.def
#   2437 -rw-rw-r-- kterm-4.1.2/Tekparse.h
#  39998 -rw-rw-r-- kterm-4.1.2/Tekproc.c
#  75504 -rw-rw-r-- kterm-4.1.2/VTPrsTbl.c
#   1108 -rw-rw-r-- kterm-4.1.2/VTparse.def
#   3502 -rw-rw-r-- kterm-4.1.2/VTparse.h
#    476 -rw-rw-r-- kterm-4.1.2/b2g
#  55853 -rw-rw-r-- kterm-4.1.2/button.c
# 139105 -rw-rw-r-- kterm-4.1.2/charproc.c
#    166 -rwxrwxr-x kterm-4.1.2/colortest
#  15524 -rw-rw-r-- kterm-4.1.2/convert.c
#  14017 -rw-rw-r-- kterm-4.1.2/convlib.c
#  16552 -rw-rw-r-- kterm-4.1.2/ctlseqs.ms
#   6443 -rw-rw-r-- kterm-4.1.2/cursor.c
#   3198 -rw-rw-r-- kterm-4.1.2/data.c
#   2484 -rw-rw-r-- kterm-4.1.2/data.h
#   4916 -rw-rw-r-- kterm-4.1.2/error.h
#  21178 -rw-rw-r-- kterm-4.1.2/g2b
#  13217 -rw-rw-r-- kterm-4.1.2/hgutil.c
#   1110 -rw-rw-r-- kterm-4.1.2/hgutil.h
#   7921 -rw-rw-r-- kterm-4.1.2/hzutil.c
#   3632 -rw-rw-r-- kterm-4.1.2/hzutil.h
#   7832 -rw-rw-r-- kterm-4.1.2/input.c
#   5187 -rw-rw-r-- kterm-4.1.2/kconvert.c
#   3627 -rw-rw-r-- kterm-4.1.2/kterm.h
#  13070 -rw-rw-r-- kterm-4.1.2/kterm.jman
#  13156 -rw-rw-r-- kterm-4.1.2/kterm.man
#  73676 -rw-rw-r-- kterm-4.1.2/main.c
#   1328 -rw-rw-r-- kterm-4.1.2/main.h
#  36692 -rw-rw-r-- kterm-4.1.2/menu.c
#  10856 -rw-rw-r-- kterm-4.1.2/menu.h
#  19514 -rw-rw-r-- kterm-4.1.2/misc.c
#  15081 -rw-rw-r-- kterm-4.1.2/n2ks
#     21 -rw-rw-r-- kterm-4.1.2/patchlevel.h
#  21948 -rw-rw-r-- kterm-4.1.2/ptyx.h
#  30881 -rw-rw-r-- kterm-4.1.2/screen.c
#  15832 -rw-rw-r-- kterm-4.1.2/scrollbar.c
#   2605 -rw-rw-r-- kterm-4.1.2/tabs.c
#    166 -rw-rw-r-- kterm-4.1.2/termcap.kt
#    167 -rw-rw-r-- kterm-4.1.2/terminfo.kt
#  32241 -rw-rw-r-- kterm-4.1.2/util.c
#
if test -r _shar_seq_.tmp; then
	echo 'Must unpack archives in sequence!'
	echo Please unpack part `cat _shar_seq_.tmp` next
	exit 1
fi
# ============= kterm-4.1.2/INSTALL ==============
if test ! -d 'kterm-4.1.2'; then
    echo 'x - creating directory kterm-4.1.2'
    mkdir 'kterm-4.1.2'
fi
if test -f 'kterm-4.1.2/INSTALL' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/INSTALL (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/INSTALL (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/INSTALL' &&
IMAKEFILE
---------
There are a number of things that may need changing in the Imakefile
in relation to using the 2-byte character fonts.  These should be set
in the DEFINES line in the Imakefile:
X
1. -DKTERM
X   This sets the flags needed for compiling in support for Hangul,
X   Hanzi, and Kanji.  The KTERM_HANGUL, KTERM_HANZI, and KTERM_KANJI
X   flags are set in the kterm.h file, *IF* -DKTERM is defined in the
X   Imakefile.
X
2. -DWCHAR_T
X   If your system already has a wchar_t type defined, you need to define
X   this or you might get a type conflict.  If your system doesn't have
X   this type defined, wchar_t will be defined as an unsigned short
X   int.  If an unsigned short int is not 16 bits on your system, then
X   change the typedef in the ptyx.h file so that wchar_t will be a 16
X   bit integer type.
X
3. -DMB_WSEL
X   Define this flag if you want to get word selection capabilities in
X   Chinese, Japanese, and Korean text.  Basically, each character is
X   looked at as being in a certain class of characters.  When the left
X   mouse button is clicked twice, the text around the mouse pointer
X   will be looked at and only the characters that have the same class
X   as the one under the mouse pointer will be selected.  Examples of
X   character classes in multi-byte character sets are punctuation,
X   line drawing characters, Hiragana, Katakana, Greek, Russian,
X   Hangul, Hanzi, etc.
X
The install mode for the Hangul and Hanzi conversion tables is set
equivalent to the manual page mode in the KTerm.tmpl file.  You might
want to change this mode to something appropriate for your site.
X
OTHER DEFINES
-------------
If you want kterm to recognize most of the Compound Text character set
sequences, make sure KTERM_CTEXT is defined in kterm.h.  Not all of
the legal Compound Text character sets are supported, but ISO 8859-1
and the 3 multi-byte character sets are.
X
If you want the ANSI color capability, make sure -DCOLOR_TEXT is
defined in the Imakefile on the DEFINES line.
X
APPLICATION DEFAULTS FILE
-------------------------
Here is an example of things that you might want to change in the
application defaults file KTerm.ad:
X
*VT100*font:       8x16
*VT100*kanjiFont:  kanji16
*VT100*hanziFont:  beijing16
*VT100*hangulFont: h16myungjo
X
*VT100*language:   japanese
*VT100*kanjiMode:  euc
*VT100*hanziMode:  guobiao
*VT100*hangulMode: ks-8bit
X
The following three resources *cannot* be set from the command line,
so they have to be set in the application defaults file KTerm.ad, or
in your .Xdefaults file in your root directory.
X
*VT100*hanziGbToBigTable: /usr/local/lib/X11/kterm/g2b.table
*VT100*hanziBigToGbTable: /usr/local/lib/X11/kterm/b2g.table
*VT100*hangulNtoKSTable:  /usr/local/lib/X11/kterm/n2ks.table
X
Setting the above resources in the application defaults file should be
enough to get kterm up an running smoothly.  Of course, you may want
to choose another default language.
X
INSTALLATION
------------
X
Once you have fixed up the Imakefile and application defaults file,
the build and install process should go smoothly with this sequence of
commands:
X
1. xmkmf                /* Creates the Makefile. */
2. make                 /* Creates the executable. */
3. make install         /* Installs the executable and app default file. */
4. make install.man     /* Installs the man page. */
5. make install.table   /* Installs the conversion tables. */
6. make clean           /* Cleans up after the compile. */
X
TERMCAP AND TERMINFO
--------------------
To get a status line and curses functionality, you will need to
install either the termcap.kt in the /etc/termcap (or wherever it is
on your system) file or, for System V, compile the terminfo.kt with
tic and install in the appropriate directory.  On Sun OS 4.1 (and up I
think), you will need to use /usr/5bin/tic to compile the terminfo.kt
file if you want to use vi.  Most of the other vi clones work fine
with just the termcap.kt entry.
X
The termcap information can also be set in the .login file if you
don't have access to the destination directories for termcap or
terminfo.
X
If you install the termcap.kt file in /etc/termcap, be careful that it
is installed *before* any other entries that have ``vk'' as the
initial name.  If it isn't and you set the terminal type to ``vk'',
you might get the wrong termcap entry.
SHAR_EOF
chmod 0664 kterm-4.1.2/INSTALL ||
echo 'restore of kterm-4.1.2/INSTALL failed'
Wc_c="`wc -c < 'kterm-4.1.2/INSTALL'`"
test 4315 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/INSTALL: original size 4315, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/Imakefile ==============
if test -f 'kterm-4.1.2/Imakefile' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/Imakefile (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/Imakefile (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/Imakefile' &&
/**/###########################################################################
/**/#                                                                         #
/**/#                         Attention kterm porters                         #
/**/#                                                                         #
/**/#                                                                         #
/**/# Kterm assumes that bcopy can handle overlapping arguments.  If your     #
/**/# bcopy (or memcpy) can't, write a routine called bcopy and link it in    #
/**/# or add -Dbcopy=mybcopy to the DEFINES list below.                       #
/**/#                                                                         #
/**/###########################################################################
X
#ifdef BandAidCompiler
#include BandAidCompiler
#endif
X
/*
X * add -DWTMP and -DLASTLOG if you want them; make sure that bcopy can
X * handle overlapping copies before using it.
X */
#ifdef SetTtyGroup			/* turn on in config/machine.cf */
X   TTYGROUPDEF = -DUSE_TTY_GROUP
#endif
/*
X *	[PUCC = Purdue University Computer Center]
X *	If you use PUCC's ptyd, add "-DPUCC_PTYD" to the DEFINES
X *	and dink the -DUTMP (also don't define WTMP or LASTLOG - since
X *	ptyd does all that logging for you)  You will need to add
X *	the right library load line (we use -lpucc) to the 
X *	ComplexProgramTarget (right next to -ltermcap)
X */
#ifdef UsePUCCPtyd			/* turn on in config/site.def */
X    PUCCPTYDDEF = -DPUCC_PTYD		/* does not need to be setuid */
X         PTYLIB = -lpucc
#endif
X
X   MAIN_DEFINES = -DUTMP $(TTYGROUPDEF) $(PUCCPTYDDEF)
X   MISC_DEFINES = /* -temp=./tmp /* -DALLOWLOGFILEEXEC */
X   DEFINES = -DKTERM -DMB_WSEL -DWCHAR_T -DSTATUSLINE -DKEEPALIVE -DCOLOR_TEXT
X
/*
X * Include the file containing the table install rule.
X */
#include "KTerm.tmpl"
X
X         TABLES = b2g.table g2b.table n2ks.table
X   CONV_TBL_DIR = $(USRLIBDIR)/kterm
X
X          SRCS1 = button.c charproc.c cursor.c data.c input.c \
X		  main.c menu.c misc.c screen.c scrollbar.c tabs.c \
X		  TekPrsTbl.c Tekproc.c util.c VTPrsTbl.c \
X		  convert.c kconvert.c convlib.c hgutil.c hzutil.c
X          OBJS1 = main.o input.o charproc.o cursor.o util.o tabs.o \
X		  screen.o scrollbar.o button.o Tekproc.o misc.o \
X		  VTPrsTbl.o TekPrsTbl.o data.o menu.o \
X		  convert.o kconvert.o convlib.o hgutil.o hzutil.o
X           SRCS = $(SRCS1)
X           OBJS = $(OBJS1)
X       PROGRAMS = kterm
X       DEPLIBS1 = XawClientDepLibs
X       PROGRAMS = kterm
X
#ifndef TermcapLibrary
#if SystemV && !defined(MacIIArchitecture)
#ifdef CrayArchitecture
#define TermcapLibrary -lcurses		/* special case of system v */
#else
#define TermcapLibrary -ltermlib	/* usually in here */
#endif
#else
#define TermcapLibrary -ltermcap	/* bsd puts it here */
#endif
#endif
X
X     TERMCAPLIB = TermcapLibrary
X
AllTarget($(PROGRAMS))
X
SpecialObjectRule(main.o, ,$(MAIN_DEFINES))
SpecialObjectRule(misc.o, ,$(MISC_DEFINES))
SpecialObjectRule(charproc.o, ,$(MISC_DEFINES))
X
NormalProgramTarget(kterm,$(OBJS1),$(DEPLIBS1),XawClientLibs,$(TERMCAPLIB) $(PTYLIB))
InstallProgramWithFlags(kterm, $(BINDIR), $(INSTUIDFLAGS))
X
InstallAppDefaults(KTerm)
InstallManPage(kterm,$(MANDIR))
X
InstallKtermConvTable($(TABLES),$(CONV_TBL_DIR))
X
DependTarget()
SHAR_EOF
chmod 0664 kterm-4.1.2/Imakefile ||
echo 'restore of kterm-4.1.2/Imakefile failed'
Wc_c="`wc -c < 'kterm-4.1.2/Imakefile'`"
test 3276 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/Imakefile: original size 3276, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/KTerm.ad ==============
if test -f 'kterm-4.1.2/KTerm.ad' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/KTerm.ad (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/KTerm.ad (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/KTerm.ad' &&
! $Header: /usr/local/src/X11/contrib/clients/kterm-4.1.2/RCS/KTerm.ad,v 1.3 1991/01/16 07:02:55 mleisher Exp $
X
*SimpleMenu*BackingStore:	NotUseful
*SimpleMenu*menuLabel.font:	-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-iso*-*
*SimpleMenu*menuLabel.vertSpace: 	100
*SimpleMenu*HorizontalMargins:	16
*SimpleMenu*Sme.height:		16
X
*SimpleMenu*Cursor:		left_ptr
*mainMenu.Label:		Main Options
*mainMenu*securekbd*Label:	Secure Keyboard
*mainMenu*allowsends*Label:	Allow SendEvents
*mainMenu*logging*Label:	Log to File
*mainMenu*redraw*Label:		Redraw Window
*mainMenu*suspend*Label:	Send STOP Signal
*mainMenu*continue*Label:	Send CONT Signal
*mainMenu*interrupt*Label:	Send INT Signal
*mainMenu*hangup*Label:		Send HUP Signal
*mainMenu*terminate*Label:	Send TERM Signal
*mainMenu*kill*Label:		Send KILL Signal
*mainMenu*quit*Label:		Quit
X
*vtMenu.Label:			VT Options
*vtMenu*scrollbar*Label:	Enable Scrollbar
*vtMenu*jumpscroll*Label:	Enable Jump Scroll
*vtMenu*reversevideo*Label:	Enable Reverse Video
*vtMenu*autowrap*Label:		Enable Auto Wraparound
*vtMenu*reversewrap*Label:	Enable Reverse Wraparound
*vtMenu*autolinefeed*Label:	Enable Auto Linefeed
*vtMenu*appcursor*Label:	Enable Application Cursor Keys
*vtMenu*appkeypad*Label:	Enable Application Keypad
*vtMenu*scrollkey*Label:	Scroll to Bottom on Key Press
*vtMenu*scrollttyoutput*Label:	Scroll to Bottom on Tty Output
*vtMenu*allow132*Label:		Allow 80/132 Column Switching
*vtMenu*cursesemul*Label:	Enable Curses Emulation
*vtMenu*visualbell*Label:	Enable Visual Bell
*vtMenu*marginbell*Label:	Enable Margin Bell
*vtMenu*altscreen*Label:	Show Alternate Screen
*vtMenu*softreset*Label:	Do Soft Reset
*vtMenu*hardreset*Label:	Do Full Reset
*vtMenu*tekshow*Label:		Show Tek Window
*vtMenu*tekmode*Label:		Switch to Tek Mode
*vtMenu*vthide*Label:		Hide VT Window
*vtMenu*statusline*Label:	Enable Status Line
*vtMenu*reversestatus*Label:	Status Line Reverse Video
*vtMenu*eucmode*Label:		EUC Kanji Mode
*vtMenu*sjismode*Label:		Shift-JIS Kanji Mode
*vtMenu*sgbmode*Label:		Shift-GB Hanzi Mode
*vtMenu*big5mode*Label:		Big5 Hanzi Mode
*vtMenu*ksmode*Label:		KS Hangul Mode
*vtMenu*nbmode*Label:		N-Byte Hangul Mode
X
*fontMenu.Label:		VT Fonts
*fontMenu*fontdefault*Label:	Default
*VT100*font:			8x16
*VT100*kanjiFont:		kanji16
*VT100*hanziFont:		beijing16
*VT100*hangulFont:		h16myungjo
X
!*VT100*fontList:		-*-fixed-medium-r-normal--14-*
!*VT100*font:			-*-fixed-medium-r-normal--14-*-iso8859-1
!*VT100*romanKanaFont:		-*-fixed-medium-r-normal--14-*-jisx0201.1976-0
!*VT100*kanjiFont:		-*-fixed-medium-r-normal--14-*-jisx0208.1983-0
!*VT100*hanziFont:		-*-fixed-medium-r-normal--14-*-gb2312.1980-0
!*VT100*hangulFont:		-*-fixed-medium-r-normal--14-*-ksc5601.1987-0
!*VT100*boldFontList:		-*-fixed-bold-r-normal--14-*
!*VT100*boldFont:		-*-fixed-bold-r-normal--14-*-iso8859-1
!*VT100*romanKanaBoldFont:	-*-fixed-bold-r-normal--14-*-jisx0201.1976-0
!*VT100*kanjiBoldFont:		-*-fixed-bold-r-normal--14-*-jisx0208.1983-0
!*VT100*hanziBoldFont:		-*-fixed-bold-r-normal--14-*-gb2312.1980-0
!*VT100*hangulBoldFont:		-*-fixed-bold-r-normal--14-*-ksc5601.1987-0
X
*fontMenu*font1*Label:		Tiny
!*VT100*fontList1:		-*-fixed-medium-r-normal--2-*
!*VT100*font1:			-*-fixed-medium-r-normal--2-*-iso8859-1
!*VT100*romanKanaFont1:		-*-fixed-medium-r-normal--2-*-jisx0201.1976-0
!*VT100*kanjiFont1:		-*-fixed-medium-r-normal--2-*-jisx0208.1983-0
!*VT100*hanziFont1:		-*-fixed-medium-r-normal--2-*-gb2312.1980-0
!*VT100*hangulFont1:		-*-fixed-medium-r-normal--2-*-ksc5601.1987-0
!*VT100*boldFontList1:		-*-fixed-bold-r-normal--2-*
!*VT100*boldFont1:		-*-fixed-bold-r-normal--2-*-iso8859-1
!*VT100*romanKanaBoldFont1:	-*-fixed-bold-r-normal--2-*-jisx0201.1976-0
!*VT100*kanjiBoldFont1:		-*-fixed-bold-r-normal--2-*-jisx0208.1983-0
!*VT100*hanziBoldFont1:		-*-fixed-bold-r-normal--2-*-gb2312.1980-0
!*VT100*hangulBoldFont1:	-*-fixed-bold-r-normal--2-*-ksc5601.1987-0
X
*fontMenu*font2*Label:		Small
*VT100*font2:			a14
*VT100*kanjiFont2:		k14
X
!*VT100*fontList2:		-*-fixed-medium-r-normal--14-*
!*VT100*font2:			-*-fixed-medium-r-normal--14-*-iso8859-1
!*VT100*romanKanaFont2:		-*-fixed-medium-r-normal--14-*-jisx0201.1976-0
!*VT100*kanjiFont2:		-*-fixed-medium-r-normal--14-*-jisx0208.1983-0
!*VT100*hanziFont2:		-*-fixed-medium-r-normal--14-*-gb2312.1980-0
!*VT100*hangulFont2:		-*-fixed-medium-r-normal--14-*-ksc5601.1987-0
!*VT100*boldFontList2:		-*-fixed-bold-r-normal--14-*
!*VT100*boldFont2:		-*-fixed-bold-r-normal--14-*-iso8859-1
!*VT100*romanKanaBoldFont2:	-*-fixed-bold-r-normal--14-*-jisx0201.1976-0
!*VT100*kanjiBoldFont2:		-*-fixed-bold-r-normal--14-*-jisx0208.1983-0
!*VT100*hanziBoldFont2:		-*-fixed-bold-r-normal--14-*-gb2312.1980-0
!*VT100*hangulBoldFont2:	-*-fixed-bold-r-normal--14-*-ksc5601.1987-0
X
*fontMenu*font3*Label:		Medium
*VT100*font3:			8x16
*VT100*kanjiFont3:		kanji16
*VT100*hanziFont3:		beijing16
*VT100*hangulFont3:		h16myungjo
X
!*VT100*fontList3:		-*-fixed-medium-r-normal--18-*
!*VT100*font3:			-*-fixed-medium-r-normal--18-*-iso8859-1
!*VT100*romanKanaFont3:		-*-fixed-medium-r-normal--18-*-jisx0201.1976-0
!*VT100*kanjiFont3:		-*-fixed-medium-r-normal--18-*-jisx0208.1983-0
!*VT100*hanziFont3:		-*-fixed-medium-r-normal--18-*-gb2312.1980-0
!*VT100*hangulFont3:		-*-fixed-medium-r-normal--18-*-ksc5601.1987-0
!*VT100*boldFontList3:		-*-fixed-bold-r-normal--18-*
!*VT100*boldFont3:		-*-fixed-bold-r-normal--18-*-iso8859-1
!*VT100*romanKanaBoldFont3:	-*-fixed-bold-r-normal--18-*-jisx0201.1976-0
!*VT100*kanjiBoldFont3:		-*-fixed-bold-r-normal--18-*-jisx0208.1983-0
!*VT100*hanziBoldFont3:		-*-fixed-bold-r-normal--18-*-gb2312.1980-0
!*VT100*hangulBoldFont3:	-*-fixed-bold-r-normal--18-*-ksc5601.1987-0
X
*fontMenu*font4*Label:		Large
*VT100*font4:			12x24
*VT100*kanjiFont4:		kanji24
*VT100*hanziFont4:		beijing24
X
!*VT100*fontList4:		-*-fixed-medium-r-normal--26-*
!*VT100*font4:			-*-fixed-medium-r-normal--26-*-iso8859-1
!*VT100*romanKanaFont4:		-*-fixed-medium-r-normal--26-*-jisx0201.1976-0
!*VT100*kanjiFont4:		-*-fixed-medium-r-normal--26-*-jisx0208.1983-0
!*VT100*hanziFont4:		-*-fixed-medium-r-normal--26-*-gb2312.1980-0
!*VT100*hangulFont4:		-*-fixed-medium-r-normal--26-*-ksc5601.1987-0
!*VT100*boldFontList4:		-*-fixed-bold-r-normal--26-*
!*VT100*boldFont4:		-*-fixed-bold-r-normal--26-*-iso8859-1
!*VT100*romanKanaBoldFont4:	-*-fixed-bold-r-normal--26-*-jisx0201.1976-0
!*VT100*kanjiBoldFont4:		-*-fixed-bold-r-normal--26-*-jisx0208.1983-0
!*VT100*hanziBoldFont4:		-*-fixed-bold-r-normal--26-*-gb2312.1980-0
!*VT100*hangulBoldFont4:	-*-fixed-bold-r-normal--26-*-ksc5601.1987-0
X
!fontescape and fontsel overridden by application
*fontMenu*fontescape*Label:	Escape Sequence
*fontMenu*fontsel*Label:	Selection
X
*VT100*language:		japanese
*VT100*kanjiMode:		jis
*VT100*hanziMode:		guobiao
*VT100*hangulMode:		ks-8bit
X
!The following three resources are the path/file names of the GuoBiao
!<-> Big5 conversion tables and the Hangul N-byte <-> 8-bit KS
!conversion table.  They cannot be set from the command line.
X
*VT100*hanziGbToBigTable:	/usr/local/lib/X11/kterm/g2b.table
*VT100*hanziBigToGbTable:	/usr/local/lib/X11/kterm/b2g.table
*VT100*hangulNtoKSTable:	/usr/local/lib/X11/kterm/n2ks.table
X
*VT100*lineSpace:		0
X
*VT100*Color0:			Black
*VT100*Color1:			Blue
*VT100*Color2:			Red
*VT100*Color3:			Magenta
*VT100*Color4:			Green
*VT100*Color5:			Cyan
*VT100*Color6:			Yellow
*VT100*Color7:			White
X
*tekMenu.Label:			Tek Options
*tekMenu*tektextlarge*Label:	Large Characters
*tekMenu*tektext2*Label:	#2 Size Characters
*tekMenu*tektext3*Label:	#3 Size Characters
*tekMenu*tektextsmall*Label:	Small Characters
*tekMenu*tekpage*Label:		PAGE
*tekMenu*tekreset*Label:	RESET
*tekMenu*tekcopy*Label:		COPY
*tekMenu*vtshow*Label:		Show VT Window
*tekMenu*vtmode*Label:		Switch to VT Mode
*tekMenu*tekhide*Label:		Hide Tek Window
X
*tek4014*fontLarge:		9x15
*tek4014*font2:			8x13
*tek4014*font3:			6x13
*tek4014*fontSmall:		6x10
SHAR_EOF
chmod 0664 kterm-4.1.2/KTerm.ad ||
echo 'restore of kterm-4.1.2/KTerm.ad failed'
Wc_c="`wc -c < 'kterm-4.1.2/KTerm.ad'`"
test 7899 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/KTerm.ad: original size 7899, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/KTerm.tmpl ==============
if test -f 'kterm-4.1.2/KTerm.tmpl' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/KTerm.tmpl (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/KTerm.tmpl (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/KTerm.tmpl' &&
/*
X * This file defines an imake rule for installing conversion tables.
X *
X * mleisher at nmsu.edu (Mark Leisher) Wed Jan 30 21:41:43 1991
X */
X
/*
X * InstConvTblFlags - define the flags to be used when installing
X *                    conversion tables.
X */
#ifndef InstConvTblFlags
# ifdef InstManFlags
#   define InstConvTblFlags InstManFlags
# else
#   define InstConvTblFlags -m 0644
# endif
INSTCONVTBLFLAGS = InstConvTblFlags
#endif /* InstConvTblFlags */
X
/*
X * InstallKtermConvTable - generate rules to install the indicated
X *                         kterm conversion table.
X */
#ifndef InstallKtermConvTable
#define InstallKtermConvTable(tbl,dest)					@@\
install.table:: tbl         						@@\
X	$(INSTALL) -c $(INSTCONVTBLFLAGS) tbl dest
#endif /* InstallKtermConvTable */
SHAR_EOF
chmod 0664 kterm-4.1.2/KTerm.tmpl ||
echo 'restore of kterm-4.1.2/KTerm.tmpl failed'
Wc_c="`wc -c < 'kterm-4.1.2/KTerm.tmpl'`"
test 780 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/KTerm.tmpl: original size 780, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/Makefile ==============
if test -f 'kterm-4.1.2/Makefile' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/Makefile (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/Makefile (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/Makefile' &&
# Makefile generated by imake - do not edit!
# $XConsortium: imake.c,v 1.51 89/12/12 12:37:30 jim Exp $
#
# The cpp used on this machine replaces all newlines and multiple tabs and
# spaces in a macro expansion with a single space.  Imake tries to compensate
# for this, but is not always successful.
#
X
###########################################################################
# Makefile generated from "Imake.tmpl" and <Imakefile>
# $XConsortium: Imake.tmpl,v 1.77 89/12/18 17:01:37 jim Exp $
#
# Platform-specific parameters may be set in the appropriate .cf
# configuration files.  Site-wide parameters may be set in the file
# site.def.  Full rebuilds are recommended if any parameters are changed.
#
# If your C preprocessor doesn't define any unique symbols, you'll need
# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing
# "make Makefile", "make Makefiles", or "make World").
#
# If you absolutely can't get imake to work, you'll need to set the
# variables at the top of each Makefile as well as the dependencies at the
# bottom (makedepend will do this automatically).
#
X
###########################################################################
# platform-specific configuration parameters - edit sun.cf to change
X
# platform:  $XConsortium: sun.cf,v 1.38 89/12/23 16:10:10 jim Exp $
# operating system:  SunOS 4.1
X
###########################################################################
# site-specific configuration parameters - edit site.def to change
X
# site:  $XConsortium: site.def,v 1.21 89/12/06 11:46:50 jim Exp $
X
X            SHELL = /bin/sh
X
X              TOP = /usr/local/src/X11/mit
X      CURRENT_DIR = .
X
X               AR = ar clq
X  BOOTSTRAPCFLAGS =
X               CC = cc
X
X         COMPRESS = compress
X              CPP = /lib/cpp $(STD_CPP_DEFINES)
X    PREPROCESSCMD = cc -E $(STD_CPP_DEFINES)
X          INSTALL = install
X               LD = ld
X             LINT = lint
X      LINTLIBFLAG = -C
X         LINTOPTS = -axz
X               LN = ln -s
X             MAKE = make
X               MV = mv
X               CP = cp
X           RANLIB = ranlib
X  RANLIBINSTFLAGS =
X               RM = rm -f
X     STD_INCLUDES =
X  STD_CPP_DEFINES =
X      STD_DEFINES =
X EXTRA_LOAD_FLAGS =
X  EXTRA_LIBRARIES =
X             TAGS = ctags
X
X    SHAREDCODEDEF = -DSHAREDCODE
X         SHLIBDEF = -DSUNSHLIB
X
X    PROTO_DEFINES =
X
X     INSTPGMFLAGS =
X
X     INSTBINFLAGS = -m 0775
X     INSTUIDFLAGS = -m 4775
X     INSTLIBFLAGS = -m 0664
X     INSTINCFLAGS = -m 0664
X     INSTMANFLAGS = -m 0664
X     INSTDATFLAGS = -m 0664
X    INSTKMEMFLAGS = -m 4775
X
X          DESTDIR =
X
X     TOP_INCLUDES = -I$(INCROOT)
X
X      CDEBUGFLAGS = -O
X        CCOPTIONS =
X      COMPATFLAGS = -DXAW_BC
X
X      ALLINCLUDES = $(STD_INCLUDES) $(TOP_INCLUDES) $(INCLUDES) $(EXTRA_INCLUDES)
X       ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(PROTO_DEFINES) $(DEFINES) $(COMPATFLAGS)
X           CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES)
X        LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES)
X           LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
X        LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS)
X   LDCOMBINEFLAGS = -X -r
X
X        MACROFILE = sun.cf
X           RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut
X
X    IMAKE_DEFINES =
X
X         IRULESRC = $(CONFIGDIR)
X        IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES)
X
X     ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \
X			$(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \
X			$(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES)
X
###########################################################################
# X Window System Build Parameters
# $XConsortium: Project.tmpl,v 1.63 89/12/18 16:46:44 jim Exp $
X
###########################################################################
# X Window System make variables; this need to be coordinated with rules
# $XConsortium: Project.tmpl,v 1.63 89/12/18 16:46:44 jim Exp $
X
X          PATHSEP = /
X        USRLIBDIR = /usr/local/lib/X11R4
X           BINDIR = /usr/local/bin/X11R4
X          INCROOT = /usr/include/X11
X     BUILDINCROOT = $(TOP)
X      BUILDINCDIR = $(BUILDINCROOT)/X11
X      BUILDINCTOP = ..
X           INCDIR = $(INCROOT)/X11
X           ADMDIR = $(DESTDIR)/usr/adm
X           LIBDIR = /usr/local/lib/X11R4
X        CONFIGDIR = $(LIBDIR)/config
X       LINTLIBDIR = $(USRLIBDIR)/lint
X
X          FONTDIR = /usr/local/lib/X11R4/fonts
X         XINITDIR = $(LIBDIR)/xinit
X           XDMDIR = $(LIBDIR)/xdm
X           AWMDIR = $(LIBDIR)/awm
X           TWMDIR = $(LIBDIR)/twm
X           GWMDIR = $(LIBDIR)/gwm
X          MANPATH = $(DESTDIR)/usr/local/man
X    MANSOURCEPATH = $(MANPATH)/man
X           MANDIR = /usr/local/man/man1
X        LIBMANDIR = $(MANSOURCEPATH)3X
X      XAPPLOADDIR = $(LIBDIR)/app-defaults
X
X        SOXLIBREV = 4.2
X          SOXTREV = 4.0
X         SOXAWREV = 4.0
X        SOOLDXREV = 4.0
X         SOXMUREV = 4.0
X        SOXEXTREV = 4.0
X
X       FONTCFLAGS = -t
X
X     INSTAPPFLAGS = $(INSTDATFLAGS)
X
X            IMAKE = imake
X           DEPEND = makedepend
X              RGB = rgb
X            FONTC = bdftosnf
X        MKFONTDIR = mkfontdir
X        MKDIRHIER = /bin/sh $(BINDIR)/mkdirhier.sh
X
X        CONFIGSRC = $(TOP)/config
X        CLIENTSRC = $(TOP)/clients
X          DEMOSRC = $(TOP)/demos
X           LIBSRC = $(TOP)/lib
X          FONTSRC = $(TOP)/fonts
X       INCLUDESRC = $(TOP)/X11
X        SERVERSRC = $(TOP)/server
X          UTILSRC = $(TOP)/util
X        SCRIPTSRC = $(UTILSRC)/scripts
X       EXAMPLESRC = $(TOP)/examples
X       CONTRIBSRC = $(TOP)/../contrib
X           DOCSRC = $(TOP)/doc
X           RGBSRC = $(TOP)/rgb
X        DEPENDSRC = $(UTILSRC)/makedepend
X         IMAKESRC = $(CONFIGSRC)
X         XAUTHSRC = $(LIBSRC)/Xau
X          XLIBSRC = $(LIBSRC)/X
X           XMUSRC = $(LIBSRC)/Xmu
X       TOOLKITSRC = $(LIBSRC)/Xt
X       AWIDGETSRC = $(LIBSRC)/Xaw
X       OLDXLIBSRC = $(LIBSRC)/oldX
X      XDMCPLIBSRC = $(LIBSRC)/Xdmcp
X      BDFTOSNFSRC = $(FONTSRC)/bdftosnf
X     MKFONTDIRSRC = $(FONTSRC)/mkfontdir
X     EXTENSIONSRC = $(TOP)/extensions
X
X  DEPEXTENSIONLIB = $(USRLIBDIR)/libXext.a
X     EXTENSIONLIB =  -lXext
X
X          DEPXLIB = $(DEPEXTENSIONLIB)
X             XLIB = $(EXTENSIONLIB) -lX11
X
X      DEPXAUTHLIB = $(USRLIBDIR)/libXau.a
X         XAUTHLIB =  -lXau
X
X        DEPXMULIB =
X           XMULIB = -lXmu
X
X       DEPOLDXLIB =
X          OLDXLIB = -loldX
X
X      DEPXTOOLLIB =
X         XTOOLLIB = -lXt
X
X        DEPXAWLIB =
X           XAWLIB = -lXaw
X
X LINTEXTENSIONLIB = $(USRLIBDIR)/llib-lXext.ln
X         LINTXLIB = $(USRLIBDIR)/llib-lX11.ln
X          LINTXMU = $(USRLIBDIR)/llib-lXmu.ln
X        LINTXTOOL = $(USRLIBDIR)/llib-lXt.ln
X          LINTXAW = $(USRLIBDIR)/llib-lXaw.ln
X
X          DEPLIBS = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB)
X
X         DEPLIBS1 = $(DEPLIBS)
X         DEPLIBS2 = $(DEPLIBS)
X         DEPLIBS3 = $(DEPLIBS)
X
###########################################################################
# Imake rules for building libraries, programs, scripts, and data files
# rules:  $XConsortium: Imake.rules,v 1.67 89/12/18 17:14:15 jim Exp $
X
###########################################################################
# start of Imakefile
X
###########################################################################
#                                                                         #
#                         Attention kterm porters                         #
#                                                                         #
#                                                                         #
# Kterm assumes that bcopy can handle overlapping arguments.  If your     #
# bcopy (or memcpy) can't, write a routine called bcopy and link it in    #
# or add -Dbcopy=mybcopy to the DEFINES list below.                       #
#                                                                         #
###########################################################################
X
X   TTYGROUPDEF = -DUSE_TTY_GROUP
X
X   MAIN_DEFINES = -DUTMP $(TTYGROUPDEF) $(PUCCPTYDDEF)
X   MISC_DEFINES = -temp=./tmp
X   DEFINES = -DKTERM -DMB_WSEL -DWCHAR_T -DSTATUSLINE -DKEEPALIVE -DCOLOR_TEXT
X
INSTCONVTBLFLAGS = -m 0664
X
X         TABLES = b2g.table g2b.table n2ks.table
X   CONV_TBL_DIR = $(USRLIBDIR)/kterm
X
X          SRCS1 = button.c charproc.c cursor.c data.c input.c \
X		  main.c menu.c misc.c screen.c scrollbar.c tabs.c \
X		  TekPrsTbl.c Tekproc.c util.c VTPrsTbl.c \
X		  convert.c kconvert.c convlib.c hgutil.c hzutil.c
X          OBJS1 = main.o input.o charproc.o cursor.o util.o tabs.o \
X		  screen.o scrollbar.o button.o Tekproc.o misc.o \
X		  VTPrsTbl.o TekPrsTbl.o data.o menu.o \
X		  convert.o kconvert.o convlib.o hgutil.o hzutil.o
X           SRCS = $(SRCS1)
X           OBJS = $(OBJS1)
X       PROGRAMS = kterm
X       DEPLIBS1 = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB)
X       PROGRAMS = kterm
X
X     TERMCAPLIB = -ltermcap
X
all:: $(PROGRAMS)
X
main.o:
X	$(RM) $@
X	$(CC) -c $(CFLAGS) $(MAIN_DEFINES) $*.c
X
misc.o:
X	$(RM) $@
X	$(CC) -c $(CFLAGS) $(MISC_DEFINES) $*.c
X
charproc.o:
X	$(RM) $@
X	$(CC) -c $(CFLAGS) $(MISC_DEFINES) $*.c
X
kterm: $(OBJS1) $(DEPLIBS1)
X	$(RM) $@
X	$(CC) -o $@ $(OBJS1) $(LDOPTIONS) $(XAWLIB) $(XMULIB) $(XTOOLLIB) $(XLIB) $(LDLIBS) $(TERMCAPLIB) $(PTYLIB) $(EXTRA_LOAD_FLAGS)
X
clean::
X	$(RM) kterm
X
install:: kterm
X	$(INSTALL) -c $(INSTPGMFLAGS)  $(INSTUIDFLAGS) kterm  $(BINDIR)
X
install:: KTerm.ad
X	$(INSTALL) -c $(INSTAPPFLAGS) KTerm.ad $(XAPPLOADDIR)/KTerm
X
install.man:: kterm.man
X	$(INSTALL) -c $(INSTMANFLAGS) kterm.man $(MANDIR)/kterm.1
X
install.table:: $(TABLES)
X	$(INSTALL) -c $(INSTCONVTBLFLAGS) $(TABLES) $(CONV_TBL_DIR)
X
depend::
X	$(DEPEND) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS)
X
###########################################################################
# common rules for all Makefiles - do not edit
X
emptyrule::
X
clean::
X	$(RM_CMD) \#*
X
Makefile::
X	- at if [ -f Makefile ]; then \
X	echo "	$(RM) Makefile.bak; $(MV) Makefile Makefile.bak"; \
X	$(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \
X	else exit 0; fi
X	$(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)
X
tags::
X	$(TAGS) -w *.[ch]
X	$(TAGS) -xw *.[ch] > TAGS
X
saber:
X	#load $(ALLDEFINES) $(SRCS)
X
osaber:
X	#load $(ALLDEFINES) $(OBJS)
X
###########################################################################
# empty rules for directories that do not have SUBDIRS - do not edit
X
install::
X	@echo "install in $(CURRENT_DIR) done"
X
install.man::
X	@echo "install.man in $(CURRENT_DIR) done"
X
Makefiles::
X
includes::
X
###########################################################################
# dependencies generated by makedepend
X
SHAR_EOF
chmod 0664 kterm-4.1.2/Makefile ||
echo 'restore of kterm-4.1.2/Makefile failed'
Wc_c="`wc -c < 'kterm-4.1.2/Makefile'`"
test 10613 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/Makefile: original size 10613, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/README ==============
if test -f 'kterm-4.1.2/README' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/README (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/README (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/README' &&
INTRODUCTION
------------
Kterm is a modified version of xterm that is capable of displaying
text from character sets requiring 2-bytes per character as well as
the standard single byte character sets.  The original kterm was
designed to support display of Japanese text.  This capability has
been expanded to include Chinese and Korean as well.
X
CHARACTER SETS AND CODINGS
--------------------------
Version 4.1.2 of kterm can display Chinese, Japanese, and Korean text
in a number of coding systems.  With the exception of the Korean
N-byte coding, all of the coding systems described below require two
bytes per character.
X
X   1. Chinese
X
X      A. GB2312-1980 (GuoBiao) PRC standard
X         GB is a seven bit standard that requires two bytes per
X         character.  It is most often used with the high (most
X         significant) bit set on each byte of the character to
X         distinguish the Chinese text from other seven bit text.  The
X         eight bit usage of GB is also used in CCDOS, the Chinese
X         version of MS-DOS.
X         NOTE: Perhaps the eight bit usage should be refered to as
X               EUC (Extended Unix Code).
X         CODE RANGE: 0xA1A1-0xFEFE
X
X      B. Shift-GB
X         Shift-GB is a mixed seven and eight bit coding, with the
X         first byte always having the high (most significant) bit set
X         to distinguish it from other seven bit text.  Shift-GB was
X         used by the Chinese Macintosh OS until recently.
X         NOTE: I'm not sure if it is an official standard.
X         CODE RANGE: 0x8140-0xAFFC (excluding 0x7F as a second byte)
X
X      C. Big5
X         Big5 is a mixed seven and eight bit coding, with the first
X         byte always having the high (most significant) bit set to
X         distinguish it from the other seven bit text.  Big5 is at
X         least a de facto standard in places like Hong Kong and Taiwan
X         where the Traditional Chinese ideographs are used.
X         NOTE: Rumor has it that it is, or will be a standard in
X               Taiwan.  I don't have any facts on this yet.
X         CODE RANGE: 0xA140-0xF9FE
X
X   2. Japanese
X
X      A. JIS (Japanese Industrial Standard X0208-1983)
X         JIS is a seven bit standard that is usually distinguished
X         from other seven bit text by a starting and ending escape
X         sequence.
X         START ESCAPE SEQUENCE: <ESC>$B (NEW-JIS) <ESC>@B (OLD-JIS)
X         END ESCAPE SEQUENCE  : <ESC>(B
X         CODE RANGE: 0x2121-0x7E7E
X
X      B. Shift-JIS
X         Shift-JIS is a mixed seven and eight bit coding, with the
X         high (most significant) bit of the first byte set to
X         distinguish it from the other seven bit text.
X         CODE RANGE:
X           FIRST BYTE : 0x81-0x9F and 0xE0-0xEF
X           SECOND BYTE: 0x40-0xFC (excluding 0x7F)
X
X      C. EUC
X         EUC is an eight bit usage of JIS, with the high (most
X         significant) bit of each byte set to distinguish it from
X         other seven bit text.
X         CODE RANGE: 0xA1A1-0xFEFE
X
X   3. Korean
X
X      A. KSC5601-1987 (Jamos and Hangul)
X         This version of kterm only supports the Jamos (Hangul
X         elements) and Hangul portion of the KSC5601-1987 standard.
X         The Hanja portion will come later.
X         KS is a seven bit standard that requires two bytes per
X         Hangul character.  It is most often used with the high (most
X         significant) bit set on each byte of the character to
X         distinguish the Korean text from other seven bit text.
X         NOTE: Perhaps the eight bit usage should be refered to as
X               EUC (Extended Unix Code).
X         CODE RANGE:
X           JAMOS : 0xA4A1-0xA4FE
X           HANGUL: 0xB0A1-0xC8FE
X
X      B. N-byte
X         N-byte code is a way of representing Hangul text using only
X         ASCII characters.  It uses a variable number of bytes to
X         select a particular Hangul syllable and is distinguished from
X         other seven bit text by the SO (Shift Out) sequence and the SI
X         (Shift In) sequence.
X         START ESCAPE SEQUENCE: ^N (0x0E)
X         END ESCAPE SEQUENCE  : ^O (0x0F)
X         CODE RANGE: 0x41-0x7C (full range)
X         NOTE: The code range actually varies.  See the file
X               "hgutil.c" for details.
X         
X   4. X11 Compound Text
X      Version 4.1.2 of kterm now recognizes most of the Compound Text
X      approved standard encodings.  It does not recognize the
X      non-standard character set encodings or the directionality
X      indicators.  Even though the approved standard encodings are
X      recognized, this is no guarantee that they will display text
X      appropriately, specifically the right-to-left encodings.  Code
X      will have to be added to support this.
X
X      The 94^N Compound Text sequences for GB 2312-1980, JIS
X      X0208-1983, and KS C5601-1987 will be interpreted correctly if
X      the appropriate language is chosen when starting kterm, or if it
X      is set in the application defaults file, KTerm.ad.
X
FONTS
-----
There are a number of freely available Chinese, Japanese and Korean
XX11 fonts available.  Here are some anonymous ftp sites where the
fonts are available:
X
1. HOST: crl.nmsu.edu [128.123.1.14]
X   CRL has a relatively complete collection of the freely available
X   Chinese, Japanese, and Korean X11 fonts.  They are located in the
X   subdirectories pub/chinese/fonts, pub/japanese/fonts, and
X   pub/korean/.  The CRL site also has lists of known anonymous ftp
X   sites for software related to the language of interest.
X
2. HOST: miki.cs.titech.ac.jp [131.112.16.39]
X   HOST: utsun.s.u-tokyo.ac.jp [133.11.11.11]
X   These ftp sites have large collections of many Usenet and JUNET
X   newsgroup archives.  The fj.sources archives contain many of the
X   Japanese X11 fonts that have been posted on JUNET.  There are Index
X   files in most of the directories describing which archive file has
X   the font sources.
X
3. HOST: kum.kaist.ac.kr [137.68.1.65]
X   There are a few Korean utilities available from this site as well
X   as archives of a number of Usenet news groups.  Most of the Korean
X   related code and fonts are located in pub/hangul/.
X
AUTHORS AND CONTRIBUTORS
------------------------
The initial conversion work on xterm for displaying Japanese text was
done by kagotani at cs.titech.ac.jp (Hiroto Kagotani).
X
The ANSI color support was added using the kterm 4.1.0 patches
provided by mukawa at tn-sec.ntt.junet (Susumu Mukawa).
X
The Multi-Byte Character Set Word Select feature was added using a
modified version of Kiyoshi KANAZAWA's 4.1.0 MBCS_WSEL patches.
X
The Chinese and Korean support was added by
mleisher at nmsu.edu (Mark Leisher).
X
CLOSING NOTES
-------------
The {character set,font set,language,conversion} mechanisms are a little
clumsy and should eventually be modified to be more in line with XPG3
locale specifications and the up-coming X11 i18n specifications.
Hopefully, this won't be too far away.
X
BUG REPORTS
-----------
Please send bug reports and/or fixes for kterm 4.1.2 to
mleisher at nmsu.edu or mleisher at nmsu.bitnet.
X
THANKS
------
I would like to express my thanks to Mr. Kagotani for doing the
initial conversion work.  His code made it a lot easier for me to add
support for Chinese and Korean.
X
Thanks go to Ricky Yeung and F. F. Lee for making their Chinese code
conversion programs freely available.
X
I would also like to thank ujsung at solgai.kaist.ac.kr (UnJae Sung) for
having the patience to answer my questions about Korean coding.
X
And last but not least, thanks go to these people for significant bug
reports and fixes:
X
X  John Melby of Fujitsu
X
X  Martin C. Fong of Sybase
X
X  Yang Zhiwei of the German National Research Center for Computer
X  Science
X
X  Alton Harkcom (for help updating the Japanese manual page)
X
X
X				Sat May  4 14:11:37 1991
X
X				Internet: mleisher at nmsu.edu
X				Bitnet  : mleisher at nmsu.bitnet
X
X				Mark Leisher
X				Computing Research Lab
X				New Mexico State University
X                                Box 3CRL
X				Las Cruces, NM 88001-0001
X				+1 505 646-5711
SHAR_EOF
chmod 0664 kterm-4.1.2/README ||
echo 'restore of kterm-4.1.2/README failed'
Wc_c="`wc -c < 'kterm-4.1.2/README'`"
test 8007 -eq "$Wc_c" ||
	echo 'kterm-4.1.2/README: original size 8007, current size' "$Wc_c"
rm -f _shar_wnt_.tmp
fi
# ============= kterm-4.1.2/TekPrsTbl.c ==============
if test -f 'kterm-4.1.2/TekPrsTbl.c' -a X"$1" != X"-c"; then
	echo 'x - skipping kterm-4.1.2/TekPrsTbl.c (File already exists)'
	rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting kterm-4.1.2/TekPrsTbl.c (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'kterm-4.1.2/TekPrsTbl.c' &&
/*
X *	$XConsortium: TekPrsTbl.c,v 1.3 89/03/01 19:59:14 jim Exp $
X */
X
X
#include <X11/copyright.h>
X
/*
X * Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
X *
X *                         All Rights Reserved
X *
X * Permission to use, copy, modify, and distribute this software and its
X * documentation for any purpose and without fee is hereby granted,
X * provided that the above copyright notice appear in all copies and that
X * both that copyright notice and this permission notice appear in
X * supporting documentation, and that the name of Digital Equipment
X * Corporation not be used in advertising or publicity pertaining to
X * distribution of the software without specific, written prior permission.
X *
X *
X * DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
X * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
X * DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
X * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
X * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
X * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
X * SOFTWARE.
X */
X
#ifndef lint
static char *rcsid_Tekparsetable_c = "$XConsortium: TekPrsTbl.c,v 1.3 89/03/01 19:59:14 jim Exp $";
#endif	/* lint */
X
#include "Tekparse.h"
#ifndef lint
static char rcs_id[] = "$XConsortium: TekPrsTbl.c,v 1.3 89/03/01 19:59:14 jim Exp $";
#endif	/* lint */
X
int Talptable[] = {
/*	NUL		SOH		STX		ETX	*/
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*	EOT		ENQ		ACK		BEL	*/
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_BEL,
/*	BS		HT		NL		VT	*/
CASE_BS,
CASE_TAB,
CASE_LF,
CASE_UP,
/*	NP		CR		SO		SI	*/
CASE_IGNORE,
CASE_CR,
CASE_IGNORE,
CASE_IGNORE,
/*	DLE		DC1		DC2		DC3	*/
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*	DC4		NAK		SYN		ETB	*/
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*	CAN		EM		SUB		ESC	*/
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_ESC_STATE,
/*	FS		GS		RS		US	*/
CASE_PT_STATE,
CASE_PLT_STATE,
CASE_IPL_STATE,
CASE_ALP_STATE,
/*	SP		!		"		#	*/
CASE_SP,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	$		%		&		'	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	(		)		*		+	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	,		-		.		/	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	0		1		2		3	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	4		5		6		7	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	8		9		:		;	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	<		=		>		?	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	@		A		B		C	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	D		E		F		G	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	H		I		J		K	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	L		M		N		O	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	P		Q		R		S	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	T		U		V		W	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	X		Y		Z		[	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	\		]		^		_	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	`		a		b		c	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	d		e		f		g	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	h		i		j		k	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	l		m		n		o	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	p		q		r		s	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	t		u		v		w	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	x		y		z		{	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*	|		}		~		DEL	*/
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_IGNORE,
/*      0x80            0x81            0x82            0x83    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x84            0x85            0x86            0x87    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x88            0x89            0x8a            0x8b    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x8c            0x8d            0x8e            0x8f    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x90            0x91            0x92            0x93    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x94            0x95            0x96            0x97    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x99            0x99            0x9a            0x9b    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      0x9c            0x9d            0x9e            0x9f    */
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
CASE_IGNORE,
/*      nobreakspace    exclamdown      cent            sterling        */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      currency        yen             brokenbar       section         */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      diaeresis       copyright       ordfeminine     guillemotleft   */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      notsign         hyphen          registered      macron          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      degree          plusminus       twosuperior     threesuperior   */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      acute           mu              paragraph       periodcentered  */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      cedilla         onesuperior     masculine       guillemotright  */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      onequarter      onehalf         threequarters   questiondown    */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Agrave          Aacute          Acircumflex     Atilde          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Adiaeresis      Aring           AE              Ccedilla        */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Igrave          Iacute          Icircumflex     Idiaeresis      */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Eth             Ntilde          Ograve          Oacute          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Ocircumflex     Otilde          Odiaeresis      multiply        */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Ooblique        Ugrave          Uacute          Ucircumflex     */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      Udiaeresis      Yacute          Thorn           ssharp          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      agrave          aacute          acircumflex     atilde          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      adiaeresis      aring           ae              ccedilla        */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      egrave          eacute          ecircumflex     ediaeresis      */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      igrave          iacute          icircumflex     idiaeresis      */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      eth             ntilde          ograve          oacute          */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      ocircumflex     otilde          odiaeresis      division        */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      oslash          ugrave          uacute          ucircumflex     */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
/*      udiaeresis      yacute          thorn           ydiaeresis      */
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
CASE_PRINT,
};
X
int Tbestable[] = {
/*	NUL		SOH		STX		ETX	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_VT_MODE,
/*	EOT		ENQ		ACK		BEL	*/
CASE_BYP_STATE,
CASE_REPORT,
CASE_BYP_STATE,
CASE_BEL,
/*	BS		HT		NL		VT	*/
CASE_BS,
CASE_TAB,
CASE_IGNORE,
CASE_UP,
/*	NP		CR		SO		SI	*/
CASE_PAGE,
CASE_IGNORE,
CASE_BYP_STATE,
CASE_BYP_STATE,
/*	DLE		DC1		DC2		DC3	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
/*	DC4		NAK		SYN		ETB	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_COPY,
/*	CAN		EM		SUB		ESC	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_GIN,
CASE_IGNORE,
/*	FS		GS		RS		US	*/
CASE_SPT_STATE,
CASE_PLT_STATE,
CASE_IPL_STATE,
CASE_ALP_STATE,
/*	SP		!		"		#	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
/*	$		%		&		'	*/
CASE_BYP_STATE,
CASE_BYP_STATE,
CASE_BYP_STATE,
SHAR_EOF
true || echo 'restore of kterm-4.1.2/TekPrsTbl.c failed'
fi
echo 'End of kterm-4.1.2 part 1'
echo 'File kterm-4.1.2/TekPrsTbl.c is continued in part 2'
echo 2 > _shar_seq_.tmp
exit 0


-----------------------------------------------------------------------------
mleisher at nmsu.edu                      "I laughed.
Mark Leisher                                I cried.
Computing Research Lab                          I fell down.
New Mexico State University                        It changed my life."
Las Cruces, NM                     - Rich [Cowboy Feng's Space Bar and Grille]

--
Dan Heller
O'Reilly && Associates       Z-Code Software    Comp-sources-x:
Senior Writer                President          comp-sources.x at uunet.uu.net
argv at ora.com                 argv at zipcode.com



More information about the Comp.sources.x mailing list