annotate lisp/obsolete/iso-acc.el @ 83372:d2bada79d78c

Don't let server-save-buffers-kill-display unexpectedly kill Emacs on --no-wait's X frames. * lisp/server.el (server-process-filter): Use a dummy client with --no-wait's X frames. (server-save-buffers-kill-display): Explicitly delete frame after deleting its client, in case it was a dummy. git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-412
author Karoly Lorentey <lorentey@elte.hu>
date Sun, 11 Sep 2005 03:51:40 +0000
parents 532e0a9335a9
children d04d8ccb3c41
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
61018
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
1 ;;; iso-acc.el --- minor mode providing electric accent keys
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
2
64751
5b1a238fcbb4 Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents: 64085
diff changeset
3 ;; Copyright (C) 1993, 1994, 1996, 2001, 2002, 2003, 2004,
5b1a238fcbb4 Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents: 64085
diff changeset
4 ;; 2005 Free Software Foundation, Inc.
61018
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
5
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
6 ;; Author: Johan Vromans
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
7 ;; Maintainer: FSF
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
8 ;; Keywords: i18n
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
9
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
10 ;; This file is part of GNU Emacs.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
11
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
12 ;; GNU Emacs is free software; you can redistribute it and/or modify
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
13 ;; it under the terms of the GNU General Public License as published by
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
14 ;; the Free Software Foundation; either version 2, or (at your option)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
15 ;; any later version.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
16
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
17 ;; GNU Emacs is distributed in the hope that it will be useful,
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
18 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
20 ;; GNU General Public License for more details.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
21
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
22 ;; You should have received a copy of the GNU General Public License
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
23 ;; along with GNU Emacs; see the file COPYING. If not, write to the
64085
18a818a2ee7c Update FSF's address.
Lute Kamstra <lute@gnu.org>
parents: 61018
diff changeset
24 ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18a818a2ee7c Update FSF's address.
Lute Kamstra <lute@gnu.org>
parents: 61018
diff changeset
25 ;; Boston, MA 02110-1301, USA.
61018
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
26
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
27 ;;; Commentary:
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
28
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
29 ;; Function `iso-accents-mode' activates a minor mode in which
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
30 ;; typewriter "dead keys" are emulated. The purpose of this emulation
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
31 ;; is to provide a simple means for inserting accented characters
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
32 ;; according to the ISO-8859-1...3 character sets.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
33 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
34 ;; In `iso-accents-mode', pseudo accent characters are used to
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
35 ;; introduce accented keys. The pseudo-accent characters are:
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
36 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
37 ;; ' (minute) -> actue accent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
38 ;; ` (backtick) -> grave accent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
39 ;; " (second) -> diaeresis
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
40 ;; ^ (caret) -> circumflex
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
41 ;; ~ (tilde) -> tilde over the character
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
42 ;; / (slash) -> slash through the character.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
43 ;; Also: /A is A-with-ring and /E is AE ligature.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
44 ;; These two are enabled only if you set iso-accents-enable
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
45 ;; to include them:
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
46 ;; . (period) -> dot over the character (some languages only)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
47 ;; , (cedilla) -> cedilla under the character (some languages only)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
48 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
49 ;; The action taken depends on the key that follows the pseudo accent.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
50 ;; In general:
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
51 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
52 ;; pseudo-accent + appropriate letter -> accented letter
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
53 ;; pseudo-accent + space -> pseudo-accent (except comma and period)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
54 ;; pseudo-accent + pseudo-accent -> accent (if available)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
55 ;; pseudo-accent + other -> pseudo-accent + other
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
56 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
57 ;; If the pseudo-accent is followed by anything else than a
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
58 ;; self-insert-command, the dead-key code is terminated, the
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
59 ;; pseudo-accent inserted 'as is' and the bell is rung to signal this.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
60 ;;
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
61 ;; Function `iso-accents-mode' can be used to enable the iso accents
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
62 ;; minor mode, or disable it.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
63
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
64 ;; If you want only some of these characters to serve as accents,
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
65 ;; add a language to `iso-languages' which specifies the accent characters
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
66 ;; that you want, then select the language with `iso-accents-customize'.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
67
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
68 ;;; Code:
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
69
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
70 (provide 'iso-acc)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
71
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
72 (defgroup iso-acc nil
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
73 "Minor mode providing electric accent keys."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
74 :prefix "iso-accents-"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
75 :group 'i18n)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
76
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
77 (defcustom iso-accents-insert-offset nonascii-insert-offset
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
78 "*Offset added by ISO Accents mode to character codes 0200 and above."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
79 :type 'integer
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
80 :group 'iso-acc)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
81
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
82 (defvar iso-languages
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
83 '(("catalan"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
84 ;; Note this includes some extra characters used in Spanish,
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
85 ;; on the idea that someone who uses Catalan is likely to use Spanish
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
86 ;; as well.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
87 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
88 (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363) (?u . ?\372)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
89 (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
90 (?` (?A . ?\300) (?E . ?\310) (?O . ?\322)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
91 (?a . ?\340) (?e . ?\350) (?o . ?\362)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
92 (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
93 (?\" (?I . ?\317) (?U . ?\334) (?i . ?\357) (?u . ?\374)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
94 (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
95 (?~ (?C . ?\307) (?N . ?\321) (?c . ?\347) (?n . ?\361)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
96 (?> . ?\273) (?< . ?\253) (?! . ?\241) (?? . ?\277)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
97 (?\ . ?\~)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
98
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
99 ("esperanto"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
100 (?^ (?H . ?\246) (?J . ?\254) (?h . ?\266) (?j . ?\274) (?C . ?\306)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
101 (?G . ?\330) (?S . ?\336) (?c . ?\346) (?g . ?\370) (?s . ?\376)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
102 (?^ . ?^) (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
103 (?~ (?U . ?\335) (?u . ?\375) (?\ . ?~)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
104
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
105 ("french"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
106 (?' (?E . ?\311) (?C . ?\307) (?e . ?\351) (?c . ?\347)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
107 (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
108 (?` (?A . ?\300) (?E . ?\310) (?U . ?\331)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
109 (?a . ?\340) (?e . ?\350) (?u . ?\371)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
110 (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
111 (?^ (?A . ?\302) (?E . ?\312) (?I . ?\316) (?O . ?\324) (?U . ?\333)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
112 (?a . ?\342) (?e . ?\352) (?i . ?\356) (?o . ?\364) (?u . ?\373)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
113 (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
114 (?\" (?E . ?\313) (?I . ?\317)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
115 (?e . ?\353) (?i . ?\357)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
116 (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
117 (?~ (?< . ?\253) (?> . ?\273) (?C . ?\307) (?c . ?\347)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
118 (?\ . ?~))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
119 (?, (?C . ?\307) (?c . ?\347) (?\ . ?\,)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
120
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
121 ("german"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
122 (?\" (?A . ?\304) (?O . ?\326) (?U . ?\334)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
123 (?a . ?\344) (?o . ?\366) (?u . ?\374) (?s . ?\337) (?\ . ?\")))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
124
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
125 ("irish"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
126 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
127 (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363) (?u . ?\372)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
128 (?\ . ?')))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
129
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
130 ("portuguese"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
131 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
132 (?C . ?\307) (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
133 (?u . ?\372) (?c . ?\347)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
134 (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
135 (?` (?A . ?\300) (?a . ?\340)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
136 (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
137 (?^ (?A . ?\302) (?E . ?\312) (?O . ?\324)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
138 (?a . ?\342) (?e . ?\352) (?o . ?\364)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
139 (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
140 (?\" (?U . ?\334) (?u . ?\374)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
141 (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
142 (?~ (?A . ?\303) (?O . ?\325) (?a . ?\343) (?o . ?\365)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
143 (?C . ?\307) (?N . ?\321) (?c . ?\347) (?n . ?\361)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
144 (?\ . ?~))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
145 (?, (?c . ?\347) (?C . ?\307) (?, . ?,)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
146
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
147 ("spanish"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
148 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
149 (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363) (?u . ?\372)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
150 (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
151 (?\" (?U . ?\334) (?u . ?\374) (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
152 (?\~ (?N . ?\321) (?n . ?\361) (?> . ?\273) (?< . ?\253) (?! . ?\241)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
153 (?? . ?\277) (?\ . ?\~)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
154
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
155 ("latin-1"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
156 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
157 (?Y . ?\335) (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
158 (?u . ?\372) (?y . ?\375) (?' . ?\264)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
159 (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
160 (?` (?A . ?\300) (?E . ?\310) (?I . ?\314) (?O . ?\322) (?U . ?\331)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
161 (?a . ?\340) (?e . ?\350) (?i . ?\354) (?o . ?\362) (?u . ?\371)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
162 (?` . ?`) (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
163 (?^ (?A . ?\302) (?E . ?\312) (?I . ?\316) (?O . ?\324) (?U . ?\333)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
164 (?a . ?\342) (?e . ?\352) (?i . ?\356) (?o . ?\364) (?u . ?\373)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
165 (?^ . ?^) (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
166 (?\" (?A . ?\304) (?E . ?\313) (?I . ?\317) (?O . ?\326) (?U . ?\334)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
167 (?a . ?\344) (?e . ?\353) (?i . ?\357) (?o . ?\366) (?s . ?\337)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
168 (?u . ?\374) (?y . ?\377)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
169 (?\" . ?\250) (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
170 (?~ (?A . ?\303) (?C . ?\307) (?D . ?\320) (?N . ?\321) (?O . ?\325)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
171 (?T . ?\336) (?a . ?\343) (?c . ?\347) (?d . ?\360) (?n . ?\361)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
172 (?o . ?\365) (?t . ?\376)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
173 (?> . ?\273) (?< . ?\253) (?! . ?\241) (?? . ?\277)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
174 (?\~ . ?\270) (?\ . ?~))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
175 (?/ (?A . ?\305) (?E . ?\306) (?O . ?\330) (?a . ?\345) (?e . ?\346)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
176 (?o . ?\370)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
177 (?/ . ?\260) (?\ . ?/)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
178
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
179 ("latin-2" latin-iso8859-2
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
180 (?' (?A . ?\301) (?C . ?\306) (?D . ?\320) (?E . ?\311) (?I . ?\315)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
181 (?L . ?\305) (?N . ?\321) (?O . ?\323) (?R . ?\300) (?S . ?\246)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
182 (?U . ?\332) (?Y . ?\335) (?Z . ?\254)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
183 (?a . ?\341) (?c . ?\346) (?d . ?\360) (?e . ?\351) (?i . ?\355)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
184 (?l . ?\345) (?n . ?\361) (?o . ?\363) (?r . ?\340) (?s . ?\266)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
185 (?u . ?\372) (?y . ?\375) (?z . ?\274)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
186 (?' . ?\264) (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
187 (?` (?A . ?\241) (?C . ?\307) (?E . ?\312) (?L . ?\243) (?S . ?\252)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
188 (?T . ?\336) (?Z . ?\257)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
189 (?a . ?\261) (?l . ?\263) (?c . ?\347) (?e . ?\352) (?s . ?\272)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
190 (?t . ?\376) (?z . ?\277)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
191 (?` . ?\252)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
192 (?. . ?\377) (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
193 (?^ (?A . ?\302) (?I . ?\316) (?O . ?\324)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
194 (?a . ?\342) (?i . ?\356) (?o . ?\364)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
195 (?^ . ?^) ; no special code?
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
196 (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
197 (?\" (?A . ?\304) (?E . ?\313) (?O . ?\326) (?U . ?\334)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
198 (?a . ?\344) (?e . ?\353) (?o . ?\366) (?s . ?\337) (?u . ?\374)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
199 (?\" . ?\250)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
200 (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
201 (?~ (?A . ?\303) (?C . ?\310) (?D . ?\317) (?L . ?\245) (?N . ?\322)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
202 (?O . ?\325) (?R . ?\330) (?S . ?\251) (?T . ?\253) (?U . ?\333)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
203 (?Z . ?\256)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
204 (?a . ?\343) (?c . ?\350) (?d . ?\357) (?l . ?\265) (?n . ?\362)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
205 (?o . ?\365) (?r . ?\370) (?s . ?\271) (?t . ?\273) (?u . ?\373)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
206 (?z . ?\276)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
207 (?v . ?\242) ; v accent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
208 (?\~ . ?\242) ; v accent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
209 (?\. . ?\270) ; cedilla accent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
210 (?\ . ?~)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
211
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
212 ("latin-3" latin-iso8859-3
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
213 (?' (?A . ?\301) (?E . ?\311) (?I . ?\315) (?O . ?\323) (?U . ?\332)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
214 (?a . ?\341) (?e . ?\351) (?i . ?\355) (?o . ?\363) (?u . ?\372)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
215 (?' . ?\264) (?\ . ?'))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
216 (?` (?A . ?\300) (?E . ?\310) (?I . ?\314) (?O . ?\322) (?U . ?\331)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
217 (?a . ?\340) (?e . ?\350) (?i . ?\354) (?o . ?\362) (?u . ?\371)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
218 (?` . ?`) (?\ . ?`))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
219 (?^ (?A . ?\302) (?C . ?\306) (?E . ?\312) (?G . ?\330) (?H . ?\246)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
220 (?I . ?\316) (?J . ?\254) (?O . ?\324) (?S . ?\336) (?U . ?\333)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
221 (?a . ?\342) (?c . ?\346) (?e . ?\352) (?g . ?\370) (?h . ?\266)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
222 (?i . ?\356) (?j . ?\274) (?o . ?\364) (?s . ?\376) (?u . ?\373)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
223 (?^ . ?^) (?\ . ?^))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
224 (?\" (?A . ?\304) (?E . ?\313) (?I . ?\317) (?O . ?\326) (?U . ?\334)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
225 (?a . ?\344) (?e . ?\353) (?i . ?\357) (?o . ?\366) (?u . ?\374)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
226 (?s . ?\337)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
227 (?\" . ?\250) (?\ . ?\"))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
228 (?~ (?A . ?\303) (?C . ?\307) (?D . ?\320) (?N . ?\321) (?O . ?\325)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
229 (?a . ?\343) (?c . ?\347) (?d . ?\360) (?n . ?\361) (?o . ?\365)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
230 (?$ . ?\245) (?S . ?\252) (?s . ?\272) (?G . ?\253) (?g . ?\273)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
231 (?U . ?\335) (?u . ?\375) (?` . ?\242)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
232 (?~ . ?\270) (?\ . ?~))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
233 (?/ (?C . ?\305) (?G . ?\325) (?H . ?\241) (?I . ?\251) (?Z . ?\257)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
234 (?c . ?\345) (?g . ?\365) (?h . ?\261) (?i . ?\271) (?z . ?\277)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
235 (?r . ?\256)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
236 (?. . ?\377) (?# . ?\243) (?$ . ?\244)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
237 (?/ . ?\260) (?\ . ?/))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
238 (?. (?C . ?\305) (?G . ?\325) (?I . ?\251) (?Z . ?\257)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
239 (?c . ?\345) (?g . ?\365) (?z . ?\277))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
240 "List of language-specific customizations for the ISO Accents mode.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
241
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
242 Each element of the list is of the form
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
243
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
244 (LANGUAGE [CHARSET]
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
245 (PSEUDO-ACCENT MAPPINGS)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
246 (PSEUDO-ACCENT MAPPINGS)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
247 ...)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
248
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
249 LANGUAGE is a string naming the language.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
250 CHARSET (which may be omitted) is the symbol name
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
251 of the character set used in this language.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
252 If CHARSET is omitted, latin-iso8859-1 is the default.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
253 PSEUDO-ACCENT is a char specifying an accent key.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
254 MAPPINGS are cons cells of the form (CHAR . ISO-CHAR).
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
255
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
256 The net effect is that the key sequence PSEUDO-ACCENT CHAR is mapped
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
257 to ISO-CHAR on input.")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
258
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
259 (defvar iso-language nil
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
260 "Language for which ISO Accents mode is currently customized.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
261 Change it with the `iso-accents-customize' function.")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
262
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
263 (defvar iso-accents-list nil
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
264 "Association list for ISO accent combinations, for the chosen language.")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
265
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
266 (defcustom iso-accents-mode nil
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
267 "*Non-nil enables ISO Accents mode.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
268 Setting this variable makes it local to the current buffer.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
269 See the function `iso-accents-mode'."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
270 :type 'boolean
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
271 :group 'iso-acc)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
272 (make-variable-buffer-local 'iso-accents-mode)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
273
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
274 (defcustom iso-accents-enable '(?' ?` ?^ ?\" ?~ ?/)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
275 "*List of accent keys that become prefixes in ISO Accents mode.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
276 The default is (?' ?` ?^ ?\" ?~ ?/), which contains all the supported
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
277 accent keys. If you set this variable to a list in which some of those
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
278 characters are missing, the missing ones do not act as accents.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
279
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
280 Note that if you specify a language with `iso-accents-customize',
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
281 that can also turn off certain prefixes (whichever ones are not needed in
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
282 the language you choose)."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
283 :type '(repeat character)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
284 :group 'iso-acc)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
285
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
286 (defun iso-accents-accent-key (prompt)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
287 "Modify the following character by adding an accent to it."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
288 ;; Pick up the accent character.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
289 (if (and iso-accents-mode
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
290 (memq last-input-char iso-accents-enable))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
291 (iso-accents-compose prompt)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
292 (vector last-input-char)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
293
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
294
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
295 ;; The iso-accents-compose function is called deep inside Emacs' read
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
296 ;; key sequence machinery, so the call to read-event below actually
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
297 ;; recurses into that machinery. Doing that does not cause any
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
298 ;; problem on its own, but read-event will have marked the window's
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
299 ;; display matrix to be accurate -- which is broken by the subsequent
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
300 ;; call to delete-region. Therefore, we must call force-window-update
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
301 ;; after delete-region to explicitly clear the accurate state of the
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
302 ;; window's display matrix.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
303
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
304 (defun iso-accents-compose (prompt)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
305 (let* ((first-char last-input-char)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
306 (list (assq first-char iso-accents-list))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
307 ;; Wait for the second key and look up the combination.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
308 (second-char (if (or prompt
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
309 (not (eq (key-binding "a")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
310 'self-insert-command))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
311 ;; Not at start of a key sequence.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
312 (> (length (this-single-command-keys)) 1)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
313 ;; Called from anything but the command loop.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
314 this-command)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
315 (progn
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
316 (message "%s%c"
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
317 (or prompt "Compose with ")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
318 first-char)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
319 (read-event))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
320 (insert first-char)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
321 (prog1 (read-event)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
322 (delete-region (1- (point)) (point))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
323 ;; Display is no longer up-to-date.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
324 (force-window-update (selected-window)))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
325 (entry (cdr (assq second-char list))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
326 (if entry
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
327 ;; Found it: return the mapped char
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
328 (vector
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
329 (if (and enable-multibyte-characters
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
330 (>= entry ?\200))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
331 (+ iso-accents-insert-offset entry)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
332 entry))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
333 ;; Otherwise, advance and schedule the second key for execution.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
334 (push second-char unread-command-events)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
335 (vector first-char))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
336
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
337 ;; It is a matter of taste if you want the minor mode indicated
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
338 ;; in the mode line...
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
339 ;; If so, uncomment the next four lines.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
340 ;; (or (assq 'iso-accents-mode minor-mode-alist)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
341 ;; (setq minor-mode-alist
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
342 ;; (append minor-mode-alist
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
343 ;; '((iso-accents-mode " ISO-Acc")))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
344
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
345 ;;;###autoload
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
346 (defun iso-accents-mode (&optional arg)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
347 "Toggle ISO Accents mode, in which accents modify the following letter.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
348 This permits easy insertion of accented characters according to ISO-8859-1.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
349 When Iso-accents mode is enabled, accent character keys
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
350 \(`, ', \", ^, / and ~) do not self-insert; instead, they modify the following
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
351 letter key so that it inserts an ISO accented letter.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
352
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
353 You can customize ISO Accents mode to a particular language
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
354 with the command `iso-accents-customize'.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
355
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
356 Special combinations: ~c gives a c with cedilla,
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
357 ~d gives an Icelandic eth (d with dash).
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
358 ~t gives an Icelandic thorn.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
359 \"s gives German sharp s.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
360 /a gives a with ring.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
361 /e gives an a-e ligature.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
362 ~< and ~> give guillemots.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
363 ~! gives an inverted exclamation mark.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
364 ~? gives an inverted question mark.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
365
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
366 With an argument, a positive argument enables ISO Accents mode,
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
367 and a negative argument disables it."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
368
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
369 (interactive "P")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
370
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
371 (if (if arg
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
372 ;; Negative arg means switch it off.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
373 (<= (prefix-numeric-value arg) 0)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
374 ;; No arg means toggle.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
375 iso-accents-mode)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
376 (setq iso-accents-mode nil)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
377
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
378 ;; Enable electric accents.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
379 (setq iso-accents-mode t)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
380
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
381 (defun iso-accents-customize (language)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
382 "Customize the ISO accents machinery for a particular language.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
383 It selects the customization based on the specifications in the
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
384 `iso-languages' variable."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
385 (interactive (list (completing-read "Language: " iso-languages nil t)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
386 (let ((table (cdr (assoc language iso-languages)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
387 all-accents tail)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
388 (if (not table)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
389 (error "Unknown language `%s'" language)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
390 (setq iso-accents-insert-offset (- (make-char (if (symbolp (car table))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
391 (car table)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
392 'latin-iso8859-1))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
393 128))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
394 (if (symbolp (car table))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
395 (setq table (cdr table)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
396 (setq iso-language language
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
397 iso-accents-list table)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
398 (if key-translation-map
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
399 (substitute-key-definition
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
400 'iso-accents-accent-key nil key-translation-map)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
401 (setq key-translation-map (make-sparse-keymap)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
402 ;; Set up translations for all the characters that are used as
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
403 ;; accent prefixes in this language.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
404 (setq tail iso-accents-list)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
405 (while tail
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
406 (define-key key-translation-map (vector (car (car tail)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
407 'iso-accents-accent-key)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
408 (setq tail (cdr tail))))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
409
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
410 (defun iso-accentuate (start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
411 "Convert two-character sequences in region into accented characters.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
412 Noninteractively, this operates on text from START to END.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
413 This uses the same conversion that ISO Accents mode uses for type-in."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
414 (interactive "r")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
415 (save-excursion
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
416 (save-restriction
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
417 (narrow-to-region start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
418 (goto-char start)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
419 (forward-char 1)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
420 (let (entry)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
421 (while (< (point) end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
422 (if (and (memq (preceding-char) iso-accents-enable)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
423 (setq entry (cdr (assq (following-char) (assq (preceding-char) iso-accents-list)))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
424 (progn
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
425 (forward-char -1)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
426 (delete-char 2)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
427 (insert entry)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
428 (setq end (1- end)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
429 (forward-char 1)))))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
430
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
431 (defun iso-accent-rassoc-unit (value alist)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
432 (let (elt acc)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
433 (while (and alist (not elt))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
434 (setq acc (car (car alist))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
435 elt (car (rassq value (cdr (car alist))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
436 alist (cdr alist)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
437 (if elt
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
438 (cons acc elt))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
439
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
440 (defun iso-unaccentuate (start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
441 "Convert accented characters in the region into two-character sequences.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
442 Noninteractively, this operates on text from START to END.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
443 This uses the opposite of the conversion done by ISO Accents mode for type-in."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
444 (interactive "r")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
445 (save-excursion
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
446 (save-restriction
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
447 (narrow-to-region start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
448 (goto-char start)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
449 (let (entry)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
450 (while (< (point) end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
451 (if (and (> (following-char) 127)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
452 (setq entry (iso-accent-rassoc-unit (following-char)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
453 iso-accents-list)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
454 (progn
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
455 (delete-char 1)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
456 (insert (car entry) (cdr entry))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
457 (setq end (1+ end)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
458 (forward-char 1)))))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
459
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
460 (defun iso-deaccentuate (start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
461 "Convert accented characters in the region into unaccented characters.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
462 Noninteractively, this operates on text from START to END."
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
463 (interactive "r")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
464 (save-excursion
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
465 (save-restriction
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
466 (narrow-to-region start end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
467 (goto-char start)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
468 (let (entry)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
469 (while (< (point) end)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
470 (if (and (> (following-char) 127)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
471 (setq entry (iso-accent-rassoc-unit (following-char)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
472 iso-accents-list)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
473 (progn
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
474 (delete-char 1)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
475 (insert (cdr entry)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
476 (forward-char 1)))))))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
477
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
478 ;; Set up the default settings.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
479 (iso-accents-customize "latin-1")
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
480
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
481 ;; Use Iso-Accents mode in the minibuffer
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
482 ;; if it was in use in the previous buffer.
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
483 (defun iso-acc-minibuf-setup ()
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
484 (setq iso-accents-mode
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
485 (save-excursion
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
486 (set-buffer (window-buffer minibuffer-scroll-window))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
487 iso-accents-mode)))
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
488
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
489 (add-hook 'minibuffer-setup-hook 'iso-acc-minibuf-setup)
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
490
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
491 ;; arch-tag: 149ff409-7c3e-4574-9b5d-ac038939c0a6
cd592d9f000b Move iso-acc to the obsolete subdir.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
diff changeset
492 ;;; iso-acc.el ends here