source: trunk/third/kermit/ckcxla.h @ 10780

Revision 10780, 7.4 KB checked in by brlewis, 27 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r10779, which included commits to RCS files with non-trunk default branches.
Line 
1/*
2  File CKCXLA.H
3
4  System-independent character-set translation header file for C-Kermit.
5*/
6
7/*
8  Author: Frank da Cruz (fdc@columbia.edu, FDCCU@CUVMA.BITNET),
9  Columbia University Academic Information Systems, New York City.
10
11  Copyright (C) 1985, 1996, Trustees of Columbia University in the City of New
12  York.  The C-Kermit software may not be, in whole or in part, licensed or
13  sold for profit as a software product itself, nor may it be included in or
14  distributed with commercial products or otherwise distributed by commercial
15  concerns to their clients or customers without written permission of the
16  Office of Kermit Development and Distribution, Columbia University.  This
17  copyright notice must not be removed, altered, or obscured.
18*/
19#ifndef CKCXLA_H                        /* Guard against multiple inclusion */
20#define CKCXLA_H
21
22#ifndef KANJI                           /* Systems supporting Kanji */
23#ifdef OS2
24#define KANJI
25#endif /* OS2 */
26#endif /* KANJI */
27
28#ifdef NOKANJI                          /* Except if NOKANJI is defined. */
29#ifdef KANJI
30#undef KANJI
31#endif /* KANJI */
32#endif /* NOKANJI */
33
34#ifndef CKOUNI                          /* Unicode support */
35#ifdef OS2
36#define CKOUNI
37#endif /* OS2 */
38#endif /* CKOUNI */
39
40/*
41   Disable all support for all classes of character sets
42   if NOCSETS is defined.
43*/
44#ifdef NOCSETS
45
46#ifdef CKOUNI
47#undef CKOUNI
48#endif /* CKOUNI */
49#ifdef KANJI
50#undef KANJI
51#endif /* KANJI */
52#ifdef CYRILLIC
53#undef CYRILLIC
54#endif /* CYRILLIC */
55#ifdef LATIN2
56#undef LATIN2
57#endif /* LATIN2 */
58#ifdef HEBREW
59#undef HEBREW
60#endif /* HEBREW */
61
62#else /* Not NOCSETS - Rest of this file... */
63
64#ifndef NOLATIN2                        /* If they didn't say "no Latin-2" */
65#ifndef LATIN2                          /* Then if LATIN2 isn't already */
66#define LATIN2                          /* defined, define it. */
67#endif /* LATIN2 */
68#endif /* NOLATIN2 */
69
70#ifndef NOCYRIL                         /* If they didn't say "no Cyrillic" */
71#ifndef CYRILLIC                        /* Then if CYRILLIC isn't already */
72#define CYRILLIC                        /* defined, define it. */
73#endif /* CYRILLIC */
74#endif /* NOCYRIL */
75
76#ifndef NOHEBREW                        /* If they didn't say "no Hebrew" */
77#ifndef HEBREW                          /* Then if HEBREW isn't already */
78#define HEBREW                          /* defined, define it. */
79#endif /* HEBREW */
80#endif /* NOHEBREW */
81
82/* File ckcxla.h -- Character-set-related definitions, system independent */
83
84/* Codes for Kermit Transfer Syntax Level (obsolete) */
85
86#define TS_L0 0          /* Level 0 (Transparent) */
87#define TS_L1 1          /* Level 1 (one standard character set) */
88#define TS_L2 2          /* Level 2 (multiple character sets in same file) */
89
90#define UNK 63           /* Symbol to use for unknown character (63 = ?) */
91
92/*
93  Codes for the base alphabet of a given character set.
94  These are assigned in roughly ISO 8859 order.
95  (Each is assumed to include ASCII/Roman.)
96*/
97#define AL_UNIV    0                    /* Universal (like ISO 10646) */
98#define AL_ROMAN   1                    /* Roman (Latin) alphabet */
99#define AL_CYRIL   2                    /* Cyrillic alphabet */
100#define AL_ARABIC  3                    /* Arabic */
101#define AL_GREEK   4                    /* Greek */
102#define AL_HEBREW  5                    /* Hebrew */
103#define AL_KANA    6                    /* Japanese Katakana */
104#define AL_JAPAN   7                    /* Japanese Katakana+Kanji ideograms */
105#define AL_HAN     8                    /* Chinese/Japanese/Korean ideograms */
106#define AL_INDIA   9                    /* Indian scripts (ISCII) */
107#define AL_VIET   10                    /* Vietnamese (VISCII) */
108                                        /* Add more here... */
109#define AL_UNK   999                    /* Unknown (transparent) */
110
111/* Codes for languages */
112/*
113  NOTE: It would perhaps be better to use ISO 639-1988 2-letter "Codes for
114  Representation of Names of Languages" here, shown in the comments below.
115*/
116#define L_ASCII       0  /* EN ASCII, English */
117#define L_USASCII     0  /* EN ASCII, English */
118#define L_DUTCH       1  /* NL Dutch */
119#define L_FINNISH     2  /* FI Finnish */
120#define L_FRENCH      3  /* FR French */
121#define L_GERMAN      4  /* DE German */
122#define L_HUNGARIAN   5  /* HU Hungarian */
123#define L_ITALIAN     6  /* IT Italian */
124#define L_NORWEGIAN   7  /* NO Norwegian */
125#define L_PORTUGUESE  8  /* PT Portuguese */
126#define L_SPANISH     9  /* ES Spanish */
127#define L_SWEDISH    10  /* SV Swedish */
128#define L_SWISS      11  /* RM Swiss (Rhaeto-Romance) */
129#define L_DANISH     12  /* DA Danish */
130#define L_ICELANDIC  13  /* IS Icelandic */
131#define L_RUSSIAN    14  /* RU Russian */
132#define L_JAPANESE   15  /* JA Japanese */
133#define L_HEBREW     16  /* IW Hebrew */
134
135#define MAXLANG      16  /* Number of languages */
136
137/*
138  File character-sets are defined in the system-specific ck?xla.h file,
139  except for the following ones, which must be available to all versions:
140*/
141#define FC_TRANSP  254                  /* Transparent */
142#define FC_UNDEF   255                  /* Undefined   */
143/*
144  Designators for Kermit's transfer character sets.  These are all standard
145  sets, or based on them.  Symbols must be unique in the first 8 characters,
146  because some C preprocessors have this limit.
147*/
148/* LIST1 */
149#define TC_TRANSP  0   /* Transparent, no character translation */
150#define TC_USASCII 1   /* US 7-bit ASCII */
151#define TC_1LATIN  2   /* ISO 8859-1, Latin-1 */
152#define TC_2LATIN  3   /* ISO 8859-2, Latin-2 */
153#define TC_CYRILL  4   /* ISO 8859-5, Latin/Cyrillic */
154#define TC_JEUC    5   /* Japanese EUC */
155#define TC_HEBREW  6   /* ISO 8859-8, Latin/Hebrew */
156
157#define MAXTCSETS  6   /* Highest Transfer Character Set Number */
158
159#ifdef COMMENT
160/*
161  Not used yet.
162*/
163#define TC_3LATIN  7  /* ISO 8859-3, Latin-3 */
164#define TC_4LATIN  8  /* ISO 8859-4, Latin-4 */
165#define TC_5LATIN  9  /* ISO 8859-9, Latin-5 */
166#define TC_ARABIC 10  /* ISO-8859-6, Latin/Arabic */
167#define TC_GREEK  11  /* ISO-8859-7, Latin/Greek */
168#define TC_JIS208 12  /* Japanese JIS X 0208 multibyte set */
169#define TC_CHINES 13  /* Chinese Standard GB 2312-80 */
170#define TC_KOREAN 14  /* Korean KS C 5601-1987 */
171#define TC_I10646 15  /* ISO DIS 10646 (not defined yet) */
172/* etc... */
173#endif /* COMMENT */
174
175/* Structure for character-set information */
176
177struct csinfo {
178    char *name;                         /* Descriptive name of character set */
179    int size;                           /* Size (e.g. 128, 256, 16384) */
180    int code;                           /* Like TC_1LATIN, etc.  */
181    char *designator;                   /* Designator, like I2/100 = Latin-1 */
182    int alphabet;                       /* Base alphabet */
183    char *keyword;                      /* Keyword for this character-set */
184};
185
186/* Structure for language information */
187
188struct langinfo {
189    int id;                             /* Language ID code (L_whatever) */
190    int fc;                             /* File character set to use */
191    int tc;                             /* Transfer character set to use */
192    char *description;                  /* Description of language */
193};
194
195/* Now take in the system-specific definitions */
196
197#ifdef UNIX
198#include "ckuxla.h"
199#endif /* UNIX */
200
201#ifdef OSK                              /* OS-9 */
202#include "ckuxla.h"
203#endif /* OS-9 */
204
205#ifdef VMS                              /* VAX/VMS */
206#include "ckuxla.h"
207#endif /* VMS */
208
209#ifdef GEMDOS                           /* Atari ST */
210#include "ckuxla.h"
211#endif /* GEMDOS */
212
213#ifdef MAC                              /* Macintosh */
214#include "ckmxla.h"
215#endif /* MAC */
216
217#ifdef OS2                              /* OS/2 */
218#include "ckuxla.h"                     /* Uses big UNIX version */
219#endif /* OS2 */
220
221#ifdef AMIGA                            /* Commodore Amiga */
222#include "ckuxla.h"
223#endif /* AMIGA */
224
225#ifdef datageneral                      /* Data General MV AOS/VS */
226#include "ckuxla.h"
227#endif /* datageneral */
228#ifdef STRATUS                          /* Stratus Computer, Inc. VOS */
229#include "ckuxla.h"
230#endif /* STRATUS */
231
232#ifdef KANJI
233_PROTOTYP( int xkanjf, (void) );
234_PROTOTYP( int xkanjz, (int (*)(char)) );
235_PROTOTYP( int xkanji, (int, int (*)(char)) );
236#endif /* KANJI */
237
238#ifndef MAC
239#ifndef NOLOCAL
240_PROTOTYP( int cs_size, (int) );
241_PROTOTYP( int cs_is_std, (int) );
242_PROTOTYP( int cs_is_nrc, (int) );
243#endif /* NOLOCAL */
244#endif /* MAC */
245
246#endif /* NOCSETS */
247#endif /* CKCXLA_H */
248
249/* End of ckcxla.h */
Note: See TracBrowser for help on using the repository browser.