1/* Copyright 1992 NEC Corporation, Tokyo, Japan.
2 *
3 * Permission to use, copy, modify, distribute and sell this software
4 * and its documentation for any purpose is hereby granted without
5 * fee, provided that the above copyright notice appear in all copies
6 * and that both that copyright notice and this permission notice
7 * appear in supporting documentation, and that the name of NEC
8 * Corporation not be used in advertising or publicity pertaining to
9 * distribution of the software without specific, written prior
10 * permission.  NEC Corporation makes no representations about the
11 * suitability of this software for any purpose.  It is provided "as
12 * is" without express or implied warranty.
13 *
14 * NEC CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
15 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
16 * NO EVENT SHALL NEC CORPORATION BE LIABLE FOR ANY SPECIAL, INDIRECT OR
17 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
18 * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
19 * OTHER TORTUOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20 * PERFORMANCE OF THIS SOFTWARE.
21 */
22
23#if !defined(lint) && !defined(__CODECENTER__)
24static char alphamap_id[] = "@(#) 102.1 $Id: alphamap.h 10525 2004-12-23 21:23:50Z korli $";
25#endif /* lint */
26
27extern int JapaneseMode();
28extern int DoFuncSequence(),UseOtherKeymap();
29
30static struct funccfunc alpha_funcs[] = {
31  {CANNA_FN_SelfInsert		,AlphaSelfInsert	},
32  {CANNA_FN_JapaneseMode	,JapaneseMode		},
33  {CANNA_FN_Nop			,AlphaNop		},
34  {CANNA_FN_FuncSequence	,DoFuncSequence		},
35  {CANNA_FN_UseOtherKeymap	,UseOtherKeymap		},
36  {CANNA_FN_FunctionalInsert	,AlphaSelfInsert	},
37  {DEFAULTBEHAVIOR		,AlphaSelfInsert	},
38
39#ifdef WIN
40  {CANNA_FN_DefineDicMode	,dicTouroku		},
41  {CANNA_FN_DeleteDicMode	,dicSakujo		},
42
43  {CANNA_FN_HenkanRegion	,HenkanRegion		},
44  {CANNA_FN_PhonoEdit		,PhonoEdit		},
45  {CANNA_FN_DicEdit		,DicEdit		},
46  {CANNA_FN_Configure		,Configure		},
47#endif
48  {0				,0			},
49};
50
51BYTE alpha_kmap[256] =
52{
53/* C-@ */       CANNA_FN_SelfInsert,
54/* C-a */       CANNA_FN_SelfInsert,
55/* C-b */       CANNA_FN_SelfInsert,
56/* C-c */       CANNA_FN_SelfInsert,
57/* C-d */       CANNA_FN_SelfInsert,
58/* C-e */       CANNA_FN_SelfInsert,
59/* C-f */       CANNA_FN_SelfInsert,
60/* C-g */       CANNA_FN_SelfInsert,
61/* C-h */       CANNA_FN_SelfInsert,
62/* C-i */       CANNA_FN_SelfInsert,
63/* C-j */       CANNA_FN_SelfInsert,
64/* C-k */       CANNA_FN_SelfInsert,
65/* C-l */       CANNA_FN_SelfInsert,
66/* C-m */       CANNA_FN_SelfInsert,
67/* C-n */       CANNA_FN_SelfInsert,
68/* C-o */       CANNA_FN_JapaneseMode,
69/* C-p */       CANNA_FN_SelfInsert,
70/* C-q */       CANNA_FN_SelfInsert,
71/* C-r */       CANNA_FN_SelfInsert,
72/* C-s */       CANNA_FN_SelfInsert,
73/* C-t */       CANNA_FN_SelfInsert,
74/* C-u */       CANNA_FN_SelfInsert,
75/* C-v */       CANNA_FN_SelfInsert,
76/* C-w */       CANNA_FN_SelfInsert,
77/* C-x */       CANNA_FN_SelfInsert,
78/* C-y */       CANNA_FN_SelfInsert,
79/* C-z */       CANNA_FN_SelfInsert,
80/* C-[ */       CANNA_FN_SelfInsert,
81/* C-\ */       CANNA_FN_SelfInsert,
82/* C-] */       CANNA_FN_SelfInsert,
83/* C-^ */       CANNA_FN_SelfInsert,
84/* C-_ */       CANNA_FN_SelfInsert,
85/* space */     CANNA_FN_SelfInsert,
86/* ! */         CANNA_FN_SelfInsert,
87/* " */         CANNA_FN_SelfInsert,
88/* # */         CANNA_FN_SelfInsert,
89/* $ */         CANNA_FN_SelfInsert,
90/* % */         CANNA_FN_SelfInsert,
91/* & */         CANNA_FN_SelfInsert,
92/* ' */         CANNA_FN_SelfInsert,
93/* ( */         CANNA_FN_SelfInsert,
94/* ) */         CANNA_FN_SelfInsert,
95/* * */         CANNA_FN_SelfInsert,
96/* + */         CANNA_FN_SelfInsert,
97/* , */         CANNA_FN_SelfInsert,
98/* - */         CANNA_FN_SelfInsert,
99/* . */         CANNA_FN_SelfInsert,
100/* / */         CANNA_FN_SelfInsert,
101/* 0 */         CANNA_FN_SelfInsert,
102/* 1 */         CANNA_FN_SelfInsert,
103/* 2 */         CANNA_FN_SelfInsert,
104/* 3 */         CANNA_FN_SelfInsert,
105/* 4 */         CANNA_FN_SelfInsert,
106/* 5 */         CANNA_FN_SelfInsert,
107/* 6 */         CANNA_FN_SelfInsert,
108/* 7 */         CANNA_FN_SelfInsert,
109/* 8 */         CANNA_FN_SelfInsert,
110/* 9 */         CANNA_FN_SelfInsert,
111/*   : */       CANNA_FN_SelfInsert,
112/* ; */         CANNA_FN_SelfInsert,
113/* < */         CANNA_FN_SelfInsert,
114/* = */         CANNA_FN_SelfInsert,
115/* > */         CANNA_FN_SelfInsert,
116/* ? */         CANNA_FN_SelfInsert,
117/* @ */         CANNA_FN_SelfInsert,
118/* A */         CANNA_FN_SelfInsert,
119/* B */         CANNA_FN_SelfInsert,
120/* C */         CANNA_FN_SelfInsert,
121/* D */         CANNA_FN_SelfInsert,
122/* E */         CANNA_FN_SelfInsert,
123/* F */         CANNA_FN_SelfInsert,
124/* G */         CANNA_FN_SelfInsert,
125/* H */         CANNA_FN_SelfInsert,
126/* I */         CANNA_FN_SelfInsert,
127/* J */         CANNA_FN_SelfInsert,
128/* K */         CANNA_FN_SelfInsert,
129/* L */         CANNA_FN_SelfInsert,
130/* M */         CANNA_FN_SelfInsert,
131/* N */         CANNA_FN_SelfInsert,
132/* O */         CANNA_FN_SelfInsert,
133/* P */         CANNA_FN_SelfInsert,
134/* Q */         CANNA_FN_SelfInsert,
135/* R */         CANNA_FN_SelfInsert,
136/* S */         CANNA_FN_SelfInsert,
137/* T */         CANNA_FN_SelfInsert,
138/* U */         CANNA_FN_SelfInsert,
139/* V */         CANNA_FN_SelfInsert,
140/* W */         CANNA_FN_SelfInsert,
141/* X */         CANNA_FN_SelfInsert,
142/* Y */         CANNA_FN_SelfInsert,
143/* Z */         CANNA_FN_SelfInsert,
144/* [ */         CANNA_FN_SelfInsert,
145/* \ */         CANNA_FN_SelfInsert,
146/* ] */         CANNA_FN_SelfInsert,
147/* ^ */         CANNA_FN_SelfInsert,
148/* _ */         CANNA_FN_SelfInsert,
149/* ` */         CANNA_FN_SelfInsert,
150/* a */         CANNA_FN_SelfInsert,
151/* b */         CANNA_FN_SelfInsert,
152/* c */         CANNA_FN_SelfInsert,
153/* d */         CANNA_FN_SelfInsert,
154/* e */         CANNA_FN_SelfInsert,
155/* f */         CANNA_FN_SelfInsert,
156/* g */         CANNA_FN_SelfInsert,
157/* h */         CANNA_FN_SelfInsert,
158/* i */         CANNA_FN_SelfInsert,
159/* j */         CANNA_FN_SelfInsert,
160/* k */         CANNA_FN_SelfInsert,
161/* l */         CANNA_FN_SelfInsert,
162/* m */         CANNA_FN_SelfInsert,
163/* n */         CANNA_FN_SelfInsert,
164/* o */         CANNA_FN_SelfInsert,
165/* p */         CANNA_FN_SelfInsert,
166/* q */         CANNA_FN_SelfInsert,
167/* r */         CANNA_FN_SelfInsert,
168/* s */         CANNA_FN_SelfInsert,
169/* t */         CANNA_FN_SelfInsert,
170/* u */         CANNA_FN_SelfInsert,
171/* v */         CANNA_FN_SelfInsert,
172/* w */         CANNA_FN_SelfInsert,
173/* x */         CANNA_FN_SelfInsert,
174/* y */         CANNA_FN_SelfInsert,
175/* z */         CANNA_FN_SelfInsert,
176/* { */         CANNA_FN_SelfInsert,
177/* | */         CANNA_FN_SelfInsert,
178/* } */         CANNA_FN_SelfInsert,
179/* ~ */         CANNA_FN_SelfInsert,
180/* DEL */       CANNA_FN_SelfInsert,
181/* Nfer */      CANNA_FN_SelfInsert,
182/* Xfer */      CANNA_FN_JapaneseMode,
183/* Up */        CANNA_FN_SelfInsert,
184/* Left */      CANNA_FN_SelfInsert,
185/* Right */     CANNA_FN_SelfInsert,
186/* Down */      CANNA_FN_SelfInsert,
187/* Insert */    CANNA_FN_SelfInsert,
188/* Rollup */    CANNA_FN_SelfInsert,
189/* Rolldown */  CANNA_FN_SelfInsert,
190/* Home */      CANNA_FN_SelfInsert,
191/* Help */      CANNA_FN_SelfInsert,
192/* KeyPad */    CANNA_FN_SelfInsert,
193/* 8c */        CANNA_FN_SelfInsert,
194/* 8d */        CANNA_FN_SelfInsert,
195/* 8e */        CANNA_FN_SelfInsert,
196/* 8f */        CANNA_FN_SelfInsert,
197/* S-nfer */    CANNA_FN_SelfInsert,
198/* S-xfer */    CANNA_FN_JapaneseMode,
199/* S-up */      CANNA_FN_SelfInsert,
200/* S-left */    CANNA_FN_SelfInsert,
201/* S-right */   CANNA_FN_SelfInsert,
202/* S-down */    CANNA_FN_SelfInsert,
203/* C-nfer */    CANNA_FN_SelfInsert,
204/* C-xfer */    CANNA_FN_JapaneseMode,
205/* C-up */      CANNA_FN_SelfInsert,
206/* C-left */    CANNA_FN_SelfInsert,
207/* C-right */   CANNA_FN_SelfInsert,
208/* C-down */    CANNA_FN_SelfInsert,
209/* 9c */        CANNA_FN_SelfInsert,
210/* 9d */        CANNA_FN_SelfInsert,
211/* 9e */        CANNA_FN_SelfInsert,
212/* 9f */        CANNA_FN_SelfInsert,
213/* KANASPACE */ CANNA_FN_SelfInsert,
214/* ¡£ */        CANNA_FN_SelfInsert,
215/* ¡Ö */        CANNA_FN_SelfInsert,
216/* ¡× */        CANNA_FN_SelfInsert,
217/* ¡¢ */        CANNA_FN_SelfInsert,
218/* ¡¦ */        CANNA_FN_SelfInsert,
219/* ¥ò */        CANNA_FN_SelfInsert,
220/* ¥¡ */        CANNA_FN_SelfInsert,
221/* ¥£ */        CANNA_FN_SelfInsert,
222/* ¥¥ */        CANNA_FN_SelfInsert,
223/* ¥§ */        CANNA_FN_SelfInsert,
224/* ¥© */        CANNA_FN_SelfInsert,
225/* ¥ã */        CANNA_FN_SelfInsert,
226/* ¥å */        CANNA_FN_SelfInsert,
227/* ¥ç */        CANNA_FN_SelfInsert,
228/* ¥Ã */        CANNA_FN_SelfInsert,
229/* ¡¼ */        CANNA_FN_SelfInsert,
230/* ¥¢ */        CANNA_FN_SelfInsert,
231/* ¥¤ */        CANNA_FN_SelfInsert,
232/* ¥¦ */        CANNA_FN_SelfInsert,
233/* ¥¨ */        CANNA_FN_SelfInsert,
234/* ¥ª */        CANNA_FN_SelfInsert,
235/* ¥« */        CANNA_FN_SelfInsert,
236/* ¥­ */        CANNA_FN_SelfInsert,
237/* ¥¯ */        CANNA_FN_SelfInsert,
238/* ¥± */        CANNA_FN_SelfInsert,
239/* ¥³ */        CANNA_FN_SelfInsert,
240/* ¥µ */        CANNA_FN_SelfInsert,
241/* ¥· */        CANNA_FN_SelfInsert,
242/* ¥¹ */        CANNA_FN_SelfInsert,
243/* ¥» */        CANNA_FN_SelfInsert,
244/* ¥½ */        CANNA_FN_SelfInsert,
245/* ¥¿ */        CANNA_FN_SelfInsert,
246/* ¥Á */        CANNA_FN_SelfInsert,
247/* ¥Ä */        CANNA_FN_SelfInsert,
248/* ¥Æ */        CANNA_FN_SelfInsert,
249/* ¥È */        CANNA_FN_SelfInsert,
250/* ¥Ê */        CANNA_FN_SelfInsert,
251/* ¥Ë */        CANNA_FN_SelfInsert,
252/* ¥Ì */        CANNA_FN_SelfInsert,
253/* ¥Í */        CANNA_FN_SelfInsert,
254/* ¥Î */        CANNA_FN_SelfInsert,
255/* ¥Ï */        CANNA_FN_SelfInsert,
256/* ¥Ò */        CANNA_FN_SelfInsert,
257/* ¥Õ */        CANNA_FN_SelfInsert,
258/* ¥Ø */        CANNA_FN_SelfInsert,
259/* ¥Û */        CANNA_FN_SelfInsert,
260/* ¥Þ */        CANNA_FN_SelfInsert,
261/* ¥ß */        CANNA_FN_SelfInsert,
262/* ¥à */        CANNA_FN_SelfInsert,
263/* ¥á */        CANNA_FN_SelfInsert,
264/* ¥â */        CANNA_FN_SelfInsert,
265/* ¥ä */        CANNA_FN_SelfInsert,
266/* ¥æ */        CANNA_FN_SelfInsert,
267/* ¥è */        CANNA_FN_SelfInsert,
268/* ¥é */        CANNA_FN_SelfInsert,
269/* ¥ê */        CANNA_FN_SelfInsert,
270/* ¥ë */        CANNA_FN_SelfInsert,
271/* ¥ì */        CANNA_FN_SelfInsert,
272/* ¥í */        CANNA_FN_SelfInsert,
273/* ¥ï */        CANNA_FN_SelfInsert,
274/* ¥ó */        CANNA_FN_SelfInsert,
275/* ¡« */        CANNA_FN_SelfInsert,
276/* ¡¬ */        CANNA_FN_SelfInsert,
277/* F1 */        CANNA_FN_SelfInsert,
278/* F2 */        CANNA_FN_SelfInsert,
279/* F3 */        CANNA_FN_SelfInsert,
280/* F4 */        CANNA_FN_SelfInsert,
281/* F5 */        CANNA_FN_SelfInsert,
282/* F6 */        CANNA_FN_SelfInsert,
283/* F7 */        CANNA_FN_SelfInsert,
284/* F8 */        CANNA_FN_SelfInsert,
285/* F9 */        CANNA_FN_SelfInsert,
286/* F10 */       CANNA_FN_SelfInsert,
287/* ea */        CANNA_FN_SelfInsert,
288/* eb */        CANNA_FN_SelfInsert,
289/* ec */        CANNA_FN_SelfInsert,
290/* ed */        CANNA_FN_SelfInsert,
291/* ee */        CANNA_FN_SelfInsert,
292/* ef */        CANNA_FN_SelfInsert,
293/* PF1 */       CANNA_FN_SelfInsert,
294/* PF2 */       CANNA_FN_SelfInsert,
295/* PF3 */       CANNA_FN_SelfInsert,
296/* PF4 */       CANNA_FN_SelfInsert,
297/* PF5 */       CANNA_FN_SelfInsert,
298/* PF6 */       CANNA_FN_SelfInsert,
299/* PF7 */       CANNA_FN_SelfInsert,
300/* PF8 */       CANNA_FN_SelfInsert,
301/* PF9 */       CANNA_FN_SelfInsert,
302/* PF10 */      CANNA_FN_SelfInsert,
303/* fa */        CANNA_FN_SelfInsert,
304/* fb */        CANNA_FN_SelfInsert,
305/* fc */        CANNA_FN_SelfInsert,
306/* fd */        CANNA_FN_SelfInsert,
307/* fe */        CANNA_FN_SelfInsert,
308/* ff */        CANNA_FN_SelfInsert,
309};
310
311
312KanjiModeRec alpha_mode = {
313  searchfunc,
314  alpha_kmap,
315  CANNA_KANJIMODE_TABLE_SHARED | CANNA_KANJIMODE_EMPTY_MODE,
316  alpha_funcs,
317};
318