annotate lisp/language/vietnamese.el @ 89708:b66b529d5f33

(x_set_mouse_face_gc): Call FACE_FOR_CHAR with POS and OBJECT args.
author Kenichi Handa <handa@m17n.org>
date Thu, 15 Jan 2004 06:57:45 +0000
parents 2f877ed80fa6
children 68c22ea6027c
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
38414
67b464da13ec Some fixes to follow coding conventions.
Pavel Janík <Pavel@Janik.cz>
parents: 33778
diff changeset
1 ;;; vietnamese.el --- support for Vietnamese -*- coding: iso-2022-7bit; -*-
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
2
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
3 ;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN.
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
4 ;; Licensed to the Free Software Foundation.
88559
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
5 ;; Copyright (C) 2002 Free Software Foundation, Inc.
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
6 ;; Copyright (C) 2003
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
7 ;; National Institute of Advanced Industrial Science and Technology (AIST)
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
8 ;; Registration Number H13PRO009
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
9
88559
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
10 ;; Keywords: multilingual, Vietnamese, i18n
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
11
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
12 ;; This file is part of GNU Emacs.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
13
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
14 ;; GNU Emacs is free software; you can redistribute it and/or modify
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
15 ;; it under the terms of the GNU General Public License as published by
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
16 ;; the Free Software Foundation; either version 2, or (at your option)
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
17 ;; any later version.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
18
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
19 ;; GNU Emacs is distributed in the hope that it will be useful,
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
20 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
21 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
22 ;; GNU General Public License for more details.
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
23
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
24 ;; 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
25 ;; 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
26 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
70194012fb3a Fix FSF address in comment.
Karl Heuer <kwzh@gnu.org>
parents: 17052
diff changeset
27 ;; Boston, MA 02111-1307, USA.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
28
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
29 ;;; Commentary:
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
30
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
31 ;; For Vietnames, the character sets VISCII, VSCII and TCVN-5712 are
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
32 ;; supported.
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
33
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
34 ;;; Code:
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
35
88414
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
36 (define-coding-system 'vietnamese-viscii
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
37 "8-bit encoding for Vietnamese VISCII 1.1 (MIME:VISCII)."
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
38 :coding-type 'charset
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
39 :mnemonic ?V
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
40 :charset-list '(viscii)
88513
bafe04d82c5d Fix :mime-charset properties.
Dave Love <fx@gnu.org>
parents: 88414
diff changeset
41 :mime-charset 'viscii)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
42
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
43 (define-coding-system-alias 'viscii 'vietnamese-viscii)
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
44
88414
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
45 (define-coding-system 'vietnamese-vscii
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
46 "8-bit encoding for Vietnamese VSCII-1."
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
47 :coding-type 'charset
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
48 :mnemonic ?v
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
49 :charset-list '(vscii))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
50
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
51 (define-coding-system-alias 'vscii 'vietnamese-vscii)
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
52
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
53 ;; (make-coding-system
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
54 ;; 'vietnamese-vps 4 ?p
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
55 ;; "8-bit encoding for Vietnamese VPS"
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
56 ;; '(ccl-decode-vps . ccl-encode-vps)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
57 ;; '((safe-charsets ascii vietnamese-viscii-lower vietnamese-viscii-upper)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
58 ;; (valid-codes (0 . 255))))
49598
0d8b17d428b5 Trailing whitepace deleted.
Juanma Barranquero <lekktu@gmail.com>
parents: 44962
diff changeset
59 ;;
44962
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
60 ;; (define-coding-system-alias 'vps 'vietnamese-vps)
39ed2c52ffb0 (viet-tcvn-decode-table, ccl-decode-tcvn)
Pavel Janík <Pavel@Janik.cz>
parents: 42152
diff changeset
61
88414
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
62 (define-coding-system 'vietnamese-viqr
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
63 "Vietnamese latin transcription (VIQR)."
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
64 :coding-type 'utf-8
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
65 :mnemonic ?q
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
66 :charset-list '(ascii viscii)
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
67 :post-read-conversion 'viqr-post-read-conversion
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
68 :pre-write-conversion 'viqr-pre-write-conversion)
18203
0745f30aec66 Adjusted for coding system name change.
Kenichi Handa <handa@m17n.org>
parents: 17993
diff changeset
69
18519
b6badf3614ea Fix calls to define-coding-system-alias.
Richard M. Stallman <rms@gnu.org>
parents: 18377
diff changeset
70 (define-coding-system-alias 'viqr 'vietnamese-viqr)
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
71
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
72 (set-language-info-alist
88414
fad0f879877f Call define-coding-system instead of make-coding-system. All CCL program deleted.
Kenichi Handa <handa@m17n.org>
parents: 42152
diff changeset
73 "Vietnamese" `((charset viscii)
20739
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
74 (coding-system vietnamese-viscii vietnamese-vscii
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
75 vietnamese-tcvn vietnamese-viqr windows-1258)
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
76 (nonascii-translation . viscii)
20739
5f2c7f919bbf Adjusted for the change of make-coding-system. Register
Kenichi Handa <handa@m17n.org>
parents: 20155
diff changeset
77 (coding-priority vietnamese-viscii)
22983
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
78 (input-method . "vietnamese-viqr")
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
79 (unibyte-display . vietnamese-viscii)
7a010b8c0d99 ("LANUGAGE-ENVIRONMENT"): Delete property setup-function or change
Kenichi Handa <handa@m17n.org>
parents: 22879
diff changeset
80 (features viet-util)
17772
550afdbb31d8 Make functions setup-LANGUAGE-environment
Kenichi Handa <handa@m17n.org>
parents: 17170
diff changeset
81 (sample-text . "Vietnamese (Ti,1*(Bng Vi,1.(Bt) Ch,1`(Bo b,1U(Bn")
17993
73869115ae0a Most of setup-LANGUAGE-environment functions are
Kenichi Handa <handa@m17n.org>
parents: 17841
diff changeset
82 (documentation . "\
49727
350e89367682 ("Vietnamese"): Fix typos.
Juanma Barranquero <lekktu@gmail.com>
parents: 49598
diff changeset
83 For Vietnamese, Emacs uses special charsets internally.
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
84 They can be decoded from and encoded to VISCII, VSCII, TCVN-5712, VIQR
88728
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
85 and windows-1258. VSCII is deprecated in favour of TCVN-5712. The
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
86 Current setting gives higher priority to the coding system VISCII than
88728
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
87 TCVN-5712. If you prefer TCVN-5712, please do: (prefer-coding-system
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
88 'vietnamese-tcvn). There are two Vietnamese input methods: VIQR and
89483
2f877ed80fa6 *** empty log message ***
Kenichi Handa <handa@m17n.org>
parents: 88123 88728
diff changeset
89 Telex, VIQR is the default setting.")))
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
90
88559
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
91 (define-coding-system 'windows-1258
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
92 "windows-1258 encoding for Vietnamese (MIME: WINDOWS-1258)"
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
93 :coding-type 'charset
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
94 :mnemonic ?*
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
95 :charset-list '(windows-1258)
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
96 :mime-charset 'windows-1258)
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
97 (define-coding-system-alias 'cp1258 'windows-1258)
2508448a287e (windows-1258, cp1258): New coding
Dave Love <fx@gnu.org>
parents: 88513
diff changeset
98
88728
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
99 (define-coding-system 'vietnamese-tcvn
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
100 "8-bit encoding for Vietnamese TCVN-5712"
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
101 :coding-type 'charset
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
102 :mnemonic ?t
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
103 :charset-list '(tcvn-5712))
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
104 (define-coding-system-alias 'tcvn 'vietnamese-tcvn)
e18cd612d3c4 (vietnamese-tcvn, tcvn): New coding
Dave Love <fx@gnu.org>
parents: 88722
diff changeset
105
33778
6d966e8b4bbe Use provide.
Dave Love <fx@gnu.org>
parents: 29452
diff changeset
106 (provide 'vietnamese)
6d966e8b4bbe Use provide.
Dave Love <fx@gnu.org>
parents: 29452
diff changeset
107
17052
d0d7b244b1d0 Initial revision
Karl Heuer <kwzh@gnu.org>
parents:
diff changeset
108 ;;; vietnamese.el ends here