annotate lisp/language/english.el @ 197:acd284d43ca1 r20-3b25

Import from CVS: tag r20-3b25
author cvs
date Mon, 13 Aug 2007 10:00:02 +0200
parents 929b76928fce
children e45d5e7c476e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
1 ;;; english.el --- English support
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
2
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
3 ;; Copyright (C) 1997 Electrotechnical Laboratory, JAPAN.
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
4 ;; Licensed to the Free Software Foundation.
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
5 ;; Copyright (C) 1997 MORIOKA Tomohiko
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
6
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
7 ;; Keywords: multibyte character, character set, syntax, category
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
8
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
9 ;; This file is part of XEmacs.
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
10
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
11 ;; XEmacs is free software; you can redistribute it and/or modify it
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
12 ;; under the terms of the GNU General Public License as published by
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
13 ;; the Free Software Foundation; either version 2, or (at your option)
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
14 ;; any later version.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
15
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
16 ;; XEmacs is distributed in the hope that it will be useful, but
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
17 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
18 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
19 ;; General Public License for more details.
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
20
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
21 ;; You should have received a copy of the GNU General Public License
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
22 ;; along with XEmacs; see the file COPYING. If not, write to the Free
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
23 ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
24 ;; 02111-1307, USA.
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
25
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
26 ;;; Commentary:
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
27
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
28 ;; We need nothing special to support English on Emacs. Selecting
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
29 ;; English as a language environment is one of the ways to reset
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
30 ;; various multilingual environment to the original settting.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
31
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
32 ;; modified for XEmacs by MORIOKA Tomohiko
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
33
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
34 ;;; Code
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
35
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
36 (defun setup-english-environment ()
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
37 "Reset multilingual environment of Emacs to the default status.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
38 The default status is as follows.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
39
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
40 The default value of enable-multibyte-characters is t.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
41
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
42 The default value of buffer-file-coding-system is nil.
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
43 The coding system for terminal output is nil.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
44 The coding system for keyboard input is nil.
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
45
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
46 The order of priorities of coding categories and the coding system
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
47 bound to each category are as follows
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
48 coding category coding system
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
49 --------------------------------------------------
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
50 coding-category-iso-7 iso-2022-7bit
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
51 coding-category-iso-8-1 iso-8859-1
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
52 coding-category-iso-8-2 iso-8859-1
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
53 coding-category-iso-7-else iso-2022-7bit-lock
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
54 coding-category-iso-8-else iso-2022-8bit-ss2
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
55 coding-category-emacs-mule no-conversion
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
56 coding-category-sjis japanese-shift-jis
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
57 coding-category-big5 chinese-big5
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
58 coding-category-binarry no-conversion
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
59 "
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
60 (interactive)
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
61 (setq-default enable-multibyte-characters t)
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
62
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
63 (setq coding-category-iso-7 'iso-2022-7bit
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
64 coding-category-iso-8-1 'iso-8859-1
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
65 coding-category-iso-8-2 'iso-8859-1
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
66 coding-category-iso-7-else 'iso-2022-7bit-lock
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
67 coding-category-iso-8-else 'iso-2022-8bit-ss2
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
68 coding-category-emacs-mule 'no-conversion
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
69 coding-category-sjis 'japanese-shift-jis
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
70 coding-category-big5 'chinese-big5
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
71 coding-category-binary 'binary)
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
72
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
73 (set-coding-priority
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
74 '(coding-category-iso-7
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
75 coding-category-iso-8-2
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
76 coding-category-iso-8-1
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
77 coding-category-iso-7-else
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
78 coding-category-iso-8-else
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
79 coding-category-emacs-mule
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
80 coding-category-raw-text
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
81 coding-category-sjis
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
82 coding-category-big5
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
83 coding-category-binary))
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
84
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
85 (set-default-coding-systems nil)
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
86 ;; Don't alter the terminal and keyboard coding systems here.
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
87 ;; The terminal still supports the same coding system
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
88 ;; that it supported a minute ago.
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
89 ;;; (set-terminal-coding-system-internal nil)
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
90 ;;; (set-keyboard-coding-system-internal nil)
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
91
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
92 (setq nonascii-insert-offset 0))
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
93
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
94 (set-language-info-alist
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
95 "English" '((setup-function . setup-english-environment)
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
96 (tutorial . "TUTORIAL")
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
97 (charset . (ascii))
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
98 (sample-text . "Hello!, Hi!, How are you?")
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
99 (documentation . "\
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
100 Nothing special is needed to handle English.")
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
101 ))
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
102
197
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
103 ;; Make "ASCII" an alias of "English" language environment.
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
104 (set-language-info-alist
acd284d43ca1 Import from CVS: tag r20-3b25
cvs
parents: 171
diff changeset
105 "ASCII" (cdr (assoc "English" language-info-alist)))
159
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
106
3bb7ccffb0c0 Import from CVS: tag r20-3b6
cvs
parents:
diff changeset
107 ;;; english.el ends here