wskbdmap_atari.c revision 1.2 1 1.2 bjh21 /* $NetBSD: wskbdmap_atari.c,v 1.2 2004/03/13 17:23:32 bjh21 Exp $ */
2 1.1 thomas
3 1.1 thomas /*-
4 1.1 thomas * Copyright (c) 1997 The NetBSD Foundation, Inc.
5 1.1 thomas * All rights reserved.
6 1.1 thomas *
7 1.1 thomas * This code is derived from software contributed to The NetBSD Foundation
8 1.1 thomas * by Juergen Hannken-Illjes.
9 1.1 thomas *
10 1.1 thomas * Redistribution and use in source and binary forms, with or without
11 1.1 thomas * modification, are permitted provided that the following conditions
12 1.1 thomas * are met:
13 1.1 thomas * 1. Redistributions of source code must retain the above copyright
14 1.1 thomas * notice, this list of conditions and the following disclaimer.
15 1.1 thomas * 2. Redistributions in binary form must reproduce the above copyright
16 1.1 thomas * notice, this list of conditions and the following disclaimer in the
17 1.1 thomas * documentation and/or other materials provided with the distribution.
18 1.1 thomas * 3. All advertising materials mentioning features or use of this software
19 1.1 thomas * must display the following acknowledgement:
20 1.1 thomas * This product includes software developed by the NetBSD
21 1.1 thomas * Foundation, Inc. and its contributors.
22 1.1 thomas * 4. Neither the name of The NetBSD Foundation nor the names of its
23 1.1 thomas * contributors may be used to endorse or promote products derived
24 1.1 thomas * from this software without specific prior written permission.
25 1.1 thomas *
26 1.1 thomas * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
27 1.1 thomas * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
28 1.1 thomas * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
29 1.1 thomas * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
30 1.1 thomas * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
31 1.1 thomas * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
32 1.1 thomas * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
33 1.1 thomas * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
34 1.1 thomas * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
35 1.1 thomas * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
36 1.1 thomas * POSSIBILITY OF SUCH DAMAGE.
37 1.1 thomas */
38 1.1 thomas
39 1.1 thomas #include <sys/cdefs.h>
40 1.2 bjh21 __KERNEL_RCSID(0, "$NetBSD: wskbdmap_atari.c,v 1.2 2004/03/13 17:23:32 bjh21 Exp $");
41 1.1 thomas
42 1.1 thomas #include <sys/types.h>
43 1.1 thomas #include <dev/wscons/wsksymdef.h>
44 1.1 thomas #include <dev/wscons/wsksymvar.h>
45 1.1 thomas
46 1.1 thomas #define KC(n) KS_KEYCODE(n)
47 1.1 thomas
48 1.1 thomas static const keysym_t atarikbd_keydesc_us[] = {
49 1.1 thomas /* pos command normal shifted */
50 1.1 thomas KC(1), KS_Cmd_Debugger, KS_Escape,
51 1.1 thomas KC(2), KS_1, KS_exclam,
52 1.1 thomas KC(3), KS_2, KS_at,
53 1.1 thomas KC(4), KS_3, KS_numbersign,
54 1.1 thomas KC(5), KS_4, KS_dollar,
55 1.1 thomas KC(6), KS_5, KS_percent,
56 1.1 thomas KC(7), KS_6, KS_asciicircum,
57 1.1 thomas KC(8), KS_7, KS_ampersand,
58 1.1 thomas KC(9), KS_8, KS_asterisk,
59 1.1 thomas KC(10), KS_9, KS_parenleft,
60 1.1 thomas KC(11), KS_0, KS_parenright,
61 1.1 thomas KC(12), KS_minus, KS_underscore,
62 1.1 thomas KC(13), KS_equal, KS_plus,
63 1.1 thomas KC(14), KS_Cmd_ResetEmul, KS_Delete,
64 1.1 thomas KC(15), KS_Tab,
65 1.1 thomas KC(16), KS_q,
66 1.1 thomas KC(17), KS_w,
67 1.1 thomas KC(18), KS_e,
68 1.1 thomas KC(19), KS_r,
69 1.1 thomas KC(20), KS_t,
70 1.1 thomas KC(21), KS_y,
71 1.1 thomas KC(22), KS_u,
72 1.1 thomas KC(23), KS_i,
73 1.1 thomas KC(24), KS_o,
74 1.1 thomas KC(25), KS_p,
75 1.1 thomas KC(26), KS_bracketleft, KS_braceleft,
76 1.1 thomas KC(27), KS_bracketright, KS_braceright,
77 1.1 thomas KC(28), KS_Return,
78 1.1 thomas KC(29), KS_Cmd1, KS_Control_L,
79 1.1 thomas KC(30), KS_a,
80 1.1 thomas KC(31), KS_s,
81 1.1 thomas KC(32), KS_d,
82 1.1 thomas KC(33), KS_f,
83 1.1 thomas KC(34), KS_g,
84 1.1 thomas KC(35), KS_h,
85 1.1 thomas KC(36), KS_j,
86 1.1 thomas KC(37), KS_k,
87 1.1 thomas KC(38), KS_l,
88 1.1 thomas KC(39), KS_semicolon, KS_colon,
89 1.1 thomas KC(40), KS_apostrophe, KS_quotedbl,
90 1.1 thomas KC(41), KS_grave, KS_asciitilde,
91 1.1 thomas KC(42), KS_Shift_L,
92 1.1 thomas KC(43), KS_backslash, KS_bar,
93 1.1 thomas KC(44), KS_z,
94 1.1 thomas KC(45), KS_x,
95 1.1 thomas KC(46), KS_c,
96 1.1 thomas KC(47), KS_v,
97 1.1 thomas KC(48), KS_b,
98 1.1 thomas KC(49), KS_n,
99 1.1 thomas KC(50), KS_m,
100 1.1 thomas KC(51), KS_comma, KS_less,
101 1.1 thomas KC(52), KS_period, KS_greater,
102 1.1 thomas KC(53), KS_slash, KS_question,
103 1.1 thomas KC(54), KS_Shift_R,
104 1.1 thomas KC(56), KS_Cmd2, KS_Alt_L,
105 1.1 thomas KC(57), KS_space,
106 1.1 thomas KC(58), KS_Caps_Lock,
107 1.1 thomas KC(59), KS_Cmd_Screen0, KS_f1,
108 1.1 thomas KC(60), KS_Cmd_Screen1, KS_f2,
109 1.1 thomas KC(61), KS_Cmd_Screen2, KS_f3,
110 1.1 thomas KC(62), KS_Cmd_Screen3, KS_f4,
111 1.1 thomas KC(63), KS_Cmd_Screen4, KS_f5,
112 1.1 thomas KC(64), KS_Cmd_Screen5, KS_f6,
113 1.1 thomas KC(65), KS_Cmd_Screen6, KS_f7,
114 1.1 thomas KC(66), KS_Cmd_Screen7, KS_f8,
115 1.1 thomas KC(67), KS_Cmd_Screen8, KS_f9,
116 1.1 thomas KC(68), KS_Cmd_Screen9, KS_f10,
117 1.1 thomas KC(71), KS_KP_Home,
118 1.1 thomas KC(72), KS_KP_Up, KS_KP_8,
119 1.1 thomas KC(74), KS_KP_Subtract,
120 1.1 thomas KC(75), KS_KP_Left, KS_KP_4,
121 1.1 thomas KC(77), KS_KP_Right, KS_KP_6,
122 1.1 thomas KC(78), KS_KP_Add,
123 1.1 thomas KC(80), KS_KP_Down, KS_KP_2,
124 1.1 thomas KC(82), KS_KP_Insert, KS_KP_0,
125 1.1 thomas KC(83), KS_KP_Delete, KS_KP_Decimal,
126 1.1 thomas KC(97), KS_Pause, /* should be KS_Help. but this is not available */
127 1.1 thomas KC(98), KS_Help,
128 1.1 thomas KC(99), KS_parenleft, /* should be KS_KP_parenleft */
129 1.1 thomas KC(100), KS_parenright, /* should be KS_KP_parenright */
130 1.1 thomas KC(101), KS_slash, /* should be KS_KP_slash */
131 1.1 thomas KC(102), KS_KP_Multiply,
132 1.1 thomas KC(103), KS_KP_7,
133 1.1 thomas KC(104), KS_KP_8,
134 1.1 thomas KC(105), KS_KP_9,
135 1.1 thomas KC(106), KS_KP_4,
136 1.1 thomas KC(107), KS_KP_5,
137 1.1 thomas KC(108), KS_KP_6,
138 1.1 thomas KC(109), KS_KP_1,
139 1.1 thomas KC(110), KS_KP_2,
140 1.1 thomas KC(111), KS_KP_3,
141 1.1 thomas KC(112), KS_KP_0,
142 1.1 thomas KC(113), KS_KP_Decimal,
143 1.1 thomas KC(114), KS_KP_Enter,
144 1.1 thomas };
145 1.1 thomas
146 1.1 thomas static const keysym_t atarikbd_keydesc_de[] = {
147 1.1 thomas /* pos normal shifted altgr shift-altgr */
148 1.1 thomas KC(3), KS_2, KS_quotedbl,
149 1.1 thomas KC(4), KS_3, KS_section,
150 1.1 thomas KC(7), KS_6, KS_ampersand,
151 1.1 thomas KC(8), KS_7, KS_slash,
152 1.1 thomas KC(9), KS_8, KS_parenleft,
153 1.1 thomas KC(10), KS_9, KS_parenright,
154 1.1 thomas KC(11), KS_0, KS_equal,
155 1.1 thomas KC(12), KS_ssharp, KS_question,
156 1.1 thomas KC(13), KS_dead_acute, KS_dead_grave,
157 1.1 thomas KC(16), KS_q, KS_Q,
158 1.1 thomas KC(21), KS_z,
159 1.1 thomas KC(26), KS_udiaeresis, KS_Udiaeresis, KS_at, KS_backslash,
160 1.1 thomas KC(27), KS_plus, KS_asterisk,
161 1.1 thomas KC(39), KS_odiaeresis, KS_Odiaeresis, KS_bracketleft, KS_braceleft,
162 1.1 thomas KC(40), KS_adiaeresis, KS_Adiaeresis, KS_bracketright,KS_braceright,
163 1.1 thomas KC(41), KS_numbersign, KS_dead_circumflex,
164 1.1 thomas KC(43), KS_dead_tilde, KS_bar,
165 1.1 thomas KC(44), KS_y,
166 1.1 thomas KC(51), KS_comma, KS_semicolon,
167 1.1 thomas KC(52), KS_period, KS_colon,
168 1.1 thomas KC(53), KS_minus, KS_underscore,
169 1.1 thomas KC(56), KS_Mode_switch, KS_Multi_key,
170 1.1 thomas KC(96), KS_less, KS_greater,
171 1.1 thomas };
172 1.1 thomas
173 1.1 thomas static const keysym_t atarikbd_keydesc_de_nodead[] = {
174 1.1 thomas /* pos normal shifted altgr shift-altgr */
175 1.1 thomas KC(13), KS_apostrophe, KS_grave,
176 1.1 thomas KC(41), KS_numbersign, KS_asciicircum,
177 1.1 thomas KC(43), KS_asciitilde, KS_bar,
178 1.1 thomas };
179 1.1 thomas
180 1.1 thomas static const keysym_t atarikbd_keydesc_dk[] = {
181 1.1 thomas /* pos normal shifted altgr shift-altgr */
182 1.1 thomas KC(3), KS_2, KS_quotedbl, KS_at,
183 1.1 thomas KC(4), KS_3, KS_numbersign, KS_sterling,
184 1.1 thomas KC(5), KS_4, KS_currency, KS_dollar,
185 1.1 thomas KC(7), KS_6, KS_ampersand,
186 1.1 thomas KC(8), KS_7, KS_slash, KS_braceleft,
187 1.1 thomas KC(9), KS_8, KS_parenleft, KS_bracketleft,
188 1.1 thomas KC(10), KS_9, KS_parenright, KS_bracketright,
189 1.1 thomas KC(11), KS_0, KS_equal, KS_braceright,
190 1.1 thomas KC(12), KS_plus, KS_question,
191 1.1 thomas KC(13), KS_dead_acute, KS_dead_grave, KS_bar,
192 1.1 thomas KC(26), KS_aring,
193 1.1 thomas KC(27), KS_dead_diaeresis, KS_dead_circumflex, KS_dead_tilde,
194 1.1 thomas KC(39), KS_ae,
195 1.1 thomas KC(40), KS_oslash,
196 1.1 thomas KC(41), KS_onehalf, KS_paragraph,
197 1.1 thomas KC(43), KS_apostrophe, KS_asterisk,
198 1.1 thomas KC(51), KS_comma, KS_semicolon,
199 1.1 thomas KC(52), KS_period, KS_colon,
200 1.1 thomas KC(53), KS_minus, KS_underscore,
201 1.1 thomas KC(86), KS_less, KS_greater, KS_backslash,
202 1.1 thomas KC(184), KS_Mode_switch, KS_Multi_key,
203 1.1 thomas };
204 1.1 thomas
205 1.1 thomas static const keysym_t atarikbd_keydesc_dk_nodead[] = {
206 1.1 thomas /* pos normal shifted altgr shift-altgr */
207 1.1 thomas KC(13), KS_apostrophe, KS_grave, KS_bar,
208 1.1 thomas KC(27), KS_diaeresis, KS_asciicircum, KS_asciitilde,
209 1.1 thomas };
210 1.1 thomas
211 1.1 thomas static const keysym_t atarikbd_keydesc_sv[] = {
212 1.1 thomas /* pos normal shifted altgr shift-altgr */
213 1.1 thomas KC(12), KS_plus, KS_question, KS_backslash,
214 1.1 thomas KC(27), KS_dead_diaeresis, KS_dead_circumflex, KS_dead_tilde,
215 1.1 thomas KC(39), KS_odiaeresis,
216 1.1 thomas KC(40), KS_adiaeresis,
217 1.1 thomas KC(41), KS_paragraph, KS_onehalf,
218 1.1 thomas KC(86), KS_less, KS_greater, KS_bar,
219 1.1 thomas KC(184), KS_Mode_switch, KS_Multi_key,
220 1.1 thomas };
221 1.1 thomas
222 1.1 thomas static const keysym_t atarikbd_keydesc_sv_nodead[] = {
223 1.1 thomas /* pos normal shifted altgr shift-altgr */
224 1.1 thomas KC(13), KS_apostrophe, KS_grave, KS_bar,
225 1.1 thomas KC(27), KS_diaeresis, KS_asciicircum, KS_asciitilde,
226 1.1 thomas };
227 1.1 thomas
228 1.1 thomas static const keysym_t atarikbd_keydesc_no[] = {
229 1.1 thomas /* pos normal shifted altgr shift-altgr */
230 1.1 thomas KC(13), KS_backslash, KS_dead_grave, KS_dead_acute,
231 1.1 thomas KC(27), KS_dead_diaeresis, KS_dead_circumflex, KS_dead_tilde,
232 1.1 thomas KC(39), KS_oslash,
233 1.1 thomas KC(40), KS_ae,
234 1.1 thomas KC(41), KS_bar, KS_paragraph,
235 1.1 thomas KC(86), KS_less, KS_greater,
236 1.1 thomas };
237 1.1 thomas
238 1.1 thomas static const keysym_t atarikbd_keydesc_no_nodead[] = {
239 1.1 thomas /* pos normal shifted altgr shift-altgr */
240 1.1 thomas KC(13), KS_backslash, KS_grave, KS_acute,
241 1.1 thomas KC(27), KS_diaeresis, KS_asciicircum, KS_asciitilde,
242 1.1 thomas };
243 1.1 thomas
244 1.1 thomas static const keysym_t atarikbd_keydesc_fr[] = {
245 1.1 thomas /* pos normal shifted altgr shift-altgr */
246 1.1 thomas KC(2), KS_ampersand, KS_1,
247 1.1 thomas KC(3), KS_eacute, KS_2, KS_asciitilde,
248 1.1 thomas KC(4), KS_quotedbl, KS_3, KS_numbersign,
249 1.1 thomas KC(5), KS_apostrophe, KS_4, KS_braceleft,
250 1.1 thomas KC(6), KS_parenleft, KS_5, KS_bracketleft,
251 1.1 thomas KC(7), KS_minus, KS_6, KS_bar,
252 1.1 thomas KC(8), KS_egrave, KS_7, KS_grave,
253 1.1 thomas KC(9), KS_underscore, KS_8, KS_backslash,
254 1.1 thomas KC(10), KS_ccedilla, KS_9, KS_asciicircum,
255 1.1 thomas KC(11), KS_agrave, KS_0, KS_at,
256 1.1 thomas KC(12), KS_parenright, KS_degree, KS_bracketright,
257 1.1 thomas KC(13), KS_equal, KS_plus, KS_braceright,
258 1.1 thomas KC(16), KS_a,
259 1.1 thomas KC(17), KS_z,
260 1.1 thomas KC(26), KS_dead_circumflex, KS_dead_diaeresis,
261 1.1 thomas KC(27), KS_dollar, KS_sterling, KS_currency,
262 1.1 thomas KC(30), KS_q,
263 1.1 thomas KC(39), KS_m,
264 1.1 thomas KC(40), KS_ugrave, KS_percent,
265 1.1 thomas KC(41), KS_twosuperior, KS_asciitilde,
266 1.1 thomas KC(43), KS_asterisk, KS_mu,
267 1.1 thomas KC(44), KS_w,
268 1.1 thomas KC(50), KS_comma, KS_question,
269 1.1 thomas KC(51), KS_semicolon, KS_period,
270 1.1 thomas KC(52), KS_colon, KS_slash,
271 1.1 thomas KC(53), KS_exclam, KS_section,
272 1.1 thomas KC(86), KS_less, KS_greater,
273 1.1 thomas KC(184), KS_Mode_switch, KS_Multi_key,
274 1.1 thomas };
275 1.1 thomas
276 1.1 thomas static const keysym_t atarikbd_keydesc_it[] = {
277 1.1 thomas /* pos normal shifted altgr shift-altgr */
278 1.1 thomas KC(3), KS_2, KS_quotedbl, KS_twosuperior,
279 1.1 thomas KC(4), KS_3, KS_sterling, KS_threesuperior,
280 1.1 thomas KC(5), KS_4, KS_dollar,
281 1.1 thomas KC(6), KS_5, KS_percent,
282 1.1 thomas KC(7), KS_6, KS_ampersand,
283 1.1 thomas KC(8), KS_7, KS_slash,
284 1.1 thomas KC(9), KS_8, KS_parenleft,
285 1.1 thomas KC(10), KS_9, KS_parenright,
286 1.1 thomas KC(11), KS_0, KS_equal,
287 1.1 thomas KC(12), KS_apostrophe, KS_question,
288 1.1 thomas KC(13), KS_igrave, KS_asciicircum,
289 1.1 thomas KC(26), KS_egrave, KS_eacute, KS_braceleft, KS_bracketleft,
290 1.1 thomas KC(27), KS_plus, KS_asterisk, KS_braceright, KS_bracketright,
291 1.1 thomas KC(39), KS_ograve, KS_Ccedilla, KS_at,
292 1.1 thomas KC(40), KS_agrave, KS_degree, KS_numbersign,
293 1.1 thomas KC(41), KS_backslash, KS_bar,
294 1.1 thomas KC(43), KS_ugrave, KS_section,
295 1.1 thomas KC(51), KS_comma, KS_semicolon,
296 1.1 thomas KC(52), KS_period, KS_colon,
297 1.1 thomas KC(53), KS_minus, KS_underscore,
298 1.1 thomas KC(86), KS_less, KS_greater,
299 1.1 thomas KC(184), KS_Mode_switch, KS_Multi_key,
300 1.1 thomas };
301 1.1 thomas
302 1.1 thomas static const keysym_t atarikbd_keydesc_uk[] = {
303 1.1 thomas /* pos normal shifted altgr shift-altgr */
304 1.1 thomas KC(2), KS_1, KS_exclam, KS_plusminus, KS_exclamdown,
305 1.1 thomas KC(3), KS_2, KS_quotedbl, KS_twosuperior, KS_cent,
306 1.1 thomas KC(4), KS_3, KS_sterling, KS_threesuperior,
307 1.1 thomas KC(5), KS_4, KS_dollar, KS_acute, KS_currency,
308 1.1 thomas KC(6), KS_5, KS_percent, KS_mu, KS_yen,
309 1.1 thomas KC(7), KS_6, KS_asciicircum, KS_paragraph,
310 1.1 thomas KC(8), KS_7, KS_ampersand, KS_periodcentered, KS_brokenbar,
311 1.1 thomas KC(9), KS_8, KS_asterisk, KS_cedilla, KS_ordfeminine,
312 1.1 thomas KC(10), KS_9, KS_parenleft, KS_onesuperior, KS_diaeresis,
313 1.1 thomas KC(11), KS_0, KS_parenright, KS_masculine, KS_copyright,
314 1.1 thomas KC(12), KS_minus, KS_underscore, KS_hyphen, KS_ssharp,
315 1.1 thomas KC(13), KS_equal, KS_plus, KS_onehalf, KS_guillemotleft,
316 1.1 thomas KC(40), KS_apostrophe, KS_at, KS_section, KS_Agrave,
317 1.1 thomas KC(41), KS_grave, KS_grave, KS_agrave, KS_agrave,
318 1.1 thomas KC(43), KS_numbersign, KS_asciitilde, KS_sterling, KS_thorn,
319 1.1 thomas KC(86), KS_backslash, KS_bar, KS_Udiaeresis,
320 1.1 thomas };
321 1.1 thomas
322 1.1 thomas static const keysym_t atarikbd_keydesc_jp[] = {
323 1.1 thomas /* pos normal shifted altgr shift-altgr */
324 1.1 thomas KC(3), KS_2, KS_quotedbl,
325 1.1 thomas KC(7), KS_6, KS_ampersand,
326 1.1 thomas KC(8), KS_7, KS_apostrophe,
327 1.1 thomas KC(9), KS_8, KS_parenleft,
328 1.1 thomas KC(10), KS_9, KS_parenright,
329 1.1 thomas KC(11), KS_0,
330 1.1 thomas KC(12), KS_minus, KS_equal,
331 1.1 thomas KC(13), KS_asciicircum, KS_asciitilde,
332 1.1 thomas KC(26), KS_at, KS_grave,
333 1.1 thomas KC(27), KS_bracketleft, KS_braceleft,
334 1.1 thomas KC(39), KS_semicolon, KS_plus,
335 1.1 thomas KC(40), KS_colon, KS_asterisk,
336 1.1 thomas KC(41), KS_Zenkaku_Hankaku, /* replace grave/tilde */
337 1.1 thomas KC(43), KS_bracketright, KS_braceright,
338 1.1 thomas KC(112), KS_Hiragana_Katakana,
339 1.1 thomas KC(115), KS_backslash, KS_underscore,
340 1.1 thomas KC(121), KS_Henkan,
341 1.1 thomas KC(123), KS_Muhenkan,
342 1.1 thomas KC(125), KS_backslash, KS_bar,
343 1.1 thomas };
344 1.1 thomas
345 1.1 thomas static const keysym_t atarikbd_keydesc_es[] = {
346 1.1 thomas /* pos normal shifted altgr shift-altgr */
347 1.1 thomas KC(2), KS_1, KS_exclam, KS_bar,
348 1.1 thomas KC(3), KS_2, KS_quotedbl, KS_at,
349 1.1 thomas KC(4), KS_3, KS_periodcentered, KS_numbersign,
350 1.1 thomas KC(5), KS_4, KS_dollar, KS_asciitilde,
351 1.1 thomas KC(7), KS_6, KS_ampersand,
352 1.1 thomas KC(8), KS_7, KS_slash,
353 1.1 thomas KC(9), KS_8, KS_parenleft,
354 1.1 thomas KC(10), KS_9, KS_parenright,
355 1.1 thomas KC(11), KS_0, KS_equal,
356 1.1 thomas KC(12), KS_apostrophe, KS_question,
357 1.1 thomas KC(13), KS_exclamdown, KS_questiondown,
358 1.1 thomas KC(26), KS_dead_grave, KS_dead_circumflex, KS_bracketleft,
359 1.1 thomas KC(27), KS_plus, KS_asterisk, KS_bracketright,
360 1.1 thomas KC(39), KS_ntilde,
361 1.1 thomas KC(40), KS_dead_acute, KS_dead_diaeresis, KS_braceleft,
362 1.1 thomas KC(41), KS_degree, KS_ordfeminine, KS_backslash,
363 1.1 thomas KC(43), KS_ccedilla, KS_Ccedilla, KS_braceright,
364 1.1 thomas KC(51), KS_comma, KS_semicolon,
365 1.1 thomas KC(52), KS_period, KS_colon,
366 1.1 thomas KC(53), KS_minus, KS_underscore,
367 1.1 thomas KC(86), KS_less, KS_greater,
368 1.1 thomas KC(184), KS_Mode_switch, KS_Multi_key,
369 1.1 thomas };
370 1.1 thomas
371 1.1 thomas static const keysym_t atarikbd_keydesc_us_declk[] = {
372 1.1 thomas /* pos normal shifted altgr shift-altgr */
373 1.1 thomas KC(1), KS_grave, KS_asciitilde, /* replace escape */
374 1.1 thomas KC(41), KS_less, KS_greater, /* replace grave/tilde */
375 1.1 thomas KC(143), KS_Multi_key, /* left compose */
376 1.1 thomas KC(157), KS_Multi_key, /* right compose, replace right control */
377 1.1 thomas KC(87), KS_Cmd_Debugger, KS_Escape, /* replace F11 */
378 1.1 thomas KC(189), KS_f13,
379 1.1 thomas KC(190), KS_f14,
380 1.1 thomas KC(191), KS_Help,
381 1.1 thomas KC(192), KS_Execute,
382 1.1 thomas KC(193), KS_f17,
383 1.1 thomas KC(183), KS_f18,
384 1.1 thomas KC(70), KS_f19, /* replace scroll lock */
385 1.1 thomas KC(127), KS_f20, /* replace break */
386 1.1 thomas KC(69), KS_KP_F1, /* replace num lock */
387 1.1 thomas KC(181), KS_KP_F2, /* replace divide */
388 1.1 thomas KC(55), KS_KP_F3, /* replace multiply */
389 1.1 thomas KC(74), KS_KP_F4, /* replace subtract */
390 1.1 thomas
391 1.1 thomas /* keypad is numbers only - no num lock */
392 1.1 thomas KC(71), KS_KP_7,
393 1.1 thomas KC(72), KS_KP_8,
394 1.1 thomas KC(73), KS_KP_9,
395 1.1 thomas KC(75), KS_KP_4,
396 1.1 thomas KC(76), KS_KP_5,
397 1.1 thomas KC(77), KS_KP_6,
398 1.1 thomas KC(79), KS_KP_1,
399 1.1 thomas KC(80), KS_KP_2,
400 1.1 thomas KC(81), KS_KP_3,
401 1.1 thomas KC(82), KS_KP_0,
402 1.1 thomas KC(83), KS_KP_Decimal,
403 1.1 thomas
404 1.1 thomas KC(206), KS_KP_Subtract,
405 1.1 thomas KC(78), KS_KP_Separator, /* replace add */
406 1.1 thomas KC(199), KS_Find, /* replace home */
407 1.1 thomas KC(207), KS_Select, /* replace end */
408 1.1 thomas };
409 1.1 thomas
410 1.1 thomas static const keysym_t atarikbd_keydesc_us_dvorak[] = {
411 1.1 thomas /* pos command normal shifted */
412 1.1 thomas KC(12), KS_bracketleft, KS_braceleft,
413 1.1 thomas KC(13), KS_bracketright, KS_braceright,
414 1.1 thomas KC(16), KS_apostrophe, KS_quotedbl,
415 1.1 thomas KC(17), KS_comma, KS_less,
416 1.1 thomas KC(18), KS_period, KS_greater,
417 1.1 thomas KC(19), KS_p,
418 1.1 thomas KC(20), KS_y,
419 1.1 thomas KC(21), KS_f,
420 1.1 thomas KC(22), KS_g,
421 1.1 thomas KC(23), KS_c,
422 1.1 thomas KC(24), KS_r,
423 1.1 thomas KC(25), KS_l,
424 1.1 thomas KC(26), KS_slash, KS_question,
425 1.1 thomas KC(27), KS_equal, KS_plus,
426 1.1 thomas KC(31), KS_o,
427 1.1 thomas KC(32), KS_e,
428 1.1 thomas KC(33), KS_u,
429 1.1 thomas KC(34), KS_i,
430 1.1 thomas KC(35), KS_d,
431 1.1 thomas KC(36), KS_h,
432 1.1 thomas KC(37), KS_t,
433 1.1 thomas KC(38), KS_n,
434 1.1 thomas KC(39), KS_s,
435 1.1 thomas KC(40), KS_minus, KS_underscore,
436 1.1 thomas KC(44), KS_semicolon, KS_colon,
437 1.1 thomas KC(45), KS_q,
438 1.1 thomas KC(46), KS_j,
439 1.1 thomas KC(47), KS_k,
440 1.1 thomas KC(48), KS_x,
441 1.1 thomas KC(49), KS_b,
442 1.1 thomas KC(51), KS_w,
443 1.1 thomas KC(52), KS_v,
444 1.1 thomas KC(53), KS_z,
445 1.1 thomas };
446 1.1 thomas
447 1.1 thomas static const keysym_t atarikbd_keydesc_swapctrlcaps[] = {
448 1.1 thomas /* pos command normal shifted */
449 1.1 thomas KC(29), KS_Caps_Lock,
450 1.1 thomas KC(58), KS_Cmd1, KS_Control_L,
451 1.1 thomas };
452 1.1 thomas
453 1.1 thomas static const keysym_t atarikbd_keydesc_iopener[] = {
454 1.1 thomas /* pos command normal shifted */
455 1.1 thomas KC(59), KS_Cmd_Debugger, KS_Escape,
456 1.1 thomas KC(60), KS_Cmd_Screen0, KS_f1,
457 1.1 thomas KC(61), KS_Cmd_Screen1, KS_f2,
458 1.1 thomas KC(62), KS_Cmd_Screen2, KS_f3,
459 1.1 thomas KC(63), KS_Cmd_Screen3, KS_f4,
460 1.1 thomas KC(64), KS_Cmd_Screen4, KS_f5,
461 1.1 thomas KC(65), KS_Cmd_Screen5, KS_f6,
462 1.1 thomas KC(66), KS_Cmd_Screen6, KS_f7,
463 1.1 thomas KC(67), KS_Cmd_Screen7, KS_f8,
464 1.1 thomas KC(68), KS_Cmd_Screen8, KS_f9,
465 1.1 thomas KC(87), KS_Cmd_Screen9, KS_f10,
466 1.1 thomas KC(88), KS_f11,
467 1.1 thomas };
468 1.1 thomas
469 1.1 thomas #define KBD_MAP(name, base, map) \
470 1.1 thomas { name, base, sizeof(map)/sizeof(keysym_t), map }
471 1.1 thomas /* KBD_NULLMAP generates a entry for machine native variant.
472 1.1 thomas the entry will be modified by machine dependent keyboard driver. */
473 1.1 thomas #define KBD_NULLMAP(name, base) { name, base, 0, 0 }
474 1.1 thomas
475 1.1 thomas const struct wscons_keydesc atarikbd_keydesctab[] = {
476 1.1 thomas KBD_MAP(KB_US, 0, atarikbd_keydesc_us),
477 1.1 thomas KBD_MAP(KB_DE, KB_US, atarikbd_keydesc_de),
478 1.1 thomas KBD_MAP(KB_DE | KB_NODEAD, KB_DE, atarikbd_keydesc_de_nodead),
479 1.1 thomas KBD_MAP(KB_FR, KB_US, atarikbd_keydesc_fr),
480 1.1 thomas KBD_MAP(KB_DK, KB_US, atarikbd_keydesc_dk),
481 1.1 thomas KBD_MAP(KB_DK | KB_NODEAD, KB_DK, atarikbd_keydesc_dk_nodead),
482 1.1 thomas KBD_MAP(KB_IT, KB_US, atarikbd_keydesc_it),
483 1.1 thomas KBD_MAP(KB_UK, KB_US, atarikbd_keydesc_uk),
484 1.1 thomas KBD_MAP(KB_JP, KB_US, atarikbd_keydesc_jp),
485 1.1 thomas KBD_MAP(KB_SV, KB_DK, atarikbd_keydesc_sv),
486 1.1 thomas KBD_MAP(KB_SV | KB_NODEAD, KB_SV, atarikbd_keydesc_sv_nodead),
487 1.1 thomas KBD_MAP(KB_NO, KB_DK, atarikbd_keydesc_no),
488 1.1 thomas KBD_MAP(KB_NO | KB_NODEAD, KB_NO, atarikbd_keydesc_no_nodead),
489 1.1 thomas KBD_MAP(KB_US | KB_DECLK, KB_US, atarikbd_keydesc_us_declk),
490 1.1 thomas KBD_MAP(KB_US | KB_DVORAK, KB_US, atarikbd_keydesc_us_dvorak),
491 1.1 thomas KBD_MAP(KB_US | KB_SWAPCTRLCAPS, KB_US, atarikbd_keydesc_swapctrlcaps),
492 1.1 thomas KBD_MAP(KB_US | KB_IOPENER, KB_US, atarikbd_keydesc_iopener),
493 1.1 thomas KBD_MAP(KB_JP | KB_SWAPCTRLCAPS, KB_JP, atarikbd_keydesc_swapctrlcaps),
494 1.1 thomas KBD_MAP(KB_FR | KB_SWAPCTRLCAPS, KB_FR, atarikbd_keydesc_swapctrlcaps),
495 1.1 thomas KBD_MAP(KB_US | KB_DVORAK | KB_SWAPCTRLCAPS, KB_US | KB_DVORAK,
496 1.1 thomas atarikbd_keydesc_swapctrlcaps),
497 1.1 thomas KBD_MAP(KB_US | KB_IOPENER | KB_SWAPCTRLCAPS, KB_US | KB_IOPENER,
498 1.1 thomas atarikbd_keydesc_swapctrlcaps),
499 1.1 thomas KBD_MAP(KB_ES , KB_US, atarikbd_keydesc_es),
500 1.1 thomas KBD_NULLMAP(KB_US | KB_MACHDEP, KB_US),
501 1.1 thomas KBD_NULLMAP(KB_JP | KB_MACHDEP, KB_JP),
502 1.1 thomas KBD_NULLMAP(KB_US | KB_MACHDEP | KB_SWAPCTRLCAPS,
503 1.1 thomas KB_US | KB_SWAPCTRLCAPS),
504 1.1 thomas KBD_NULLMAP(KB_JP | KB_MACHDEP | KB_SWAPCTRLCAPS,
505 1.1 thomas KB_JP | KB_SWAPCTRLCAPS),
506 1.1 thomas {0, 0, 0, 0}
507 1.1 thomas };
508 1.1 thomas
509 1.1 thomas #undef KBD_MAP
510 1.1 thomas #undef KC
511