25e051
;; latn1-pre.mim -- Latin input method simulating "US International Keyboard"
25e051
;; Copyright (C) 2014  Florêncio Neves  <florencioneves@gmail.com>
25e051
25e051
;; This file is part of the m17n database, a sub-part of the m17n library.
25e051
25e051
;; The m17n library is free software; you can redistribute it and/or
25e051
;; modify it under the terms of the GNU General Public License as
25e051
;; published by the Free Software Foundation; either version 2, or (at
25e051
;; your option) any later version.
25e051
25e051
;; The m17n library is distributed in the hope that it will be useful,
25e051
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
25e051
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
25e051
;; GNU General Public License for more details.
25e051
25e051
;; You should have received a copy of the GNU General Public License
25e051
;; along with the m17n library; see the file COPYING.  If not, write to
25e051
;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
25e051
;; Boston, MA 02110-1301, USA.
25e051
25e051
;;; Input method for Latin script with prefix modifiers and AltGr combinations.
25e051
25e051
;; | mark       | prefix | examples
25e051
;; |------------+--------+----------
25e051
;; | acute      |   '    | 'a -> á
25e051
;; | grave      |   `    | `a -> à
25e051
;; | circumflex |   ^    | ^a -> â
25e051
;; | diaeresis  |   "    | "a -> ä
25e051
;; | tilde      |   ~    | ~a -> ã
25e051
;; | cedilla    |   '    | 'c -> ç
25e051
;; | symbol     |        | AltGr-/ -> ¿  AltGr-5 ~> €
25e051
;; | symbol     |        | AltGr-z -> æ  AltGr-s -> ß
25e051
25e051
(input-method t latn1-pre)
25e051
25e051
(description
25e051
 "Latin1 input method simulating \"US International Keyboard\"
25e051
which uses prefix modifiers and AltGr combinations as this:
25e051
 | mark       | prefix | examples
25e051
 |------------+--------+----------
25e051
 | acute      |   '    | 'a -> á
25e051
 | grave      |   `    | `a -> à
25e051
 | circumflex |   ^    | ^a -> â
25e051
 | diaeresis  |   \"    | \"a -> ä
25e051
 | tilde      |   ~    | ~a -> ã
25e051
 | cedilla    |   '    | 'c -> ç
25e051
 | symbol     |        | AltGr-/ -> ¿,  AltGr-z -> æ,  AltGr-s -> ß
25e051
25e051
For Western European languages, these characters are supported too:
25e051
   \"Y -> Ÿ, AltGr-x -> œ, AltGr-X -> Œ, AltGr-5 -> €,
25e051
  AltGr-{ -> ª, AltGr-} ?º, AltGr-( -> “, AltGr-) -> ”")
25e051
25e051
(title "latin1")
25e051
25e051
(map
25e051
 (us-international-keyboard
25e051
  ;; Dead keys
25e051
  ("' " ?')
25e051
  ("'A" ?Á)
25e051
  ("'E" ?É)
25e051
  ("'I" ?Í)
25e051
  ("'O" ?Ó)
25e051
  ("'U" ?Ú)
25e051
  ("'Y" ?Ý)
25e051
  ("'C" ?Ç)
25e051
  ("'a" ?á)
25e051
  ("'e" ?é)
25e051
  ("'i" ?í)
25e051
  ("'o" ?ó)
25e051
  ("'u" ?ú)
25e051
  ("'y" ?ý)
25e051
  ("'c" ?ç)
25e051
  ("\" " ?\")
25e051
  ("\"A" ?Ä)
25e051
  ("\"E" ?Ë)
25e051
  ("\"I" ?Ï)
25e051
  ("\"O" ?Ö)
25e051
  ("\"U" ?Ü)
25e051
  ("\"a" ?ä)
25e051
  ("\"e" ?ë)
25e051
  ("\"i" ?ï)
25e051
  ("\"o" ?ö)
25e051
  ("\"u" ?ü)
25e051
  ("\"y" ?ÿ)
25e051
  ("^ " ?^)
25e051
  ("^A" ?Â)
25e051
  ("^E" ?Ê)
25e051
  ("^I" ?Î)
25e051
  ("^O" ?Ô)
25e051
  ("^U" ?Û)
25e051
  ("^a" ?â)
25e051
  ("^e" ?ê)
25e051
  ("^i" ?î)
25e051
  ("^o" ?ô)
25e051
  ("^u" ?û)
25e051
  ("` " ?`)
25e051
  ("`A" ?À)
25e051
  ("`E" ?È)
25e051
  ("`I" ?Ì)
25e051
  ("`O" ?Ò)
25e051
  ("`U" ?Ù)
25e051
  ("`a" ?à)
25e051
  ("`e" ?è)
25e051
  ("`i" ?ì)
25e051
  ("`o" ?ò)
25e051
  ("`u" ?ù)
25e051
  ("~ " ?~)
25e051
  ("~A" ?Ã)
25e051
  ("~N" ?Ñ)
25e051
  ("~O" ?Õ)
25e051
  ("~a" ?ã)
25e051
  ("~n" ?ñ)
25e051
  ("~o" ?õ)
25e051
25e051
  ;; AltGr combinations
25e051
  ((G-1) ?¡)
25e051
  ((G-2) ?²)
25e051
  ((G-3) ?³)
25e051
  ((G-4) ?¤)
25e051
  ((G-6) ?¼)
25e051
  ((G-7) ?½)
25e051
  ((G-8) ?¾)     
25e051
  ((G-9) ?‘)
25e051
  ((G-0) ?’)
25e051
  ((G--) ?¥)
25e051
  ((G-=) ?×)
25e051
  ((G-!) ?¹)
25e051
  ((G-$) ?£)
25e051
  ((G-+) ?÷)
25e051
  ((G-q) ?ä)
25e051
  ((G-w) ?å)
25e051
  ((G-e) ?é)
25e051
  ((G-r) ?®)
25e051
  ((G-t) ?þ)
25e051
  ((G-y) ?ü)
25e051
  ((G-u) ?ú)
25e051
  ((G-i) ?í)
25e051
  ((G-o) ?ó)
25e051
  ((G-p) ?ö)
25e051
  ((G-\[) ?«)
25e051
  ((G-\]) ?»)
25e051
  ((G-a) ?á)
25e051
  ((G-s) ?ß)
25e051
  ((G-d) ?ð)
25e051
  ((G-l) ?ø)
25e051
  ((G-\;) ?¶)
25e051
  ((G-\') ?´)
25e051
  ((G-\\) ?¬)
25e051
  ((G-z) ?æ)
25e051
  ((G-c) ?©)
25e051
  ((G-n) ?ñ)
25e051
  ((G-m) ?µ)
25e051
  ((G-,) ?ç)
25e051
  ((G-/) ?¿)
25e051
  ((G-Q) ?Ä)
25e051
  ((G-W) ?Å)
25e051
  ((G-E) ?É)
25e051
  ((G-T) ?Þ)
25e051
  ((G-Y) ?Ü)
25e051
  ((G-U) ?Ú)
25e051
  ((G-I) ?Í)
25e051
  ((G-O) ?Ó)
25e051
  ((G-P) ?Ö)
25e051
  ((G-A) ?Á)
25e051
  ((G-S) ?§)
25e051
  ((G-D) ?Ð)
25e051
  ((G-L) ?Ø)
25e051
  ((G-:) ?°)
25e051
  ((G-\") ?¨)
25e051
  ((G-|) ?¦)
25e051
  ((G-Z) ?Æ)
25e051
  ((G-C) ?¢)
25e051
  ((G-N) ?Ñ)
25e051
  ((G-<) ?Ç))
25e051
25e051
 (extra
25e051
  ;; Not in "US International Keyboard, but needed in some Western
25e051
  ;; European languages.
25e051
  ("\"Y" ?Ÿ)
25e051
  ((G-x) ?œ)
25e051
  ((G-X) ?Œ)
25e051
  ((G-5) ?€)
25e051
  ((G-{) ?ª)
25e051
  ((G-}) ?º)
25e051
  ((G-\() ?“)
25e051
  ((G-\)) ?”)
25e051
  ))
25e051
25e051
(state
25e051
  (init
25e051
   (us-international-keyboard)
25e051
   (extra)))
25e051
25e051
;; Local Variables:
25e051
;; coding: utf-8
25e051
;; mode: emacs-lisp
25e051
;; End: