xref: /haiku/src/apps/terminal/VTPrsTbl.c (revision 3386b8b7858f5659c205b8f088eb568692699591)
1 /*
2  * Copyright (c) 2003-4 Kian Duffy <myob@users.sourceforge.net>
3  * Parts Copyright (C) 1998,99 Kazuho Okui and Takashi Murai.
4  *
5  * Distributed under the terms of the MIT License.
6  *
7  * Authors:
8  *		Kian Duffy, myob@users.sourceforge.net
9  *		Siarzhuk Zharski, zharik@gmx.li
10  */
11 
12 
13 #include <SupportDefs.h>
14 
15 #include "VTparse.h"
16 
17 
18 // #pragma mark UTF8 coding ground table
19 int gUTF8GroundTable[] =
20 {
21 /*	NUL		SOH		STX		ETX	*/
22 CASE_IGNORE,
23 CASE_IGNORE,
24 CASE_IGNORE,
25 CASE_IGNORE,
26 /*	EOT		ENQ		ACK		BEL	*/
27 CASE_IGNORE,
28 CASE_IGNORE,
29 CASE_IGNORE,
30 CASE_BELL,
31 /*	BS		HT		NL		VT	*/
32 CASE_BS,
33 CASE_TAB,
34 CASE_LF,
35 CASE_LF, /* CASE_UP*/
36 /*	NP		CR		SO		SI	*/
37 CASE_LF, /* CASE_IGNORE*/
38 CASE_CR,
39 CASE_LS1,
40 CASE_LS0,
41 /*	DLE		DC1		DC2		DC3	*/
42 CASE_IGNORE,
43 CASE_IGNORE,
44 CASE_IGNORE,
45 CASE_IGNORE,
46 /*	DC4		NAK		SYN		ETB	*/
47 CASE_IGNORE,
48 CASE_IGNORE,
49 CASE_IGNORE,
50 CASE_IGNORE,
51 /*	CAN		EM		SUB		ESC	*/
52 CASE_IGNORE,
53 CASE_IGNORE,
54 CASE_IGNORE,
55 CASE_ESC,
56 /*	FS		GS		RS		US	*/
57 CASE_IGNORE,
58 CASE_IGNORE,
59 CASE_IGNORE,
60 CASE_IGNORE,
61 /*	SP		!		"		#	*/
62 CASE_PRINT,
63 CASE_PRINT,
64 CASE_PRINT,
65 CASE_PRINT,
66 /*	$		%		&		'	*/
67 CASE_PRINT,
68 CASE_PRINT,
69 CASE_PRINT,
70 CASE_PRINT,
71 /*	(		)		*		+	*/
72 CASE_PRINT,
73 CASE_PRINT,
74 CASE_PRINT,
75 CASE_PRINT,
76 /*	,		-		.		/	*/
77 CASE_PRINT,
78 CASE_PRINT,
79 CASE_PRINT,
80 CASE_PRINT,
81 /*	0		1		2		3	*/
82 CASE_PRINT,
83 CASE_PRINT,
84 CASE_PRINT,
85 CASE_PRINT,
86 /*	4		5		6		7	*/
87 CASE_PRINT,
88 CASE_PRINT,
89 CASE_PRINT,
90 CASE_PRINT,
91 /*	8		9		:		;	*/
92 CASE_PRINT,
93 CASE_PRINT,
94 CASE_PRINT,
95 CASE_PRINT,
96 /*	<		=		>		?	*/
97 CASE_PRINT,
98 CASE_PRINT,
99 CASE_PRINT,
100 CASE_PRINT,
101 /*	@		A		B		C	*/
102 CASE_PRINT,
103 CASE_PRINT,
104 CASE_PRINT,
105 CASE_PRINT,
106 /*	D		E		F		G	*/
107 CASE_PRINT,
108 CASE_PRINT,
109 CASE_PRINT,
110 CASE_PRINT,
111 /*	H		I		J		K	*/
112 CASE_PRINT,
113 CASE_PRINT,
114 CASE_PRINT,
115 CASE_PRINT,
116 /*	L		M		N		O	*/
117 CASE_PRINT,
118 CASE_PRINT,
119 CASE_PRINT,
120 CASE_PRINT,
121 /*	P		Q		R		S	*/
122 CASE_PRINT,
123 CASE_PRINT,
124 CASE_PRINT,
125 CASE_PRINT,
126 /*	T		U		V		W	*/
127 CASE_PRINT,
128 CASE_PRINT,
129 CASE_PRINT,
130 CASE_PRINT,
131 /*	X		Y		Z		[	*/
132 CASE_PRINT,
133 CASE_PRINT,
134 CASE_PRINT,
135 CASE_PRINT,
136 /*	\		]		^		_	*/
137 CASE_PRINT,
138 CASE_PRINT,
139 CASE_PRINT,
140 CASE_PRINT,
141 /*	`		a		b		c	*/
142 CASE_PRINT,
143 CASE_PRINT,
144 CASE_PRINT,
145 CASE_PRINT,
146 /*	d		e		f		g	*/
147 CASE_PRINT,
148 CASE_PRINT,
149 CASE_PRINT,
150 CASE_PRINT,
151 /*	h		i		j		k	*/
152 CASE_PRINT,
153 CASE_PRINT,
154 CASE_PRINT,
155 CASE_PRINT,
156 /*	l		m		n		o	*/
157 CASE_PRINT,
158 CASE_PRINT,
159 CASE_PRINT,
160 CASE_PRINT,
161 /*	p		q		r		s	*/
162 CASE_PRINT,
163 CASE_PRINT,
164 CASE_PRINT,
165 CASE_PRINT,
166 /*	t		u		v		w	*/
167 CASE_PRINT,
168 CASE_PRINT,
169 CASE_PRINT,
170 CASE_PRINT,
171 /*	x		y		z		{	*/
172 CASE_PRINT,
173 CASE_PRINT,
174 CASE_PRINT,
175 CASE_PRINT,
176 /*	|		}		~		DEL	*/
177 CASE_PRINT,
178 CASE_PRINT,
179 CASE_PRINT,
180 CASE_IGNORE,
181 /*      0x80            0x81            0x82            0x83    */
182 CASE_UTF8_INSTRING,
183 CASE_UTF8_INSTRING,
184 CASE_UTF8_INSTRING,
185 CASE_UTF8_INSTRING,
186 /*      0x84            0x85            0x86            0x87    */
187 CASE_UTF8_INSTRING,
188 CASE_UTF8_INSTRING,
189 CASE_UTF8_INSTRING,
190 CASE_UTF8_INSTRING,
191 /*      0x88            0x89            0x8a            0x8b    */
192 CASE_UTF8_INSTRING,
193 CASE_UTF8_INSTRING,
194 CASE_UTF8_INSTRING,
195 CASE_UTF8_INSTRING,
196 /*      0x8c            0x8d            0x8e            0x8f    */
197 CASE_UTF8_INSTRING,
198 CASE_UTF8_INSTRING,
199 CASE_UTF8_INSTRING,
200 CASE_UTF8_INSTRING,
201 /*      0x90            0x91            0x92            0x93    */
202 CASE_UTF8_INSTRING,
203 CASE_UTF8_INSTRING,
204 CASE_UTF8_INSTRING,
205 CASE_UTF8_INSTRING,
206 /*      0x94            0x95            0x96            0x97    */
207 CASE_UTF8_INSTRING,
208 CASE_UTF8_INSTRING,
209 CASE_UTF8_INSTRING,
210 CASE_UTF8_INSTRING,
211 /*      0x99            0x99            0x9a            0x9b    */
212 CASE_UTF8_INSTRING,
213 CASE_UTF8_INSTRING,
214 CASE_UTF8_INSTRING,
215 CASE_UTF8_INSTRING,
216 /*      0x9c            0x9d            0x9e            0x9f    */
217 CASE_UTF8_INSTRING,
218 CASE_UTF8_INSTRING,
219 CASE_UTF8_INSTRING,
220 CASE_UTF8_INSTRING,
221 /*      0xa0		0xa1		0xa2		0xa3	*/
222 CASE_UTF8_INSTRING,
223 CASE_UTF8_INSTRING,
224 CASE_UTF8_INSTRING,
225 CASE_UTF8_INSTRING,
226 /*      0xa4		0xa5		0xa6		0xa7	*/
227 CASE_UTF8_INSTRING,
228 CASE_UTF8_INSTRING,
229 CASE_UTF8_INSTRING,
230 CASE_UTF8_INSTRING,
231 /*      0xa8		0xa9		0xaa		0xab	*/
232 CASE_UTF8_INSTRING,
233 CASE_UTF8_INSTRING,
234 CASE_UTF8_INSTRING,
235 CASE_UTF8_INSTRING,
236 /*      0xac		0xad		0xae		0xaf	*/
237 CASE_UTF8_INSTRING,
238 CASE_UTF8_INSTRING,
239 CASE_UTF8_INSTRING,
240 CASE_UTF8_INSTRING,
241 /*      0xb0		0xb1		0xb2		0xb3	*/
242 CASE_UTF8_INSTRING,
243 CASE_UTF8_INSTRING,
244 CASE_UTF8_INSTRING,
245 CASE_UTF8_INSTRING,
246 /*      0xb4		0xb5		0xb6		0xb7	*/
247 CASE_UTF8_INSTRING,
248 CASE_UTF8_INSTRING,
249 CASE_UTF8_INSTRING,
250 CASE_UTF8_INSTRING,
251 /*      0xb8		0xb9		0xba		0xbb	*/
252 CASE_UTF8_INSTRING,
253 CASE_UTF8_INSTRING,
254 CASE_UTF8_INSTRING,
255 CASE_UTF8_INSTRING,
256 /*      0xbc		0xbd		0xbe		0xbf	*/
257 CASE_UTF8_INSTRING,
258 CASE_UTF8_INSTRING,
259 CASE_UTF8_INSTRING,
260 CASE_UTF8_INSTRING,
261 /*      0xc0		0xc1		0xc2		0xc3	*/
262 CASE_UTF8_2BYTE,
263 CASE_UTF8_2BYTE,
264 CASE_UTF8_2BYTE,
265 CASE_UTF8_2BYTE,
266 /*      0xc4		0xc5		0xc6		0xc7	*/
267 CASE_UTF8_2BYTE,
268 CASE_UTF8_2BYTE,
269 CASE_UTF8_2BYTE,
270 CASE_UTF8_2BYTE,
271 /*      0xc8		0xc9		0xca		0xcb	*/
272 CASE_UTF8_2BYTE,
273 CASE_UTF8_2BYTE,
274 CASE_UTF8_2BYTE,
275 CASE_UTF8_2BYTE,
276 /*      0xcc		0xcd		0xce		0xcf	*/
277 CASE_UTF8_2BYTE,
278 CASE_UTF8_2BYTE,
279 CASE_UTF8_2BYTE,
280 CASE_UTF8_2BYTE,
281 /*      0xd0		0xd1		0xd2		0xd3	*/
282 CASE_UTF8_2BYTE,
283 CASE_UTF8_2BYTE,
284 CASE_UTF8_2BYTE,
285 CASE_UTF8_2BYTE,
286 /*      0xd4		0xd5		0xd6		0xd7	*/
287 CASE_UTF8_2BYTE,
288 CASE_UTF8_2BYTE,
289 CASE_UTF8_2BYTE,
290 CASE_UTF8_2BYTE,
291 /*      0xd8		0xd9		0xda		0xdb	*/
292 CASE_UTF8_2BYTE,
293 CASE_UTF8_2BYTE,
294 CASE_UTF8_2BYTE,
295 CASE_UTF8_2BYTE,
296 /*      0xdc		0xdd		0xde		0xdf	*/
297 CASE_UTF8_2BYTE,
298 CASE_UTF8_2BYTE,
299 CASE_UTF8_2BYTE,
300 CASE_UTF8_2BYTE,
301 /*      0xe0		0xe1		0xe2		0xe3	*/
302 CASE_UTF8_3BYTE,
303 CASE_UTF8_3BYTE,
304 CASE_UTF8_3BYTE,
305 CASE_UTF8_3BYTE,
306 /*      0xe4		0xe5		0xe6		0xe7	*/
307 CASE_UTF8_3BYTE,
308 CASE_UTF8_3BYTE,
309 CASE_UTF8_3BYTE,
310 CASE_UTF8_3BYTE,
311 /*      0xe8		0xe9		0xea		0xeb	*/
312 CASE_UTF8_3BYTE,
313 CASE_UTF8_3BYTE,
314 CASE_UTF8_3BYTE,
315 CASE_UTF8_3BYTE,
316 /*      0xec		0xed		0xee		0xef	*/
317 CASE_UTF8_3BYTE,
318 CASE_UTF8_3BYTE,
319 CASE_UTF8_3BYTE,
320 CASE_UTF8_3BYTE,
321 /*      0xf0		0xf1		0xf2		0xf3	*/
322 CASE_UTF8_3BYTE,
323 CASE_UTF8_3BYTE,
324 CASE_UTF8_3BYTE,
325 CASE_UTF8_3BYTE,
326 /*      0xf4		0xf5		0xf6		0xf7	*/
327 CASE_UTF8_3BYTE,
328 CASE_UTF8_3BYTE,
329 CASE_UTF8_3BYTE,
330 CASE_UTF8_3BYTE,
331 /*      0xf8		0xf9		0xfa		0xfb	*/
332 CASE_UTF8_3BYTE,
333 CASE_UTF8_3BYTE,
334 CASE_UTF8_3BYTE,
335 CASE_UTF8_3BYTE,
336 /*      0xfc		0xfd		0xfe		0xff	*/
337 CASE_UTF8_3BYTE,
338 CASE_UTF8_3BYTE,
339 CASE_UTF8_3BYTE,
340 CASE_UTF8_3BYTE,
341 };
342 
343 // #pragma mark ISO8859 table
344 int gISO8859GroundTable[] =
345 {
346 /*	NUL		SOH		STX		ETX	*/
347 CASE_IGNORE,
348 CASE_IGNORE,
349 CASE_IGNORE,
350 CASE_IGNORE,
351 /*	EOT		ENQ		ACK		BEL	*/
352 CASE_IGNORE,
353 CASE_IGNORE,
354 CASE_IGNORE,
355 CASE_BELL,
356 /*	BS		HT		NL		VT	*/
357 CASE_BS,
358 CASE_TAB,
359 CASE_LF,
360 CASE_LF, /*CASE_UP,*/
361 /*	NP		CR		SO		SI	*/
362 CASE_LF, /*CASE_IGNORE,*/
363 CASE_CR,
364 CASE_LS1,
365 CASE_LS0,
366 /*	DLE		DC1		DC2		DC3	*/
367 CASE_IGNORE,
368 CASE_IGNORE,
369 CASE_IGNORE,
370 CASE_IGNORE,
371 /*	DC4		NAK		SYN		ETB	*/
372 CASE_IGNORE,
373 CASE_IGNORE,
374 CASE_IGNORE,
375 CASE_IGNORE,
376 /*	CAN		EM		SUB		ESC	*/
377 CASE_IGNORE,
378 CASE_IGNORE,
379 CASE_IGNORE,
380 CASE_ESC,
381 /*	FS		GS		RS		US	*/
382 CASE_IGNORE,
383 CASE_IGNORE,
384 CASE_IGNORE,
385 CASE_IGNORE,
386 /*	SP		!		"		#	*/
387 CASE_PRINT,
388 CASE_PRINT,
389 CASE_PRINT,
390 CASE_PRINT,
391 /*	$		%		&		'	*/
392 CASE_PRINT,
393 CASE_PRINT,
394 CASE_PRINT,
395 CASE_PRINT,
396 /*	(		)		*		+	*/
397 CASE_PRINT,
398 CASE_PRINT,
399 CASE_PRINT,
400 CASE_PRINT,
401 /*	,		-		.		/	*/
402 CASE_PRINT,
403 CASE_PRINT,
404 CASE_PRINT,
405 CASE_PRINT,
406 /*	0		1		2		3	*/
407 CASE_PRINT,
408 CASE_PRINT,
409 CASE_PRINT,
410 CASE_PRINT,
411 /*	4		5		6		7	*/
412 CASE_PRINT,
413 CASE_PRINT,
414 CASE_PRINT,
415 CASE_PRINT,
416 /*	8		9		:		;	*/
417 CASE_PRINT,
418 CASE_PRINT,
419 CASE_PRINT,
420 CASE_PRINT,
421 /*	<		=		>		?	*/
422 CASE_PRINT,
423 CASE_PRINT,
424 CASE_PRINT,
425 CASE_PRINT,
426 /*	@		A		B		C	*/
427 CASE_PRINT,
428 CASE_PRINT,
429 CASE_PRINT,
430 CASE_PRINT,
431 /*	D		E		F		G	*/
432 CASE_PRINT,
433 CASE_PRINT,
434 CASE_PRINT,
435 CASE_PRINT,
436 /*	H		I		J		K	*/
437 CASE_PRINT,
438 CASE_PRINT,
439 CASE_PRINT,
440 CASE_PRINT,
441 /*	L		M		N		O	*/
442 CASE_PRINT,
443 CASE_PRINT,
444 CASE_PRINT,
445 CASE_PRINT,
446 /*	P		Q		R		S	*/
447 CASE_PRINT,
448 CASE_PRINT,
449 CASE_PRINT,
450 CASE_PRINT,
451 /*	T		U		V		W	*/
452 CASE_PRINT,
453 CASE_PRINT,
454 CASE_PRINT,
455 CASE_PRINT,
456 /*	X		Y		Z		[	*/
457 CASE_PRINT,
458 CASE_PRINT,
459 CASE_PRINT,
460 CASE_PRINT,
461 /*	\		]		^		_	*/
462 CASE_PRINT,
463 CASE_PRINT,
464 CASE_PRINT,
465 CASE_PRINT,
466 /*	`		a		b		c	*/
467 CASE_PRINT,
468 CASE_PRINT,
469 CASE_PRINT,
470 CASE_PRINT,
471 /*	d		e		f		g	*/
472 CASE_PRINT,
473 CASE_PRINT,
474 CASE_PRINT,
475 CASE_PRINT,
476 /*	h		i		j		k	*/
477 CASE_PRINT,
478 CASE_PRINT,
479 CASE_PRINT,
480 CASE_PRINT,
481 /*	l		m		n		o	*/
482 CASE_PRINT,
483 CASE_PRINT,
484 CASE_PRINT,
485 CASE_PRINT,
486 /*	p		q		r		s	*/
487 CASE_PRINT,
488 CASE_PRINT,
489 CASE_PRINT,
490 CASE_PRINT,
491 /*	t		u		v		w	*/
492 CASE_PRINT,
493 CASE_PRINT,
494 CASE_PRINT,
495 CASE_PRINT,
496 /*	x		y		z		{	*/
497 CASE_PRINT,
498 CASE_PRINT,
499 CASE_PRINT,
500 CASE_PRINT,
501 /*	|		}		~		DEL	*/
502 CASE_PRINT,
503 CASE_PRINT,
504 CASE_PRINT,
505 CASE_PRINT,
506 /*      0x80            0x81            0x82            0x83    */
507 CASE_IGNORE,
508 CASE_IGNORE,
509 CASE_IGNORE,
510 CASE_IGNORE,
511 /*      0x84            0x85            0x86            0x87    */
512 CASE_IGNORE,
513 CASE_IGNORE,
514 CASE_IGNORE,
515 CASE_IGNORE,
516 /*      0x88            0x89            0x8a            0x8b    */
517 CASE_IGNORE,
518 CASE_IGNORE,
519 CASE_IGNORE,
520 CASE_IGNORE,
521 /*      0x8c            0x8d            0x8e            0x8f    */
522 CASE_IGNORE,
523 CASE_IGNORE,
524 CASE_SS2,
525 CASE_SS3,
526 /*      0x90            0x91            0x92            0x93    */
527 CASE_IGNORE,
528 CASE_IGNORE,
529 CASE_IGNORE,
530 CASE_IGNORE,
531 /*      0x94            0x95            0x96            0x97    */
532 CASE_IGNORE,
533 CASE_IGNORE,
534 CASE_IGNORE,
535 CASE_IGNORE,
536 /*      0x99            0x99            0x9a            0x9b    */
537 CASE_IGNORE,
538 CASE_IGNORE,
539 CASE_IGNORE,
540 CASE_CSI_STATE,
541 /*      0x9c            0x9d            0x9e            0x9f    */
542 CASE_IGNORE,
543 CASE_IGNORE,
544 CASE_IGNORE,
545 CASE_IGNORE,
546 /*      nobreakspace    exclamdown      cent            sterling        */
547 CASE_PRINT_GR,
548 CASE_PRINT_GR,
549 CASE_PRINT_GR,
550 CASE_PRINT_GR,
551 /*      currency        yen             brokenbar       section         */
552 CASE_PRINT_GR,
553 CASE_PRINT_GR,
554 CASE_PRINT_GR,
555 CASE_PRINT_GR,
556 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
557 CASE_PRINT_GR,
558 CASE_PRINT_GR,
559 CASE_PRINT_GR,
560 CASE_PRINT_GR,
561 /*      notsign         hyphen          registered      macron          */
562 CASE_PRINT_GR,
563 CASE_PRINT_GR,
564 CASE_PRINT_GR,
565 CASE_PRINT_GR,
566 /*      degree          plusminus       twosuperior     threesuperior   */
567 CASE_PRINT_GR,
568 CASE_PRINT_GR,
569 CASE_PRINT_GR,
570 CASE_PRINT_GR,
571 /*      acute           mu              paragraph       periodcentered  */
572 CASE_PRINT_GR,
573 CASE_PRINT_GR,
574 CASE_PRINT_GR,
575 CASE_PRINT_GR,
576 /*      cedilla         onesuperior     masculine       guillemotright  */
577 CASE_PRINT_GR,
578 CASE_PRINT_GR,
579 CASE_PRINT_GR,
580 CASE_PRINT_GR,
581 /*      onequarter      onehalf         threequarters   questiondown    */
582 CASE_PRINT_GR,
583 CASE_PRINT_GR,
584 CASE_PRINT_GR,
585 CASE_PRINT_GR,
586 /*      Agrave          Aacute          Acircumflex     Atilde          */
587 CASE_PRINT_GR,
588 CASE_PRINT_GR,
589 CASE_PRINT_GR,
590 CASE_PRINT_GR,
591 /*      Adiaeresis      Aring           AE              Ccedilla        */
592 CASE_PRINT_GR,
593 CASE_PRINT_GR,
594 CASE_PRINT_GR,
595 CASE_PRINT_GR,
596 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
597 CASE_PRINT_GR,
598 CASE_PRINT_GR,
599 CASE_PRINT_GR,
600 CASE_PRINT_GR,
601 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
602 CASE_PRINT_GR,
603 CASE_PRINT_GR,
604 CASE_PRINT_GR,
605 CASE_PRINT_GR,
606 /*      Eth             Ntilde          Ograve          Oacute          */
607 CASE_PRINT_GR,
608 CASE_PRINT_GR,
609 CASE_PRINT_GR,
610 CASE_PRINT_GR,
611 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
612 CASE_PRINT_GR,
613 CASE_PRINT_GR,
614 CASE_PRINT_GR,
615 CASE_PRINT_GR,
616 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
617 CASE_PRINT_GR,
618 CASE_PRINT_GR,
619 CASE_PRINT_GR,
620 CASE_PRINT_GR,
621 /*      Udiaeresis      Yacute          Thorn           ssharp          */
622 CASE_PRINT_GR,
623 CASE_PRINT_GR,
624 CASE_PRINT_GR,
625 CASE_PRINT_GR,
626 /*      agrave          aacute          acircumflex     atilde          */
627 CASE_PRINT_GR,
628 CASE_PRINT_GR,
629 CASE_PRINT_GR,
630 CASE_PRINT_GR,
631 /*      adiaeresis      aring           ae              ccedilla        */
632 CASE_PRINT_GR,
633 CASE_PRINT_GR,
634 CASE_PRINT_GR,
635 CASE_PRINT_GR,
636 /*      egrave          eacute          ecircumflex     ediaeresis      */
637 CASE_PRINT_GR,
638 CASE_PRINT_GR,
639 CASE_PRINT_GR,
640 CASE_PRINT_GR,
641 /*      igrave          iacute          icircumflex     idiaeresis      */
642 CASE_PRINT_GR,
643 CASE_PRINT_GR,
644 CASE_PRINT_GR,
645 CASE_PRINT_GR,
646 /*      eth             ntilde          ograve          oacute          */
647 CASE_PRINT_GR,
648 CASE_PRINT_GR,
649 CASE_PRINT_GR,
650 CASE_PRINT_GR,
651 /*      ocircumflex     otilde          odiaeresis      division        */
652 CASE_PRINT_GR,
653 CASE_PRINT_GR,
654 CASE_PRINT_GR,
655 CASE_PRINT_GR,
656 /*      oslash          ugrave          uacute          ucircumflex     */
657 CASE_PRINT_GR,
658 CASE_PRINT_GR,
659 CASE_PRINT_GR,
660 CASE_PRINT_GR,
661 /*      udiaeresis      yacute          thorn           ydiaeresis      */
662 CASE_PRINT_GR,
663 CASE_PRINT_GR,
664 CASE_PRINT_GR,
665 CASE_PRINT_GR,
666 };
667 
668 // #pragma mark WinCP table (ISO8859 + C1)
669 // This one defines both C1 control and GR characters
670 // as CASE_PRINT_GR to let process set of encodings
671 // using this areas: cp1252, cp1251, koi-8r, cp866, gb18030
672 int gWinCPGroundTable[] =
673 {
674 /*	NUL		SOH		STX		ETX	*/
675 CASE_IGNORE,
676 CASE_IGNORE,
677 CASE_IGNORE,
678 CASE_IGNORE,
679 /*	EOT		ENQ		ACK		BEL	*/
680 CASE_IGNORE,
681 CASE_IGNORE,
682 CASE_IGNORE,
683 CASE_BELL,
684 /*	BS		HT		NL		VT	*/
685 CASE_BS,
686 CASE_TAB,
687 CASE_LF,
688 CASE_LF, /*CASE_UP,*/
689 /*	NP		CR		SO		SI	*/
690 CASE_LF, /*CASE_IGNORE,*/
691 CASE_CR,
692 CASE_LS1,
693 CASE_LS0,
694 /*	DLE		DC1		DC2		DC3	*/
695 CASE_IGNORE,
696 CASE_IGNORE,
697 CASE_IGNORE,
698 CASE_IGNORE,
699 /*	DC4		NAK		SYN		ETB	*/
700 CASE_IGNORE,
701 CASE_IGNORE,
702 CASE_IGNORE,
703 CASE_IGNORE,
704 /*	CAN		EM		SUB		ESC	*/
705 CASE_IGNORE,
706 CASE_IGNORE,
707 CASE_IGNORE,
708 CASE_ESC,
709 /*	FS		GS		RS		US	*/
710 CASE_IGNORE,
711 CASE_IGNORE,
712 CASE_IGNORE,
713 CASE_IGNORE,
714 /*	SP		!		"		#	*/
715 CASE_PRINT,
716 CASE_PRINT,
717 CASE_PRINT,
718 CASE_PRINT,
719 /*	$		%		&		'	*/
720 CASE_PRINT,
721 CASE_PRINT,
722 CASE_PRINT,
723 CASE_PRINT,
724 /*	(		)		*		+	*/
725 CASE_PRINT,
726 CASE_PRINT,
727 CASE_PRINT,
728 CASE_PRINT,
729 /*	,		-		.		/	*/
730 CASE_PRINT,
731 CASE_PRINT,
732 CASE_PRINT,
733 CASE_PRINT,
734 /*	0		1		2		3	*/
735 CASE_PRINT,
736 CASE_PRINT,
737 CASE_PRINT,
738 CASE_PRINT,
739 /*	4		5		6		7	*/
740 CASE_PRINT,
741 CASE_PRINT,
742 CASE_PRINT,
743 CASE_PRINT,
744 /*	8		9		:		;	*/
745 CASE_PRINT,
746 CASE_PRINT,
747 CASE_PRINT,
748 CASE_PRINT,
749 /*	<		=		>		?	*/
750 CASE_PRINT,
751 CASE_PRINT,
752 CASE_PRINT,
753 CASE_PRINT,
754 /*	@		A		B		C	*/
755 CASE_PRINT,
756 CASE_PRINT,
757 CASE_PRINT,
758 CASE_PRINT,
759 /*	D		E		F		G	*/
760 CASE_PRINT,
761 CASE_PRINT,
762 CASE_PRINT,
763 CASE_PRINT,
764 /*	H		I		J		K	*/
765 CASE_PRINT,
766 CASE_PRINT,
767 CASE_PRINT,
768 CASE_PRINT,
769 /*	L		M		N		O	*/
770 CASE_PRINT,
771 CASE_PRINT,
772 CASE_PRINT,
773 CASE_PRINT,
774 /*	P		Q		R		S	*/
775 CASE_PRINT,
776 CASE_PRINT,
777 CASE_PRINT,
778 CASE_PRINT,
779 /*	T		U		V		W	*/
780 CASE_PRINT,
781 CASE_PRINT,
782 CASE_PRINT,
783 CASE_PRINT,
784 /*	X		Y		Z		[	*/
785 CASE_PRINT,
786 CASE_PRINT,
787 CASE_PRINT,
788 CASE_PRINT,
789 /*	\		]		^		_	*/
790 CASE_PRINT,
791 CASE_PRINT,
792 CASE_PRINT,
793 CASE_PRINT,
794 /*	`		a		b		c	*/
795 CASE_PRINT,
796 CASE_PRINT,
797 CASE_PRINT,
798 CASE_PRINT,
799 /*	d		e		f		g	*/
800 CASE_PRINT,
801 CASE_PRINT,
802 CASE_PRINT,
803 CASE_PRINT,
804 /*	h		i		j		k	*/
805 CASE_PRINT,
806 CASE_PRINT,
807 CASE_PRINT,
808 CASE_PRINT,
809 /*	l		m		n		o	*/
810 CASE_PRINT,
811 CASE_PRINT,
812 CASE_PRINT,
813 CASE_PRINT,
814 /*	p		q		r		s	*/
815 CASE_PRINT,
816 CASE_PRINT,
817 CASE_PRINT,
818 CASE_PRINT,
819 /*	t		u		v		w	*/
820 CASE_PRINT,
821 CASE_PRINT,
822 CASE_PRINT,
823 CASE_PRINT,
824 /*	x		y		z		{	*/
825 CASE_PRINT,
826 CASE_PRINT,
827 CASE_PRINT,
828 CASE_PRINT,
829 /*	|		}		~		DEL	*/
830 CASE_PRINT,
831 CASE_PRINT,
832 CASE_PRINT,
833 CASE_PRINT,
834 /*      0x80            0x81            0x82            0x83    */
835 CASE_PRINT_GR,
836 CASE_PRINT_GR,
837 CASE_PRINT_GR,
838 CASE_PRINT_GR,
839 /*      0x84            0x85            0x86            0x87    */
840 CASE_PRINT_GR,
841 CASE_PRINT_GR,
842 CASE_PRINT_GR,
843 CASE_PRINT_GR,
844 /*      0x88            0x89            0x8a            0x8b    */
845 CASE_PRINT_GR,
846 CASE_PRINT_GR,
847 CASE_PRINT_GR,
848 CASE_PRINT_GR,
849 /*      0x8c            0x8d            0x8e            0x8f    */
850 CASE_PRINT_GR,
851 CASE_PRINT_GR,
852 CASE_PRINT_GR,
853 CASE_PRINT_GR,
854 /*      0x90            0x91            0x92            0x93    */
855 CASE_PRINT_GR,
856 CASE_PRINT_GR,
857 CASE_PRINT_GR,
858 CASE_PRINT_GR,
859 /*      0x94            0x95            0x96            0x97    */
860 CASE_PRINT_GR,
861 CASE_PRINT_GR,
862 CASE_PRINT_GR,
863 CASE_PRINT_GR,
864 /*      0x99            0x99            0x9a            0x9b    */
865 CASE_PRINT_GR,
866 CASE_PRINT_GR,
867 CASE_PRINT_GR,
868 CASE_PRINT_GR,
869 /*      0x9c            0x9d            0x9e            0x9f    */
870 CASE_PRINT_GR,
871 CASE_PRINT_GR,
872 CASE_PRINT_GR,
873 CASE_PRINT_GR,
874 /*      nobreakspace    exclamdown      cent            sterling        */
875 CASE_PRINT_GR,
876 CASE_PRINT_GR,
877 CASE_PRINT_GR,
878 CASE_PRINT_GR,
879 /*      currency        yen             brokenbar       section         */
880 CASE_PRINT_GR,
881 CASE_PRINT_GR,
882 CASE_PRINT_GR,
883 CASE_PRINT_GR,
884 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
885 CASE_PRINT_GR,
886 CASE_PRINT_GR,
887 CASE_PRINT_GR,
888 CASE_PRINT_GR,
889 /*      notsign         hyphen          registered      macron          */
890 CASE_PRINT_GR,
891 CASE_PRINT_GR,
892 CASE_PRINT_GR,
893 CASE_PRINT_GR,
894 /*      degree          plusminus       twosuperior     threesuperior   */
895 CASE_PRINT_GR,
896 CASE_PRINT_GR,
897 CASE_PRINT_GR,
898 CASE_PRINT_GR,
899 /*      acute           mu              paragraph       periodcentered  */
900 CASE_PRINT_GR,
901 CASE_PRINT_GR,
902 CASE_PRINT_GR,
903 CASE_PRINT_GR,
904 /*      cedilla         onesuperior     masculine       guillemotright  */
905 CASE_PRINT_GR,
906 CASE_PRINT_GR,
907 CASE_PRINT_GR,
908 CASE_PRINT_GR,
909 /*      onequarter      onehalf         threequarters   questiondown    */
910 CASE_PRINT_GR,
911 CASE_PRINT_GR,
912 CASE_PRINT_GR,
913 CASE_PRINT_GR,
914 /*      Agrave          Aacute          Acircumflex     Atilde          */
915 CASE_PRINT_GR,
916 CASE_PRINT_GR,
917 CASE_PRINT_GR,
918 CASE_PRINT_GR,
919 /*      Adiaeresis      Aring           AE              Ccedilla        */
920 CASE_PRINT_GR,
921 CASE_PRINT_GR,
922 CASE_PRINT_GR,
923 CASE_PRINT_GR,
924 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
925 CASE_PRINT_GR,
926 CASE_PRINT_GR,
927 CASE_PRINT_GR,
928 CASE_PRINT_GR,
929 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
930 CASE_PRINT_GR,
931 CASE_PRINT_GR,
932 CASE_PRINT_GR,
933 CASE_PRINT_GR,
934 /*      Eth             Ntilde          Ograve          Oacute          */
935 CASE_PRINT_GR,
936 CASE_PRINT_GR,
937 CASE_PRINT_GR,
938 CASE_PRINT_GR,
939 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
940 CASE_PRINT_GR,
941 CASE_PRINT_GR,
942 CASE_PRINT_GR,
943 CASE_PRINT_GR,
944 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
945 CASE_PRINT_GR,
946 CASE_PRINT_GR,
947 CASE_PRINT_GR,
948 CASE_PRINT_GR,
949 /*      Udiaeresis      Yacute          Thorn           ssharp          */
950 CASE_PRINT_GR,
951 CASE_PRINT_GR,
952 CASE_PRINT_GR,
953 CASE_PRINT_GR,
954 /*      agrave          aacute          acircumflex     atilde          */
955 CASE_PRINT_GR,
956 CASE_PRINT_GR,
957 CASE_PRINT_GR,
958 CASE_PRINT_GR,
959 /*      adiaeresis      aring           ae              ccedilla        */
960 CASE_PRINT_GR,
961 CASE_PRINT_GR,
962 CASE_PRINT_GR,
963 CASE_PRINT_GR,
964 /*      egrave          eacute          ecircumflex     ediaeresis      */
965 CASE_PRINT_GR,
966 CASE_PRINT_GR,
967 CASE_PRINT_GR,
968 CASE_PRINT_GR,
969 /*      igrave          iacute          icircumflex     idiaeresis      */
970 CASE_PRINT_GR,
971 CASE_PRINT_GR,
972 CASE_PRINT_GR,
973 CASE_PRINT_GR,
974 /*      eth             ntilde          ograve          oacute          */
975 CASE_PRINT_GR,
976 CASE_PRINT_GR,
977 CASE_PRINT_GR,
978 CASE_PRINT_GR,
979 /*      ocircumflex     otilde          odiaeresis      division        */
980 CASE_PRINT_GR,
981 CASE_PRINT_GR,
982 CASE_PRINT_GR,
983 CASE_PRINT_GR,
984 /*      oslash          ugrave          uacute          ucircumflex     */
985 CASE_PRINT_GR,
986 CASE_PRINT_GR,
987 CASE_PRINT_GR,
988 CASE_PRINT_GR,
989 /*      udiaeresis      yacute          thorn           ydiaeresis      */
990 CASE_PRINT_GR,
991 CASE_PRINT_GR,
992 CASE_PRINT_GR,
993 CASE_PRINT_GR,
994 };
995 
996 // #pragma mark ESC [ - CSI table
997 int gCsiTable[] =
998 {
999 /*	NUL		SOH		STX		ETX	*/
1000 CASE_IGNORE,
1001 CASE_IGNORE,
1002 CASE_IGNORE,
1003 CASE_IGNORE,
1004 /*	EOT		ENQ		ACK		BEL	*/
1005 CASE_IGNORE,
1006 CASE_IGNORE,
1007 CASE_IGNORE,
1008 CASE_BELL,
1009 /*	BS		HT		NL		VT	*/
1010 CASE_BS,
1011 CASE_TAB,
1012 CASE_ESC_IGNORE,
1013 CASE_ESC_IGNORE,
1014 /*	NP		CR		SO		SI	*/
1015 CASE_ESC_IGNORE,
1016 CASE_CR,
1017 CASE_LS1,
1018 CASE_LS0,
1019 /*	DLE		DC1		DC2		DC3	*/
1020 CASE_IGNORE,
1021 CASE_IGNORE,
1022 CASE_IGNORE,
1023 CASE_IGNORE,
1024 /*	DC4		NAK		SYN		ETB	*/
1025 CASE_IGNORE,
1026 CASE_IGNORE,
1027 CASE_IGNORE,
1028 CASE_IGNORE,
1029 /*	CAN		EM		SUB		ESC	*/
1030 CASE_IGNORE,
1031 CASE_IGNORE,
1032 CASE_IGNORE,
1033 CASE_ESC,
1034 /*	FS		GS		RS		US	*/
1035 CASE_IGNORE,
1036 CASE_IGNORE,
1037 CASE_IGNORE,
1038 CASE_IGNORE,
1039 /*	SP		!		"		#	*/
1040 CASE_CSI_SP,
1041 CASE_ESC_IGNORE,
1042 CASE_ESC_IGNORE,
1043 CASE_ESC_IGNORE,
1044 /*	$		%		&		'	*/
1045 CASE_ESC_IGNORE,
1046 CASE_ESC_IGNORE,
1047 CASE_ESC_IGNORE,
1048 CASE_ESC_IGNORE,
1049 /*	(		)		*		+	*/
1050 CASE_ESC_IGNORE,
1051 CASE_ESC_IGNORE,
1052 CASE_ESC_IGNORE,
1053 CASE_ESC_IGNORE,
1054 /*	,		-		.		/	*/
1055 CASE_ESC_IGNORE,
1056 CASE_ESC_IGNORE,
1057 CASE_ESC_IGNORE,
1058 CASE_ESC_IGNORE,
1059 /*	0		1		2		3	*/
1060 CASE_ESC_DIGIT,
1061 CASE_ESC_DIGIT,
1062 CASE_ESC_DIGIT,
1063 CASE_ESC_DIGIT,
1064 /*	4		5		6		7	*/
1065 CASE_ESC_DIGIT,
1066 CASE_ESC_DIGIT,
1067 CASE_ESC_DIGIT,
1068 CASE_ESC_DIGIT,
1069 /*	8		9		:		;	*/
1070 CASE_ESC_DIGIT,
1071 CASE_ESC_DIGIT,
1072 CASE_ESC_SEMI,
1073 CASE_ESC_SEMI,
1074 /*	<		=		>		?	*/
1075 CASE_IGNORE,
1076 CASE_IGNORE,
1077 CASE_IGNORE,
1078 CASE_DEC_STATE,
1079 /*	@		A		B		C	*/
1080 CASE_ICH,
1081 CASE_CUU,
1082 CASE_CUD,
1083 CASE_CUF,
1084 /*	D		E		F		G	*/
1085 CASE_CUB,
1086 CASE_CNL,
1087 CASE_CPL,
1088 CASE_HPA,
1089 /*	H		I		J		K	*/
1090 CASE_CUP,
1091 CASE_CFT,
1092 CASE_ED,
1093 CASE_EL,
1094 /*	L		M		N		O	*/
1095 CASE_IL,
1096 CASE_DL,
1097 CASE_GROUND_STATE,
1098 CASE_GROUND_STATE,
1099 /*	P		Q		R		S	*/
1100 CASE_DCH,
1101 CASE_GROUND_STATE,
1102 CASE_GROUND_STATE,
1103 CASE_SU,
1104 /*	T		U		V		W	*/
1105 CASE_SD,
1106 CASE_GROUND_STATE,
1107 CASE_GROUND_STATE,
1108 CASE_GROUND_STATE,
1109 /*	X		Y		Z		[	*/
1110 CASE_ECH,
1111 CASE_GROUND_STATE,
1112 CASE_CBT,
1113 CASE_GROUND_STATE,
1114 /*	\		]		^		_	*/
1115 CASE_GROUND_STATE,
1116 CASE_GROUND_STATE,
1117 CASE_GROUND_STATE,
1118 CASE_GROUND_STATE,
1119 /*	`		a		b		c	*/
1120 CASE_GROUND_STATE,
1121 CASE_GROUND_STATE,
1122 CASE_REP,
1123 CASE_DA1,
1124 /*	d		e		f		g	*/
1125 CASE_VPA,
1126 CASE_GROUND_STATE,
1127 CASE_CUP,
1128 CASE_TBC,
1129 /*	h		i		j		k	*/
1130 CASE_SET,
1131 CASE_GROUND_STATE,
1132 CASE_GROUND_STATE,
1133 CASE_GROUND_STATE,
1134 /*	l		m		n		o	*/
1135 CASE_RST,
1136 CASE_SGR,
1137 CASE_CPR,
1138 CASE_GROUND_STATE,
1139 /*	p		q		r		s	*/
1140 CASE_GROUND_STATE,
1141 CASE_DECSCUSR_ETC,
1142 CASE_DECSTBM,
1143 CASE_GROUND_STATE,
1144 /*	t		u		v		w	*/
1145 CASE_GROUND_STATE,
1146 CASE_GROUND_STATE,
1147 CASE_GROUND_STATE,
1148 CASE_GROUND_STATE,
1149 /*	x		y		z		{	*/
1150 CASE_DECREQTPARM,
1151 CASE_GROUND_STATE,
1152 CASE_GROUND_STATE,
1153 CASE_GROUND_STATE,
1154 /*	|		}		~		DEL	*/
1155 CASE_GROUND_STATE,
1156 CASE_GROUND_STATE,
1157 CASE_GROUND_STATE,
1158 CASE_GROUND_STATE,
1159 /*      0x80            0x81            0x82            0x83    */
1160 CASE_IGNORE,
1161 CASE_IGNORE,
1162 CASE_IGNORE,
1163 CASE_IGNORE,
1164 /*      0x84            0x85            0x86            0x87    */
1165 CASE_IGNORE,
1166 CASE_IGNORE,
1167 CASE_IGNORE,
1168 CASE_IGNORE,
1169 /*      0x88            0x89            0x8a            0x8b    */
1170 CASE_IGNORE,
1171 CASE_IGNORE,
1172 CASE_IGNORE,
1173 CASE_IGNORE,
1174 /*      0x8c            0x8d            0x8e            0x8f    */
1175 CASE_IGNORE,
1176 CASE_IGNORE,
1177 CASE_IGNORE,
1178 CASE_IGNORE,
1179 /*      0x90            0x91            0x92            0x93    */
1180 CASE_IGNORE,
1181 CASE_IGNORE,
1182 CASE_IGNORE,
1183 CASE_IGNORE,
1184 /*      0x94            0x95            0x96            0x97    */
1185 CASE_IGNORE,
1186 CASE_IGNORE,
1187 CASE_IGNORE,
1188 CASE_IGNORE,
1189 /*      0x99            0x99            0x9a            0x9b    */
1190 CASE_IGNORE,
1191 CASE_IGNORE,
1192 CASE_IGNORE,
1193 CASE_IGNORE,
1194 /*      0x9c            0x9d            0x9e            0x9f    */
1195 CASE_IGNORE,
1196 CASE_IGNORE,
1197 CASE_IGNORE,
1198 CASE_IGNORE,
1199 /*      nobreakspace    exclamdown      cent            sterling        */
1200 CASE_GROUND_STATE,
1201 CASE_GROUND_STATE,
1202 CASE_GROUND_STATE,
1203 CASE_GROUND_STATE,
1204 /*      currency        yen             brokenbar       section         */
1205 CASE_GROUND_STATE,
1206 CASE_GROUND_STATE,
1207 CASE_GROUND_STATE,
1208 CASE_GROUND_STATE,
1209 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
1210 CASE_GROUND_STATE,
1211 CASE_GROUND_STATE,
1212 CASE_GROUND_STATE,
1213 CASE_GROUND_STATE,
1214 /*      notsign         hyphen          registered      macron          */
1215 CASE_GROUND_STATE,
1216 CASE_GROUND_STATE,
1217 CASE_GROUND_STATE,
1218 CASE_GROUND_STATE,
1219 /*      degree          plusminus       twosuperior     threesuperior   */
1220 CASE_GROUND_STATE,
1221 CASE_GROUND_STATE,
1222 CASE_GROUND_STATE,
1223 CASE_GROUND_STATE,
1224 /*      acute           mu              paragraph       periodcentered  */
1225 CASE_GROUND_STATE,
1226 CASE_GROUND_STATE,
1227 CASE_GROUND_STATE,
1228 CASE_GROUND_STATE,
1229 /*      cedilla         onesuperior     masculine       guillemotright  */
1230 CASE_GROUND_STATE,
1231 CASE_GROUND_STATE,
1232 CASE_GROUND_STATE,
1233 CASE_GROUND_STATE,
1234 /*      onequarter      onehalf         threequarters   questiondown    */
1235 CASE_GROUND_STATE,
1236 CASE_GROUND_STATE,
1237 CASE_GROUND_STATE,
1238 CASE_GROUND_STATE,
1239 /*      Agrave          Aacute          Acircumflex     Atilde          */
1240 CASE_GROUND_STATE,
1241 CASE_GROUND_STATE,
1242 CASE_GROUND_STATE,
1243 CASE_GROUND_STATE,
1244 /*      Adiaeresis      Aring           AE              Ccedilla        */
1245 CASE_GROUND_STATE,
1246 CASE_GROUND_STATE,
1247 CASE_GROUND_STATE,
1248 CASE_GROUND_STATE,
1249 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
1250 CASE_GROUND_STATE,
1251 CASE_GROUND_STATE,
1252 CASE_GROUND_STATE,
1253 CASE_GROUND_STATE,
1254 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
1255 CASE_GROUND_STATE,
1256 CASE_GROUND_STATE,
1257 CASE_GROUND_STATE,
1258 CASE_GROUND_STATE,
1259 /*      Eth             Ntilde          Ograve          Oacute          */
1260 CASE_GROUND_STATE,
1261 CASE_GROUND_STATE,
1262 CASE_GROUND_STATE,
1263 CASE_GROUND_STATE,
1264 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
1265 CASE_GROUND_STATE,
1266 CASE_GROUND_STATE,
1267 CASE_GROUND_STATE,
1268 CASE_GROUND_STATE,
1269 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
1270 CASE_GROUND_STATE,
1271 CASE_GROUND_STATE,
1272 CASE_GROUND_STATE,
1273 CASE_GROUND_STATE,
1274 /*      Udiaeresis      Yacute          Thorn           ssharp          */
1275 CASE_GROUND_STATE,
1276 CASE_GROUND_STATE,
1277 CASE_GROUND_STATE,
1278 CASE_GROUND_STATE,
1279 /*      agrave          aacute          acircumflex     atilde          */
1280 CASE_GROUND_STATE,
1281 CASE_GROUND_STATE,
1282 CASE_GROUND_STATE,
1283 CASE_GROUND_STATE,
1284 /*      adiaeresis      aring           ae              ccedilla        */
1285 CASE_GROUND_STATE,
1286 CASE_GROUND_STATE,
1287 CASE_GROUND_STATE,
1288 CASE_GROUND_STATE,
1289 /*      egrave          eacute          ecircumflex     ediaeresis      */
1290 CASE_GROUND_STATE,
1291 CASE_GROUND_STATE,
1292 CASE_GROUND_STATE,
1293 CASE_GROUND_STATE,
1294 /*      igrave          iacute          icircumflex     idiaeresis      */
1295 CASE_GROUND_STATE,
1296 CASE_GROUND_STATE,
1297 CASE_GROUND_STATE,
1298 CASE_GROUND_STATE,
1299 /*      eth             ntilde          ograve          oacute          */
1300 CASE_GROUND_STATE,
1301 CASE_GROUND_STATE,
1302 CASE_GROUND_STATE,
1303 CASE_GROUND_STATE,
1304 /*      ocircumflex     otilde          odiaeresis      division        */
1305 CASE_GROUND_STATE,
1306 CASE_GROUND_STATE,
1307 CASE_GROUND_STATE,
1308 CASE_GROUND_STATE,
1309 /*      oslash          ugrave          uacute          ucircumflex     */
1310 CASE_GROUND_STATE,
1311 CASE_GROUND_STATE,
1312 CASE_GROUND_STATE,
1313 CASE_GROUND_STATE,
1314 /*      udiaeresis      yacute          thorn           ydiaeresis      */
1315 CASE_GROUND_STATE,
1316 CASE_GROUND_STATE,
1317 CASE_GROUND_STATE,
1318 CASE_GROUND_STATE,
1319 };
1320 
1321 // #pragma mark ESC [ ? - DEC table
1322 int gDecTable[] =
1323 {
1324 /*	NUL		SOH		STX		ETX	*/
1325 CASE_IGNORE,
1326 CASE_IGNORE,
1327 CASE_IGNORE,
1328 CASE_IGNORE,
1329 /*	EOT		ENQ		ACK		BEL	*/
1330 CASE_IGNORE,
1331 CASE_IGNORE,
1332 CASE_IGNORE,
1333 CASE_BELL,
1334 /*	BS		HT		NL		VT	*/
1335 CASE_BS,
1336 CASE_TAB,
1337 CASE_VMOT,
1338 CASE_VMOT,
1339 /*	NP		CR		SO		SI	*/
1340 CASE_VMOT,
1341 CASE_CR,
1342 CASE_LS1,
1343 CASE_LS0,
1344 /*	DLE		DC1		DC2		DC3	*/
1345 CASE_IGNORE,
1346 CASE_IGNORE,
1347 CASE_IGNORE,
1348 CASE_IGNORE,
1349 /*	DC4		NAK		SYN		ETB	*/
1350 CASE_IGNORE,
1351 CASE_IGNORE,
1352 CASE_IGNORE,
1353 CASE_IGNORE,
1354 /*	CAN		EM		SUB		ESC	*/
1355 CASE_IGNORE,
1356 CASE_IGNORE,
1357 CASE_IGNORE,
1358 CASE_ESC,
1359 /*	FS		GS		RS		US	*/
1360 CASE_IGNORE,
1361 CASE_IGNORE,
1362 CASE_IGNORE,
1363 CASE_IGNORE,
1364 /*	SP		!		"		#	*/
1365 CASE_ESC_IGNORE,
1366 CASE_ESC_IGNORE,
1367 CASE_ESC_IGNORE,
1368 CASE_ESC_IGNORE,
1369 /*	$		%		&		'	*/
1370 CASE_ESC_IGNORE,
1371 CASE_ESC_IGNORE,
1372 CASE_ESC_IGNORE,
1373 CASE_ESC_IGNORE,
1374 /*	(		)		*		+	*/
1375 CASE_ESC_IGNORE,
1376 CASE_ESC_IGNORE,
1377 CASE_ESC_IGNORE,
1378 CASE_ESC_IGNORE,
1379 /*	,		-		.		/	*/
1380 CASE_ESC_IGNORE,
1381 CASE_ESC_IGNORE,
1382 CASE_ESC_IGNORE,
1383 CASE_ESC_IGNORE,
1384 /*	0		1		2		3	*/
1385 CASE_ESC_DIGIT,
1386 CASE_ESC_DIGIT,
1387 CASE_ESC_DIGIT,
1388 CASE_ESC_DIGIT,
1389 /*	4		5		6		7	*/
1390 CASE_ESC_DIGIT,
1391 CASE_ESC_DIGIT,
1392 CASE_ESC_DIGIT,
1393 CASE_ESC_DIGIT,
1394 /*	8		9		:		;	*/
1395 CASE_ESC_DIGIT,
1396 CASE_ESC_DIGIT,
1397 CASE_IGNORE,
1398 CASE_ESC_SEMI,
1399 /*	<		=		>		?	*/
1400 CASE_GROUND_STATE,
1401 CASE_GROUND_STATE,
1402 CASE_GROUND_STATE,
1403 CASE_GROUND_STATE,
1404 /*	@		A		B		C	*/
1405 CASE_GROUND_STATE,
1406 CASE_GROUND_STATE,
1407 CASE_GROUND_STATE,
1408 CASE_GROUND_STATE,
1409 /*	D		E		F		G	*/
1410 CASE_GROUND_STATE,
1411 CASE_GROUND_STATE,
1412 CASE_GROUND_STATE,
1413 CASE_GROUND_STATE,
1414 /*	H		I		J		K	*/
1415 CASE_GROUND_STATE,
1416 CASE_GROUND_STATE,
1417 CASE_GROUND_STATE,
1418 CASE_GROUND_STATE,
1419 /*	L		M		N		O	*/
1420 CASE_GROUND_STATE,
1421 CASE_GROUND_STATE,
1422 CASE_GROUND_STATE,
1423 CASE_GROUND_STATE,
1424 /*	P		Q		R		S	*/
1425 CASE_GROUND_STATE,
1426 CASE_GROUND_STATE,
1427 CASE_GROUND_STATE,
1428 CASE_GROUND_STATE,
1429 /*	T		U		V		W	*/
1430 CASE_GROUND_STATE,
1431 CASE_GROUND_STATE,
1432 CASE_GROUND_STATE,
1433 CASE_GROUND_STATE,
1434 /*	X		Y		Z		[	*/
1435 CASE_GROUND_STATE,
1436 CASE_GROUND_STATE,
1437 CASE_GROUND_STATE,
1438 CASE_GROUND_STATE,
1439 /*	\		]		^		_	*/
1440 CASE_GROUND_STATE,
1441 CASE_GROUND_STATE,
1442 CASE_GROUND_STATE,
1443 CASE_GROUND_STATE,
1444 /*	`		a		b		c	*/
1445 CASE_GROUND_STATE,
1446 CASE_GROUND_STATE,
1447 CASE_GROUND_STATE,
1448 CASE_GROUND_STATE,
1449 /*	d		e		f		g	*/
1450 CASE_GROUND_STATE,
1451 CASE_GROUND_STATE,
1452 CASE_GROUND_STATE,
1453 CASE_GROUND_STATE,
1454 /*	h		i		j		k	*/
1455 CASE_DECSET,
1456 CASE_GROUND_STATE,
1457 CASE_GROUND_STATE,
1458 CASE_GROUND_STATE,
1459 /*	l		m		n		o	*/
1460 CASE_DECRST,
1461 CASE_GROUND_STATE,
1462 CASE_GROUND_STATE,
1463 CASE_GROUND_STATE,
1464 /*	p		q		r		s	*/
1465 CASE_GROUND_STATE,
1466 CASE_GROUND_STATE,
1467 CASE_GROUND_STATE,
1468 CASE_GROUND_STATE,
1469 /*	t		u		v		w	*/
1470 CASE_GROUND_STATE,
1471 CASE_GROUND_STATE,
1472 CASE_GROUND_STATE,
1473 CASE_GROUND_STATE,
1474 /*	x		y		z		{	*/
1475 CASE_GROUND_STATE,
1476 CASE_GROUND_STATE,
1477 CASE_GROUND_STATE,
1478 CASE_GROUND_STATE,
1479 /*	|		}		~		DEL	*/
1480 CASE_GROUND_STATE,
1481 CASE_GROUND_STATE,
1482 CASE_GROUND_STATE,
1483 CASE_GROUND_STATE,
1484 /*      0x80            0x81            0x82            0x83    */
1485 CASE_IGNORE,
1486 CASE_IGNORE,
1487 CASE_IGNORE,
1488 CASE_IGNORE,
1489 /*      0x84            0x85            0x86            0x87    */
1490 CASE_IGNORE,
1491 CASE_IGNORE,
1492 CASE_IGNORE,
1493 CASE_IGNORE,
1494 /*      0x88            0x89            0x8a            0x8b    */
1495 CASE_IGNORE,
1496 CASE_IGNORE,
1497 CASE_IGNORE,
1498 CASE_IGNORE,
1499 /*      0x8c            0x8d            0x8e            0x8f    */
1500 CASE_IGNORE,
1501 CASE_IGNORE,
1502 CASE_IGNORE,
1503 CASE_IGNORE,
1504 /*      0x90            0x91            0x92            0x93    */
1505 CASE_IGNORE,
1506 CASE_IGNORE,
1507 CASE_IGNORE,
1508 CASE_IGNORE,
1509 /*      0x94            0x95            0x96            0x97    */
1510 CASE_IGNORE,
1511 CASE_IGNORE,
1512 CASE_IGNORE,
1513 CASE_IGNORE,
1514 /*      0x99            0x99            0x9a            0x9b    */
1515 CASE_IGNORE,
1516 CASE_IGNORE,
1517 CASE_IGNORE,
1518 CASE_IGNORE,
1519 /*      0x9c            0x9d            0x9e            0x9f    */
1520 CASE_IGNORE,
1521 CASE_IGNORE,
1522 CASE_IGNORE,
1523 CASE_IGNORE,
1524 /*      nobreakspace    exclamdown      cent            sterling        */
1525 CASE_GROUND_STATE,
1526 CASE_GROUND_STATE,
1527 CASE_GROUND_STATE,
1528 CASE_GROUND_STATE,
1529 /*      currency        yen             brokenbar       section         */
1530 CASE_GROUND_STATE,
1531 CASE_GROUND_STATE,
1532 CASE_GROUND_STATE,
1533 CASE_GROUND_STATE,
1534 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
1535 CASE_GROUND_STATE,
1536 CASE_GROUND_STATE,
1537 CASE_GROUND_STATE,
1538 CASE_GROUND_STATE,
1539 /*      notsign         hyphen          registered      macron          */
1540 CASE_GROUND_STATE,
1541 CASE_GROUND_STATE,
1542 CASE_GROUND_STATE,
1543 CASE_GROUND_STATE,
1544 /*      degree          plusminus       twosuperior     threesuperior   */
1545 CASE_GROUND_STATE,
1546 CASE_GROUND_STATE,
1547 CASE_GROUND_STATE,
1548 CASE_GROUND_STATE,
1549 /*      acute           mu              paragraph       periodcentered  */
1550 CASE_GROUND_STATE,
1551 CASE_GROUND_STATE,
1552 CASE_GROUND_STATE,
1553 CASE_GROUND_STATE,
1554 /*      cedilla         onesuperior     masculine       guillemotright  */
1555 CASE_GROUND_STATE,
1556 CASE_GROUND_STATE,
1557 CASE_GROUND_STATE,
1558 CASE_GROUND_STATE,
1559 /*      onequarter      onehalf         threequarters   questiondown    */
1560 CASE_GROUND_STATE,
1561 CASE_GROUND_STATE,
1562 CASE_GROUND_STATE,
1563 CASE_GROUND_STATE,
1564 /*      Agrave          Aacute          Acircumflex     Atilde          */
1565 CASE_GROUND_STATE,
1566 CASE_GROUND_STATE,
1567 CASE_GROUND_STATE,
1568 CASE_GROUND_STATE,
1569 /*      Adiaeresis      Aring           AE              Ccedilla        */
1570 CASE_GROUND_STATE,
1571 CASE_GROUND_STATE,
1572 CASE_GROUND_STATE,
1573 CASE_GROUND_STATE,
1574 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
1575 CASE_GROUND_STATE,
1576 CASE_GROUND_STATE,
1577 CASE_GROUND_STATE,
1578 CASE_GROUND_STATE,
1579 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
1580 CASE_GROUND_STATE,
1581 CASE_GROUND_STATE,
1582 CASE_GROUND_STATE,
1583 CASE_GROUND_STATE,
1584 /*      Eth             Ntilde          Ograve          Oacute          */
1585 CASE_GROUND_STATE,
1586 CASE_GROUND_STATE,
1587 CASE_GROUND_STATE,
1588 CASE_GROUND_STATE,
1589 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
1590 CASE_GROUND_STATE,
1591 CASE_GROUND_STATE,
1592 CASE_GROUND_STATE,
1593 CASE_GROUND_STATE,
1594 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
1595 CASE_GROUND_STATE,
1596 CASE_GROUND_STATE,
1597 CASE_GROUND_STATE,
1598 CASE_GROUND_STATE,
1599 /*      Udiaeresis      Yacute          Thorn           ssharp          */
1600 CASE_GROUND_STATE,
1601 CASE_GROUND_STATE,
1602 CASE_GROUND_STATE,
1603 CASE_GROUND_STATE,
1604 /*      agrave          aacute          acircumflex     atilde          */
1605 CASE_GROUND_STATE,
1606 CASE_GROUND_STATE,
1607 CASE_GROUND_STATE,
1608 CASE_GROUND_STATE,
1609 /*      adiaeresis      aring           ae              ccedilla        */
1610 CASE_GROUND_STATE,
1611 CASE_GROUND_STATE,
1612 CASE_GROUND_STATE,
1613 CASE_GROUND_STATE,
1614 /*      egrave          eacute          ecircumflex     ediaeresis      */
1615 CASE_GROUND_STATE,
1616 CASE_GROUND_STATE,
1617 CASE_GROUND_STATE,
1618 CASE_GROUND_STATE,
1619 /*      igrave          iacute          icircumflex     idiaeresis      */
1620 CASE_GROUND_STATE,
1621 CASE_GROUND_STATE,
1622 CASE_GROUND_STATE,
1623 CASE_GROUND_STATE,
1624 /*      eth             ntilde          ograve          oacute          */
1625 CASE_GROUND_STATE,
1626 CASE_GROUND_STATE,
1627 CASE_GROUND_STATE,
1628 CASE_GROUND_STATE,
1629 /*      ocircumflex     otilde          odiaeresis      division        */
1630 CASE_GROUND_STATE,
1631 CASE_GROUND_STATE,
1632 CASE_GROUND_STATE,
1633 CASE_GROUND_STATE,
1634 /*      oslash          ugrave          uacute          ucircumflex     */
1635 CASE_GROUND_STATE,
1636 CASE_GROUND_STATE,
1637 CASE_GROUND_STATE,
1638 CASE_GROUND_STATE,
1639 /*      udiaeresis      yacute          thorn           ydiaeresis      */
1640 CASE_GROUND_STATE,
1641 CASE_GROUND_STATE,
1642 CASE_GROUND_STATE,
1643 CASE_GROUND_STATE,
1644 };
1645 
1646 // #pragma mark CASE_ESC_IGNORE table
1647 int gEscIgnoreTable[] =
1648 {
1649 /*	NUL		SOH		STX		ETX	*/
1650 CASE_IGNORE,
1651 CASE_IGNORE,
1652 CASE_IGNORE,
1653 CASE_IGNORE,
1654 /*	EOT		ENQ		ACK		BEL	*/
1655 CASE_IGNORE,
1656 CASE_IGNORE,
1657 CASE_IGNORE,
1658 CASE_BELL,
1659 /*	BS		HT		NL		VT	*/
1660 CASE_BS,
1661 CASE_TAB,
1662 CASE_VMOT,
1663 CASE_VMOT,
1664 /*	NP		CR		SO		SI	*/
1665 CASE_VMOT,
1666 CASE_CR,
1667 CASE_LS1,
1668 CASE_LS0,
1669 /*	DLE		DC1		DC2		DC3	*/
1670 CASE_IGNORE,
1671 CASE_IGNORE,
1672 CASE_IGNORE,
1673 CASE_IGNORE,
1674 /*	DC4		NAK		SYN		ETB	*/
1675 CASE_IGNORE,
1676 CASE_IGNORE,
1677 CASE_IGNORE,
1678 CASE_IGNORE,
1679 /*	CAN		EM		SUB		ESC	*/
1680 CASE_IGNORE,
1681 CASE_IGNORE,
1682 CASE_IGNORE,
1683 CASE_ESC,
1684 /*	FS		GS		RS		US	*/
1685 CASE_IGNORE,
1686 CASE_IGNORE,
1687 CASE_IGNORE,
1688 CASE_IGNORE,
1689 /*	SP		!		"		#	*/
1690 CASE_IGNORE,
1691 CASE_IGNORE,
1692 CASE_IGNORE,
1693 CASE_IGNORE,
1694 /*	$		%		&		'	*/
1695 CASE_IGNORE,
1696 CASE_IGNORE,
1697 CASE_IGNORE,
1698 CASE_IGNORE,
1699 /*	(		)		*		+	*/
1700 CASE_IGNORE,
1701 CASE_IGNORE,
1702 CASE_IGNORE,
1703 CASE_IGNORE,
1704 /*	,
1705 	-		.		/	*/
1706 CASE_IGNORE,
1707 CASE_IGNORE,
1708 CASE_IGNORE,
1709 CASE_IGNORE,
1710 /*	0		1		2		3	*/
1711 CASE_GROUND_STATE,
1712 CASE_GROUND_STATE,
1713 CASE_GROUND_STATE,
1714 CASE_GROUND_STATE,
1715 /*	4		5		6		7	*/
1716 CASE_GROUND_STATE,
1717 CASE_GROUND_STATE,
1718 CASE_GROUND_STATE,
1719 CASE_GROUND_STATE,
1720 /*	8		9		:		;	*/
1721 CASE_GROUND_STATE,
1722 CASE_GROUND_STATE,
1723 CASE_GROUND_STATE,
1724 CASE_GROUND_STATE,
1725 /*	<		=		>		?	*/
1726 CASE_GROUND_STATE,
1727 CASE_GROUND_STATE,
1728 CASE_GROUND_STATE,
1729 CASE_GROUND_STATE,
1730 /*	@		A		B		C	*/
1731 CASE_GROUND_STATE,
1732 CASE_GROUND_STATE,
1733 CASE_GROUND_STATE,
1734 CASE_GROUND_STATE,
1735 /*	D		E		F		G	*/
1736 CASE_GROUND_STATE,
1737 CASE_GROUND_STATE,
1738 CASE_GROUND_STATE,
1739 CASE_GROUND_STATE,
1740 /*	H		I		J		K	*/
1741 CASE_GROUND_STATE,
1742 CASE_GROUND_STATE,
1743 CASE_GROUND_STATE,
1744 CASE_GROUND_STATE,
1745 /*	L		M		N		O	*/
1746 CASE_GROUND_STATE,
1747 CASE_GROUND_STATE,
1748 CASE_GROUND_STATE,
1749 CASE_GROUND_STATE,
1750 /*	P		Q		R		S	*/
1751 CASE_GROUND_STATE,
1752 CASE_GROUND_STATE,
1753 CASE_GROUND_STATE,
1754 CASE_GROUND_STATE,
1755 /*	T		U		V		W	*/
1756 CASE_GROUND_STATE,
1757 CASE_GROUND_STATE,
1758 CASE_GROUND_STATE,
1759 CASE_GROUND_STATE,
1760 /*	X		Y		Z		[	*/
1761 CASE_GROUND_STATE,
1762 CASE_GROUND_STATE,
1763 CASE_GROUND_STATE,
1764 CASE_GROUND_STATE,
1765 /*	\		]		^		_	*/
1766 CASE_GROUND_STATE,
1767 CASE_GROUND_STATE,
1768 CASE_GROUND_STATE,
1769 CASE_GROUND_STATE,
1770 /*	`		a		b		c	*/
1771 CASE_GROUND_STATE,
1772 CASE_GROUND_STATE,
1773 CASE_GROUND_STATE,
1774 CASE_GROUND_STATE,
1775 /*	d		e		f		g	*/
1776 CASE_GROUND_STATE,
1777 CASE_GROUND_STATE,
1778 CASE_GROUND_STATE,
1779 CASE_GROUND_STATE,
1780 /*	h		i		j		k	*/
1781 CASE_GROUND_STATE,
1782 CASE_GROUND_STATE,
1783 CASE_GROUND_STATE,
1784 CASE_GROUND_STATE,
1785 /*	l		m		n		o	*/
1786 CASE_GROUND_STATE,
1787 CASE_GROUND_STATE,
1788 CASE_GROUND_STATE,
1789 CASE_GROUND_STATE,
1790 /*	p		q		r		s	*/
1791 CASE_GROUND_STATE,
1792 CASE_GROUND_STATE,
1793 CASE_GROUND_STATE,
1794 CASE_GROUND_STATE,
1795 /*	t		u		v		w	*/
1796 CASE_GROUND_STATE,
1797 CASE_GROUND_STATE,
1798 CASE_GROUND_STATE,
1799 CASE_GROUND_STATE,
1800 /*	x		y		z		{	*/
1801 CASE_GROUND_STATE,
1802 CASE_GROUND_STATE,
1803 CASE_GROUND_STATE,
1804 CASE_GROUND_STATE,
1805 /*	|		}		~		DEL	*/
1806 CASE_GROUND_STATE,
1807 CASE_GROUND_STATE,
1808 CASE_GROUND_STATE,
1809 CASE_GROUND_STATE,
1810 /*      0x80            0x81            0x82            0x83    */
1811 CASE_IGNORE,
1812 CASE_IGNORE,
1813 CASE_IGNORE,
1814 CASE_IGNORE,
1815 /*      0x84            0x85            0x86            0x87    */
1816 CASE_IGNORE,
1817 CASE_IGNORE,
1818 CASE_IGNORE,
1819 CASE_IGNORE,
1820 /*      0x88            0x89            0x8a            0x8b    */
1821 CASE_IGNORE,
1822 CASE_IGNORE,
1823 CASE_IGNORE,
1824 CASE_IGNORE,
1825 /*      0x8c            0x8d            0x8e            0x8f    */
1826 CASE_IGNORE,
1827 CASE_IGNORE,
1828 CASE_IGNORE,
1829 CASE_IGNORE,
1830 /*      0x90            0x91            0x92            0x93    */
1831 CASE_IGNORE,
1832 CASE_IGNORE,
1833 CASE_IGNORE,
1834 CASE_IGNORE,
1835 /*      0x94            0x95            0x96            0x97    */
1836 CASE_IGNORE,
1837 CASE_IGNORE,
1838 CASE_IGNORE,
1839 CASE_IGNORE,
1840 /*      0x99            0x99            0x9a            0x9b    */
1841 CASE_IGNORE,
1842 CASE_IGNORE,
1843 CASE_IGNORE,
1844 CASE_IGNORE,
1845 /*      0x9c            0x9d            0x9e            0x9f    */
1846 CASE_IGNORE,
1847 CASE_IGNORE,
1848 CASE_IGNORE,
1849 CASE_IGNORE,
1850 /*      nobreakspace    exclamdown      cent            sterling        */
1851 CASE_GROUND_STATE,
1852 CASE_GROUND_STATE,
1853 CASE_GROUND_STATE,
1854 CASE_GROUND_STATE,
1855 /*      currency        yen             brokenbar       section         */
1856 CASE_GROUND_STATE,
1857 CASE_GROUND_STATE,
1858 CASE_GROUND_STATE,
1859 CASE_GROUND_STATE,
1860 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
1861 CASE_GROUND_STATE,
1862 CASE_GROUND_STATE,
1863 CASE_GROUND_STATE,
1864 CASE_GROUND_STATE,
1865 /*      notsign         hyphen          registered      macron          */
1866 CASE_GROUND_STATE,
1867 CASE_GROUND_STATE,
1868 CASE_GROUND_STATE,
1869 CASE_GROUND_STATE,
1870 /*      degree          plusminus       twosuperior     threesuperior   */
1871 CASE_GROUND_STATE,
1872 CASE_GROUND_STATE,
1873 CASE_GROUND_STATE,
1874 CASE_GROUND_STATE,
1875 /*      acute           mu              paragraph       periodcentered  */
1876 CASE_GROUND_STATE,
1877 CASE_GROUND_STATE,
1878 CASE_GROUND_STATE,
1879 CASE_GROUND_STATE,
1880 /*      cedilla         onesuperior     masculine       guillemotright  */
1881 CASE_GROUND_STATE,
1882 CASE_GROUND_STATE,
1883 CASE_GROUND_STATE,
1884 CASE_GROUND_STATE,
1885 /*      onequarter      onehalf         threequarters   questiondown    */
1886 CASE_GROUND_STATE,
1887 CASE_GROUND_STATE,
1888 CASE_GROUND_STATE,
1889 CASE_GROUND_STATE,
1890 /*      Agrave          Aacute          Acircumflex     Atilde          */
1891 CASE_GROUND_STATE,
1892 CASE_GROUND_STATE,
1893 CASE_GROUND_STATE,
1894 CASE_GROUND_STATE,
1895 /*      Adiaeresis      Aring           AE              Ccedilla        */
1896 CASE_GROUND_STATE,
1897 CASE_GROUND_STATE,
1898 CASE_GROUND_STATE,
1899 CASE_GROUND_STATE,
1900 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
1901 CASE_GROUND_STATE,
1902 CASE_GROUND_STATE,
1903 CASE_GROUND_STATE,
1904 CASE_GROUND_STATE,
1905 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
1906 CASE_GROUND_STATE,
1907 CASE_GROUND_STATE,
1908 CASE_GROUND_STATE,
1909 CASE_GROUND_STATE,
1910 /*      Eth             Ntilde          Ograve          Oacute          */
1911 CASE_GROUND_STATE,
1912 CASE_GROUND_STATE,
1913 CASE_GROUND_STATE,
1914 CASE_GROUND_STATE,
1915 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
1916 CASE_GROUND_STATE,
1917 CASE_GROUND_STATE,
1918 CASE_GROUND_STATE,
1919 CASE_GROUND_STATE,
1920 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
1921 CASE_GROUND_STATE,
1922 CASE_GROUND_STATE,
1923 CASE_GROUND_STATE,
1924 CASE_GROUND_STATE,
1925 /*      Udiaeresis      Yacute          Thorn           ssharp          */
1926 CASE_GROUND_STATE,
1927 CASE_GROUND_STATE,
1928 CASE_GROUND_STATE,
1929 CASE_GROUND_STATE,
1930 /*      agrave          aacute          acircumflex     atilde          */
1931 CASE_GROUND_STATE,
1932 CASE_GROUND_STATE,
1933 CASE_GROUND_STATE,
1934 CASE_GROUND_STATE,
1935 /*      adiaeresis      aring           ae              ccedilla        */
1936 CASE_GROUND_STATE,
1937 CASE_GROUND_STATE,
1938 CASE_GROUND_STATE,
1939 CASE_GROUND_STATE,
1940 /*      egrave          eacute          ecircumflex     ediaeresis      */
1941 CASE_GROUND_STATE,
1942 CASE_GROUND_STATE,
1943 CASE_GROUND_STATE,
1944 CASE_GROUND_STATE,
1945 /*      igrave          iacute          icircumflex     idiaeresis      */
1946 CASE_GROUND_STATE,
1947 CASE_GROUND_STATE,
1948 CASE_GROUND_STATE,
1949 CASE_GROUND_STATE,
1950 /*      eth             ntilde          ograve          oacute          */
1951 CASE_GROUND_STATE,
1952 CASE_GROUND_STATE,
1953 CASE_GROUND_STATE,
1954 CASE_GROUND_STATE,
1955 /*      ocircumflex     otilde          odiaeresis      division        */
1956 CASE_GROUND_STATE,
1957 CASE_GROUND_STATE,
1958 CASE_GROUND_STATE,
1959 CASE_GROUND_STATE,
1960 /*      oslash          ugrave          uacute          ucircumflex     */
1961 CASE_GROUND_STATE,
1962 CASE_GROUND_STATE,
1963 CASE_GROUND_STATE,
1964 CASE_GROUND_STATE,
1965 /*      udiaeresis      yacute          thorn           ydiaeresis      */
1966 CASE_GROUND_STATE,
1967 CASE_GROUND_STATE,
1968 CASE_GROUND_STATE,
1969 CASE_GROUND_STATE,
1970 };
1971 
1972 // #pragma mark ESC table
1973 int gEscTable[] =
1974 {
1975 /*	NUL		SOH		STX		ETX	*/
1976 CASE_IGNORE,
1977 CASE_IGNORE,
1978 CASE_IGNORE,
1979 CASE_IGNORE,
1980 /*	EOT		ENQ		ACK		BEL	*/
1981 CASE_IGNORE,
1982 CASE_IGNORE,
1983 CASE_IGNORE,
1984 CASE_BELL,
1985 /*	BS		HT		NL		VT	*/
1986 CASE_BS,
1987 CASE_TAB,
1988 CASE_LF,
1989 CASE_LF, /*CASE_UP,*/
1990 /*	NP		CR		SO		SI	*/
1991 CASE_LF, /*CASE_IGNORE,*/
1992 CASE_CR,
1993 CASE_LS1,
1994 CASE_LS0,
1995 /*	DLE		DC1		DC2		DC3	*/
1996 CASE_IGNORE,
1997 CASE_IGNORE,
1998 CASE_IGNORE,
1999 CASE_IGNORE,
2000 /*	DC4		NAK		SYN		ETB	*/
2001 CASE_IGNORE,
2002 CASE_IGNORE,
2003 CASE_IGNORE,
2004 CASE_IGNORE,
2005 /*	CAN		EM		SUB		ESC	*/
2006 CASE_IGNORE,
2007 CASE_IGNORE,
2008 CASE_IGNORE,
2009 CASE_ESC,
2010 /*	FS		GS		RS		US	*/
2011 CASE_IGNORE,
2012 CASE_IGNORE,
2013 CASE_IGNORE,
2014 CASE_IGNORE,
2015 /*	SP		!		"		#	*/
2016 CASE_ESC_IGNORE,
2017 CASE_ESC_IGNORE,
2018 CASE_ESC_IGNORE,
2019 CASE_SCR_STATE,
2020 /*	$		%		&		'	*/
2021 CASE_ESC_IGNORE,
2022 CASE_ESC_IGNORE,
2023 CASE_ESC_IGNORE,
2024 CASE_ESC_IGNORE,
2025 /*	(		)		*		+	*/
2026 CASE_SCS_STATE,
2027 CASE_SCS_STATE,
2028 CASE_SCS_STATE,
2029 CASE_SCS_STATE,
2030 /*	,		-		.		/	*/
2031 CASE_SCS_STATE,	/* not defined in ISO2022 but used in Mule */
2032 CASE_SCS_STATE,
2033 CASE_SCS_STATE,
2034 CASE_SCS_STATE,
2035 /*	0		1		2		3	*/
2036 CASE_GROUND_STATE,
2037 CASE_GROUND_STATE,
2038 CASE_GROUND_STATE,
2039 CASE_GROUND_STATE,
2040 /*	4		5		6		7	*/
2041 CASE_GROUND_STATE,
2042 CASE_GROUND_STATE,
2043 CASE_GROUND_STATE,
2044 CASE_DECSC,
2045 /*	8		9		:		;	*/
2046 CASE_DECRC,
2047 CASE_GROUND_STATE,
2048 CASE_GROUND_STATE,
2049 CASE_GROUND_STATE,
2050 /*	<		=		>		?	*/
2051 CASE_GROUND_STATE,
2052 CASE_GROUND_STATE,
2053 CASE_GROUND_STATE,
2054 CASE_GROUND_STATE,
2055 /*	@		A		B		C	*/
2056 CASE_GROUND_STATE,
2057 CASE_GROUND_STATE,
2058 CASE_GROUND_STATE,
2059 CASE_GROUND_STATE,
2060 /*	D		E		F		G	*/
2061 CASE_INDEX,
2062 CASE_NEXT_LINE,
2063 CASE_GROUND_STATE,
2064 CASE_GROUND_STATE,
2065 /*	H		I		J		K	*/
2066 CASE_HTS,
2067 CASE_GROUND_STATE,
2068 CASE_GROUND_STATE,
2069 CASE_GROUND_STATE,
2070 /*	L		M		N		O	*/
2071 CASE_GROUND_STATE,
2072 CASE_RI,
2073 CASE_SS2,
2074 CASE_SS3,
2075 /*	P		Q		R		S	*/
2076 CASE_IGNORE_STATE,
2077 CASE_GROUND_STATE,
2078 CASE_GROUND_STATE,
2079 CASE_GROUND_STATE,
2080 /*	T		U		V		W	*/
2081 CASE_XTERM_TITLE,
2082 CASE_GROUND_STATE,
2083 CASE_GROUND_STATE,
2084 CASE_GROUND_STATE,
2085 /*	X		Y		Z		[	*/
2086 CASE_GROUND_STATE,
2087 CASE_GROUND_STATE,
2088 CASE_DA1,
2089 CASE_CSI_STATE,
2090 /*	\		]		^		_	*/
2091 CASE_GROUND_STATE,
2092 CASE_OSC,
2093 CASE_IGNORE_STATE,
2094 CASE_IGNORE_STATE,
2095 /*	`		a		b		c	*/
2096 CASE_GROUND_STATE,
2097 CASE_GROUND_STATE,
2098 CASE_GROUND_STATE,
2099 CASE_RIS,
2100 /*	d		e		f		g	*/
2101 CASE_GROUND_STATE,
2102 CASE_GROUND_STATE,
2103 CASE_GROUND_STATE,
2104 CASE_GROUND_STATE,
2105 /*	h		i		j		k	*/
2106 CASE_GROUND_STATE,
2107 CASE_GROUND_STATE,
2108 CASE_GROUND_STATE,
2109 CASE_GROUND_STATE,
2110 /*	l		m		n		o	*/
2111 CASE_GROUND_STATE,
2112 CASE_GROUND_STATE,
2113 CASE_LS2,
2114 CASE_LS3,
2115 /*	p		q		r		s	*/
2116 CASE_GROUND_STATE,
2117 CASE_GROUND_STATE,
2118 CASE_GROUND_STATE,
2119 CASE_GROUND_STATE,
2120 /*	t		u		v		w	*/
2121 CASE_GROUND_STATE,
2122 CASE_GROUND_STATE,
2123 CASE_GROUND_STATE,
2124 CASE_GROUND_STATE,
2125 /*	x		y		z		{	*/
2126 CASE_GROUND_STATE,
2127 CASE_GROUND_STATE,
2128 CASE_GROUND_STATE,
2129 CASE_GROUND_STATE,
2130 /*	|		}		~		DEL	*/
2131 CASE_LS3R,
2132 CASE_LS2R,
2133 CASE_LS1R,
2134 CASE_GROUND_STATE,
2135 /*      0x80            0x81            0x82            0x83    */
2136 CASE_IGNORE,
2137 CASE_IGNORE,
2138 CASE_IGNORE,
2139 CASE_IGNORE,
2140 /*      0x84            0x85            0x86            0x87    */
2141 CASE_IGNORE,
2142 CASE_IGNORE,
2143 CASE_IGNORE,
2144 CASE_IGNORE,
2145 /*      0x88            0x89            0x8a            0x8b    */
2146 CASE_IGNORE,
2147 CASE_IGNORE,
2148 CASE_IGNORE,
2149 CASE_IGNORE,
2150 /*      0x8c            0x8d            0x8e            0x8f    */
2151 CASE_IGNORE,
2152 CASE_IGNORE,
2153 CASE_IGNORE,
2154 CASE_IGNORE,
2155 /*      0x90            0x91            0x92            0x93    */
2156 CASE_IGNORE,
2157 CASE_IGNORE,
2158 CASE_IGNORE,
2159 CASE_IGNORE,
2160 /*      0x94            0x95            0x96            0x97    */
2161 CASE_IGNORE,
2162 CASE_IGNORE,
2163 CASE_IGNORE,
2164 CASE_IGNORE,
2165 /*      0x99            0x99            0x9a            0x9b    */
2166 CASE_IGNORE,
2167 CASE_IGNORE,
2168 CASE_IGNORE,
2169 CASE_IGNORE,
2170 /*      0x9c            0x9d            0x9e            0x9f    */
2171 CASE_IGNORE,
2172 CASE_IGNORE,
2173 CASE_IGNORE,
2174 CASE_IGNORE,
2175 /*      nobreakspace    exclamdown      cent            sterling        */
2176 CASE_GROUND_STATE,
2177 CASE_GROUND_STATE,
2178 CASE_GROUND_STATE,
2179 CASE_GROUND_STATE,
2180 /*      currency        yen             brokenbar       section         */
2181 CASE_GROUND_STATE,
2182 CASE_GROUND_STATE,
2183 CASE_GROUND_STATE,
2184 CASE_GROUND_STATE,
2185 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
2186 CASE_GROUND_STATE,
2187 CASE_GROUND_STATE,
2188 CASE_GROUND_STATE,
2189 CASE_GROUND_STATE,
2190 /*      notsign         hyphen          registered      macron          */
2191 CASE_GROUND_STATE,
2192 CASE_GROUND_STATE,
2193 CASE_GROUND_STATE,
2194 CASE_GROUND_STATE,
2195 /*      degree          plusminus       twosuperior     threesuperior   */
2196 CASE_GROUND_STATE,
2197 CASE_GROUND_STATE,
2198 CASE_GROUND_STATE,
2199 CASE_GROUND_STATE,
2200 /*      acute           mu              paragraph       periodcentered  */
2201 CASE_GROUND_STATE,
2202 CASE_GROUND_STATE,
2203 CASE_GROUND_STATE,
2204 CASE_GROUND_STATE,
2205 /*      cedilla         onesuperior     masculine       guillemotright  */
2206 CASE_GROUND_STATE,
2207 CASE_GROUND_STATE,
2208 CASE_GROUND_STATE,
2209 CASE_GROUND_STATE,
2210 /*      onequarter      onehalf         threequarters   questiondown    */
2211 CASE_GROUND_STATE,
2212 CASE_GROUND_STATE,
2213 CASE_GROUND_STATE,
2214 CASE_GROUND_STATE,
2215 /*      Agrave          Aacute          Acircumflex     Atilde          */
2216 CASE_GROUND_STATE,
2217 CASE_GROUND_STATE,
2218 CASE_GROUND_STATE,
2219 CASE_GROUND_STATE,
2220 /*      Adiaeresis      Aring           AE              Ccedilla        */
2221 CASE_GROUND_STATE,
2222 CASE_GROUND_STATE,
2223 CASE_GROUND_STATE,
2224 CASE_GROUND_STATE,
2225 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
2226 CASE_GROUND_STATE,
2227 CASE_GROUND_STATE,
2228 CASE_GROUND_STATE,
2229 CASE_GROUND_STATE,
2230 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
2231 CASE_GROUND_STATE,
2232 CASE_GROUND_STATE,
2233 CASE_GROUND_STATE,
2234 CASE_GROUND_STATE,
2235 /*      Eth             Ntilde          Ograve          Oacute          */
2236 CASE_GROUND_STATE,
2237 CASE_GROUND_STATE,
2238 CASE_GROUND_STATE,
2239 CASE_GROUND_STATE,
2240 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
2241 CASE_GROUND_STATE,
2242 CASE_GROUND_STATE,
2243 CASE_GROUND_STATE,
2244 CASE_GROUND_STATE,
2245 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
2246 CASE_GROUND_STATE,
2247 CASE_GROUND_STATE,
2248 CASE_GROUND_STATE,
2249 CASE_GROUND_STATE,
2250 /*      Udiaeresis      Yacute          Thorn           ssharp          */
2251 CASE_GROUND_STATE,
2252 CASE_GROUND_STATE,
2253 CASE_GROUND_STATE,
2254 CASE_GROUND_STATE,
2255 /*      agrave          aacute          acircumflex     atilde          */
2256 CASE_GROUND_STATE,
2257 CASE_GROUND_STATE,
2258 CASE_GROUND_STATE,
2259 CASE_GROUND_STATE,
2260 /*      adiaeresis      aring           ae              ccedilla        */
2261 CASE_GROUND_STATE,
2262 CASE_GROUND_STATE,
2263 CASE_GROUND_STATE,
2264 CASE_GROUND_STATE,
2265 /*      egrave          eacute          ecircumflex     ediaeresis      */
2266 CASE_GROUND_STATE,
2267 CASE_GROUND_STATE,
2268 CASE_GROUND_STATE,
2269 CASE_GROUND_STATE,
2270 /*      igrave          iacute          icircumflex     idiaeresis      */
2271 CASE_GROUND_STATE,
2272 CASE_GROUND_STATE,
2273 CASE_GROUND_STATE,
2274 CASE_GROUND_STATE,
2275 /*      eth             ntilde          ograve          oacute          */
2276 CASE_GROUND_STATE,
2277 CASE_GROUND_STATE,
2278 CASE_GROUND_STATE,
2279 CASE_GROUND_STATE,
2280 /*      ocircumflex     otilde          odiaeresis      division        */
2281 CASE_GROUND_STATE,
2282 CASE_GROUND_STATE,
2283 CASE_GROUND_STATE,
2284 CASE_GROUND_STATE,
2285 /*      oslash          ugrave          uacute          ucircumflex     */
2286 CASE_GROUND_STATE,
2287 CASE_GROUND_STATE,
2288 CASE_GROUND_STATE,
2289 CASE_GROUND_STATE,
2290 /*      udiaeresis      yacute          thorn           ydiaeresis      */
2291 CASE_GROUND_STATE,
2292 CASE_GROUND_STATE,
2293 CASE_GROUND_STATE,
2294 CASE_GROUND_STATE,
2295 };
2296 
2297 // #pragma mark CASE_IGNORE_ESC table
2298 int gIesTable[] =
2299 {
2300 /*	NUL		SOH		STX		ETX	*/
2301 CASE_IGNORE_STATE,
2302 CASE_IGNORE_STATE,
2303 CASE_IGNORE_STATE,
2304 CASE_IGNORE_STATE,
2305 /*	EOT		ENQ		ACK		BEL	*/
2306 CASE_IGNORE_STATE,
2307 CASE_IGNORE_STATE,
2308 CASE_IGNORE_STATE,
2309 CASE_IGNORE_STATE,
2310 /*	BS		HT		NL		VT	*/
2311 CASE_IGNORE_STATE,
2312 CASE_IGNORE_STATE,
2313 CASE_IGNORE_STATE,
2314 CASE_IGNORE_STATE,
2315 /*	NP		CR		SO		SI	*/
2316 CASE_IGNORE_STATE,
2317 CASE_IGNORE_STATE,
2318 CASE_IGNORE_STATE,
2319 CASE_IGNORE_STATE,
2320 /*	DLE		DC1		DC2		DC3	*/
2321 CASE_IGNORE_STATE,
2322 CASE_IGNORE_STATE,
2323 CASE_IGNORE_STATE,
2324 CASE_IGNORE_STATE,
2325 /*	DC4		NAK		SYN		ETB	*/
2326 CASE_IGNORE_STATE,
2327 CASE_IGNORE_STATE,
2328 CASE_IGNORE_STATE,
2329 CASE_IGNORE_STATE,
2330 /*	CAN		EM		SUB		ESC	*/
2331 CASE_IGNORE_STATE,
2332 CASE_IGNORE_STATE,
2333 CASE_IGNORE_STATE,
2334 CASE_IGNORE_STATE,
2335 /*	FS		GS		RS		US	*/
2336 CASE_IGNORE_STATE,
2337 CASE_IGNORE_STATE,
2338 CASE_IGNORE_STATE,
2339 CASE_IGNORE_STATE,
2340 /*	SP		!		"		#	*/
2341 CASE_IGNORE_STATE,
2342 CASE_IGNORE_STATE,
2343 CASE_IGNORE_STATE,
2344 CASE_IGNORE_STATE,
2345 /*	$		%		&		'	*/
2346 CASE_IGNORE_STATE,
2347 CASE_IGNORE_STATE,
2348 CASE_IGNORE_STATE,
2349 CASE_IGNORE_STATE,
2350 /*	(		)		*		+	*/
2351 CASE_IGNORE_STATE,
2352 CASE_IGNORE_STATE,
2353 CASE_IGNORE_STATE,
2354 CASE_IGNORE_STATE,
2355 /*	,		-		.		/	*/
2356 CASE_IGNORE_STATE,
2357 CASE_IGNORE_STATE,
2358 CASE_IGNORE_STATE,
2359 CASE_IGNORE_STATE,
2360 /*	0		1		2		3	*/
2361 CASE_IGNORE_STATE,
2362 CASE_IGNORE_STATE,
2363 CASE_IGNORE_STATE,
2364 CASE_IGNORE_STATE,
2365 /*	4		5		6		7	*/
2366 CASE_IGNORE_STATE,
2367 CASE_IGNORE_STATE,
2368 CASE_IGNORE_STATE,
2369 CASE_IGNORE_STATE,
2370 /*	8		9		:		;	*/
2371 CASE_IGNORE_STATE,
2372 CASE_IGNORE_STATE,
2373 CASE_IGNORE_STATE,
2374 CASE_IGNORE_STATE,
2375 /*	<		=		>		?	*/
2376 CASE_IGNORE_STATE,
2377 CASE_IGNORE_STATE,
2378 CASE_IGNORE_STATE,
2379 CASE_IGNORE_STATE,
2380 /*	@		A		B		C	*/
2381 CASE_IGNORE_STATE,
2382 CASE_IGNORE_STATE,
2383 CASE_IGNORE_STATE,
2384 CASE_IGNORE_STATE,
2385 /*	D		E		F		G	*/
2386 CASE_IGNORE_STATE,
2387 CASE_IGNORE_STATE,
2388 CASE_IGNORE_STATE,
2389 CASE_IGNORE_STATE,
2390 /*	H		I		J		K	*/
2391 CASE_IGNORE_STATE,
2392 CASE_IGNORE_STATE,
2393 CASE_IGNORE_STATE,
2394 CASE_IGNORE_STATE,
2395 /*	L		M		N		O	*/
2396 CASE_IGNORE_STATE,
2397 CASE_IGNORE_STATE,
2398 CASE_IGNORE_STATE,
2399 CASE_IGNORE_STATE,
2400 /*	P		Q		R		S	*/
2401 CASE_IGNORE_STATE,
2402 CASE_IGNORE_STATE,
2403 CASE_IGNORE_STATE,
2404 CASE_IGNORE_STATE,
2405 /*	T		U		V		W	*/
2406 CASE_IGNORE_STATE,
2407 CASE_IGNORE_STATE,
2408 CASE_IGNORE_STATE,
2409 CASE_IGNORE_STATE,
2410 /*	X		Y		Z		[	*/
2411 CASE_IGNORE_STATE,
2412 CASE_IGNORE_STATE,
2413 CASE_IGNORE_STATE,
2414 CASE_IGNORE_STATE,
2415 /*	\		]		^		_	*/
2416 CASE_GROUND_STATE,
2417 CASE_IGNORE_STATE,
2418 CASE_IGNORE_STATE,
2419 CASE_IGNORE_STATE,
2420 /*	`		a		b		c	*/
2421 CASE_IGNORE_STATE,
2422 CASE_IGNORE_STATE,
2423 CASE_IGNORE_STATE,
2424 CASE_IGNORE_STATE,
2425 /*	d		e		f		g	*/
2426 CASE_IGNORE_STATE,
2427 CASE_IGNORE_STATE,
2428 CASE_IGNORE_STATE,
2429 CASE_IGNORE_STATE,
2430 /*	h		i		j		k	*/
2431 CASE_IGNORE_STATE,
2432 CASE_IGNORE_STATE,
2433 CASE_IGNORE_STATE,
2434 CASE_IGNORE_STATE,
2435 /*	l		m		n		o	*/
2436 CASE_IGNORE_STATE,
2437 CASE_IGNORE_STATE,
2438 CASE_IGNORE_STATE,
2439 CASE_IGNORE_STATE,
2440 /*	p		q		r		s	*/
2441 CASE_IGNORE_STATE,
2442 CASE_IGNORE_STATE,
2443 CASE_IGNORE_STATE,
2444 CASE_IGNORE_STATE,
2445 /*	t		u		v		w	*/
2446 CASE_IGNORE_STATE,
2447 CASE_IGNORE_STATE,
2448 CASE_IGNORE_STATE,
2449 CASE_IGNORE_STATE,
2450 /*	x		y		z		{	*/
2451 CASE_IGNORE_STATE,
2452 CASE_IGNORE_STATE,
2453 CASE_IGNORE_STATE,
2454 CASE_IGNORE_STATE,
2455 /*	|		}		~		DEL	*/
2456 CASE_IGNORE_STATE,
2457 CASE_IGNORE_STATE,
2458 CASE_IGNORE_STATE,
2459 CASE_IGNORE_STATE,
2460 /*      0x80            0x81            0x82            0x83    */
2461 CASE_IGNORE,
2462 CASE_IGNORE,
2463 CASE_IGNORE,
2464 CASE_IGNORE,
2465 /*      0x84            0x85            0x86            0x87    */
2466 CASE_IGNORE,
2467 CASE_IGNORE,
2468 CASE_IGNORE,
2469 CASE_IGNORE,
2470 /*      0x88            0x89            0x8a            0x8b    */
2471 CASE_IGNORE,
2472 CASE_IGNORE,
2473 CASE_IGNORE,
2474 CASE_IGNORE,
2475 /*      0x8c            0x8d            0x8e            0x8f    */
2476 CASE_IGNORE,
2477 CASE_IGNORE,
2478 CASE_IGNORE,
2479 CASE_IGNORE,
2480 /*      0x90            0x91            0x92            0x93    */
2481 CASE_IGNORE,
2482 CASE_IGNORE,
2483 CASE_IGNORE,
2484 CASE_IGNORE,
2485 /*      0x94            0x95            0x96            0x97    */
2486 CASE_IGNORE,
2487 CASE_IGNORE,
2488 CASE_IGNORE,
2489 CASE_IGNORE,
2490 /*      0x99            0x99            0x9a            0x9b    */
2491 CASE_IGNORE,
2492 CASE_IGNORE,
2493 CASE_IGNORE,
2494 CASE_IGNORE,
2495 /*      0x9c            0x9d            0x9e            0x9f    */
2496 CASE_IGNORE,
2497 CASE_IGNORE,
2498 CASE_IGNORE,
2499 CASE_IGNORE,
2500 /*      nobreakspace    exclamdown      cent            sterling        */
2501 CASE_GROUND_STATE,
2502 CASE_GROUND_STATE,
2503 CASE_GROUND_STATE,
2504 CASE_GROUND_STATE,
2505 /*      currency        yen             brokenbar       section         */
2506 CASE_GROUND_STATE,
2507 CASE_GROUND_STATE,
2508 CASE_GROUND_STATE,
2509 CASE_GROUND_STATE,
2510 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
2511 CASE_GROUND_STATE,
2512 CASE_GROUND_STATE,
2513 CASE_GROUND_STATE,
2514 CASE_GROUND_STATE,
2515 /*      notsign         hyphen          registered      macron          */
2516 CASE_GROUND_STATE,
2517 CASE_GROUND_STATE,
2518 CASE_GROUND_STATE,
2519 CASE_GROUND_STATE,
2520 /*      degree          plusminus       twosuperior     threesuperior   */
2521 CASE_GROUND_STATE,
2522 CASE_GROUND_STATE,
2523 CASE_GROUND_STATE,
2524 CASE_GROUND_STATE,
2525 /*      acute           mu              paragraph       periodcentered  */
2526 CASE_GROUND_STATE,
2527 CASE_GROUND_STATE,
2528 CASE_GROUND_STATE,
2529 CASE_GROUND_STATE,
2530 /*      cedilla         onesuperior     masculine       guillemotright  */
2531 CASE_GROUND_STATE,
2532 CASE_GROUND_STATE,
2533 CASE_GROUND_STATE,
2534 CASE_GROUND_STATE,
2535 /*      onequarter      onehalf         threequarters   questiondown    */
2536 CASE_GROUND_STATE,
2537 CASE_GROUND_STATE,
2538 CASE_GROUND_STATE,
2539 CASE_GROUND_STATE,
2540 /*      Agrave          Aacute          Acircumflex     Atilde          */
2541 CASE_GROUND_STATE,
2542 CASE_GROUND_STATE,
2543 CASE_GROUND_STATE,
2544 CASE_GROUND_STATE,
2545 /*      Adiaeresis      Aring           AE              Ccedilla        */
2546 CASE_GROUND_STATE,
2547 CASE_GROUND_STATE,
2548 CASE_GROUND_STATE,
2549 CASE_GROUND_STATE,
2550 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
2551 CASE_GROUND_STATE,
2552 CASE_GROUND_STATE,
2553 CASE_GROUND_STATE,
2554 CASE_GROUND_STATE,
2555 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
2556 CASE_GROUND_STATE,
2557 CASE_GROUND_STATE,
2558 CASE_GROUND_STATE,
2559 CASE_GROUND_STATE,
2560 /*      Eth             Ntilde          Ograve          Oacute          */
2561 CASE_GROUND_STATE,
2562 CASE_GROUND_STATE,
2563 CASE_GROUND_STATE,
2564 CASE_GROUND_STATE,
2565 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
2566 CASE_GROUND_STATE,
2567 CASE_GROUND_STATE,
2568 CASE_GROUND_STATE,
2569 CASE_GROUND_STATE,
2570 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
2571 CASE_GROUND_STATE,
2572 CASE_GROUND_STATE,
2573 CASE_GROUND_STATE,
2574 CASE_GROUND_STATE,
2575 /*      Udiaeresis      Yacute          Thorn           ssharp          */
2576 CASE_GROUND_STATE,
2577 CASE_GROUND_STATE,
2578 CASE_GROUND_STATE,
2579 CASE_GROUND_STATE,
2580 /*      agrave          aacute          acircumflex     atilde          */
2581 CASE_GROUND_STATE,
2582 CASE_GROUND_STATE,
2583 CASE_GROUND_STATE,
2584 CASE_GROUND_STATE,
2585 /*      adiaeresis      aring           ae              ccedilla        */
2586 CASE_GROUND_STATE,
2587 CASE_GROUND_STATE,
2588 CASE_GROUND_STATE,
2589 CASE_GROUND_STATE,
2590 /*      egrave          eacute          ecircumflex     ediaeresis      */
2591 CASE_GROUND_STATE,
2592 CASE_GROUND_STATE,
2593 CASE_GROUND_STATE,
2594 CASE_GROUND_STATE,
2595 /*      igrave          iacute          icircumflex     idiaeresis      */
2596 CASE_GROUND_STATE,
2597 CASE_GROUND_STATE,
2598 CASE_GROUND_STATE,
2599 CASE_GROUND_STATE,
2600 /*      eth             ntilde          ograve          oacute          */
2601 CASE_GROUND_STATE,
2602 CASE_GROUND_STATE,
2603 CASE_GROUND_STATE,
2604 CASE_GROUND_STATE,
2605 /*      ocircumflex     otilde          odiaeresis      division        */
2606 CASE_GROUND_STATE,
2607 CASE_GROUND_STATE,
2608 CASE_GROUND_STATE,
2609 CASE_GROUND_STATE,
2610 /*      oslash          ugrave          uacute          ucircumflex     */
2611 CASE_GROUND_STATE,
2612 CASE_GROUND_STATE,
2613 CASE_GROUND_STATE,
2614 CASE_GROUND_STATE,
2615 /*      udiaeresis      yacute          thorn           ydiaeresis      */
2616 CASE_GROUND_STATE,
2617 CASE_GROUND_STATE,
2618 CASE_GROUND_STATE,
2619 CASE_GROUND_STATE,
2620 };
2621 
2622 // #pragma mark CASE_IGNORE_STATE table
2623 int gIgnoreTable[] =
2624 {
2625 /*	NUL		SOH		STX		ETX	*/
2626 CASE_IGNORE,
2627 CASE_IGNORE,
2628 CASE_IGNORE,
2629 CASE_IGNORE,
2630 /*	EOT		ENQ		ACK		BEL	*/
2631 CASE_IGNORE,
2632 CASE_IGNORE,
2633 CASE_IGNORE,
2634 CASE_IGNORE,
2635 /*	BS		HT		NL		VT	*/
2636 CASE_IGNORE,
2637 CASE_IGNORE,
2638 CASE_IGNORE,
2639 CASE_IGNORE,
2640 /*	NP		CR		SO		SI	*/
2641 CASE_IGNORE,
2642 CASE_IGNORE,
2643 CASE_IGNORE,
2644 CASE_IGNORE,
2645 /*	DLE		DC1		DC2		DC3	*/
2646 CASE_IGNORE,
2647 CASE_IGNORE,
2648 CASE_IGNORE,
2649 CASE_IGNORE,
2650 /*	DC4		NAK		SYN		ETB	*/
2651 CASE_IGNORE,
2652 CASE_IGNORE,
2653 CASE_IGNORE,
2654 CASE_IGNORE,
2655 /*	CAN		EM		SUB		ESC	*/
2656 CASE_GROUND_STATE,
2657 CASE_IGNORE,
2658 CASE_GROUND_STATE,
2659 CASE_IGNORE_ESC,
2660 /*	FS		GS		RS		US	*/
2661 CASE_IGNORE,
2662 CASE_IGNORE,
2663 CASE_IGNORE,
2664 CASE_IGNORE,
2665 /*	SP		!		"		#	*/
2666 CASE_IGNORE,
2667 CASE_IGNORE,
2668 CASE_IGNORE,
2669 CASE_IGNORE,
2670 /*	$		%		&		'	*/
2671 CASE_IGNORE,
2672 CASE_IGNORE,
2673 CASE_IGNORE,
2674 CASE_IGNORE,
2675 /*	(		)		*		+	*/
2676 CASE_IGNORE,
2677 CASE_IGNORE,
2678 CASE_IGNORE,
2679 CASE_IGNORE,
2680 /*	,		-		.		/	*/
2681 CASE_IGNORE,
2682 CASE_IGNORE,
2683 CASE_IGNORE,
2684 CASE_IGNORE,
2685 /*	0		1		2		3	*/
2686 CASE_IGNORE,
2687 CASE_IGNORE,
2688 CASE_IGNORE,
2689 CASE_IGNORE,
2690 /*	4		5		6		7	*/
2691 CASE_IGNORE,
2692 CASE_IGNORE,
2693 CASE_IGNORE,
2694 CASE_IGNORE,
2695 /*	8		9		:		;	*/
2696 CASE_IGNORE,
2697 CASE_IGNORE,
2698 CASE_IGNORE,
2699 CASE_IGNORE,
2700 /*	<		=		>		?	*/
2701 CASE_IGNORE,
2702 CASE_IGNORE,
2703 CASE_IGNORE,
2704 CASE_IGNORE,
2705 /*	@		A		B		C	*/
2706 CASE_IGNORE,
2707 CASE_IGNORE,
2708 CASE_IGNORE,
2709 CASE_IGNORE,
2710 /*	D		E		F		G	*/
2711 CASE_IGNORE,
2712 CASE_IGNORE,
2713 CASE_IGNORE,
2714 CASE_IGNORE,
2715 /*	H		I		J		K	*/
2716 CASE_IGNORE,
2717 CASE_IGNORE,
2718 CASE_IGNORE,
2719 CASE_IGNORE,
2720 /*	L		M		N		O	*/
2721 CASE_IGNORE,
2722 CASE_IGNORE,
2723 CASE_IGNORE,
2724 CASE_IGNORE,
2725 /*	P		Q		R		S	*/
2726 CASE_IGNORE,
2727 CASE_IGNORE,
2728 CASE_IGNORE,
2729 CASE_IGNORE,
2730 /*	T		U		V		W	*/
2731 CASE_IGNORE,
2732 CASE_IGNORE,
2733 CASE_IGNORE,
2734 CASE_IGNORE,
2735 /*	X		Y		Z		[	*/
2736 CASE_IGNORE,
2737 CASE_IGNORE,
2738 CASE_IGNORE,
2739 CASE_IGNORE,
2740 /*	\		]		^		_	*/
2741 CASE_IGNORE,
2742 CASE_IGNORE,
2743 CASE_IGNORE,
2744 CASE_IGNORE,
2745 /*	`		a		b		c	*/
2746 CASE_IGNORE,
2747 CASE_IGNORE,
2748 CASE_IGNORE,
2749 CASE_IGNORE,
2750 /*	d		e		f		g	*/
2751 CASE_IGNORE,
2752 CASE_IGNORE,
2753 CASE_IGNORE,
2754 CASE_IGNORE,
2755 /*	h		i		j		k	*/
2756 CASE_IGNORE,
2757 CASE_IGNORE,
2758 CASE_IGNORE,
2759 CASE_IGNORE,
2760 /*	l		m		n		o	*/
2761 CASE_IGNORE,
2762 CASE_IGNORE,
2763 CASE_IGNORE,
2764 CASE_IGNORE,
2765 /*	p		q		r		s	*/
2766 CASE_IGNORE,
2767 CASE_IGNORE,
2768 CASE_IGNORE,
2769 CASE_IGNORE,
2770 /*	t		u		v		w	*/
2771 CASE_IGNORE,
2772 CASE_IGNORE,
2773 CASE_IGNORE,
2774 CASE_IGNORE,
2775 /*	x		y		z		{	*/
2776 CASE_IGNORE,
2777 CASE_IGNORE,
2778 CASE_IGNORE,
2779 CASE_IGNORE,
2780 /*	|		}		~		DEL	*/
2781 CASE_IGNORE,
2782 CASE_IGNORE,
2783 CASE_IGNORE,
2784 CASE_IGNORE,
2785 /*      0x80            0x81            0x82            0x83    */
2786 CASE_IGNORE,
2787 CASE_IGNORE,
2788 CASE_IGNORE,
2789 CASE_IGNORE,
2790 /*      0x84            0x85            0x86            0x87    */
2791 CASE_IGNORE,
2792 CASE_IGNORE,
2793 CASE_IGNORE,
2794 CASE_IGNORE,
2795 /*      0x88            0x89            0x8a            0x8b    */
2796 CASE_IGNORE,
2797 CASE_IGNORE,
2798 CASE_IGNORE,
2799 CASE_IGNORE,
2800 /*      0x8c            0x8d            0x8e            0x8f    */
2801 CASE_IGNORE,
2802 CASE_IGNORE,
2803 CASE_IGNORE,
2804 CASE_IGNORE,
2805 /*      0x90            0x91            0x92            0x93    */
2806 CASE_IGNORE,
2807 CASE_IGNORE,
2808 CASE_IGNORE,
2809 CASE_IGNORE,
2810 /*      0x94            0x95            0x96            0x97    */
2811 CASE_IGNORE,
2812 CASE_IGNORE,
2813 CASE_IGNORE,
2814 CASE_IGNORE,
2815 /*      0x99            0x99            0x9a            0x9b    */
2816 CASE_IGNORE,
2817 CASE_IGNORE,
2818 CASE_IGNORE,
2819 CASE_IGNORE,
2820 /*      0x9c            0x9d            0x9e            0x9f    */
2821 CASE_IGNORE,
2822 CASE_IGNORE,
2823 CASE_IGNORE,
2824 CASE_IGNORE,
2825 /*      nobreakspace    exclamdown      cent            sterling        */
2826 CASE_GROUND_STATE,
2827 CASE_GROUND_STATE,
2828 CASE_GROUND_STATE,
2829 CASE_GROUND_STATE,
2830 /*      currency        yen             brokenbar       section         */
2831 CASE_GROUND_STATE,
2832 CASE_GROUND_STATE,
2833 CASE_GROUND_STATE,
2834 CASE_GROUND_STATE,
2835 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
2836 CASE_GROUND_STATE,
2837 CASE_GROUND_STATE,
2838 CASE_GROUND_STATE,
2839 CASE_GROUND_STATE,
2840 /*      notsign         hyphen          registered      macron          */
2841 CASE_GROUND_STATE,
2842 CASE_GROUND_STATE,
2843 CASE_GROUND_STATE,
2844 CASE_GROUND_STATE,
2845 /*      degree          plusminus       twosuperior     threesuperior   */
2846 CASE_GROUND_STATE,
2847 CASE_GROUND_STATE,
2848 CASE_GROUND_STATE,
2849 CASE_GROUND_STATE,
2850 /*      acute           mu              paragraph       periodcentered  */
2851 CASE_GROUND_STATE,
2852 CASE_GROUND_STATE,
2853 CASE_GROUND_STATE,
2854 CASE_GROUND_STATE,
2855 /*      cedilla         onesuperior     masculine       guillemotright  */
2856 CASE_GROUND_STATE,
2857 CASE_GROUND_STATE,
2858 CASE_GROUND_STATE,
2859 CASE_GROUND_STATE,
2860 /*      onequarter      onehalf         threequarters   questiondown    */
2861 CASE_GROUND_STATE,
2862 CASE_GROUND_STATE,
2863 CASE_GROUND_STATE,
2864 CASE_GROUND_STATE,
2865 /*      Agrave          Aacute          Acircumflex     Atilde          */
2866 CASE_GROUND_STATE,
2867 CASE_GROUND_STATE,
2868 CASE_GROUND_STATE,
2869 CASE_GROUND_STATE,
2870 /*      Adiaeresis      Aring           AE              Ccedilla        */
2871 CASE_GROUND_STATE,
2872 CASE_GROUND_STATE,
2873 CASE_GROUND_STATE,
2874 CASE_GROUND_STATE,
2875 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
2876 CASE_GROUND_STATE,
2877 CASE_GROUND_STATE,
2878 CASE_GROUND_STATE,
2879 CASE_GROUND_STATE,
2880 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
2881 CASE_GROUND_STATE,
2882 CASE_GROUND_STATE,
2883 CASE_GROUND_STATE,
2884 CASE_GROUND_STATE,
2885 /*      Eth             Ntilde          Ograve          Oacute          */
2886 CASE_GROUND_STATE,
2887 CASE_GROUND_STATE,
2888 CASE_GROUND_STATE,
2889 CASE_GROUND_STATE,
2890 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
2891 CASE_GROUND_STATE,
2892 CASE_GROUND_STATE,
2893 CASE_GROUND_STATE,
2894 CASE_GROUND_STATE,
2895 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
2896 CASE_GROUND_STATE,
2897 CASE_GROUND_STATE,
2898 CASE_GROUND_STATE,
2899 CASE_GROUND_STATE,
2900 /*      Udiaeresis      Yacute          Thorn           ssharp          */
2901 CASE_GROUND_STATE,
2902 CASE_GROUND_STATE,
2903 CASE_GROUND_STATE,
2904 CASE_GROUND_STATE,
2905 /*      agrave          aacute          acircumflex     atilde          */
2906 CASE_GROUND_STATE,
2907 CASE_GROUND_STATE,
2908 CASE_GROUND_STATE,
2909 CASE_GROUND_STATE,
2910 /*      adiaeresis      aring           ae              ccedilla        */
2911 CASE_GROUND_STATE,
2912 CASE_GROUND_STATE,
2913 CASE_GROUND_STATE,
2914 CASE_GROUND_STATE,
2915 /*      egrave          eacute          ecircumflex     ediaeresis      */
2916 CASE_GROUND_STATE,
2917 CASE_GROUND_STATE,
2918 CASE_GROUND_STATE,
2919 CASE_GROUND_STATE,
2920 /*      igrave          iacute          icircumflex     idiaeresis      */
2921 CASE_GROUND_STATE,
2922 CASE_GROUND_STATE,
2923 CASE_GROUND_STATE,
2924 CASE_GROUND_STATE,
2925 /*      eth             ntilde          ograve          oacute          */
2926 CASE_GROUND_STATE,
2927 CASE_GROUND_STATE,
2928 CASE_GROUND_STATE,
2929 CASE_GROUND_STATE,
2930 /*      ocircumflex     otilde          odiaeresis      division        */
2931 CASE_GROUND_STATE,
2932 CASE_GROUND_STATE,
2933 CASE_GROUND_STATE,
2934 CASE_GROUND_STATE,
2935 /*      oslash          ugrave          uacute          ucircumflex     */
2936 CASE_GROUND_STATE,
2937 CASE_GROUND_STATE,
2938 CASE_GROUND_STATE,
2939 CASE_GROUND_STATE,
2940 /*      udiaeresis      yacute          thorn           ydiaeresis      */
2941 CASE_GROUND_STATE,
2942 CASE_GROUND_STATE,
2943 CASE_GROUND_STATE,
2944 CASE_GROUND_STATE,
2945 };
2946 
2947 // #pragma mark ESC # - SCR table
2948 int gScrTable[] =
2949 {
2950 /*	NUL		SOH		STX		ETX	*/
2951 CASE_IGNORE,
2952 CASE_IGNORE,
2953 CASE_IGNORE,
2954 CASE_IGNORE,
2955 /*	EOT		ENQ		ACK		BEL	*/
2956 CASE_IGNORE,
2957 CASE_IGNORE,
2958 CASE_IGNORE,
2959 CASE_BELL,
2960 /*	BS		HT		NL		VT	*/
2961 CASE_BS,
2962 CASE_TAB,
2963 CASE_VMOT,
2964 CASE_VMOT,
2965 /*	NP		CR		SO		SI	*/
2966 CASE_VMOT,
2967 CASE_CR,
2968 CASE_LS1,
2969 CASE_LS0,
2970 /*	DLE		DC1		DC2		DC3	*/
2971 CASE_IGNORE,
2972 CASE_IGNORE,
2973 CASE_IGNORE,
2974 CASE_IGNORE,
2975 /*	DC4		NAK		SYN		ETB	*/
2976 CASE_IGNORE,
2977 CASE_IGNORE,
2978 CASE_IGNORE,
2979 CASE_IGNORE,
2980 /*	CAN		EM		SUB		ESC	*/
2981 CASE_IGNORE,
2982 CASE_IGNORE,
2983 CASE_IGNORE,
2984 CASE_ESC,
2985 /*	FS		GS		RS		US	*/
2986 CASE_IGNORE,
2987 CASE_IGNORE,
2988 CASE_IGNORE,
2989 CASE_IGNORE,
2990 /*	SP		!		"		#	*/
2991 CASE_ESC_IGNORE,
2992 CASE_ESC_IGNORE,
2993 CASE_ESC_IGNORE,
2994 CASE_ESC_IGNORE,
2995 /*	$		%		&		'	*/
2996 CASE_ESC_IGNORE,
2997 CASE_ESC_IGNORE,
2998 CASE_ESC_IGNORE,
2999 CASE_ESC_IGNORE,
3000 /*	(		)		*		+	*/
3001 CASE_ESC_IGNORE,
3002 CASE_ESC_IGNORE,
3003 CASE_ESC_IGNORE,
3004 CASE_ESC_IGNORE,
3005 /*	,		-		.		/	*/
3006 CASE_ESC_IGNORE,
3007 CASE_ESC_IGNORE,
3008 CASE_ESC_IGNORE,
3009 CASE_ESC_IGNORE,
3010 /*	0		1		2		3	*/
3011 CASE_GROUND_STATE,
3012 CASE_GROUND_STATE,
3013 CASE_GROUND_STATE,
3014 CASE_GROUND_STATE,
3015 /*	4		5		6		7	*/
3016 CASE_GROUND_STATE,
3017 CASE_GROUND_STATE,
3018 CASE_GROUND_STATE,
3019 CASE_GROUND_STATE,
3020 /*	8		9		:		;	*/
3021 CASE_DECALN,
3022 CASE_GROUND_STATE,
3023 CASE_GROUND_STATE,
3024 CASE_GROUND_STATE,
3025 /*	<		=		>		?	*/
3026 CASE_GROUND_STATE,
3027 CASE_GROUND_STATE,
3028 CASE_GROUND_STATE,
3029 CASE_GROUND_STATE,
3030 /*	@		A		B		C	*/
3031 CASE_GROUND_STATE,
3032 CASE_GROUND_STATE,
3033 CASE_GROUND_STATE,
3034 CASE_GROUND_STATE,
3035 /*	D		E		F		G	*/
3036 CASE_GROUND_STATE,
3037 CASE_GROUND_STATE,
3038 CASE_GROUND_STATE,
3039 CASE_GROUND_STATE,
3040 /*	H		I		J		K	*/
3041 CASE_GROUND_STATE,
3042 CASE_GROUND_STATE,
3043 CASE_GROUND_STATE,
3044 CASE_GROUND_STATE,
3045 /*	L		M		N		O	*/
3046 CASE_GROUND_STATE,
3047 CASE_GROUND_STATE,
3048 CASE_GROUND_STATE,
3049 CASE_GROUND_STATE,
3050 /*	P		Q		R		S	*/
3051 CASE_GROUND_STATE,
3052 CASE_GROUND_STATE,
3053 CASE_GROUND_STATE,
3054 CASE_GROUND_STATE,
3055 /*	T		U		V		W	*/
3056 CASE_GROUND_STATE,
3057 CASE_GROUND_STATE,
3058 CASE_GROUND_STATE,
3059 CASE_GROUND_STATE,
3060 /*	X		Y		Z		[	*/
3061 CASE_GROUND_STATE,
3062 CASE_GROUND_STATE,
3063 CASE_GROUND_STATE,
3064 CASE_GROUND_STATE,
3065 /*	\		]		^		_	*/
3066 CASE_GROUND_STATE,
3067 CASE_GROUND_STATE,
3068 CASE_GROUND_STATE,
3069 CASE_GROUND_STATE,
3070 /*	`		a		b		c	*/
3071 CASE_GROUND_STATE,
3072 CASE_GROUND_STATE,
3073 CASE_GROUND_STATE,
3074 CASE_GROUND_STATE,
3075 /*	d		e		f		g	*/
3076 CASE_GROUND_STATE,
3077 CASE_GROUND_STATE,
3078 CASE_GROUND_STATE,
3079 CASE_GROUND_STATE,
3080 /*	h		i		j		k	*/
3081 CASE_GROUND_STATE,
3082 CASE_GROUND_STATE,
3083 CASE_GROUND_STATE,
3084 CASE_GROUND_STATE,
3085 /*	l		m		n		o	*/
3086 CASE_GROUND_STATE,
3087 CASE_GROUND_STATE,
3088 CASE_GROUND_STATE,
3089 CASE_GROUND_STATE,
3090 /*	p		q		r		s	*/
3091 CASE_GROUND_STATE,
3092 CASE_GROUND_STATE,
3093 CASE_GROUND_STATE,
3094 CASE_GROUND_STATE,
3095 /*	t		u		v		w	*/
3096 CASE_GROUND_STATE,
3097 CASE_GROUND_STATE,
3098 CASE_GROUND_STATE,
3099 CASE_GROUND_STATE,
3100 /*	x		y		z		{	*/
3101 CASE_GROUND_STATE,
3102 CASE_GROUND_STATE,
3103 CASE_GROUND_STATE,
3104 CASE_GROUND_STATE,
3105 /*	|		}		~		DEL	*/
3106 CASE_GROUND_STATE,
3107 CASE_GROUND_STATE,
3108 CASE_GROUND_STATE,
3109 CASE_GROUND_STATE,
3110 /*      0x80            0x81            0x82            0x83    */
3111 CASE_IGNORE,
3112 CASE_IGNORE,
3113 CASE_IGNORE,
3114 CASE_IGNORE,
3115 /*      0x84            0x85            0x86            0x87    */
3116 CASE_IGNORE,
3117 CASE_IGNORE,
3118 CASE_IGNORE,
3119 CASE_IGNORE,
3120 /*      0x88            0x89            0x8a            0x8b    */
3121 CASE_IGNORE,
3122 CASE_IGNORE,
3123 CASE_IGNORE,
3124 CASE_IGNORE,
3125 /*      0x8c            0x8d            0x8e            0x8f    */
3126 CASE_IGNORE,
3127 CASE_IGNORE,
3128 CASE_IGNORE,
3129 CASE_IGNORE,
3130 /*      0x90            0x91            0x92            0x93    */
3131 CASE_IGNORE,
3132 CASE_IGNORE,
3133 CASE_IGNORE,
3134 CASE_IGNORE,
3135 /*      0x94            0x95            0x96            0x97    */
3136 CASE_IGNORE,
3137 CASE_IGNORE,
3138 CASE_IGNORE,
3139 CASE_IGNORE,
3140 /*      0x99            0x99            0x9a            0x9b    */
3141 CASE_IGNORE,
3142 CASE_IGNORE,
3143 CASE_IGNORE,
3144 CASE_IGNORE,
3145 /*      0x9c            0x9d            0x9e            0x9f    */
3146 CASE_IGNORE,
3147 CASE_IGNORE,
3148 CASE_IGNORE,
3149 CASE_IGNORE,
3150 /*      nobreakspace    exclamdown      cent            sterling        */
3151 CASE_GROUND_STATE,
3152 CASE_GROUND_STATE,
3153 CASE_GROUND_STATE,
3154 CASE_GROUND_STATE,
3155 /*      currency        yen             brokenbar       section         */
3156 CASE_GROUND_STATE,
3157 CASE_GROUND_STATE,
3158 CASE_GROUND_STATE,
3159 CASE_GROUND_STATE,
3160 /*      diaeresis       copyright       ordfeminine     guillemotleft   */
3161 CASE_GROUND_STATE,
3162 CASE_GROUND_STATE,
3163 CASE_GROUND_STATE,
3164 CASE_GROUND_STATE,
3165 /*      notsign         hyphen          registered      macron          */
3166 CASE_GROUND_STATE,
3167 CASE_GROUND_STATE,
3168 CASE_GROUND_STATE,
3169 CASE_GROUND_STATE,
3170 /*      degree          plusminus       twosuperior     threesuperior   */
3171 CASE_GROUND_STATE,
3172 CASE_GROUND_STATE,
3173 CASE_GROUND_STATE,
3174 CASE_GROUND_STATE,
3175 /*      acute           mu              paragraph       periodcentered  */
3176 CASE_GROUND_STATE,
3177 CASE_GROUND_STATE,
3178 CASE_GROUND_STATE,
3179 CASE_GROUND_STATE,
3180 /*      cedilla         onesuperior     masculine       guillemotright  */
3181 CASE_GROUND_STATE,
3182 CASE_GROUND_STATE,
3183 CASE_GROUND_STATE,
3184 CASE_GROUND_STATE,
3185 /*      onequarter      onehalf         threequarters   questiondown    */
3186 CASE_GROUND_STATE,
3187 CASE_GROUND_STATE,
3188 CASE_GROUND_STATE,
3189 CASE_GROUND_STATE,
3190 /*      Agrave          Aacute          Acircumflex     Atilde          */
3191 CASE_GROUND_STATE,
3192 CASE_GROUND_STATE,
3193 CASE_GROUND_STATE,
3194 CASE_GROUND_STATE,
3195 /*      Adiaeresis      Aring           AE              Ccedilla        */
3196 CASE_GROUND_STATE,
3197 CASE_GROUND_STATE,
3198 CASE_GROUND_STATE,
3199 CASE_GROUND_STATE,
3200 /*      Egrave          Eacute          Ecircumflex     Ediaeresis      */
3201 CASE_GROUND_STATE,
3202 CASE_GROUND_STATE,
3203 CASE_GROUND_STATE,
3204 CASE_GROUND_STATE,
3205 /*      Igrave          Iacute          Icircumflex     Idiaeresis      */
3206 CASE_GROUND_STATE,
3207 CASE_GROUND_STATE,
3208 CASE_GROUND_STATE,
3209 CASE_GROUND_STATE,
3210 /*      Eth             Ntilde          Ograve          Oacute          */
3211 CASE_GROUND_STATE,
3212 CASE_GROUND_STATE,
3213 CASE_GROUND_STATE,
3214 CASE_GROUND_STATE,
3215 /*      Ocircumflex     Otilde          Odiaeresis      multiply        */
3216 CASE_GROUND_STATE,
3217 CASE_GROUND_STATE,
3218 CASE_GROUND_STATE,
3219 CASE_GROUND_STATE,
3220 /*      Ooblique        Ugrave          Uacute          Ucircumflex     */
3221 CASE_GROUND_STATE,
3222 CASE_GROUND_STATE,
3223 CASE_GROUND_STATE,
3224 CASE_GROUND_STATE,
3225 /*      Udiaeresis      Yacute          Thorn           ssharp          */
3226 CASE_GROUND_STATE,
3227 CASE_GROUND_STATE,
3228 CASE_GROUND_STATE,
3229 CASE_GROUND_STATE,
3230 /*      agrave          aacute          acircumflex     atilde          */
3231 CASE_GROUND_STATE,
3232 CASE_GROUND_STATE,
3233 CASE_GROUND_STATE,
3234 CASE_GROUND_STATE,
3235 /*      adiaeresis      aring           ae              ccedilla        */
3236 CASE_GROUND_STATE,
3237 CASE_GROUND_STATE,
3238 CASE_GROUND_STATE,
3239 CASE_GROUND_STATE,
3240 /*      egrave          eacute          ecircumflex     ediaeresis      */
3241 CASE_GROUND_STATE,
3242 CASE_GROUND_STATE,
3243 CASE_GROUND_STATE,
3244 CASE_GROUND_STATE,
3245 /*      igrave          iacute          icircumflex     idiaeresis      */
3246 CASE_GROUND_STATE,
3247 CASE_GROUND_STATE,
3248 CASE_GROUND_STATE,
3249 CASE_GROUND_STATE,
3250 /*      eth             ntilde          ograve          oacute          */
3251 CASE_GROUND_STATE,
3252 CASE_GROUND_STATE,
3253 CASE_GROUND_STATE,
3254 CASE_GROUND_STATE,
3255 /*      ocircumflex     otilde          odiaeresis      division        */
3256 CASE_GROUND_STATE,
3257 CASE_GROUND_STATE,
3258 CASE_GROUND_STATE,
3259 CASE_GROUND_STATE,
3260 /*      oslash          ugrave          uacute          ucircumflex     */
3261 CASE_GROUND_STATE,
3262 CASE_GROUND_STATE,
3263 CASE_GROUND_STATE,
3264 CASE_GROUND_STATE,
3265 /*      udiaeresis      yacute          thorn           ydiaeresis      */
3266 CASE_GROUND_STATE,
3267 CASE_GROUND_STATE,
3268 CASE_GROUND_STATE,
3269 CASE_GROUND_STATE,
3270 };
3271 
3272 // #pragma mark Shift-JIS ground table
3273 int gSJISGroundTable[] =
3274 {
3275 /*	NUL		SOH		STX		ETX	*/
3276 CASE_IGNORE,
3277 CASE_IGNORE,
3278 CASE_IGNORE,
3279 CASE_IGNORE,
3280 /*	EOT		ENQ		ACK		BEL	*/
3281 CASE_IGNORE,
3282 CASE_IGNORE,
3283 CASE_IGNORE,
3284 CASE_BELL,
3285 /*	BS		HT		NL		VT	*/
3286 CASE_BS,
3287 CASE_TAB,
3288 CASE_LF,
3289 CASE_LF, /*CASE_UP,*/
3290 /*	NP		CR		SO		SI	*/
3291 CASE_LF, /*CASE_IGNORE,*/
3292 CASE_CR,
3293 CASE_LS1,
3294 CASE_LS0,
3295 /*	DLE		DC1		DC2		DC3	*/
3296 CASE_IGNORE,
3297 CASE_IGNORE,
3298 CASE_IGNORE,
3299 CASE_IGNORE,
3300 /*	DC4		NAK		SYN		ETB	*/
3301 CASE_IGNORE,
3302 CASE_IGNORE,
3303 CASE_IGNORE,
3304 CASE_IGNORE,
3305 /*	CAN		EM		SUB		ESC	*/
3306 CASE_IGNORE,
3307 CASE_IGNORE,
3308 CASE_IGNORE,
3309 CASE_ESC,
3310 /*	FS		GS		RS		US	*/
3311 CASE_IGNORE,
3312 CASE_IGNORE,
3313 CASE_IGNORE,
3314 CASE_IGNORE,
3315 /*	SP		!		"		#	*/
3316 CASE_PRINT,
3317 CASE_PRINT,
3318 CASE_PRINT,
3319 CASE_PRINT,
3320 /*	$		%		&		'	*/
3321 CASE_PRINT,
3322 CASE_PRINT,
3323 CASE_PRINT,
3324 CASE_PRINT,
3325 /*	(		)		*		+	*/
3326 CASE_PRINT,
3327 CASE_PRINT,
3328 CASE_PRINT,
3329 CASE_PRINT,
3330 /*	,		-		.		/	*/
3331 CASE_PRINT,
3332 CASE_PRINT,
3333 CASE_PRINT,
3334 CASE_PRINT,
3335 /*	0		1		2		3	*/
3336 CASE_PRINT,
3337 CASE_PRINT,
3338 CASE_PRINT,
3339 CASE_PRINT,
3340 /*	4		5		6		7	*/
3341 CASE_PRINT,
3342 CASE_PRINT,
3343 CASE_PRINT,
3344 CASE_PRINT,
3345 /*	8		9		:		;	*/
3346 CASE_PRINT,
3347 CASE_PRINT,
3348 CASE_PRINT,
3349 CASE_PRINT,
3350 /*	<		=		>		?	*/
3351 CASE_PRINT,
3352 CASE_PRINT,
3353 CASE_PRINT,
3354 CASE_PRINT,
3355 /*	@		A		B		C	*/
3356 CASE_PRINT,
3357 CASE_PRINT,
3358 CASE_PRINT,
3359 CASE_PRINT,
3360 /*	D		E		F		G	*/
3361 CASE_PRINT,
3362 CASE_PRINT,
3363 CASE_PRINT,
3364 CASE_PRINT,
3365 /*	H		I		J		K	*/
3366 CASE_PRINT,
3367 CASE_PRINT,
3368 CASE_PRINT,
3369 CASE_PRINT,
3370 /*	L		M		N		O	*/
3371 CASE_PRINT,
3372 CASE_PRINT,
3373 CASE_PRINT,
3374 CASE_PRINT,
3375 /*	P		Q		R		S	*/
3376 CASE_PRINT,
3377 CASE_PRINT,
3378 CASE_PRINT,
3379 CASE_PRINT,
3380 /*	T		U		V		W	*/
3381 CASE_PRINT,
3382 CASE_PRINT,
3383 CASE_PRINT,
3384 CASE_PRINT,
3385 /*	X		Y		Z		[	*/
3386 CASE_PRINT,
3387 CASE_PRINT,
3388 CASE_PRINT,
3389 CASE_PRINT,
3390 /*	\		]		^		_	*/
3391 CASE_PRINT,
3392 CASE_PRINT,
3393 CASE_PRINT,
3394 CASE_PRINT,
3395 /*	`		a		b		c	*/
3396 CASE_PRINT,
3397 CASE_PRINT,
3398 CASE_PRINT,
3399 CASE_PRINT,
3400 /*	d		e		f		g	*/
3401 CASE_PRINT,
3402 CASE_PRINT,
3403 CASE_PRINT,
3404 CASE_PRINT,
3405 /*	h		i		j		k	*/
3406 CASE_PRINT,
3407 CASE_PRINT,
3408 CASE_PRINT,
3409 CASE_PRINT,
3410 /*	l		m		n		o	*/
3411 CASE_PRINT,
3412 CASE_PRINT,
3413 CASE_PRINT,
3414 CASE_PRINT,
3415 /*	p		q		r		s	*/
3416 CASE_PRINT,
3417 CASE_PRINT,
3418 CASE_PRINT,
3419 CASE_PRINT,
3420 /*	t		u		v		w	*/
3421 CASE_PRINT,
3422 CASE_PRINT,
3423 CASE_PRINT,
3424 CASE_PRINT,
3425 /*	x		y		z		{	*/
3426 CASE_PRINT,
3427 CASE_PRINT,
3428 CASE_PRINT,
3429 CASE_PRINT,
3430 /*	|		}		~		DEL	*/
3431 CASE_PRINT,
3432 CASE_PRINT,
3433 CASE_PRINT,
3434 CASE_PRINT,
3435 /*      0x80            0x81            0x82            0x83    */
3436 CASE_SJIS_INSTRING,
3437 CASE_SJIS_INSTRING,
3438 CASE_SJIS_INSTRING,
3439 CASE_SJIS_INSTRING,
3440 /*      0x84            0x85            0x86            0x87    */
3441 CASE_SJIS_INSTRING,
3442 CASE_SJIS_INSTRING,
3443 CASE_SJIS_INSTRING,
3444 CASE_SJIS_INSTRING,
3445 /*      0x88            0x89            0x8a            0x8b    */
3446 CASE_SJIS_INSTRING,
3447 CASE_SJIS_INSTRING,
3448 CASE_SJIS_INSTRING,
3449 CASE_SJIS_INSTRING,
3450 /*      0x8c            0x8d            0x8e            0x8f    */
3451 CASE_SJIS_INSTRING,
3452 CASE_SJIS_INSTRING,
3453 CASE_SJIS_INSTRING,
3454 CASE_SJIS_INSTRING,
3455 /*      0x90            0x91            0x92            0x93    */
3456 CASE_SJIS_INSTRING,
3457 CASE_SJIS_INSTRING,
3458 CASE_SJIS_INSTRING,
3459 CASE_SJIS_INSTRING,
3460 /*      0x94            0x95            0x96            0x97    */
3461 CASE_SJIS_INSTRING,
3462 CASE_SJIS_INSTRING,
3463 CASE_SJIS_INSTRING,
3464 CASE_SJIS_INSTRING,
3465 /*      0x99            0x99            0x9a            0x9b    */
3466 CASE_SJIS_INSTRING,
3467 CASE_SJIS_INSTRING,
3468 CASE_SJIS_INSTRING,
3469 CASE_SJIS_INSTRING,
3470 /*      0x9c            0x9d            0x9e            0x9f    */
3471 CASE_SJIS_INSTRING,
3472 CASE_SJIS_INSTRING,
3473 CASE_SJIS_INSTRING,
3474 CASE_SJIS_INSTRING,
3475 /*      0xa0		0xa1		0xa2		0xa3	*/
3476 CASE_SJIS_KANA,
3477 CASE_SJIS_KANA,
3478 CASE_SJIS_KANA,
3479 CASE_SJIS_KANA,
3480 /*      0xa4		0xa5		0xa6		0xa7	*/
3481 CASE_SJIS_KANA,
3482 CASE_SJIS_KANA,
3483 CASE_SJIS_KANA,
3484 CASE_SJIS_KANA,
3485 /*      0xa8		0xa9		0xaa		0xab	*/
3486 CASE_SJIS_KANA,
3487 CASE_SJIS_KANA,
3488 CASE_SJIS_KANA,
3489 CASE_SJIS_KANA,
3490 /*      0xac		0xad		0xae		0xaf	*/
3491 CASE_SJIS_KANA,
3492 CASE_SJIS_KANA,
3493 CASE_SJIS_KANA,
3494 CASE_SJIS_KANA,
3495 /*      0xb0		0xb1		0xb2		0xb3	*/
3496 CASE_SJIS_KANA,
3497 CASE_SJIS_KANA,
3498 CASE_SJIS_KANA,
3499 CASE_SJIS_KANA,
3500 /*      0xb4		0xb5		0xb6		0xb7	*/
3501 CASE_SJIS_KANA,
3502 CASE_SJIS_KANA,
3503 CASE_SJIS_KANA,
3504 CASE_SJIS_KANA,
3505 /*      0xb8		0xb9		0xba		0xbb	*/
3506 CASE_SJIS_KANA,
3507 CASE_SJIS_KANA,
3508 CASE_SJIS_KANA,
3509 CASE_SJIS_KANA,
3510 /*      0xbc		0xbd		0xbe		0xbf	*/
3511 CASE_SJIS_KANA,
3512 CASE_SJIS_KANA,
3513 CASE_SJIS_KANA,
3514 CASE_SJIS_KANA,
3515 /*      0xc0		0xc1		0xc2		0xc3	*/
3516 CASE_SJIS_KANA,
3517 CASE_SJIS_KANA,
3518 CASE_SJIS_KANA,
3519 CASE_SJIS_KANA,
3520 /*      0xc4		0xc5		0xc6		0xc7	*/
3521 CASE_SJIS_KANA,
3522 CASE_SJIS_KANA,
3523 CASE_SJIS_KANA,
3524 CASE_SJIS_KANA,
3525 /*      0xc8		0xc9		0xca		0xcb	*/
3526 CASE_SJIS_KANA,
3527 CASE_SJIS_KANA,
3528 CASE_SJIS_KANA,
3529 CASE_SJIS_KANA,
3530 /*      0xcc		0xcd		0xce		0xcf	*/
3531 CASE_SJIS_KANA,
3532 CASE_SJIS_KANA,
3533 CASE_SJIS_KANA,
3534 CASE_SJIS_KANA,
3535 /*      0xd0		0xd1		0xd2		0xd3	*/
3536 CASE_SJIS_KANA,
3537 CASE_SJIS_KANA,
3538 CASE_SJIS_KANA,
3539 CASE_SJIS_KANA,
3540 /*      0xd4		0xd5		0xd6		0xd7	*/
3541 CASE_SJIS_KANA,
3542 CASE_SJIS_KANA,
3543 CASE_SJIS_KANA,
3544 CASE_SJIS_KANA,
3545 /*      0xd8		0xd9		0xda		0xdb	*/
3546 CASE_SJIS_KANA,
3547 CASE_SJIS_KANA,
3548 CASE_SJIS_KANA,
3549 CASE_SJIS_KANA,
3550 /*      0xdc		0xdd		0xde		0xdf	*/
3551 CASE_SJIS_KANA,
3552 CASE_SJIS_KANA,
3553 CASE_SJIS_KANA,
3554 CASE_SJIS_KANA,
3555 /*      0xe0		0xe1		0xe2		0xe3	*/
3556 CASE_SJIS_INSTRING,
3557 CASE_SJIS_INSTRING,
3558 CASE_SJIS_INSTRING,
3559 CASE_SJIS_INSTRING,
3560 /*      0xe4		0xe5		0xe6		0xe7	*/
3561 CASE_SJIS_INSTRING,
3562 CASE_SJIS_INSTRING,
3563 CASE_SJIS_INSTRING,
3564 CASE_SJIS_INSTRING,
3565 /*      0xe8		0xe9		0xea		0xeb	*/
3566 CASE_SJIS_INSTRING,
3567 CASE_SJIS_INSTRING,
3568 CASE_SJIS_INSTRING,
3569 CASE_SJIS_INSTRING,
3570 /*      0xec		0xed		0xee		0xef	*/
3571 CASE_SJIS_INSTRING,
3572 CASE_SJIS_INSTRING,
3573 CASE_SJIS_INSTRING,
3574 CASE_SJIS_INSTRING,
3575 /*      0xf0		0xf1		0xf2		0xf3	*/
3576 CASE_SJIS_INSTRING,
3577 CASE_SJIS_INSTRING,
3578 CASE_SJIS_INSTRING,
3579 CASE_SJIS_INSTRING,
3580 /*      0xf4		0xf5		0xf6		0xf7	*/
3581 CASE_SJIS_INSTRING,
3582 CASE_SJIS_INSTRING,
3583 CASE_SJIS_INSTRING,
3584 CASE_SJIS_INSTRING,
3585 /*      0xf8		0xf9		0xfa		0xfb	*/
3586 CASE_SJIS_INSTRING,
3587 CASE_SJIS_INSTRING,
3588 CASE_SJIS_INSTRING,
3589 CASE_SJIS_INSTRING,
3590 /*      0xfc		0xfd		0xfe		0xff	*/
3591 CASE_SJIS_INSTRING,
3592 CASE_SJIS_INSTRING,
3593 CASE_SJIS_INSTRING,
3594 CASE_SJIS_INSTRING,
3595 };
3596 
3597 /*
3598  * 94/96 alternative character sets for G0-G3
3599  *
3600  * - characters to replace are UTF-8 literals
3601  * - NULL mean falling through to corresponding ASCII chars
3602  *
3603  */
3604 
3605 /* DEC Special Graphic Character Set - mix of xterm
3606    definitions and ncurses extended characters (ACS_)  */
3607 const char* gLineDrawGraphSet[96] =
3608 {
3609 //	SP		!		"		#
3610 NULL,
3611 NULL,
3612 NULL,
3613 NULL,
3614 
3615 //	$		%		&		'
3616 NULL,
3617 NULL,
3618 NULL,
3619 NULL,
3620 
3621 //	(		)		*		+
3622 NULL,
3623 NULL,
3624 NULL,
3625 "\xE2\x86\x92", // ACS_RARROW
3626 
3627 //	,		-		.		/
3628 "\xE2\x86\x90", // ACS_LARROW
3629 "\xE2\x86\x91", // ACS_UARROW
3630 "\xE2\x86\x93", // ACS_DARROW
3631 NULL,
3632 
3633 //	0		1		2		3
3634 "\xE2\x96\xAE", // ACS_BLOCK
3635 NULL,
3636 NULL,
3637 NULL,
3638 
3639 //	4		5		6		7
3640 NULL,
3641 NULL,
3642 NULL,
3643 NULL,
3644 
3645 //	8		9		:		;
3646 NULL,
3647 NULL,
3648 NULL,
3649 NULL,
3650 
3651 //	<		=		>		?
3652 NULL,
3653 NULL,
3654 NULL,
3655 NULL,
3656 
3657 //	@		A		B		C
3658 NULL,
3659 NULL,
3660 NULL,
3661 NULL,
3662 
3663 //	D		E		F		G
3664 NULL,
3665 NULL,
3666 NULL,
3667 NULL,
3668 
3669 //	H		I		J		K
3670 NULL,
3671 NULL,
3672 NULL,
3673 NULL,
3674 
3675 //	L		M		N		O
3676 NULL,
3677 NULL,
3678 NULL,
3679 NULL,
3680 
3681 //	P		Q		R		S
3682 NULL,
3683 NULL,
3684 NULL,
3685 NULL,
3686 
3687 //	T		U		V		W
3688 NULL,
3689 NULL,
3690 NULL,
3691 NULL,
3692 
3693 //	X		Y		Z		[
3694 NULL,
3695 NULL,
3696 NULL,
3697 NULL,
3698 //	\		]		^		_
3699 NULL,
3700 NULL,
3701 NULL,
3702 "\xE2\x96\xAE", // xterm: black vertical rectangle
3703 
3704 //	`		a		b		c
3705 "\xE2\x97\x86", // ACS_DIAMOND
3706 "\xE2\x96\x92", // ACS_CKBOARD
3707 "\xE2\x90\x89", // xterm:symbol for horizontal tabulation
3708 "\xE2\x90\x8C", // xterm:symbol for form feed
3709 
3710 //	d		e		f		g
3711 "\xE2\x90\x8D", // xterm:symbol for carriage return
3712 "\xE2\x90\x8A", // xterm:symbol for line feed
3713 "\xC2\xB0", // ACS_DEGREE
3714 "\xC2\xB1", // ACS_PLMINUS
3715 
3716 //	h		i		j		k
3717 "\xE2\x90\xA4", // xterm:symbol for newline (ACS_BOARD)
3718 "\xE2\x98\x83", // ACS_LANTERN (xterm:symbol for vert.tab: \xE2\x90\x8B)
3719 "\xE2\x94\x98", // ACS_LRCORNER
3720 "\xE2\x94\x90", // ACS_URCORNER
3721 
3722 //	l		m		n		o
3723 "\xE2\x94\x8C", // ACS_ULCORNER
3724 "\xE2\x94\x94", // ACS_LLCORNER
3725 "\xE2\x94\xBC", // ACS_PLUS
3726 "\xE2\x8E\xBA", // ACS_S1
3727 
3728 //	p		q		r		s
3729 "\xE2\x8E\xBB", // ACS_S3
3730 "\xE2\x94\x80", // ACS_HLINE
3731 "\xE2\x8E\xBC", // ACS_S7
3732 "\xE2\x8E\xBD", // ACS_S9
3733 
3734 //	t		u		v		w
3735 "\xE2\x94\x9C", // ACS_LTEE
3736 "\xE2\x94\xA4", // ACS_RTEE
3737 "\xE2\x94\xB4", // ACS_BTEE
3738 "\xE2\x94\xAC", // ACS_TTEE
3739 
3740 //	x		y		z		{
3741 "\xE2\x94\x82", // ACS_VLINE
3742 "\xE2\x89\xA4", // ACS_LEQUAL
3743 "\xE2\x89\xA5", // ACS_GEQUAL
3744 "\xCF\x80", // ACS_PI
3745 
3746 //	|		}		~		DEL
3747 "\xE2\x89\xA0", // ACS_NEQUAL
3748 "\xC2\xA3", // ACS_STERLING
3749 "\xC2\xB7", // ACS_BULLET
3750 NULL
3751 };
3752