annotate lisp/language/vietnamese.el @ 85133:87df82f093bd

New VC command docs for the Emacs manual.
author Eric S. Raymond <esr@snark.thyrsus.com>
date Wed, 10 Oct 2007 13:24:29 +0000
parents 0938de05f510
children b5d3fc1c4afe f55f9811f5d7
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
38414
67b464da13ec Some fixes to follow coding conventions.
Pavel Janík <Pavel@Janik.cz>
parents: 33778
diff changeset
1 ;;; vietnamese.el --- support for Vietnamese -*- coding: iso-2022-7bit; -*-
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
2
75347
e3694f1cb928 Add 2007 to copyright years.
Glenn Morris <rgm@gnu.org>
parents: 74605
diff changeset
3 ;; Copyright (C) 1998, 2001, 2002, 2003, 2004, 2005, 2006, 2007
74544
43cc94d955c2 Update copyright years.
Glenn Morris <rgm@gnu.org>
parents: 66260
diff changeset
4 ;; Free Software Foundation, Inc.
74605
6ee41fdd69ff Update AIST copyright years.
Kenichi Handa <handa@m17n.org>
parents: 74544
diff changeset
5 ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
75347
e3694f1cb928 Add 2007 to copyright years.
Glenn Morris <rgm@gnu.org>
parents: 74605
diff changeset
6 ;; 2005, 2006, 2007
62396
197607499a29 Fix copyrights.
Kenichi Handa <handa@m17n.org>
parents: 52401
diff changeset
7 ;; National Institute of Advanced Industrial Science and Technology (AIST)
197607499a29 Fix copyrights.
Kenichi Handa <handa@m17n.org>
parents: 52401
diff changeset
8 ;; Registration Number H14PRO021
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
9
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
10 ;; Keywords: multilingual, Vietnamese
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
11
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
12 ;; This file is part of GNU Emacs.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
13
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
14 ;; GNU Emacs is free software; you can redistribute it and/or modify
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
15 ;; it under the terms of the GNU General Public License as published by
78309
0938de05f510 Restore comma mistakenly removed in last change.
Glenn Morris <rgm@gnu.org>
parents: 78300
diff changeset
16 ;; the Free Software Foundation; either version 3, or (at your option)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
17 ;; any later version.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
18
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
19 ;; GNU Emacs is distributed in the hope that it will be useful,
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
20 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
21 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
22 ;; GNU General Public License for more details.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
23
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
24 ;; You should have received a copy of the GNU General Public License
17071
70194012fb3a Fix FSF address in comment.
Karl Heuer <kwzh@gnu.org>
parents: 17052
diff changeset
25 ;; along with GNU Emacs; see the file COPYING. If not, write to the
64085
18a818a2ee7c Update FSF's address.
Lute Kamstra <lute@gnu.org>
parents: 62396
diff changeset
26 ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18a818a2ee7c Update FSF's address.
Lute Kamstra <lute@gnu.org>
parents: 62396
diff changeset
27 ;; Boston, MA 02110-1301, USA.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
28
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
29 ;;; Commentary:
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
30
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
31 ;; For Vietnames, the character sets VISCII, VSCII and TCVN-5712 are
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
32 ;; supported.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
33
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
34 ;;; Code:
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
35
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
36 (defvar viet-viscii-decode-table
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
37 [;; VISCII is a full 8-bit code.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
38 0 1 ?,2F(B 3 4 ?,2G(B ?,2g(B 7 8 9 10 11 12 13 14 15
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
39 16 17 18 19 ?,2V(B 21 22 23 24 ?,2[(B 26 27 28 29 ?,2\(B 31
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
40 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
41 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
42 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
43 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
44 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
45 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
46 ?,2U(B ?,2!(B ?,2"(B ?,2#(B ?,2$(B ?,2%(B ?,2&(B ?,2'(B ?,2((B ?,2)(B ?,2*(B ?,2+(B ?,2,(B ?,2-(B ?,2.(B ?,2/(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
47 ?,20(B ?,21(B ?,22(B ?,25(B ?,2~(B ?,2>(B ?,26(B ?,27(B ?,28(B ?,2v(B ?,2w(B ?,2o(B ?,2|(B ?,2{(B ?,2x(B ?,2O(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
48 ?,2u(B ?,1!(B ?,1"(B ?,1#(B ?,1$(B ?,1%(B ?,1&(B ?,1'(B ?,1((B ?,1)(B ?,1*(B ?,1+(B ?,1,(B ?,1-(B ?,1.(B ?,1/(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
49 ?,10(B ?,11(B ?,12(B ?,2^(B ?,2=(B ?,15(B ?,16(B ?,17(B ?,18(B ?,2q(B ?,2Q(B ?,2W(B ?,2X(B ?,1=(B ?,1>(B ?,2_(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
50 ?,2`(B ?,2a(B ?,2b(B ?,2c(B ?,2d(B ?,2e(B ?,1F(B ?,1G(B ?,2h(B ?,2i(B ?,2j(B ?,2k(B ?,2l(B ?,2m(B ?,2n(B ?,1O(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
51 ?,2p(B ?,1Q(B ?,2r(B ?,2s(B ?,2t(B ?,1U(B ?,1V(B ?,1W(B ?,1X(B ?,2y(B ?,2z(B ?,1[(B ?,1\(B ?,2}(B ?,1^(B ?,1_(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
52 ?,1`(B ?,1a(B ?,1b(B ?,1c(B ?,1d(B ?,1e(B ?,1f(B ?,1g(B ?,1h(B ?,1i(B ?,1j(B ?,1k(B ?,1l(B ?,1m(B ?,1n(B ?,1o(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
53 ?,1p(B ?,1q(B ?,1r(B ?,1s(B ?,1t(B ?,1u(B ?,1v(B ?,1w(B ?,1x(B ?,1y(B ?,1z(B ?,1{(B ?,1|(B ?,1}(B ?,1~(B ?,2f(B ]
22879
33987189baf3 (viet-viscii-decode-table): Docstring
Kenichi Handa <handa@m17n.org>
parents: 21663
diff changeset
54 "Vietnamese VISCII decoding table.")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
55
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
56 (let ((table (make-translation-table-from-vector viet-viscii-decode-table)))
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
57 (define-translation-table 'viet-viscii-nonascii-translation-table table)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
58 (define-translation-table 'viet-viscii-encode-table
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
59 (char-table-extra-slot table 0)))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
60
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
61 ;;;
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
62 ;;; VSCII is a pre-version of TCVN-5712 and deprecated
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
63 ;;;
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
64 (defvar viet-vscii-decode-table
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
65 [;; VSCII is a full 8-bit code.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
66 0 ?,2z(B ?,2x(B 3 ?,2W(B ?,2X(B ?,2f(B 7 8 9 10 11 12 13 14 15
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
67 16 ?,2Q(B ?,2_(B ?,2O(B ?,2V(B ?,2[(B ?,2}(B ?,2\(B 24 25 26 27 28 29 30 31
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
68 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
69 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
70 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
71 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
72 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
73 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
74 ?,2`(B ?,2d(B ?,2c(B ?,2a(B ?,2U(B ?,2#(B ?,2'(B ?,2h(B ?,2k(B ?,2((B ?,2i(B ?,2)(B ?,2.(B ?,2l(B ?,2o(B ?,2n(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
75 ?,2m(B ?,28(B ?,2r(B ?,2v(B ?,2u(B ?,2s(B ?,2w(B ?,25(B ?,26(B ?,27(B ?,2^(B ?,2>(B ?,2~(B ?,2y(B ?,2|(B ?,2{(B
28536
fd56586afd85 (viet-vscii-decode-table): Fix a bug.
Kenichi Handa <handa@m17n.org>
parents: 24808
diff changeset
76 160 ?,2e(B ?,2b(B ?,2j(B ?,2t(B ?,2=(B ?,2_(B ?,2p(B ?,1e(B ?,1b(B ?,1j(B ?,1t(B ?,1=(B ?,1y(B ?,1p(B ?,2"(B
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
77 192 193 194 195 196 ?,1`(B ?,1d(B ?,1c(B ?,1a(B ?,1U(B ?,2F(B ?,1"(B ?,1F(B ?,1G(B ?,1!(B ?,2G(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
78 ?,2!(B ?,2%(B ?,2&(B ?,2g(B ?,2%(B ?,2+(B ?,1#(B ?,1%(B ?,1&(B ?,1g(B ?,1$(B ?,1'(B ?,1h(B ?,2,(B ?,1k(B ?,1((B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
79 ?,1i(B ?,1)(B ?,1+(B ?,1,(B ?,1-(B ?,1*(B ?,1.(B ?,1l(B ?,1o(B ?,2-(B ?,2*(B ?,20(B ?,1n(B ?,1m(B ?,18(B ?,1r(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
80 ?,21(B ?,1v(B ?,1u(B ?,1s(B ?,1w(B ?,10(B ?,11(B ?,12(B ?,1/(B ?,15(B ?,16(B ?,17(B ?,1^(B ?,1>(B ?,1~(B ?,1y(B
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
81 ?,22(B ?,1|(B ?,1{(B ?,1z(B ?,1x(B ?,1W(B ?,1X(B ?,1f(B ?,1Q(B ?,1q(B ?,1O(B ?,1V(B ?,1[(B ?,1}(B ?,1\(B ?,2/(B]
22879
33987189baf3 (viet-viscii-decode-table): Docstring
Kenichi Handa <handa@m17n.org>
parents: 21663
diff changeset
82 "Vietnamese VSCII decoding table.")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
83
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
84 (let ((table (make-translation-table-from-vector viet-vscii-decode-table)))
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
85 (define-translation-table 'viet-vscii-nonascii-translation-table table)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
86 (define-translation-table 'viet-vscii-encode-table
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
87 (char-table-extra-slot table 0)))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
88
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
89 ;; Does not support combining characters in the range [176, 180]
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
90 (defvar viet-tcvn-decode-table
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
91 [;; TCVN is a full 8-bit code.
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
92 0 ?,2z(B ?,2x(B 3 ?,2W(B ?,2X(B ?,2f(B 7 8 9 10 11 12 13 14 15
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
93 16 ?,2Q(B ?,2q(B ?,2O(B ?,2V(B ?,2[(B ?,2}(B ?,2\(B 24 25 26 27 28 29 30 31
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
94 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
95 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
96 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
97 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
98 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
99 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
100 ?,2`(B ?,2d(B ?,2c(B ?,2a(B ?,2U(B ?,2#(B ?,2'(B ?,2h(B ?,2k(B ?,2((B ?,2i(B ?,2)(B ?,2.(B ?,2l(B ?,2o(B ?,2n(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
101 ?,2m(B ?,28(B ?,2r(B ?,2v(B ?,2u(B ?,2s(B ?,2w(B ?,25(B ?,26(B ?,27(B ?,2^(B ?,2>(B ?,2~(B ?,2y(B ?,2|(B ?,2{(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
102 160 ?,2e(B ?,2b(B ?,2j(B ?,2t(B ?,2=(B ?,2_(B ?,2p(B ?,1e(B ?,1b(B ?,1j(B ?,1t(B ?,1=(B ?,1_(B ?,1p(B ?,2"(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
103 176 177 178 179 180 ?,1`(B ?,1d(B ?,1c(B ?,1a(B ?,1U(B ?,2F(B ?,1"(B ?,1F(B ?,1G(B ?,1!(B ?,2G(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
104 ?,2!(B ?,2%(B ?,2&(B ?,2g(B ?,2$(B ?,2+(B ?,1#(B ?,1%(B ?,1&(B ?,1g(B ?,1$(B ?,1'(B ?,1h(B ?,2,(B ?,1k(B ?,1((B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
105 ?,1i(B ?,1)(B ?,1+(B ?,1,(B ?,1-(B ?,1*(B ?,1.(B ?,1l(B ?,1o(B ?,2-(B ?,2*(B ?,20(B ?,1n(B ?,1m(B ?,18(B ?,1r(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
106 ?,21(B ?,1v(B ?,1u(B ?,1s(B ?,1w(B ?,10(B ?,11(B ?,12(B ?,1/(B ?,15(B ?,16(B ?,17(B ?,1^(B ?,1>(B ?,1~(B ?,1y(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
107 ?,22(B ?,1|(B ?,1{(B ?,1z(B ?,1x(B ?,1W(B ?,1X(B ?,1f(B ?,1Q(B ?,1q(B ?,1O(B ?,1V(B ?,1[(B ?,1}(B ?,1\(B ?,2/(B]
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
108 "Vietnamese TCVN-5712 decoding table.")
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
109
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
110 (let ((table (make-translation-table-from-vector viet-tcvn-decode-table)))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
111 (define-translation-table 'viet-tcvn-nonascii-translation-table table)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
112 (define-translation-table 'viet-tcvn-encode-table
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
113 (char-table-extra-slot table 0)))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
114
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
115 ;; (defvar viet-vps-decode-table
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
116 ;; [;; VPS is a full 8-bit code.
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
117 ;; 0 1 ?,2U(B ?,2'(B ?,2#(B ?,2)(B ?,2.(B 7 8 9 10 11 12 13 14 15
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
118 ;; ?,28(B ?,2w(B ?,25(B ?,2~(B ?,2x(B ?,2q(B 22 23 24 ?,2\(B 26 27 ?,2g(B ?,2f(B 30 31
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
119 ;; 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
120 ;; 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
121 ;; 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
122 ;; 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
123 ;; 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
124 ;; 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
125 ;; ?,2`(B ?,2d(B ?,2c(B ?,2$(B ?,2%(B ?,2&(B ?,1w(B ?,12(B ?,2e(B ?,1*(B ?,1+(B ?,1,(B ?,1.(B ?,2!(B ?,2"(B ?,2F(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
126 ;; ?,2*(B 145 146 ?,2+(B ?,2,(B ?,2-(B ?,2/(B ?,20(B ?,21(B ?,22(B ?,1}(B ?,1V(B ?,1\(B ?,2>(B ?,26(B ?,27(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
127 ;; 160 ?,1!(B ?,1"(B ?,1F(B ?,1G(B ?,1#(B ?,2^(B ?,1>(B ?,2y(B ?,16(B ?,17(B ?,1^(B ?,2{(B ?,2Q(B ?,1~(B ?,2W(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
128 ;; ?,11(B ?,2X(B ?,2O(B ?,2[(B ?,2m(B ?,2l(B ?,15(B ?,2o(B ?,2n(B ?,2s(B ?,1X(B ?,1f(B ?,2r(B ?,2v(B ?,2u(B ?,1q(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
129 ;; ?,1%(B ?,2a(B ?,2b(B ?,1$(B ?,1&(B ?,1g(B ?,1'(B ?,1p(B ?,1k(B ?,2i(B ?,2j(B ?,1)(B ?,1o(B ?,1-(B ?,18(B ?,1[(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
130 ;; ?,2_(B ?,2|(B ?,10(B ?,1/(B ?,2t(B ?,1v(B ?,1=(B ?,2h(B ?,1W(B ?,1Q(B ?,2z(B ?,1{(B ?,1_(B ?,2}(B ?,2k(B 223
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
131 ;; ?,1`(B ?,1a(B ?,1b(B ?,1c(B ?,1d(B ?,1U(B ?,1e(B 231 ?,1h(B ?,1i(B ?,1j(B ?,1((B ?,1l(B ?,1m(B 238 ?,1n(B
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
132 ;; ?,2G(B ?,2p(B ?,1r(B ?,1s(B ?,1t(B ?,1u(B 246 ?,2=(B ?,1x(B ?,1y(B ?,1z(B ?,1|(B 252 ?,2V(B ?,2((B ?,1O(B]
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
133 ;; "Vietnamese VPS decoding table.")
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
134 ;;
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
135 ;; (let ((table (make-translation-table-from-vector viet-vps-decode-table)))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
136 ;; (define-translation-table 'viet-vps-nonascii-translation-table table)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
137 ;; (define-translation-table 'viet-vps-encode-table
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
138 ;; (char-table-extra-slot table 0)))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
139
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
140 (define-ccl-program ccl-decode-viscii
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
141 `(3
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
142 ((loop
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
143 (r0 = 0)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
144 (read r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
145 (translate-character viet-viscii-nonascii-translation-table r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
146 (write-multibyte-character r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
147 (repeat))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
148 "CCL program to decode VISCII 1.1")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
149
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
150 (define-ccl-program ccl-encode-viscii
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
151 `(1
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
152 ((loop
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
153 (read-multibyte-character r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
154 (translate-character viet-viscii-encode-table r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
155 (write-repeat r1))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
156 "CCL program to encode VISCII 1.1")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
157
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
158 (define-ccl-program ccl-encode-viscii-font
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
159 `(0
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
160 ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
161 ;; R1:position code
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
162 ;; Out: R1:font code point
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
163 (translate-character viet-viscii-encode-table r0 r1))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
164 "CCL program to encode Vietnamese chars to VISCII 1.1 font")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
165
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
166 (define-ccl-program ccl-decode-vscii
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
167 `(3
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
168 ((loop
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
169 (r0 = 0)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
170 (read r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
171 (translate-character viet-vscii-nonascii-translation-table r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
172 (write-multibyte-character r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
173 (repeat))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
174 "CCL program to decode VSCII-1.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
175
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
176 (define-ccl-program ccl-encode-vscii
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
177 `(1
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
178 ((loop
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
179 (read-multibyte-character r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
180 (translate-character viet-vscii-encode-table r0 r1)
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
181 (write-repeat r1))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
182 "CCL program to encode VSCII-1.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
183
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
184 (define-ccl-program ccl-encode-vscii-font
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
185 `(0
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
186 ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
187 ;; R1:position code
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
188 ;; Out: R1:font code point
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
189 (translate-character viet-vscii-encode-table r0 r1))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
190 "CCL program to encode Vietnamese chars to VSCII-1 font.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
191
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
192 (define-ccl-program ccl-decode-tcvn
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
193 `(3
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
194 ((loop
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
195 (r0 = 0)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
196 (read r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
197 (translate-character viet-tcvn-nonascii-translation-table r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
198 (write-multibyte-character r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
199 (repeat))))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
200 "CCL program to decode TCVN-5712.")
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
201
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
202 (define-ccl-program ccl-encode-tcvn
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
203 `(1
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
204 ((loop
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
205 (read-multibyte-character r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
206 (translate-character viet-tcvn-encode-table r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
207 (write-repeat r1))))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
208 "CCL program to encode TCVN-5712.")
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
209
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
210 (define-ccl-program ccl-encode-tcvn-font
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
211 `(0
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
212 ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
213 ;; R1:position code
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
214 ;; Out: R1:font code point
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
215 (translate-character viet-tcvn-encode-table r0 r1))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
216 "CCL program to encode Vietnamese chars to TCVN-5712 font.")
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
217
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
218 ;; (define-ccl-program ccl-decode-vps
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
219 ;; `(3
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
220 ;; ((loop
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
221 ;; (r0 = 0)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
222 ;; (read r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
223 ;; (translate-character viet-vps-nonascii-translation-table r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
224 ;; (write-multibyte-character r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
225 ;; (repeat))))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
226 ;; "CCL program to decode VPS.")
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
227 ;;
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
228 ;; (define-ccl-program ccl-encode-vps
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
229 ;; `(1
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
230 ;; ((loop
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
231 ;; (read-multibyte-character r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
232 ;; (translate-character viet-vps-encode-table r0 r1)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
233 ;; (write-repeat r1))))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
234 ;; "CCL program to encode VPS.")
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
235 ;;
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
236 ;; (define-ccl-program ccl-encode-vps-font
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
237 ;; `(0
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
238 ;; ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
239 ;; ;; R1:position code
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
240 ;; ;; Out: R1:font code point
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
241 ;; (translate-character viet-vps-encode-table r0 r1))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
242 ;; "CCL program to encode Vietnamese chars to VPS font.")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
243
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
244 (make-coding-system
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
245 'vietnamese-viscii 4 ?V
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
246 "8-bit encoding for Vietnamese VISCII 1.1 (MIME:VISCII)"
21663
a03ddc4a728b FLAGS arguments for make-coding-system changed.
Kenichi Handa <handa@m17n.org>
parents: 20739
diff changeset
247 '(ccl-decode-viscii . ccl-encode-viscii)
20739
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
248 '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
22879
33987189baf3 (viet-viscii-decode-table): Docstring
Kenichi Handa <handa@m17n.org>
parents: 21663
diff changeset
249 (mime-charset . viscii)
23069
96139be23b05 (vietnamese-viscii): Fix the value of
Kenichi Handa <handa@m17n.org>
parents: 22983
diff changeset
250 (valid-codes (0 . 255))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
251
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
252 (define-coding-system-alias 'viscii 'vietnamese-viscii)
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
253
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
254 (make-coding-system
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
255 'vietnamese-vscii 4 ?v
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
256 "8-bit encoding for Vietnamese VSCII-1"
21663
a03ddc4a728b FLAGS arguments for make-coding-system changed.
Kenichi Handa <handa@m17n.org>
parents: 20739
diff changeset
257 '(ccl-decode-vscii . ccl-encode-vscii)
22879
33987189baf3 (viet-viscii-decode-table): Docstring
Kenichi Handa <handa@m17n.org>
parents: 21663
diff changeset
258 '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
23069
96139be23b05 (vietnamese-viscii): Fix the value of
Kenichi Handa <handa@m17n.org>
parents: 22983
diff changeset
259 (valid-codes (0 . 255))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
260
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
261 (define-coding-system-alias 'vscii 'vietnamese-vscii)
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
262
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
263 (make-coding-system
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
264 'vietnamese-tcvn 4 ?t
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
265 "8-bit encoding for Vietnamese TCVN-5712"
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
266 '(ccl-decode-tcvn . ccl-encode-tcvn)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
267 '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
268 (valid-codes (0 . 255))))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
269
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
270 (define-coding-system-alias 'tcvn 'vietnamese-tcvn)
66260
86f5594365ad (tcvn-5712): Make it an alias of
Kenichi Handa <handa@m17n.org>
parents: 64085
diff changeset
271 (define-coding-system-alias 'tcvn-5712 'vietnamese-tcvn)
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
272
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
273 ;; (make-coding-system
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
274 ;; 'vietnamese-vps 4 ?p
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
275 ;; "8-bit encoding for Vietnamese VPS"
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
276 ;; '(ccl-decode-vps . ccl-encode-vps)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
277 ;; '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
278 ;; (valid-codes (0 . 255))))
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
279 ;;
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
280 ;; (define-coding-system-alias 'vps 'vietnamese-vps)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
281
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
282 (make-coding-system
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
283 'vietnamese-viqr 0 ?q
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
284 "Vietnamese latin transcription (VIQR)"
20155
d74c1bd094a2 Give proper SAFE-CHARSET argument in
Kenichi Handa <handa@m17n.org>
parents: 20108
diff changeset
285 nil
20739
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
286 '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
287 (post-read-conversion . viqr-post-read-conversion)
24296
28d942c5d967 (vietnamese-viqr): Add charset-origin-alist property.
Kenichi Handa <handa@m17n.org>
parents: 23158
diff changeset
288 (pre-write-conversion . viqr-pre-write-conversion)
28d942c5d967 (vietnamese-viqr): Add charset-origin-alist property.
Kenichi Handa <handa@m17n.org>
parents: 23158
diff changeset
289 (charset-origin-alist
28d942c5d967 (vietnamese-viqr): Add charset-origin-alist property.
Kenichi Handa <handa@m17n.org>
parents: 23158
diff changeset
290 (vietnamese-viscii-lower "VISCII" viet-encode-viscii-char)
28d942c5d967 (vietnamese-viqr): Add charset-origin-alist property.
Kenichi Handa <handa@m17n.org>
parents: 23158
diff changeset
291 (vietnamese-viscii-upper "VISCII" viet-encode-viscii-char))))
28d942c5d967 (vietnamese-viqr): Add charset-origin-alist property.
Kenichi Handa <handa@m17n.org>
parents: 23158
diff changeset
292
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
293
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
294 (define-coding-system-alias 'viqr 'vietnamese-viqr)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
295
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
296 (setq font-ccl-encoder-alist
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
297 (cons '("viscii" . ccl-encode-viscii-font) font-ccl-encoder-alist))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
298
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
299 (setq font-ccl-encoder-alist
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
300 (cons '("vscii" . ccl-encode-vscii-font) font-ccl-encoder-alist))
22879
33987189baf3 (viet-viscii-decode-table): Docstring
Kenichi Handa <handa@m17n.org>
parents: 21663
diff changeset
301
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
302 (setq font-ccl-encoder-alist
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
303 (cons '("tcvn" . ccl-encode-tcvn-font) font-ccl-encoder-alist))
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
304
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
305 (set-language-info-alist
22983
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
306 "Vietnamese" `((charset vietnamese-viscii-lower vietnamese-viscii-upper)
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
307 (nonascii-translation
29452
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
308 . ,(get 'viet-viscii-nonascii-translation-table
86a268b661c2 Remove eval-when-compile.
Kenichi Handa <handa@m17n.org>
parents: 28536
diff changeset
309 'translation-table))
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
310 (coding-system vietnamese-viscii vietnamese-vscii vietnamese-tcvn
20739
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
311 vietnamese-viqr)
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
312 (coding-priority vietnamese-viscii)
22983
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
313 (input-method . "vietnamese-viqr")
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
314 (unibyte-display . vietnamese-viscii)
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
315 (features viet-util)
17772
550afdbb31d8 Make functions setup-LANGUAGE-environment
Kenichi Handa <handa@m17n.org>
parents: 17170
diff changeset
316 (sample-text . "Vietnamese (Ti,1*(Bng Vi,1.(Bt) Ch,1`(Bo b,1U(Bn")
17993
73869115ae0a Most of setup-LANGUAGE-environment functions are
Kenichi Handa <handa@m17n.org>
parents: 17841
diff changeset
317 (documentation . "\
49727
350e89367682 ("Vietnamese"): Fix typos.
Juanma Barranquero <lekktu@gmail.com>
parents: 49598
diff changeset
318 For Vietnamese, Emacs uses special charsets internally.
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
319 They can be decoded from and encoded to VISCII, VSCII, TCVN-5712, and
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
320 VIQR. VSCII is deprecated in favour of TCVN-5712. Current setting
49727
350e89367682 ("Vietnamese"): Fix typos.
Juanma Barranquero <lekktu@gmail.com>
parents: 49598
diff changeset
321 puts higher priority to the coding system VISCII than TCVN-5712. If
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
322 you prefer TCVN-5712, please do: (prefer-coding-system 'vietnamese-tcvn).
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
323 There are two Vietnamese input methods: VIQR and Telex, VIQR is the
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
324 default setting.")
17841
084d922fcd78 Coding system names changed as follows:
Kenichi Handa <handa@m17n.org>
parents: 17772
diff changeset
325 ))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
326
33778
6d966e8b4bbe Use provide.
Dave Love <fx@gnu.org>
parents: 29452
diff changeset
327 (provide 'vietnamese)
6d966e8b4bbe Use provide.
Dave Love <fx@gnu.org>
parents: 29452
diff changeset
328
52401
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 49727
diff changeset
329 ;;; arch-tag: 5bd4f1aa-2d4e-4f33-b7d8-0679c6a19ee6
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
330 ;;; vietnamese.el ends here