-
Notifications
You must be signed in to change notification settings - Fork 0
/
northern-saami-eim.el
152 lines (127 loc) · 3.17 KB
/
northern-saami-eim.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
;;; northern-saami.el --- Northern Saami input method for Emacs
;; Copyright (C) 2015 Kevin Brubeck Unhammer
;; Author: Kevin Brubeck Unhammer <unhammer@fsfe.org>
;; Version: 0.1.1
;; Url: https://github.com/unhammer/northern-saami-eim
;; Keywords: multilingual, input method, Northern Saami, i18n
;; This file is not part of GNU Emacs.
;; This program is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; So far only tested with a Norwegian physical keyboard and Norwegian
;; GNU/Linux keyboard layout; mappings for other configurations TODO
;; if anyone has suggestions.
;; Usage:
;; Put the following in your ~/.emacs.d/init.el:
;; (register-input-method
;; "northern-saami" "Northern Saami / davvisámegiella" 'quail-use-package
;; "DS" "Northern Saami keyboard layout for Norwegian keyboards"
;; "quail/northern-saami")
;; and do `C-\' (or `C-u C-\'), selecting "northern-saami".
;;; Code:
(defconst northern-saami-version "0.1.1"
"Version of Northern Saami input method")
(quail-define-package
"northern-saami" "Northern Saami / davvisámegiella" "DS" nil
"Northern Saami keyboard layout for Norwegian keyboards.
The ŧ is on alt-gr + t (as with regular GNU/Linux layouts), and
the ŋ is on ¨/^/~. The typical Norwegian layout uses deadkeys, so
you'll have to press the ¨/^/~ key twice to get ŋ; but you can
still use that key to compose letters like ï (used in South
Saami).
Shift + alt-gr + t gives Ŧ, while shift and a double press of the
¨/^/~ key gives Ŋ.
The regular GNU/Linux Saami layout doesn't give a way to type
</>; I've mapped these to the regular </> key combined with
alt+gr (shadowing the rarely-if-ever-used ǯ/Ǯ).
" nil t t t t nil nil nil nil nil t)
(quail-define-rules
("q" ?á)
("w" ?š)
("e" ?e)
("r" ?r)
("t" ?t)
("y" ?y)
("u" ?u)
("i" ?i)
("o" ?o)
("p" ?p)
("å" ?å)
("¨" ?ŋ)
("a" ?a)
("s" ?s)
("d" ?d)
("f" ?f)
("g" ?g)
("h" ?h)
("j" ?j)
("k" ?k)
("l" ?l)
("ø" ?ø)
("æ" ?æ)
("'" ?đ)
("<" ?ž)
("z" ?z)
("x" ?č)
("c" ?c)
("v" ?v)
("b" ?b)
("n" ?n)
("m" ?m)
("," ?,)
("." ?.)
("-" ?-)
("Q" ?Á)
("W" ?Š)
("E" ?E)
("R" ?R)
("T" ?T)
("Y" ?Y)
("U" ?U)
("I" ?I)
("O" ?O)
("P" ?P)
("Å" ?Å)
("^" ?Ŋ)
("A" ?A)
("S" ?S)
("D" ?D)
("F" ?F)
("G" ?G)
("H" ?H)
("J" ?J)
("K" ?K)
("L" ?L)
("Ø" ?Ø)
("Æ" ?Æ)
("*" ?Đ)
(">" ?Ž)
("Z" ?Z)
("X" ?Č)
("C" ?C)
("V" ?V)
("B" ?B)
("N" ?N)
("M" ?M)
(";" ?\;)
(":" ?:)
("_" ?_)
;; alt-gr + t:
("Þ" ?Ŧ)
("þ" ?ŧ)
;; alt-gr + </> for </>:
("½" ?<)
("¾" ?>))
(provide 'northern-saami-eim)
;; Local Variables:
;; coding: utf-8
;; End:
;;; northern-saami.el ends here