|
1 /* |
|
2 * Copyright (c) 1250 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of the License "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #include <e32std.h> |
|
22 #include <convdata.h> |
|
23 #include <convgeneratedcpp.h> |
|
24 |
|
25 #define ARRAY_LENGTH(aArray) (sizeof(aArray)/sizeof((aArray)[0])) |
|
26 |
|
27 #pragma warning (disable: 4049) // compiler limit : terminating line number emission |
|
28 |
|
29 _LIT8(KLit8ReplacementForUnconvertibleUnicodeCharacters, "\x1a"); |
|
30 |
|
31 GLDEF_C const TDesC8& ReplacementForUnconvertibleUnicodeCharacters_internal() |
|
32 { |
|
33 return KLit8ReplacementForUnconvertibleUnicodeCharacters; |
|
34 } |
|
35 |
|
36 LOCAL_D const TUint16 keyedTables16OfIndexedTables16_indexedEntries_foreignToUnicode_1[]= |
|
37 { |
|
38 0x20ac, |
|
39 0x0081, |
|
40 0x201a, |
|
41 0x0083, |
|
42 0x201e, |
|
43 0x2026, |
|
44 0x2020, |
|
45 0x2021, |
|
46 0x0088, |
|
47 0x2030, |
|
48 0x0160, |
|
49 0x2039, |
|
50 0x015a, |
|
51 0x0164, |
|
52 0x017d, |
|
53 0x0179, |
|
54 0x0090, |
|
55 0x2018, |
|
56 0x2019, |
|
57 0x201c, |
|
58 0x201d, |
|
59 0x2022, |
|
60 0x2013, |
|
61 0x2014, |
|
62 0x0098, |
|
63 0x2122, |
|
64 0x0161, |
|
65 0x203a, |
|
66 0x015b, |
|
67 0x0165, |
|
68 0x017e, |
|
69 0x017a, |
|
70 0x00a0, |
|
71 0x02c7, |
|
72 0x02d8, |
|
73 0x0141, |
|
74 0x00a4, |
|
75 0x0104, |
|
76 0x00a6, |
|
77 0x00a7, |
|
78 0x00a8, |
|
79 0x00a9, |
|
80 0x015e, |
|
81 0x00ab, |
|
82 0x00ac, |
|
83 0x00ad, |
|
84 0x00ae, |
|
85 0x017b, |
|
86 0x00b0, |
|
87 0x00b1, |
|
88 0x02db, |
|
89 0x0142, |
|
90 0x00b4, |
|
91 0x00b5, |
|
92 0x00b6, |
|
93 0x00b7, |
|
94 0x00b8, |
|
95 0x0105, |
|
96 0x015f, |
|
97 0x00bb, |
|
98 0x013d, |
|
99 0x02dd, |
|
100 0x013e, |
|
101 0x017c, |
|
102 0x0154, |
|
103 0x00c1, |
|
104 0x00c2, |
|
105 0x0102, |
|
106 0x00c4, |
|
107 0x0139, |
|
108 0x0106, |
|
109 0x00c7, |
|
110 0x010c, |
|
111 0x00c9, |
|
112 0x0118, |
|
113 0x00cb, |
|
114 0x011a, |
|
115 0x00cd, |
|
116 0x00ce, |
|
117 0x010e, |
|
118 0x0110, |
|
119 0x0143, |
|
120 0x0147, |
|
121 0x00d3, |
|
122 0x00d4, |
|
123 0x0150, |
|
124 0x00d6, |
|
125 0x00d7, |
|
126 0x0158, |
|
127 0x016e, |
|
128 0x00da, |
|
129 0x0170, |
|
130 0x00dc, |
|
131 0x00dd, |
|
132 0x0162, |
|
133 0x00df, |
|
134 0x0155, |
|
135 0x00e1, |
|
136 0x00e2, |
|
137 0x0103, |
|
138 0x00e4, |
|
139 0x013a, |
|
140 0x0107, |
|
141 0x00e7, |
|
142 0x010d, |
|
143 0x00e9, |
|
144 0x0119, |
|
145 0x00eb, |
|
146 0x011b, |
|
147 0x00ed, |
|
148 0x00ee, |
|
149 0x010f, |
|
150 0x0111, |
|
151 0x0144, |
|
152 0x0148, |
|
153 0x00f3, |
|
154 0x00f4, |
|
155 0x0151, |
|
156 0x00f6, |
|
157 0x00f7, |
|
158 0x0159, |
|
159 0x016f, |
|
160 0x00fa, |
|
161 0x0171, |
|
162 0x00fc, |
|
163 0x00fd, |
|
164 0x0163, |
|
165 0x02d9 |
|
166 }; |
|
167 |
|
168 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable16OfIndexedTables16::SKeyedEntry keyedTables16OfIndexedTables16_keyedEntries_foreignToUnicode_1[]= |
|
169 { |
|
170 { |
|
171 0x80, |
|
172 0xff, |
|
173 keyedTables16OfIndexedTables16_indexedEntries_foreignToUnicode_1 |
|
174 } |
|
175 }; |
|
176 |
|
177 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry indexedTable16_unicodeToForeign_1[]= |
|
178 { |
|
179 { |
|
180 0xc3 |
|
181 }, |
|
182 { |
|
183 0xe3 |
|
184 }, |
|
185 { |
|
186 0xa5 |
|
187 }, |
|
188 { |
|
189 0xb9 |
|
190 }, |
|
191 { |
|
192 0xc6 |
|
193 }, |
|
194 { |
|
195 0xe6 |
|
196 } |
|
197 }; |
|
198 |
|
199 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry indexedTable16_unicodeToForeign_2[]= |
|
200 { |
|
201 { |
|
202 0xc8 |
|
203 }, |
|
204 { |
|
205 0xe8 |
|
206 }, |
|
207 { |
|
208 0xcf |
|
209 }, |
|
210 { |
|
211 0xef |
|
212 }, |
|
213 { |
|
214 0xd0 |
|
215 }, |
|
216 { |
|
217 0xf0 |
|
218 } |
|
219 }; |
|
220 |
|
221 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry indexedTable16_unicodeToForeign_3[]= |
|
222 { |
|
223 { |
|
224 0xaa |
|
225 }, |
|
226 { |
|
227 0xba |
|
228 }, |
|
229 { |
|
230 0x8a |
|
231 }, |
|
232 { |
|
233 0x9a |
|
234 }, |
|
235 { |
|
236 0xde |
|
237 }, |
|
238 { |
|
239 0xfe |
|
240 }, |
|
241 { |
|
242 0x8d |
|
243 }, |
|
244 { |
|
245 0x9d |
|
246 } |
|
247 }; |
|
248 |
|
249 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry indexedTable16_unicodeToForeign_4[]= |
|
250 { |
|
251 { |
|
252 0x8f |
|
253 }, |
|
254 { |
|
255 0x9f |
|
256 }, |
|
257 { |
|
258 0xaf |
|
259 }, |
|
260 { |
|
261 0xbf |
|
262 }, |
|
263 { |
|
264 0x8e |
|
265 }, |
|
266 { |
|
267 0x9e |
|
268 } |
|
269 }; |
|
270 |
|
271 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable1616::SEntry keyedTable1616_unicodeToForeign_1[]= |
|
272 { |
|
273 { |
|
274 0x0081, |
|
275 0x81 |
|
276 }, |
|
277 { |
|
278 0x0083, |
|
279 0x83 |
|
280 }, |
|
281 { |
|
282 0x0088, |
|
283 0x88 |
|
284 }, |
|
285 { |
|
286 0x0090, |
|
287 0x90 |
|
288 }, |
|
289 { |
|
290 0x0098, |
|
291 0x98 |
|
292 }, |
|
293 { |
|
294 0x00a0, |
|
295 0xa0 |
|
296 }, |
|
297 { |
|
298 0x00a4, |
|
299 0xa4 |
|
300 }, |
|
301 { |
|
302 0x00a6, |
|
303 0xa6 |
|
304 }, |
|
305 { |
|
306 0x00a7, |
|
307 0xa7 |
|
308 }, |
|
309 { |
|
310 0x00a8, |
|
311 0xa8 |
|
312 }, |
|
313 { |
|
314 0x00a9, |
|
315 0xa9 |
|
316 }, |
|
317 { |
|
318 0x00ab, |
|
319 0xab |
|
320 }, |
|
321 { |
|
322 0x00ac, |
|
323 0xac |
|
324 }, |
|
325 { |
|
326 0x00ad, |
|
327 0xad |
|
328 }, |
|
329 { |
|
330 0x00ae, |
|
331 0xae |
|
332 }, |
|
333 { |
|
334 0x00b0, |
|
335 0xb0 |
|
336 }, |
|
337 { |
|
338 0x00b1, |
|
339 0xb1 |
|
340 }, |
|
341 { |
|
342 0x00b4, |
|
343 0xb4 |
|
344 }, |
|
345 { |
|
346 0x00b5, |
|
347 0xb5 |
|
348 }, |
|
349 { |
|
350 0x00b6, |
|
351 0xb6 |
|
352 }, |
|
353 { |
|
354 0x00b7, |
|
355 0xb7 |
|
356 }, |
|
357 { |
|
358 0x00b8, |
|
359 0xb8 |
|
360 }, |
|
361 { |
|
362 0x00bb, |
|
363 0xbb |
|
364 }, |
|
365 { |
|
366 0x00c1, |
|
367 0xc1 |
|
368 }, |
|
369 { |
|
370 0x00c2, |
|
371 0xc2 |
|
372 }, |
|
373 { |
|
374 0x00c4, |
|
375 0xc4 |
|
376 }, |
|
377 { |
|
378 0x00c7, |
|
379 0xc7 |
|
380 }, |
|
381 { |
|
382 0x00c9, |
|
383 0xc9 |
|
384 }, |
|
385 { |
|
386 0x00cb, |
|
387 0xcb |
|
388 }, |
|
389 { |
|
390 0x00cd, |
|
391 0xcd |
|
392 }, |
|
393 { |
|
394 0x00ce, |
|
395 0xce |
|
396 }, |
|
397 { |
|
398 0x00d3, |
|
399 0xd3 |
|
400 }, |
|
401 { |
|
402 0x00d4, |
|
403 0xd4 |
|
404 }, |
|
405 { |
|
406 0x00d6, |
|
407 0xd6 |
|
408 }, |
|
409 { |
|
410 0x00d7, |
|
411 0xd7 |
|
412 }, |
|
413 { |
|
414 0x00da, |
|
415 0xda |
|
416 }, |
|
417 { |
|
418 0x00dc, |
|
419 0xdc |
|
420 }, |
|
421 { |
|
422 0x00dd, |
|
423 0xdd |
|
424 }, |
|
425 { |
|
426 0x00df, |
|
427 0xdf |
|
428 }, |
|
429 { |
|
430 0x00e1, |
|
431 0xe1 |
|
432 }, |
|
433 { |
|
434 0x00e2, |
|
435 0xe2 |
|
436 }, |
|
437 { |
|
438 0x00e4, |
|
439 0xe4 |
|
440 }, |
|
441 { |
|
442 0x00e7, |
|
443 0xe7 |
|
444 }, |
|
445 { |
|
446 0x00e9, |
|
447 0xe9 |
|
448 }, |
|
449 { |
|
450 0x00eb, |
|
451 0xeb |
|
452 }, |
|
453 { |
|
454 0x00ed, |
|
455 0xed |
|
456 }, |
|
457 { |
|
458 0x00ee, |
|
459 0xee |
|
460 }, |
|
461 { |
|
462 0x00f3, |
|
463 0xf3 |
|
464 }, |
|
465 { |
|
466 0x00f4, |
|
467 0xf4 |
|
468 }, |
|
469 { |
|
470 0x00f6, |
|
471 0xf6 |
|
472 }, |
|
473 { |
|
474 0x00f7, |
|
475 0xf7 |
|
476 }, |
|
477 { |
|
478 0x00fa, |
|
479 0xfa |
|
480 }, |
|
481 { |
|
482 0x00fc, |
|
483 0xfc |
|
484 }, |
|
485 { |
|
486 0x00fd, |
|
487 0xfd |
|
488 } |
|
489 }; |
|
490 |
|
491 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable1616::SEntry keyedTable1616_unicodeToForeign_2[]= |
|
492 { |
|
493 { |
|
494 0x0118, |
|
495 0xca |
|
496 }, |
|
497 { |
|
498 0x0119, |
|
499 0xea |
|
500 }, |
|
501 { |
|
502 0x011a, |
|
503 0xcc |
|
504 }, |
|
505 { |
|
506 0x011b, |
|
507 0xec |
|
508 }, |
|
509 { |
|
510 0x0139, |
|
511 0xc5 |
|
512 }, |
|
513 { |
|
514 0x013a, |
|
515 0xe5 |
|
516 }, |
|
517 { |
|
518 0x013d, |
|
519 0xbc |
|
520 }, |
|
521 { |
|
522 0x013e, |
|
523 0xbe |
|
524 }, |
|
525 { |
|
526 0x0141, |
|
527 0xa3 |
|
528 }, |
|
529 { |
|
530 0x0142, |
|
531 0xb3 |
|
532 }, |
|
533 { |
|
534 0x0143, |
|
535 0xd1 |
|
536 }, |
|
537 { |
|
538 0x0144, |
|
539 0xf1 |
|
540 }, |
|
541 { |
|
542 0x0147, |
|
543 0xd2 |
|
544 }, |
|
545 { |
|
546 0x0148, |
|
547 0xf2 |
|
548 }, |
|
549 { |
|
550 0x0150, |
|
551 0xd5 |
|
552 }, |
|
553 { |
|
554 0x0151, |
|
555 0xf5 |
|
556 }, |
|
557 { |
|
558 0x0154, |
|
559 0xc0 |
|
560 }, |
|
561 { |
|
562 0x0155, |
|
563 0xe0 |
|
564 }, |
|
565 { |
|
566 0x0158, |
|
567 0xd8 |
|
568 }, |
|
569 { |
|
570 0x0159, |
|
571 0xf8 |
|
572 }, |
|
573 { |
|
574 0x015a, |
|
575 0x8c |
|
576 }, |
|
577 { |
|
578 0x015b, |
|
579 0x9c |
|
580 }, |
|
581 { |
|
582 0x016e, |
|
583 0xd9 |
|
584 }, |
|
585 { |
|
586 0x016f, |
|
587 0xf9 |
|
588 }, |
|
589 { |
|
590 0x0170, |
|
591 0xdb |
|
592 }, |
|
593 { |
|
594 0x0171, |
|
595 0xfb |
|
596 }, |
|
597 { |
|
598 0x02c7, |
|
599 0xa1 |
|
600 }, |
|
601 { |
|
602 0x02d8, |
|
603 0xa2 |
|
604 }, |
|
605 { |
|
606 0x02d9, |
|
607 0xff |
|
608 }, |
|
609 { |
|
610 0x02db, |
|
611 0xb2 |
|
612 }, |
|
613 { |
|
614 0x02dd, |
|
615 0xbd |
|
616 }, |
|
617 { |
|
618 0x2013, |
|
619 0x96 |
|
620 }, |
|
621 { |
|
622 0x2014, |
|
623 0x97 |
|
624 }, |
|
625 { |
|
626 0x2018, |
|
627 0x91 |
|
628 }, |
|
629 { |
|
630 0x2019, |
|
631 0x92 |
|
632 }, |
|
633 { |
|
634 0x201a, |
|
635 0x82 |
|
636 }, |
|
637 { |
|
638 0x201c, |
|
639 0x93 |
|
640 }, |
|
641 { |
|
642 0x201d, |
|
643 0x94 |
|
644 }, |
|
645 { |
|
646 0x201e, |
|
647 0x84 |
|
648 }, |
|
649 { |
|
650 0x2020, |
|
651 0x86 |
|
652 }, |
|
653 { |
|
654 0x2021, |
|
655 0x87 |
|
656 }, |
|
657 { |
|
658 0x2022, |
|
659 0x95 |
|
660 }, |
|
661 { |
|
662 0x2026, |
|
663 0x85 |
|
664 }, |
|
665 { |
|
666 0x2030, |
|
667 0x89 |
|
668 }, |
|
669 { |
|
670 0x2039, |
|
671 0x8b |
|
672 }, |
|
673 { |
|
674 0x203a, |
|
675 0x9b |
|
676 }, |
|
677 { |
|
678 0x20ac, |
|
679 0x80 |
|
680 }, |
|
681 { |
|
682 0x2122, |
|
683 0x99 |
|
684 } |
|
685 }; |
|
686 |
|
687 LOCAL_D const SCnvConversionData::SVariableByteData::SRange foreignVariableByteDataRanges[]= |
|
688 { |
|
689 { |
|
690 0x00, |
|
691 0xff, |
|
692 0, |
|
693 0 |
|
694 } |
|
695 }; |
|
696 |
|
697 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange foreignToUnicodeDataRanges[]= |
|
698 { |
|
699 { |
|
700 0x00, |
|
701 0x7f, |
|
702 SCnvConversionData::SOneDirectionData::SRange::EDirect, |
|
703 0, |
|
704 0, |
|
705 { |
|
706 0, |
|
707 0 |
|
708 } |
|
709 }, |
|
710 { |
|
711 0x80, |
|
712 0xff, |
|
713 SCnvConversionData::SOneDirectionData::SRange::EKeyedTable16OfIndexedTables16, |
|
714 0, |
|
715 0, |
|
716 { |
|
717 STATIC_CAST(TUint, ARRAY_LENGTH(keyedTables16OfIndexedTables16_keyedEntries_foreignToUnicode_1)), |
|
718 REINTERPRET_CAST( TUint, CONST_CAST(SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable16OfIndexedTables16::SKeyedEntry*, keyedTables16OfIndexedTables16_keyedEntries_foreignToUnicode_1)) |
|
719 } |
|
720 } |
|
721 }; |
|
722 |
|
723 LOCAL_D const SCnvConversionData::SOneDirectionData::SRange unicodeToForeignDataRanges[]= |
|
724 { |
|
725 { |
|
726 0x0000, |
|
727 0x007f, |
|
728 SCnvConversionData::SOneDirectionData::SRange::EDirect, |
|
729 1, |
|
730 0, |
|
731 { |
|
732 0, |
|
733 0 |
|
734 } |
|
735 }, |
|
736 { |
|
737 0x0102, |
|
738 0x0107, |
|
739 SCnvConversionData::SOneDirectionData::SRange::EIndexedTable16, |
|
740 1, |
|
741 0, |
|
742 { |
|
743 REINTERPRET_CAST(TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry*, indexedTable16_unicodeToForeign_1)), |
|
744 0 |
|
745 } |
|
746 }, |
|
747 { |
|
748 0x010c, |
|
749 0x0111, |
|
750 SCnvConversionData::SOneDirectionData::SRange::EIndexedTable16, |
|
751 1, |
|
752 0, |
|
753 { |
|
754 REINTERPRET_CAST( TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry*, indexedTable16_unicodeToForeign_2)), |
|
755 0 |
|
756 } |
|
757 }, |
|
758 { |
|
759 0x015e, |
|
760 0x0165, |
|
761 SCnvConversionData::SOneDirectionData::SRange::EIndexedTable16, |
|
762 1, |
|
763 0, |
|
764 { |
|
765 REINTERPRET_CAST(TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry*, indexedTable16_unicodeToForeign_3)), |
|
766 0 |
|
767 } |
|
768 }, |
|
769 { |
|
770 0x0179, |
|
771 0x017e, |
|
772 SCnvConversionData::SOneDirectionData::SRange::EIndexedTable16, |
|
773 1, |
|
774 0, |
|
775 { |
|
776 REINTERPRET_CAST(TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SIndexedTable16::SEntry*, indexedTable16_unicodeToForeign_4)), |
|
777 0 |
|
778 } |
|
779 }, |
|
780 { |
|
781 0x0081, |
|
782 0x00fd, |
|
783 SCnvConversionData::SOneDirectionData::SRange::EKeyedTable1616, |
|
784 1, |
|
785 0, |
|
786 { |
|
787 STATIC_CAST(TUint, ARRAY_LENGTH(keyedTable1616_unicodeToForeign_1)), |
|
788 REINTERPRET_CAST(TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable1616::SEntry*, keyedTable1616_unicodeToForeign_1)) |
|
789 } |
|
790 }, |
|
791 { |
|
792 0x0118, |
|
793 0x2122, |
|
794 SCnvConversionData::SOneDirectionData::SRange::EKeyedTable1616, |
|
795 1, |
|
796 0, |
|
797 { |
|
798 STATIC_CAST(TUint, ARRAY_LENGTH(keyedTable1616_unicodeToForeign_2)), |
|
799 REINTERPRET_CAST(TUint, CONST_CAST( SCnvConversionData::SOneDirectionData::SRange::UData::SKeyedTable1616::SEntry*, keyedTable1616_unicodeToForeign_2)) |
|
800 } |
|
801 } |
|
802 }; |
|
803 |
|
804 GLDEF_D const SCnvConversionData conversionData= |
|
805 { |
|
806 SCnvConversionData::EFixedBigEndian, |
|
807 { |
|
808 ARRAY_LENGTH(foreignVariableByteDataRanges), |
|
809 foreignVariableByteDataRanges |
|
810 }, |
|
811 { |
|
812 ARRAY_LENGTH(foreignToUnicodeDataRanges), |
|
813 foreignToUnicodeDataRanges |
|
814 }, |
|
815 { |
|
816 ARRAY_LENGTH(unicodeToForeignDataRanges), |
|
817 unicodeToForeignDataRanges |
|
818 }, |
|
819 NULL, |
|
820 NULL |
|
821 }; |
|
822 |