annotate lisp/mule/japanese.el @ 355:182f72e8cd0d r21-1-7

Import from CVS: tag r21-1-7
author cvs
date Mon, 13 Aug 2007 10:56:21 +0200
parents 4f79e16b1112
children 4711e16a8e49
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
333
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
1 ;;; japanese.el --- Japanese support
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
2
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
3 ;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
4 ;; Licensed to the Free Software Foundation.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
5 ;; Copyright (C) 1997 MORIOKA Tomohiko
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
6
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
7 ;; Keywords: multilingual, Japanese
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
8
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
9 ;; This file is part of XEmacs.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
10
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
11 ;; XEmacs is free software; you can redistribute it and/or modify it
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
12 ;; under the terms of the GNU General Public License as published by
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
13 ;; the Free Software Foundation; either version 2, or (at your option)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
14 ;; any later version.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
15
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
16 ;; XEmacs is distributed in the hope that it will be useful, but
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
17 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
18 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
19 ;; General Public License for more details.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
20
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
21 ;; You should have received a copy of the GNU General Public License
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
22 ;; along with XEmacs; see the file COPYING. If not, write to the Free
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
23 ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
24 ;; 02111-1307, USA.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
25
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
26 ;;; Commentary:
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
27
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
28 ;; For Japanese, character sets JISX0201, JISX0208, JISX0212 are
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
29 ;; supported.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
30
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
31 ;;; Code:
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
32
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
33 ;;; Syntax of Japanese characters.
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
34 (modify-syntax-entry 'katakana-jisx0201 "w")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
35 (modify-syntax-entry 'japanese-jisx0212 "w")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
36
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
37 (modify-syntax-entry 'japanese-jisx0208 "w")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
38 (loop for row in '(33 34 40)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
39 do (modify-syntax-entry `[japanese-jisx0208 ,row] "_"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
40 (loop for char in '(?$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)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
41 do (modify-syntax-entry char "w"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
42 (modify-syntax-entry ?\$B!J(B "($B!K(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
43 (modify-syntax-entry ?\$B!N(B "($B!O(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
44 (modify-syntax-entry ?\$B!P(B "($B!Q(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
45 (modify-syntax-entry ?\$B!V(B "($B!W(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
46 (modify-syntax-entry ?\$B!X(B "($B!Y(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
47 (modify-syntax-entry ?\$B!K(B ")$B!J(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
48 (modify-syntax-entry ?\$B!O(B ")$B!N(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
49 (modify-syntax-entry ?\$B!Q(B ")$B!P(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
50 (modify-syntax-entry ?\$B!W(B ")$B!V(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
51 (modify-syntax-entry ?\$B!Y(B ")$B!X(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
52
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
53 ;;; Character categories S, A, H, K, G, Y, and C
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
54 (define-category ?S "Japanese 2-byte symbol character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
55 (modify-category-entry [japanese-jisx0208 33] ?S)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
56 (modify-category-entry [japanese-jisx0208 34] ?S)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
57 (modify-category-entry [japanese-jisx0208 40] ?S)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
58 (define-category ?A "Japanese 2-byte Alphanumeric character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
59 (modify-category-entry [japanese-jisx0208 35] ?A)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
60 (define-category ?H "Japanese 2-byte Hiragana character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
61 (modify-category-entry [japanese-jisx0208 36] ?H)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
62 (define-category ?K "Japanese 2-byte Katakana character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
63 (modify-category-entry [japanese-jisx0208 37] ?K)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
64 (define-category ?G "Japanese 2-byte Greek character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
65 (modify-category-entry [japanese-jisx0208 38] ?G)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
66 (define-category ?Y "Japanese 2-byte Cyrillic character.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
67 (modify-category-entry [japanese-jisx0208 39] ?Y)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
68 (define-category ?C "Japanese 2-byte Kanji characters.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
69 (loop for row from 48 to 126
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
70 do (modify-category-entry `[japanese-jisx0208 ,row] ?C))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
71 (loop for char in '(?$B!<(B ?$B!+(B ?$B!,(B)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
72 do (modify-category-entry char ?K)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
73 (modify-category-entry char ?H))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
74 (loop for char in '(?$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)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
75 do (modify-category-entry char ?C))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
76 (modify-category-entry 'japanese-jisx0212 ?C)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
77
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
78 (defvar japanese-word-regexp
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
79 "\\cA+\\cH*\\|\\cK+\\cH*\\|\\cC+\\cH*\\|\\cH+\\|\\ck+\\|\\sw+"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
80 "Regular expression used to match a Japanese word.")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
81
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
82 (set-word-regexp japanese-word-regexp)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
83 (setq forward-word-regexp "\\w\\>")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
84 (setq backward-word-regexp "\\<\\w")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
85
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
86 ;;; Paragraph setting
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
87 (setq sentence-end
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
88 (concat
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
89 "\\("
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
90 "\\("
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
91 "[.?!][]\"')}]*"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
92 "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
93 "[$B!%!)!*(B][$B!O!I!G!K!Q!M!S!U!W!Y(B]*"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
94 "\\)"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
95 "\\($\\|\t\\| \\)"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
96 "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
97 "$B!#(B"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
98 "\\)"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
99 "[ \t\n]*"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
100 (setq paragraph-start "^[ $B!!(B\t\n\f]")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
101 (setq paragraph-separate "^[ $B!!(B\t\f]*$")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
102
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
103 ;; EGG specific setup
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
104 (define-egg-environment 'japanese
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
105 "Japanese settings for egg."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
106 (lambda ()
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
107 (when (not (featurep 'egg-jpn))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
108 (load "its-hira")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
109 (load "its-kata")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
110 (load "its-hankaku")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
111 (load "its-zenkaku")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
112 (setq its:*standard-modes*
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
113 (append
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
114 (list (its:get-mode-map "roma-kana")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
115 (its:get-mode-map "roma-kata")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
116 (its:get-mode-map "downcase")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
117 (its:get-mode-map "upcase")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
118 (its:get-mode-map "zenkaku-downcase")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
119 (its:get-mode-map "zenkaku-upcase"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
120 its:*standard-modes*))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
121 (provide 'egg-jpn))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
122 (setq wnn-server-type 'jserver)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
123 ;; Can't do this here any more. Must do it when selecting egg-wnn
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
124 ;; or egg-sj3
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
125 ;; (setq egg-default-startup-file "eggrc-wnn")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
126 (setq-default its:*current-map* (its:get-mode-map "roma-kana"))))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
127
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
128 ;; stuff for providing gramatic processing of Japanese text
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
129 ;; something like this should probably be created for all environments...
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
130
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
131 (defvar aletter (concat "\\(" ascii-char "\\|" kanji-char "\\)"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
132 (defvar kanji-space-insertable (concat
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
133 "$B!"(B" aletter "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
134 "$B!#(B" aletter "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
135 aletter "$B!J(B" "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
136 "$B!K(B" aletter "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
137 ascii-alphanumeric kanji-kanji-char "\\|"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
138 kanji-kanji-char ascii-alphanumeric ))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
139
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
140 (defvar space-insertable (concat " " aletter "\\|" kanji-space-insertable)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
141 "Regexp for finding points that can have spaces inserted into them for justification")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
142
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
143 ;; (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
144 ;; 'iso-2022-jp 2 ?J
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
145 ;; "ISO 2022 based 7bit encoding for Japanese (MIME:ISO-2022-JP)"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
146 ;; '((ascii japanese-jisx0208-1978 japanese-jisx0208
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
147 ;; latin-jisx0201 japanese-jisx0212 katakana-jisx0201 t) nil nil nil
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
148 ;; short ascii-eol ascii-cntl seven))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
149
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
150 ;; (define-coding-system-alias 'junet 'iso-2022-jp)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
151
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
152 (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
153 'iso-2022-jp 'iso2022
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
154 "Coding-system used for communication with mail and news in Japan."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
155 '(charset-g0 ascii
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
156 short t
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
157 seven t
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
158 input-charset-conversion ((latin-jisx0201 ascii)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
159 (japanese-jisx0208-1978 japanese-jisx0208))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
160 mnemonic "MULE/7bit"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
161 ))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
162
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
163 (copy-coding-system 'iso-2022-jp 'junet)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
164
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
165 ;; (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
166 ;; 'shift_jis 1 ?S
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
167 ;; "Coding-system of Shift-JIS used in Japan." t)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
168
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
169 (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
170 'shift_jis 'shift-jis
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
171 "Coding-system of Shift-JIS used in Japan."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
172 '(mnemonic "Ja/SJIS"))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
173
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
174 ;;(define-coding-system-alias 'shift_jis 'sjis)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
175
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
176 (copy-coding-system 'shift_jis 'sjis)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
177
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
178 ;; (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
179 ;; 'iso-2022-jp-1978-irv 2 ?J
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
180 ;; "Coding-system used for old jis terminal."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
181 ;; '((ascii t) nil nil nil
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
182 ;; short ascii-eol ascii-cntl seven nil nil use-roman use-oldjis))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
183
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
184 (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
185 'iso-2022-jp-1978-irv 'iso2022
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
186 "Coding-system used for old JIS terminal."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
187 '(charset-g0 ascii
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
188 short t
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
189 seven t
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
190 output-charset-conversion ((ascii latin-jisx0201)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
191 (japanese-jisx0208 japanese-jisx0208-1978))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
192 mnemonic "Ja-78/7bit"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
193 ))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
194
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
195 ;;(define-coding-system-alias 'iso-2022-jp-1978-irv 'old-jis)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
196
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
197 (copy-coding-system 'iso-2022-jp-1978-irv 'old-jis)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
198
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
199 ;; (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
200 ;; 'euc-japan-1990 2 ?E
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
201 ;; "Coding-system of Japanese EUC (Extended Unix Code)."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
202 ;; '(ascii japanese-jisx0208 katakana-jisx0201 japanese-jisx0212
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
203 ;; short ascii-eol ascii-cntl nil nil single-shift))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
204
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
205 (make-coding-system
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
206 'euc-jp 'iso2022
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
207 "Coding-system of Japanese EUC (Extended Unix Code)."
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
208 '(charset-g0 ascii
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
209 charset-g1 japanese-jisx0208
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
210 charset-g2 katakana-jisx0201
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
211 charset-g3 japanese-jisx0212
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
212 short t
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
213 mnemonic "Ja/EUC"
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
214 ))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
215
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
216 ;;(define-coding-system-alias 'euc-japan-1990 'euc-japan)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
217
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
218 (copy-coding-system 'euc-jp 'euc-japan) ; only for w3
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
219 (copy-coding-system 'euc-jp 'japanese-euc)
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
220
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
221 (set-language-info-alist
355
182f72e8cd0d Import from CVS: tag r21-1-7
cvs
parents: 333
diff changeset
222 "Japanese" '((setup-function . setup-japanese-environment-internal)
333
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
223 (tutorial . "TUTORIAL.ja")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
224 (charset . (japanese-jisx0208 japanese-jisx0208-1978
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
225 japanese-jisx0212 latin-jisx0201
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
226 katakana-jisx0201))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
227 (coding-system . (iso-2022-jp euc-jp
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
228 shift_jis iso-2022-jp-1978-irv))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
229 (sample-text . "Japanese ($BF|K\8l(B) $B$3$s$K$A$O(B, (I:]FAJ(B")
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
230 (documentation . t)))
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
231
4f79e16b1112 Import from CVS: tag r21-0-64
cvs
parents:
diff changeset
232 ;;; japanese.el ends here