aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenichi Handa2000-07-27 06:22:42 +0000
committerKenichi Handa2000-07-27 06:22:42 +0000
commit53a1db8067165cd7dec8087aae276ba7b2890ae7 (patch)
tree25807d865ba91ffbad64560518884cea998d9610
parent5ddcadb8e3a23725045e3b65a3264bf13df72020 (diff)
downloademacs-53a1db8067165cd7dec8087aae276ba7b2890ae7.tar.gz
emacs-53a1db8067165cd7dec8087aae276ba7b2890ae7.zip
(cyrillic-koi8): Use `safe-chars' property instead of `safe-charsets'.
(cyrillic-alternativnyj): Likewise. (ccl-encode-alternativnyj): Don't check the charset cyrillic-iso8859-5.
-rw-r--r--lisp/language/cyrillic.el18
1 files changed, 14 insertions, 4 deletions
diff --git a/lisp/language/cyrillic.el b/lisp/language/cyrillic.el
index e81698c3550..63810434f47 100644
--- a/lisp/language/cyrillic.el
+++ b/lisp/language/cyrillic.el
@@ -112,7 +112,12 @@
112 ;; will have to forgive us. 112 ;; will have to forgive us.
113 ?R "KOI8 8-bit encoding for Cyrillic (MIME: KOI8-R)" 113 ?R "KOI8 8-bit encoding for Cyrillic (MIME: KOI8-R)"
114 '(ccl-decode-koi8 . ccl-encode-koi8) 114 '(ccl-decode-koi8 . ccl-encode-koi8)
115 '((safe-charsets ascii cyrillic-iso8859-5) 115 `((safe-chars . ,(let ((table (make-char-table 'safe-chars))
116 (i 0))
117 (while (< i 256)
118 (aset table (aref cyrillic-koi8-r-decode-table i) t)
119 (setq i (1+ i)))
120 table))
116 (mime-charset . koi8-r) 121 (mime-charset . koi8-r)
117 (valid-codes (0 . 127) 163 179 (192 . 255)) 122 (valid-codes (0 . 127) 163 179 (192 . 255))
118 (charset-origin-alist (cyrillic-iso8859-5 "KOI8-R" 123 (charset-origin-alist (cyrillic-iso8859-5 "KOI8-R"
@@ -190,8 +195,7 @@
190 `(1 195 `(1
191 ((loop 196 ((loop
192 (read-multibyte-character r0 r1) 197 (read-multibyte-character r0 r1)
193 (if (r0 == ,(charset-id 'cyrillic-iso8859-5)) 198 (translate-character cyrillic-alternativnyj-encode-table r0 r1)
194 (translate-character cyrillic-alternativnyj-encode-table r0 r1))
195 (write-repeat r1)))) 199 (write-repeat r1))))
196 "CCL program to encode Alternativnyj.") 200 "CCL program to encode Alternativnyj.")
197 201
@@ -199,7 +203,13 @@
199 'cyrillic-alternativnyj 4 ?A 203 'cyrillic-alternativnyj 4 ?A
200 "ALTERNATIVNYJ 8-bit encoding for Cyrillic" 204 "ALTERNATIVNYJ 8-bit encoding for Cyrillic"
201 '(ccl-decode-alternativnyj . ccl-encode-alternativnyj) 205 '(ccl-decode-alternativnyj . ccl-encode-alternativnyj)
202 '((safe-charsets ascii cyrillic-iso8859-5) 206 `((safe-chars . ,(let ((table (make-char-table 'safe-chars))
207 (i 0))
208 (while (< i 256)
209 (aset table (aref cyrillic-alternativnyj-decode-table i)
210 t)
211 (setq i (1+ i)))
212 table))
203 (valid-codes (0 . 175) (224 . 241) 255) 213 (valid-codes (0 . 175) (224 . 241) 255)
204 (charset-origin-alist (cyrillic-iso8859-5 "ALTERNATIVNYJ" 214 (charset-origin-alist (cyrillic-iso8859-5 "ALTERNATIVNYJ"
205 cyrillic-encode-koi8-r-char)))) 215 cyrillic-encode-koi8-r-char))))