annotate lisp/international/characters.el @ 29453:22f8105a7dc7

Remove eval-when-compile. (cyrillic-koi8-r-nonascii-translation-table): Define it as a translation table made from cyrillic-koi8-r-decode-table. (cyrillic-koi8-r-encode-table): Define it as a translation table made from the reverse map of above. (ccl-decode-koi8): Use translate-character. (ccl-encode-koi8, ccl-encode-koi8-font): Likewize (cyrillic-alternativnyj-nonascii-translation-table): Define it as a translation table made from cyrillic-alternativnyj-decode-table. (cyrillic-alternativnyj-encode-table): Define it as a translation table made from the reverse map of above. (ccl-decode-alternativnyj): Use translate-character. (ccl-encode-alternativnyj, ccl-encode-alternativnyj-font): Likewize
author Kenichi Handa <handa@m17n.org>
date Tue, 06 Jun 2000 02:10:04 +0000
parents 038c13f83357
children b41bc1b0a044
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
1 ;;; characters.el --- set syntax and category for multibyte characters
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
2
19958
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
3 ;; Copyright (C) 1995, 1997 Electrotechnical Laboratory, JAPAN.
18377
8b4a66c66dd6 Change copyright notice.
Richard M. Stallman <rms@gnu.org>
parents: 18304
diff changeset
4 ;; Licensed to the Free Software Foundation.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
5
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
6 ;; Keywords: multibyte character, character set, syntax, category
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
7
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
8 ;; This file is part of GNU Emacs.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
9
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
10 ;; GNU Emacs is free software; you can redistribute it and/or modify
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
11 ;; it under the terms of the GNU General Public License as published by
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
12 ;; the Free Software Foundation; either version 2, or (at your option)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
13 ;; any later version.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
14
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
15 ;; GNU Emacs is distributed in the hope that it will be useful,
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
18 ;; GNU General Public License for more details.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
19
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
20 ;; 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
21 ;; along with GNU Emacs; see the file COPYING. If not, write to the
70194012fb3a Fix FSF address in comment.
Karl Heuer <kwzh@gnu.org>
parents: 17052
diff changeset
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
70194012fb3a Fix FSF address in comment.
Karl Heuer <kwzh@gnu.org>
parents: 17052
diff changeset
23 ;; Boston, MA 02111-1307, USA.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
24
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
25 ;;; Commentary:
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
26
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
27 ;; This file contains multibyte characters. Save this file always in
18197
90235db802c7 Comment changed (iso-2022-7 -> iso-2022-7bit).
Kenichi Handa <handa@m17n.org>
parents: 17753
diff changeset
28 ;; the coding system `iso-2022-7bit'.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
29
18205
40dc3b2e9e27 Delete syntax stuff for Latin-1 and Latin-2.
Richard M. Stallman <rms@gnu.org>
parents: 18197
diff changeset
30 ;; This file does not define the syntax for Latin-N character sets;
40dc3b2e9e27 Delete syntax stuff for Latin-1 and Latin-2.
Richard M. Stallman <rms@gnu.org>
parents: 18197
diff changeset
31 ;; those are defined by the files latin-N.el.
40dc3b2e9e27 Delete syntax stuff for Latin-1 and Latin-2.
Richard M. Stallman <rms@gnu.org>
parents: 18197
diff changeset
32
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
33 ;;; Predefined categories.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
34
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
35 ;; For each character set.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
36
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
37 (define-category ?a "ASCII")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
38 (define-category ?l "Latin")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
39 (define-category ?t "Thai")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
40 (define-category ?g "Greek")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
41 (define-category ?b "Arabic")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
42 (define-category ?w "Hebrew")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
43 (define-category ?y "Cyrillic")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
44 (define-category ?k "Japanese katakana")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
45 (define-category ?r "Japanese roman")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
46 (define-category ?c "Chinese")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
47 (define-category ?j "Japanese")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
48 (define-category ?h "Korean")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
49 (define-category ?e "Ethiopic (Ge'ez)")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
50 (define-category ?v "Vietnamese")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
51 (define-category ?i "Indian")
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
52 (define-category ?o "Lao")
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
53 (define-category ?q "Tibetan")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
54
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
55 ;; For each group (row) of 2-byte character sets.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
56
22529
d9eac134a41b Doc fixes.
Karl Heuer <kwzh@gnu.org>
parents: 20843
diff changeset
57 (define-category ?A "Alpha-numeric characters of 2-byte character sets")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
58 (define-category ?C "Chinese (Han) characters of 2-byte character sets")
22529
d9eac134a41b Doc fixes.
Karl Heuer <kwzh@gnu.org>
parents: 20843
diff changeset
59 (define-category ?G "Greek characters of 2-byte character sets")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
60 (define-category ?H "Japanese Hiragana characters of 2-byte character sets")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
61 (define-category ?K "Japanese Katakana characters of 2-byte character sets")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
62 (define-category ?N "Korean Hangul characters of 2-byte character sets")
22529
d9eac134a41b Doc fixes.
Karl Heuer <kwzh@gnu.org>
parents: 20843
diff changeset
63 (define-category ?Y "Cyrillic characters of 2-byte character sets")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
64 (define-category ?I "Indian Glyphs")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
65
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
66 ;; For phonetic classifications.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
67
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
68 (define-category ?0 "consonant")
18561
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
69 (define-category ?1 "base (independent) vowel")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
70 (define-category ?2 "upper diacritical mark (including upper vowel)")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
71 (define-category ?3 "lower diacritical mark (including lower vowel)")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
72 (define-category ?4 "tone mark")
18561
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
73 (define-category ?5 "symbol")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
74 (define-category ?6 "digit")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
75 (define-category ?7 "vowel-modifying diacritical mark")
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
76 (define-category ?8 "vowel-signs")
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
77 (define-category ?9 "semivowel lower")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
78
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
79 ;; For filling.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
80 (define-category ?| "While filling, we can break a line at this character.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
81
20247
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
82 ;; For indentation calculation.
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
83 (define-category ?
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
84 "This character counts as a space for indentation purposes.")
20247
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
85
22529
d9eac134a41b Doc fixes.
Karl Heuer <kwzh@gnu.org>
parents: 20843
diff changeset
86 ;; Keep the following for `kinsoku' processing. See comments in
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
87 ;; kinsoku.el.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
88 (define-category ?> "A character which can't be placed at beginning of line.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
89 (define-category ?< "A character which can't be placed at end of line.")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
90
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
91
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
92 ;;; Setting syntax and category.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
93
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
94 ;; ASCII
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
95
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
96 (let ((ch 32))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
97 (while (< ch 127) ; All ASCII characters have
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
98 (modify-category-entry ch ?a) ; the category `a' (ASCII)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
99 (modify-category-entry ch ?l) ; and `l' (Latin).
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
100 (setq ch (1+ ch))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
101
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
102 ;; Arabic character set
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
103
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
104 (let ((charsets '(arabic-iso8859-6
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
105 arabic-digit
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
106 arabic-1-column
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
107 arabic-2-column)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
108 (while charsets
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
109 (modify-syntax-entry (make-char (car charsets)) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
110 (modify-category-entry (make-char (car charsets)) ?b)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
111 (setq charsets (cdr charsets))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
112
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
113 ;; Chinese character set (GB2312)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
114
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
115 (modify-syntax-entry (make-char 'chinese-gb2312) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
116 (modify-syntax-entry (make-char 'chinese-gb2312 33) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
117 (modify-syntax-entry (make-char 'chinese-gb2312 34) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
118 (modify-syntax-entry (make-char 'chinese-gb2312 41) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
119 (modify-syntax-entry ?\$A!2(B "($A!3(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
120 (modify-syntax-entry ?\$A!4(B "($A!5(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
121 (modify-syntax-entry ?\$A!6(B "($A!7(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
122 (modify-syntax-entry ?\$A!8(B "($A!9(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
123 (modify-syntax-entry ?\$A!:(B "($A!;(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
124 (modify-syntax-entry ?\$A!<(B "($A!=(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
125 (modify-syntax-entry ?\$A!>(B "($A!?(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
126 (modify-syntax-entry ?\$A!3(B ")$A!2(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
127 (modify-syntax-entry ?\$A!5(B ")$A!4(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
128 (modify-syntax-entry ?\$A!7(B ")$A!6(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
129 (modify-syntax-entry ?\$A!9(B ")$A!8(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
130 (modify-syntax-entry ?\$A!;(B ")$A!:(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
131 (modify-syntax-entry ?\$A!=(B ")$A!<(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
132 (modify-syntax-entry ?\$A!?(B ")$A!>(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
133
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
134 (modify-category-entry (make-char 'chinese-gb2312) ?c)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
135 (modify-category-entry (make-char 'chinese-gb2312) ?\|)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
136 (modify-category-entry (make-char 'chinese-gb2312 35) ?A)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
137 (modify-category-entry (make-char 'chinese-gb2312 36) ?H)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
138 (modify-category-entry (make-char 'chinese-gb2312 37) ?K)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
139 (modify-category-entry (make-char 'chinese-gb2312 38) ?G)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
140 (modify-category-entry (make-char 'chinese-gb2312 39) ?Y)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
141 (let ((row 48))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
142 (while (< row 127)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
143 (modify-category-entry (make-char 'chinese-gb2312 row) ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
144 (setq row (1+ row))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
145
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
146 ;; Chinese character set (BIG5)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
147
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
148 (let ((generic-big5-1-char (make-char 'chinese-big5-1))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
149 (generic-big5-2-char (make-char 'chinese-big5-2)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
150 (modify-syntax-entry generic-big5-1-char "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
151 (modify-syntax-entry generic-big5-2-char "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
152
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
153 (modify-category-entry generic-big5-1-char ?c)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
154 (modify-category-entry generic-big5-2-char ?c)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
155
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
156 (modify-category-entry generic-big5-1-char ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
157 (modify-category-entry generic-big5-2-char ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
158
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
159 (modify-category-entry generic-big5-1-char ?\|)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
160 (modify-category-entry generic-big5-2-char ?\|))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
161
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
162
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
163 ;; Chinese character set (CNS11643)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
164
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
165 (let ((cns-list '(chinese-cns11643-1
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
166 chinese-cns11643-2
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
167 chinese-cns11643-3
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
168 chinese-cns11643-4
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
169 chinese-cns11643-5
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
170 chinese-cns11643-6
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
171 chinese-cns11643-7))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
172 generic-char)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
173 (while cns-list
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
174 (setq generic-char (make-char (car cns-list)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
175 (modify-syntax-entry generic-char "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
176 (modify-category-entry generic-char ?c)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
177 (modify-category-entry generic-char ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
178 (modify-category-entry generic-char ?|)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
179 (setq cns-list (cdr cns-list))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
180
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
181 ;; Cyrillic character set (ISO-8859-5)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
182
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
183 (modify-category-entry (make-char 'cyrillic-iso8859-5) ?y)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
184
19958
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
185 (modify-syntax-entry (make-char 'cyrillic-iso8859-5 160) " ")
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
186 (modify-syntax-entry ?,L-(B ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
187 (modify-syntax-entry ?,Lp(B ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
188 (modify-syntax-entry ?,L}(B ".")
19958
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
189 (let ((tbl (standard-case-table)))
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
190 (set-case-syntax-pair ?,L!(B ?,Lq(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
191 (set-case-syntax-pair ?,L"(B ?,Lr(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
192 (set-case-syntax-pair ?,L#(B ?,Ls(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
193 (set-case-syntax-pair ?,L$(B ?,Lt(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
194 (set-case-syntax-pair ?,L%(B ?,Lu(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
195 (set-case-syntax-pair ?,L&(B ?,Lv(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
196 (set-case-syntax-pair ?,L'(B ?,Lw(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
197 (set-case-syntax-pair ?,L((B ?,Lx(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
198 (set-case-syntax-pair ?,L)(B ?,Ly(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
199 (set-case-syntax-pair ?,L*(B ?,Lz(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
200 (set-case-syntax-pair ?,L+(B ?,L{(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
201 (set-case-syntax-pair ?,L,(B ?,L|(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
202 (set-case-syntax-pair ?,L.(B ?,L~(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
203 (set-case-syntax-pair ?,L/(B ?,L(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
204 (set-case-syntax-pair ?,L0(B ?,LP(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
205 (set-case-syntax-pair ?,L1(B ?,LQ(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
206 (set-case-syntax-pair ?,L2(B ?,LR(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
207 (set-case-syntax-pair ?,L3(B ?,LS(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
208 (set-case-syntax-pair ?,L4(B ?,LT(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
209 (set-case-syntax-pair ?,L5(B ?,LU(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
210 (set-case-syntax-pair ?,L6(B ?,LV(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
211 (set-case-syntax-pair ?,L7(B ?,LW(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
212 (set-case-syntax-pair ?,L8(B ?,LX(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
213 (set-case-syntax-pair ?,L9(B ?,LY(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
214 (set-case-syntax-pair ?,L:(B ?,LZ(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
215 (set-case-syntax-pair ?,L;(B ?,L[(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
216 (set-case-syntax-pair ?,L<(B ?,L\(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
217 (set-case-syntax-pair ?,L=(B ?,L](B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
218 (set-case-syntax-pair ?,L>(B ?,L^(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
219 (set-case-syntax-pair ?,L?(B ?,L_(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
220 (set-case-syntax-pair ?,L@(B ?,L`(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
221 (set-case-syntax-pair ?,LA(B ?,La(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
222 (set-case-syntax-pair ?,LB(B ?,Lb(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
223 (set-case-syntax-pair ?,LC(B ?,Lc(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
224 (set-case-syntax-pair ?,LD(B ?,Ld(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
225 (set-case-syntax-pair ?,LE(B ?,Le(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
226 (set-case-syntax-pair ?,LF(B ?,Lf(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
227 (set-case-syntax-pair ?,LG(B ?,Lg(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
228 (set-case-syntax-pair ?,LH(B ?,Lh(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
229 (set-case-syntax-pair ?,LI(B ?,Li(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
230 (set-case-syntax-pair ?,LJ(B ?,Lj(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
231 (set-case-syntax-pair ?,LK(B ?,Lk(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
232 (set-case-syntax-pair ?,LL(B ?,Ll(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
233 (set-case-syntax-pair ?,LM(B ?,Lm(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
234 (set-case-syntax-pair ?,LN(B ?,Ln(B tbl)
f7ab34ae92bb Set case-table for Cyrillic characters.
Richard M. Stallman <rms@gnu.org>
parents: 18561
diff changeset
235 (set-case-syntax-pair ?,LO(B ?,Lo(B tbl))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
236
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
237 ;; Devanagari character set
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
238
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
239 (let ((deflist '(;; chars syntax category
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
240 ("$(5!!!"!#(B" "w" ?7) ; vowel-modifying diacritical mark
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
241 ; chandrabindu, anuswar, visarga
18561
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
242 ("$(5!$(B-$(5!2(B" "w" ?1) ; independent vowel
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
243 ("$(5!3(B-$(5!X(B" "w" ?0) ; consonant
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
244 ("$(5!Z(B-$(5!g(B" "w" ?8) ; matra
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
245 ("$(5!q(B-$(5!z(B" "w" ?6) ; digit
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
246 ))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
247 elm chars len syntax category to ch i)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
248 (while deflist
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
249 (setq elm (car deflist))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
250 (setq chars (car elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
251 len (length chars)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
252 syntax (nth 1 elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
253 category (nth 2 elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
254 i 0)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
255 (while (< i len)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
256 (if (= (aref chars i) ?-)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
257 (setq i (1+ i)
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
258 to (aref chars i))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
259 (setq ch (aref chars i)
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
260 to ch))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
261 (while (<= ch to)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
262 (modify-syntax-entry ch syntax)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
263 (modify-category-entry ch category)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
264 (setq ch (1+ ch)))
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
265 (setq i (1+ i)))
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
266 (setq deflist (cdr deflist))))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
267
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
268 ;; Ethiopic character set
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
269
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
270 (modify-category-entry (make-char 'ethiopic) ?e)
18304
58b39b4108d5 Set syntaxes of Ethiopic characters.
Kenichi Handa <handa@m17n.org>
parents: 18205
diff changeset
271 (modify-syntax-entry (make-char 'ethiopic) "w")
58b39b4108d5 Set syntaxes of Ethiopic characters.
Kenichi Handa <handa@m17n.org>
parents: 18205
diff changeset
272 (let ((chars '(?$(3$h(B ?$(3$i(B ?$(3$j(B ?$(3$k(B ?$(3$l(B ?$(3$m(B ?$(3$n(B ?$(3$o(B ?$(3%i(B ?$(3%t(B ?$(3%u(B ?$(3%v(B ?$(3%w(B ?$(3%x(B)))
58b39b4108d5 Set syntaxes of Ethiopic characters.
Kenichi Handa <handa@m17n.org>
parents: 18205
diff changeset
273 (while chars
58b39b4108d5 Set syntaxes of Ethiopic characters.
Kenichi Handa <handa@m17n.org>
parents: 18205
diff changeset
274 (modify-syntax-entry (car chars) ".")
58b39b4108d5 Set syntaxes of Ethiopic characters.
Kenichi Handa <handa@m17n.org>
parents: 18205
diff changeset
275 (setq chars (cdr chars))))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
276
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
277 ;; European character set (Latin-1,2,3,4,5)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
278
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
279 (modify-category-entry (make-char 'latin-iso8859-1) ?l)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
280 (modify-category-entry (make-char 'latin-iso8859-2) ?l)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
281 (modify-category-entry (make-char 'latin-iso8859-3) ?l)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
282 (modify-category-entry (make-char 'latin-iso8859-4) ?l)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
283 (modify-category-entry (make-char 'latin-iso8859-9) ?l)
26013
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
284 (modify-category-entry (make-char 'latin-iso8859-14) ?l)
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
285 (modify-category-entry (make-char 'latin-iso8859-15) ?l)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
286
20247
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
287 (modify-category-entry (make-char 'latin-iso8859-1 160) ?\ )
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
288 (modify-category-entry (make-char 'latin-iso8859-2 160) ?\ )
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
289 (modify-category-entry (make-char 'latin-iso8859-3 160) ?\ )
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
290 (modify-category-entry (make-char 'latin-iso8859-4 160) ?\ )
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
291 (modify-category-entry (make-char 'latin-iso8859-9 160) ?\ )
26013
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
292 (modify-category-entry (make-char 'latin-iso8859-14 160) ?\ )
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
293 (modify-category-entry (make-char 'latin-iso8859-15 160) ?\ )
20247
7cb27e61a1d5 New category ` '.
Karl Heuer <kwzh@gnu.org>
parents: 19958
diff changeset
294
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
295 ;; Greek character set (ISO-8859-7)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
296
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
297 (modify-category-entry (make-char 'greek-iso8859-7) ?g)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
298
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
299 (let ((c 182))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
300 (while (< c 255)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
301 (modify-syntax-entry (make-char 'greek-iso8859-7 c) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
302 (setq c (1+ c))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
303 (modify-syntax-entry (make-char 'greek-iso8859-7 160) "w") ; NBSP
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
304 (modify-syntax-entry ?,F7(B ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
305 (modify-syntax-entry ?,F;(B ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
306 (modify-syntax-entry ?,F=(B ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
307
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
308 ;; Hebrew character set (ISO-8859-8)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
309
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
310 (modify-category-entry (make-char 'hebrew-iso8859-8) ?w)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
311
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
312 (let ((c 224))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
313 (while (< c 251)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
314 (modify-syntax-entry (make-char 'hebrew-iso8859-8 c) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
315 (setq c (1+ c))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
316 (modify-syntax-entry (make-char 'hebrew-iso8859-8 160) "w") ; NBSP
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
317
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
318 ;; Indian character set (IS 13194 and other Emacs original Indian charsets)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
319
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
320 (modify-category-entry (make-char 'indian-is13194) ?i)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
321 (modify-category-entry (make-char 'indian-2-column) ?I)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
322 (modify-category-entry (make-char 'indian-1-column) ?I)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
323
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
324 (let ((deflist
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
325 '(;; chars syntax category
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
326 ("(5!"#(B" "w" ?7) ; vowel-modifying diacritical mark
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
327 ; chandrabindu, anuswar, visarga
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
328 ("(5$(B-(52(B" "w" ?1) ; base (independent) vowel
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
329 ("(53(B-(5X(B" "w" ?0) ; consonant
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
330 ("(5Z(B-(5g(B" "w" ?8) ; matra
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
331 ("(5q(B-(5z(B" "w" ?6) ; digit
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
332 ))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
333 elm chars len syntax category to ch i)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
334 (while deflist
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
335 (setq elm (car deflist))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
336 (setq chars (car elm)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
337 len (length chars)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
338 syntax (nth 1 elm)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
339 category (nth 2 elm)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
340 i 0)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
341 (while (< i len)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
342 (if (= (aref chars i) ?-)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
343 (setq i (1+ i)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
344 to (aref chars i))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
345 (setq ch (aref chars i)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
346 to ch))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
347 (while (<= ch to)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
348 (modify-syntax-entry ch syntax)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
349 (modify-category-entry ch category)
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
350 (setq ch (1+ ch)))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
351 (setq i (1+ i)))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
352 (setq deflist (cdr deflist))))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
353
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
354
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
355 ;; Japanese character set (JISX0201-kana, JISX0201-roman, JISX0208, JISX0212)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
356
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
357 (modify-category-entry (make-char 'katakana-jisx0201) ?k)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
358 (modify-category-entry (make-char 'latin-jisx0201) ?r)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
359 (modify-category-entry (make-char 'japanese-jisx0208) ?j)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
360 (modify-category-entry (make-char 'japanese-jisx0212) ?j)
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
361 (modify-category-entry (make-char 'katakana-jisx0201) ?\|)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
362 (modify-category-entry (make-char 'japanese-jisx0208) ?\|)
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
363 (modify-category-entry (make-char 'japanese-jisx0212) ?\|)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
364
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
365 ;; JISX0208
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
366 (modify-syntax-entry (make-char 'japanese-jisx0208) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
367 (modify-syntax-entry (make-char 'japanese-jisx0208 33) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
368 (modify-syntax-entry (make-char 'japanese-jisx0208 34) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
369 (modify-syntax-entry (make-char 'japanese-jisx0208 40) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
370 (let ((chars '(?$B!<(B ?$B!+(B ?$B!,(B ?$B!3(B ?$B!4(B ?$B!5(B ?$B!6(B ?$B!7(B ?$B!8(B ?$B!9(B ?$B!:(B ?$B!;(B)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
371 (while chars
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
372 (modify-syntax-entry (car chars) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
373 (setq chars (cdr chars))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
374 (modify-syntax-entry ?\$B!J(B "($B!K(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
375 (modify-syntax-entry ?\$B!N(B "($B!O(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
376 (modify-syntax-entry ?\$B!P(B "($B!Q(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
377 (modify-syntax-entry ?\$B!V(B "($B!W(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
378 (modify-syntax-entry ?\$B!X(B "($B!Y(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
379 (modify-syntax-entry ?\$B!K(B ")$B!J(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
380 (modify-syntax-entry ?\$B!O(B ")$B!N(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
381 (modify-syntax-entry ?\$B!Q(B ")$B!P(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
382 (modify-syntax-entry ?\$B!W(B ")$B!V(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
383 (modify-syntax-entry ?\$B!Y(B ")$B!X(B")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
384
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
385 (modify-category-entry (make-char 'japanese-jisx0208 35) ?A)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
386 (modify-category-entry (make-char 'japanese-jisx0208 36) ?H)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
387 (modify-category-entry (make-char 'japanese-jisx0208 37) ?K)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
388 (modify-category-entry (make-char 'japanese-jisx0208 38) ?G)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
389 (modify-category-entry (make-char 'japanese-jisx0208 39) ?Y)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
390 (let ((row 48))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
391 (while (< row 127)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
392 (modify-category-entry (make-char 'japanese-jisx0208 row) ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
393 (setq row (1+ row))))
17296
dc3f449803f6 Change a category of one Japanese character.
Kenichi Handa <handa@m17n.org>
parents: 17078
diff changeset
394 (modify-category-entry ?$B!<(B ?K)
dc3f449803f6 Change a category of one Japanese character.
Kenichi Handa <handa@m17n.org>
parents: 17078
diff changeset
395 (let ((chars '(?$B!+(B ?$B!,(B)))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
396 (while chars
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
397 (modify-category-entry (car chars) ?K)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
398 (modify-category-entry (car chars) ?H)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
399 (setq chars (cdr chars))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
400 (let ((chars '(?$B!3(B ?$B!4(B ?$B!5(B ?$B!6(B ?$B!7(B ?$B!8(B ?$B!9(B ?$B!:(B ?$B!;(B)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
401 (while chars
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
402 (modify-category-entry (car chars) ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
403 (setq chars (cdr chars))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
404
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
405 ;; JISX0212
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
406 (modify-syntax-entry (make-char 'japanese-jisx0212) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
407 (modify-syntax-entry (make-char 'japanese-jisx0212 33) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
408 (modify-syntax-entry (make-char 'japanese-jisx0212 34) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
409 (modify-syntax-entry (make-char 'japanese-jisx0212 35) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
410
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
411 (modify-category-entry (make-char 'japanese-jisx0212 ) ?C)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
412
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
413 ;; JISX0201-Kana
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
414 (modify-syntax-entry (make-char 'katakana-jisx0201) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
415 (let ((chars '(?(I!(B ?(I"(B ?(I#(B ?(I$(B ?(I%(B)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
416 (while chars
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
417 (modify-syntax-entry (car chars) ".")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
418 (setq chars (cdr chars))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
419
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
420 ;; Korean character set (KSC5601)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
421
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
422 (modify-syntax-entry (make-char 'korean-ksc5601) "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
423 (modify-syntax-entry (make-char 'korean-ksc5601 33) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
424 (modify-syntax-entry (make-char 'korean-ksc5601 34) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
425 (modify-syntax-entry (make-char 'korean-ksc5601 38) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
426 (modify-syntax-entry (make-char 'korean-ksc5601 39) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
427 (modify-syntax-entry (make-char 'korean-ksc5601 40) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
428 (modify-syntax-entry (make-char 'korean-ksc5601 41) "_")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
429
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
430 (modify-category-entry (make-char 'korean-ksc5601) ?h)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
431 (modify-category-entry (make-char 'korean-ksc5601 35) ?A)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
432 (modify-category-entry (make-char 'korean-ksc5601 37) ?G)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
433 (modify-category-entry (make-char 'korean-ksc5601 42) ?H)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
434 (modify-category-entry (make-char 'korean-ksc5601 43) ?K)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
435 (modify-category-entry (make-char 'korean-ksc5601 44) ?Y)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
436
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
437 ;; Lao character set
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
438
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
439 (modify-category-entry (make-char 'lao) ?o)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
440
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
441 (let ((deflist '(;; chars syntax category
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
442 ("(1!(B-(1N(B" "w" ?0) ; consonant
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
443 ("(1PRS]`(B-(1d(B" "w" ?1) ; vowel base
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
444 ("(1QT(B-(1W[m(B" "w" ?2) ; vowel upper
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
445 ("(1XY(B" "w" ?3) ; vowel lower
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
446 ("(1h(B-(1l(B" "w" ?4) ; tone mark
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
447 ("(1\(B" "w" ?9) ; semivowel lower
18561
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
448 ("(1p(B-(1y(B" "w" ?6) ; digit
26885
c151d3ae1794 Fix cateogries of Lao symbols.
Kenichi Handa <handa@m17n.org>
parents: 26013
diff changeset
449 ("(1Of(B" "_" ?5) ; symbol
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
450 ))
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
451 elm chars len syntax category to ch i)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
452 (while deflist
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
453 (setq elm (car deflist))
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
454 (setq chars (car elm)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
455 len (length chars)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
456 syntax (nth 1 elm)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
457 category (nth 2 elm)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
458 i 0)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
459 (while (< i len)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
460 (if (= (aref chars i) ?-)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
461 (setq i (1+ i)
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
462 to (aref chars i))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
463 (setq ch (aref chars i)
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
464 to ch))
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
465 (while (<= ch to)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
466 (modify-syntax-entry ch syntax)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
467 (modify-category-entry ch category)
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
468 (setq ch (1+ ch)))
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
469 (setq i (1+ i)))
17078
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
470 (setq deflist (cdr deflist))))
874b471d6635 Remove prefix "coding-system-" from coding system symbol names.
Kenichi Handa <handa@m17n.org>
parents: 17071
diff changeset
471
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
472 ;; Thai character set (TIS620)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
473
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
474 (modify-category-entry (make-char 'thai-tis620) ?t)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
475
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
476 (let ((deflist '(;; chars syntax category
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
477 (",T!(B-,TCEG(B-,TN(B" "w" ?0) ; consonant
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
478 (",TDFPRS`(B-,Te(B" "w" ?1) ; vowel base
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
479 (",TQT(B-,TWgn(B" "w" ?2) ; vowel upper
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
480 (",TX(B-,TZ(B" "w" ?3) ; vowel lower
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
481 (",Th(B-,Tm(B" "w" ?4) ; tone mark
18561
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
482 (",Tp(B-,Ty(B" "w" ?6) ; digit
f3c28fd5118e Modify docstring of char category
Kenichi Handa <handa@m17n.org>
parents: 18377
diff changeset
483 (",TOf_oz{(B" "_" ?5) ; symbol
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
484 ))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
485 elm chars len syntax category to ch i)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
486 (while deflist
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
487 (setq elm (car deflist))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
488 (setq chars (car elm)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
489 len (length chars)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
490 syntax (nth 1 elm)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
491 category (nth 2 elm)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
492 i 0)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
493 (while (< i len)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
494 (if (= (aref chars i) ?-)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
495 (setq i (1+ i)
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
496 to (aref chars i))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
497 (setq ch (aref chars i)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
498 to ch))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
499 (while (<= ch to)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
500 (modify-syntax-entry ch syntax)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
501 (modify-category-entry ch category)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
502 (setq ch (1+ ch)))
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
503 (setq i (1+ i)))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
504 (setq deflist (cdr deflist))))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
505
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
506 ;; Tibetan character set
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
507
24208
6964e11724dc Set category `q' for all characters
Kenichi Handa <handa@m17n.org>
parents: 23527
diff changeset
508 (modify-category-entry (make-char 'tibetan) ?q)
6964e11724dc Set category `q' for all characters
Kenichi Handa <handa@m17n.org>
parents: 23527
diff changeset
509 (modify-category-entry (make-char 'tibetan-1-column) ?q)
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
510
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
511 (let ((deflist '(;; chars syntax category
29362
038c13f83357 Fix syntax/category setting of Tibetan characters.
Kenichi Handa <handa@m17n.org>
parents: 27691
diff changeset
512 ("$(7"!(B-$(7"J"K(B" "w" ?0) ; consonant
038c13f83357 Fix syntax/category setting of Tibetan characters.
Kenichi Handa <handa@m17n.org>
parents: 27691
diff changeset
513 ("$(7#!(B-$(7#J#K#L#M!"!#(B" "w" ?0) ;
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
514 ("$(7$!(B-$(7$e(B" "w" ?0) ;
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
515 ("$(7%!(B-$(7%u(B" "w" ?0) ;
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
516 ("$(7"S"["\"]"^"a(B" "w" ?2) ; upper vowel
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
517 ("$(7"_"c"d"g"h"i"j"k"l(B" "w" ?2) ; upper modifier
29362
038c13f83357 Fix syntax/category setting of Tibetan characters.
Kenichi Handa <handa@m17n.org>
parents: 27691
diff changeset
518 ("$(7!I"Q"R"U"e!e!g(B" "w" ?3) ; lowel vowel/modifier
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
519 ("$(7!P(B-$(7!Y!Z(B-$(7!c(B" "w" ?6) ; digit
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
520 ("$(7!;!=(B-$(7!B!D"`(B" "." ?|) ; line-break char
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
521 ("$(8!;!=!?!@!A!D"`(B" "." ?|) ;
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
522 ("$(7!8!;!=(B-$(7!B!D"`!m!d(B" "." ?>) ; prohibition
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
523 ("$(8!;!=!?!@!A!D"`(B" "." ?>) ;
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
524 ("$(7!0(B-$(7!:!l#R#S"f(B" "." ?<) ; prohibition
29362
038c13f83357 Fix syntax/category setting of Tibetan characters.
Kenichi Handa <handa@m17n.org>
parents: 27691
diff changeset
525 ("$(7!C!E(B-$(7!H!J(B-$(7!O!f!h(B-$(7!k!n!o#O#P(B-$(7#`(B" "." ?q) ; others
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
526 ))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
527 elm chars len syntax category to ch i)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
528 (while deflist
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
529 (setq elm (car deflist))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
530 (setq chars (car elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
531 len (length chars)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
532 syntax (nth 1 elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
533 category (nth 2 elm)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
534 i 0)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
535 (while (< i len)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
536 (if (= (aref chars i) ?-)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
537 (setq i (1+ i)
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
538 to (aref chars i))
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
539 (setq ch (aref chars i)
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
540 to ch))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
541 (while (<= ch to)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
542 (modify-syntax-entry ch syntax)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
543 (modify-category-entry ch category)
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
544 (setq ch (1+ ch)))
20843
b60871b4710f Use aref instead of sref.
Kenichi Handa <handa@m17n.org>
parents: 20734
diff changeset
545 (setq i (1+ i)))
17753
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
546 (setq deflist (cdr deflist))))
de6be7f3b904 Set syntax and category for Devanagari, Thai, and
Kenichi Handa <handa@m17n.org>
parents: 17296
diff changeset
547
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
548 ;; Vietnamese character set
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
549
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
550 (let ((lower (make-char 'vietnamese-viscii-lower))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
551 (upper (make-char 'vietnamese-viscii-upper)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
552 (modify-syntax-entry lower "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
553 (modify-syntax-entry upper "w")
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
554 (modify-category-entry lower ?v)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
555 (modify-category-entry upper ?v)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
556 (modify-category-entry lower ?l) ; To make a word with
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
557 (modify-category-entry upper ?l) ; latin characters.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
558 )
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
559
27691
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
560 (let ((tbl (standard-case-table))
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
561 (i 32))
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
562 (while (< i 128)
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
563 (set-case-syntax-pair (make-char 'vietnamese-viscii-upper i)
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
564 (make-char 'vietnamese-viscii-lower i)
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
565 tbl)
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
566 (setq i (1+ i))))
5ed8dd27c116 Setup case table for Vietnamese.
Kenichi Handa <handa@m17n.org>
parents: 26885
diff changeset
567
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
568
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
569 ;;; Setting word boundary.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
570
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
571 (setq word-combining-categories
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
572 '((?l . ?l)))
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
573
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
574 (setq word-separating-categories ; (2-byte character sets)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
575 '((?A . ?K) ; Alpha numeric - Katakana
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
576 (?A . ?C) ; Alpha numeric - Chinese
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
577 (?H . ?A) ; Hiragana - Alpha numeric
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
578 (?H . ?K) ; Hiragana - Katakana
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
579 (?H . ?C) ; Hiragana - Chinese
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
580 (?K . ?A) ; Katakana - Alpha numeric
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
581 (?K . ?C) ; Katakana - Chinese
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
582 (?C . ?A) ; Chinese - Alpha numeric
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
583 (?C . ?K) ; Chinese - Katakana
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
584 ))
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
585
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
586
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
587 ;; For each character set, put the information of the most proper
24782
8f65cd6729b5 Typo fixed; prefered->preferred.
Kenichi Handa <handa@m17n.org>
parents: 24256
diff changeset
588 ;; coding system to encode it by `preferred-coding-system' property.
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
589
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
590 (let ((l '((latin-iso8859-1 . iso-latin-1)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
591 (latin-iso8859-2 . iso-latin-2)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
592 (latin-iso8859-3 . iso-latin-3)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
593 (latin-iso8859-4 . iso-latin-4)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
594 (thai-tis620 . thai-tis620)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
595 (greek-iso8859-7 . greek-iso-8bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
596 (arabic-iso8859-6 . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
597 (hebrew-iso8859-8 . hebrew-iso-8bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
598 (katakana-jisx0201 . japanese-shift-jis)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
599 (latin-jisx0201 . japanese-shift-jis)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
600 (cyrillic-iso8859-5 . cyrillic-iso-8bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
601 (latin-iso8859-9 . iso-latin-5)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
602 (japanese-jisx0208-1978 . iso-2022-jp)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
603 (chinese-gb2312 . cn-gb-2312)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
604 (japanese-jisx0208 . iso-2022-jp)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
605 (korean-ksc5601 . iso-2022-kr)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
606 (japanese-jisx0212 . iso-2022-jp)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
607 (chinese-cns11643-1 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
608 (chinese-cns11643-2 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
609 (chinese-big5-1 . chinese-big5)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
610 (chinese-big5-2 . chinese-big5)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
611 (chinese-sisheng . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
612 (ipa . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
613 (vietnamese-viscii-lower . vietnamese-viscii)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
614 (vietnamese-viscii-upper . vietnamese-viscii)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
615 (arabic-digit . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
616 (arabic-1-column . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
617 (ascii-right-to-left . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
618 (lao . lao)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
619 (arabic-2-column . iso-2022-7bit)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
620 (indian-is13194 . devanagari)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
621 (indian-1-column . devanagari)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
622 (tibetan-1-column . tibetan)
24256
47e6aa168a66 Let ethiopic use iso-2022-7bit.
Kenichi Handa <handa@m17n.org>
parents: 24208
diff changeset
623 (ethiopic . iso-2022-7bit)
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
624 (chinese-cns11643-3 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
625 (chinese-cns11643-4 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
626 (chinese-cns11643-5 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
627 (chinese-cns11643-6 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
628 (chinese-cns11643-7 . iso-2022-cn)
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
629 (indian-2-column . devanagari)
26013
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
630 (tibetan . tibetan)
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
631 (latin-iso8859-14 . iso-latin-8)
987e55950346 Add latin-iso8859-1[45].
Dave Love <fx@gnu.org>
parents: 25499
diff changeset
632 (latin-iso8859-15 . iso-latin-9))))
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
633 (while l
24782
8f65cd6729b5 Typo fixed; prefered->preferred.
Kenichi Handa <handa@m17n.org>
parents: 24256
diff changeset
634 (put-charset-property (car (car l)) 'preferred-coding-system (cdr (car l)))
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
635 (setq l (cdr l))))
23493
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
636
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
637
23527
06e8c3b9deec Setup charset property nospace-between-words.
Kenichi Handa <handa@m17n.org>
parents: 23493
diff changeset
638 ;; Setup auto-fill-chars for charsets that should invoke auto-filling.
06e8c3b9deec Setup charset property nospace-between-words.
Kenichi Handa <handa@m17n.org>
parents: 23493
diff changeset
639 ;; SPACE and NEWLIE are already set. Also put `nospace-between-words'
06e8c3b9deec Setup charset property nospace-between-words.
Kenichi Handa <handa@m17n.org>
parents: 23493
diff changeset
640 ;; property to the charsets.
23493
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
641 (let ((l '(katakana-jisx0201
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
642 japanese-jisx0208 japanese-jisx0212
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
643 chinese-gb2312 chinese-big5-1 chinese-big5-2)))
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
644 (while l
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
645 (aset auto-fill-chars (make-char (car l)) t)
23527
06e8c3b9deec Setup charset property nospace-between-words.
Kenichi Handa <handa@m17n.org>
parents: 23493
diff changeset
646 (put-charset-property (car l) 'nospace-between-words t)
23493
d82b305ac37b Setup auto-fill-chars.
Kenichi Handa <handa@m17n.org>
parents: 22529
diff changeset
647 (setq l (cdr l))))
20734
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
648
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
649 ;;; Local Variables:
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
650 ;;; coding: iso-2022-7bit
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
651 ;;; End:
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
652
179dbdbc3882 Put `prefered-coding-system'
Kenichi Handa <handa@m17n.org>
parents: 20247
diff changeset
653 ;;; end of characters.el