comparison lisp/mule/cyrillic.el @ 357:4711e16a8e49 r21-1-8

Import from CVS: tag r21-1-8
author cvs
date Mon, 13 Aug 2007 10:57:04 +0200
parents 4f79e16b1112
children
comparison
equal deleted inserted replaced
356:e85f639a32f3 357:4711e16a8e49
78 (tutorial . "TUTORIAL.ru") 78 (tutorial . "TUTORIAL.ru")
79 (coding-system . (iso-8859-5)) 79 (coding-system . (iso-8859-5))
80 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") 80 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!")
81 (documentation . ("Support for Cyrillic ISO-8859-5." 81 (documentation . ("Support for Cyrillic ISO-8859-5."
82 . describe-cyrillic-environment-map)))) 82 . describe-cyrillic-environment-map))))
83
84 (defun setup-cyrillic-iso-environment ()
85 "Setup multilingual environment (MULE) for Cyrillic ISO-8859-5 users."
86 (interactive)
87 (setup-english-environment)
88 (set-coding-category-system 'iso-8-1 'iso-8859-5)
89 (set-coding-priority-list
90 '(iso-8-1))
91 (set-default-coding-systems 'iso-8859-5))
83 92
84 ;; KOI-8 staff 93 ;; KOI-8 staff
85 94
86 (define-ccl-program ccl-decode-koi8 95 (define-ccl-program ccl-decode-koi8
87 '(3 96 '(3
171 (tutorial . "TUTORIAL.ru") 180 (tutorial . "TUTORIAL.ru")
172 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") 181 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!")
173 (documentation . ("Support for Cyrillic KOI-8." 182 (documentation . ("Support for Cyrillic KOI-8."
174 . describe-cyrillic-environment-map)))) 183 . describe-cyrillic-environment-map))))
175 184
185 (defun setup-cyrillic-koi8-environment ()
186 "Setup multilingual environment (MULE) for Cyrillic KOI8 users."
187 (interactive)
188 (setup-english-environment)
189 (set-coding-category-system 'iso-8-1 'koi8-r)
190 (set-coding-priority-list
191 '(iso-8-1))
192 (set-default-coding-systems 'koi8-r))
193
176 ;;; ALTERNATIVNYJ staff 194 ;;; ALTERNATIVNYJ staff
177 195
178 (define-ccl-program ccl-decode-alternativnyj 196 (define-ccl-program ccl-decode-alternativnyj
179 '(3 197 '(3
180 ((read r0) 198 ((read r0)
255 (tutorial . "TUTORIAL.ru") 273 (tutorial . "TUTORIAL.ru")
256 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") 274 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!")
257 (documentation . ("Support for Cyrillic ALTERNATIVNYJ." 275 (documentation . ("Support for Cyrillic ALTERNATIVNYJ."
258 . describe-cyrillic-environment-map)))) 276 . describe-cyrillic-environment-map))))
259 277
278 (defun setup-cyrillic-alternativnyj-environment ()
279 "Setup multilingual environment (MULE) for Cyrillic ALTERNATIVNYJ users."
280 (interactive)
281 (setup-english-environment)
282 (set-coding-category-system 'iso-8-1 'alternativnyj)
283 (set-coding-priority-list
284 '(iso-8-1))
285 (set-default-coding-systems 'alternativnyj))
286
260 ;;; GENERAL 287 ;;; GENERAL
261 288
262 (defun setup-cyrillic-environment () 289 (defun setup-cyrillic-environment ()
263 "Setup multilingual environment for Cyrillic users." 290 "Setup multilingual environment for Cyrillic users."
264 (interactive) 291 (interactive)
265 (setq primary-language "Cyrillic") 292 (set-coding-category-system 'iso-8-1 'iso-8859-5)
266 293 (set-coding-priority-list
267 (setq coding-category-iso-8-1 'iso-8859-5) 294 '(iso-8-1))
268 295
269 (set-coding-priority 296 (set-default-coding-systems 'iso-8859-5)
270 '(coding-category-iso-7 297
271 coding-category-iso-8-1)) 298 (setq default-input-method 'cyrillic-yawerty)
272
273 (setq-default buffer-file-coding-system 'iso-8859-5)
274 (set-terminal-coding-system 'iso-8859-5)
275 (set-keyboard-coding-system 'iso-8859-5)
276
277 (setq default-input-method '("Cyrillic" . "quail-yawerty"))
278 ) 299 )
279
280 (defun describe-cyrillic-support ()
281 "Describe how Emacs support Cyrillic."
282 (interactive)
283 (describe-language-support-internal "Cyrillic"))
284 300
285 (set-language-info-alist 301 (set-language-info-alist
286 "Cyrillic" '((setup-function . setup-cyrillic-environment) 302 "Cyrillic" '((setup-function . setup-cyrillic-environment)
287 (describe-function . describe-cyrillic-support)
288 (charset . (cyrillic-iso8859-5)) 303 (charset . (cyrillic-iso8859-5))
289 (tutorial . "TUTORIAL.ru") 304 (tutorial . "TUTORIAL.ru")
290 (coding-system . (iso-8859-5 koi8-r alternativnyj)) 305 (coding-system . (iso-8859-5 koi8-r alternativnyj))
291 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") 306 (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!")
292 (documentation . nil))) 307 (documentation . nil)))