VirtualBox

source: vbox/trunk/src/VBox/Frontends/Common/VBoxKeyboard/xkbtoscan.h@ 47908

Last change on this file since 47908 was 44325, checked in by vboxsync, 12 years ago

FE/Common/Keyboard: missing the XKB name for a Japanese keyboard key and added some more for completeness.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 7.3 KB
Line 
1/* $Id: xkbtoscan.h 44325 2013-01-22 07:26:21Z vboxsync $ */
2/** @file
3 * VBox/Frontends/Common - X11 keyboard driver translation tables (XT scan
4 * code mappings for XKB key names).
5 */
6
7/*
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
12 *
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 */
22
23/*
24 * Oracle LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
25 * other than GPL or LGPL is available it will apply instead, Oracle elects to use only
26 * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
27 * a choice of LGPL license versions is made available with the language indicating
28 * that LGPLv2 or any later version may be used, or where a choice of which version
29 * of the LGPL is applied is otherwise unspecified.
30 */
31
32#ifndef ___VBox_keyboard_tables_h
33# error This file must be included from within keyboard-tables.h
34#endif /* ___VBox_keyboard_tables_h */
35
36enum { XKB_NAME_SIZE = 4 };
37
38/**
39 * This table contains a list of mappings of XKB key names to XT scan codes.
40 * We only use XKB to look up layout-dependent keys (mainly the alpha-numeric
41 * ones), so that user re-mappings will work at least for the remaining keys.
42 * This is the reason for the commented out entries in the table.
43 */
44struct
45{
46 const char cszName[XKB_NAME_SIZE];
47 unsigned uScan;
48} xkbMap[] =
49{
50/* { "ESC", 0x1 }, */
51 { "AE01", 0x2 },
52 { "AE02", 0x3 },
53 { "AE03", 0x4 },
54 { "AE04", 0x5 },
55 { "AE05", 0x6 },
56 { "AE06", 0x7 },
57 { "AE07", 0x8 },
58 { "AE08", 0x9 },
59 { "AE09", 0xa },
60 { "AE10", 0xb },
61 { "AE11", 0xc },
62 { "AE12", 0xd },
63/* { "BKSP", 0xe },
64 { "TAB", 0xf }, */
65 { "AD01", 0x10 },
66 { "AD02", 0x11 },
67 { "AD03", 0x12 },
68 { "AD04", 0x13 },
69 { "AD05", 0x14 },
70 { "AD06", 0x15 },
71 { "AD07", 0x16 },
72 { "AD08", 0x17 },
73 { "AD09", 0x18 },
74 { "AD10", 0x19 },
75 { "AD11", 0x1a },
76 { "AD12", 0x1b },
77/* { "RTRN", 0x1c },
78 { "LCTL", 0x1d }, */
79 { "AC01", 0x1e },
80 { "AC02", 0x1f },
81 { "AC03", 0x20 },
82 { "AC04", 0x21 },
83 { "AC05", 0x22 },
84 { "AC06", 0x23 },
85 { "AC07", 0x24 },
86 { "AC08", 0x25 },
87 { "AC09", 0x26 },
88 { "AC10", 0x27 },
89 { "AC11", 0x28 },
90 { "AC12", 0x2b },
91 { "TLDE", 0x29 },
92/* { "LFSH", 0x2a }, */
93 { "BKSL", 0x2b },
94 { "AB01", 0x2c },
95 { "AB02", 0x2d },
96 { "AB03", 0x2e },
97 { "AB04", 0x2f },
98 { "AB05", 0x30 },
99 { "AB06", 0x31 },
100 { "AB07", 0x32 },
101 { "AB08", 0x33 },
102 { "AB09", 0x34 },
103 { "AB10", 0x35 },
104/* { "RTSH", 0x36 },
105 { "KPMU", 0x37 },
106 { "LALT", 0x38 },
107 { "SPCE", 0x39 },
108 { "CAPS", 0x3a },
109 { "FK01", 0x3b },
110 { "FK02", 0x3c },
111 { "FK03", 0x3d },
112 { "FK04", 0x3e },
113 { "FK05", 0x3f },
114 { "FK06", 0x40 },
115 { "FK07", 0x41 },
116 { "FK08", 0x42 },
117 { "FK09", 0x43 },
118 { "FK10", 0x44 },
119 { "NMLK", 0x145 },
120 { "SCLK", 0x46 },
121 { "KP7", 0x47 },
122 { "KP8", 0x48 },
123 { "KP9", 0x49 },
124 { "KPSU", 0x4a },
125 { "KP4", 0x4b },
126 { "KP5", 0x4c },
127 { "KP6", 0x4d },
128 { "KPAD", 0x4e },
129 { "KP1", 0x4f },
130 { "KP2", 0x50 },
131 { "KP3", 0x51 },
132 { "KP0", 0x52 },
133 { "KPDL", 0x53 },
134 { "KPPT", 0x7e },
135 { "LVL3", 0x138 }, */
136 { "LSGT", 0x56 },
137/* { "FK11", 0x57 },
138 { "FK12", 0x58 }, */
139 { "AB11", 0x73 },
140/* { "KATA", 0x0 },
141 { "HIRA", 0x0 },
142 { "HENK", 0x79 },
143 { "HKTG", 0x70 },
144 { "MUHE", 0x7b },
145 { "HZTG", 0x29 },
146 { "JPCM", 0x0 },
147 { "KPEN", 0x11c },
148 { "RCTL", 0x11d },
149 { "KPDV", 0x135 },
150 { "PRSC", 0x137 },
151 { "RALT", 0x138 },
152 { "ALGR", 0x138 },
153 { "LNFD", 0x0 },
154 { "HOME", 0x147 },
155 { "UP", 0x148 },
156 { "PGUP", 0x149 },
157 { "LEFT", 0x14b },
158 { "RGHT", 0x14d },
159 { "END", 0x14f },
160 { "DOWN", 0x150 },
161 { "PGDN", 0x151 },
162 { "INS", 0x152 },
163 { "DELE", 0x153 },
164 { "I120", 0x0 },
165 { "MUTE", 0x120 },
166 { "VOL-", 0x12e },
167 { "VOL+", 0x130 },
168 { "POWR", 0x15e },
169 { "KPEQ", 0x0 },
170 { "I126", 0x0 },
171 { "PAUS", 0x45 },
172 { "I128", 0x0 },
173 { "I129", 0x7e },
174 { "KPPT", 0x7e },
175 { "HNGL", 0xf2 },
176 { "HJCV", 0xf1 }, */
177 { "AE13", 0x7d },
178/* { "LWIN", 0x15b },
179 { "LMTA", 0x15b },
180 { "RWIN", 0x15c },
181 { "RMTA", 0x15c },
182 { "COMP", 0x15d },
183 { "MENU", 0x15d },
184 { "STOP", 0x168 },
185 { "AGAI", 0x105 },
186 { "PROP", 0x106 },
187 { "UNDO", 0x107 },
188 { "FRNT", 0x10c },
189 { "COPY", 0x118 },
190 { "OPEN", 0x65 },
191 { "PAST", 0x10a },
192 { "FIND", 0x110 },
193 { "CUT", 0x117 },
194 { "HELP", 0x175 },
195 { "I147", 0x0 },
196 { "I148", 0x0 },
197 { "I149", 0x0 },
198 { "I150", 0x15f },
199 { "I151", 0x163 },
200 { "I152", 0x0 },
201 { "I153", 0x119 },
202 { "I154", 0x0 },
203 { "I155", 0x0 },
204 { "I156", 0x0 },
205 { "I157", 0x0 },
206 { "I158", 0x0 },
207 { "I159", 0x0 },
208 { "I160", 0x120 },
209 { "I161", 0x0 },
210 { "I162", 0x122 },
211 { "I163", 0x16c },
212 { "I164", 0x124 },
213 { "I165", 0x15f },
214 { "I166", 0x16a },
215 { "I167", 0x169 },
216 { "I168", 0x0 },
217 { "I169", 0x0 },
218 { "I170", 0x0 },
219 { "I171", 0x119 },
220 { "I172", 0x122 },
221 { "I173", 0x110 },
222 { "I174", 0x12e },
223 { "I175", 0x0 },
224 { "I176", 0x130 },
225 { "I177", 0x0 },
226 { "I178", 0x0 },
227 { "I179", 0x0 },
228 { "I180", 0x132 },
229 { "I181", 0x167 },
230 { "I182", 0x140 },
231 { "I183", 0x0 },
232 { "I184", 0x0 },
233 { "I185", 0x10b },
234 { "I186", 0x18b },
235 { "I187", 0x0 },
236 { "I188", 0x0 },
237 { "I189", 0x0 },
238 { "I190", 0x105 },
239 { "FK13", 0x0 },
240 { "FK14", 0x0 },
241 { "FK15", 0x0 },
242 { "FK16", 0x0 },
243 { "FK17", 0x0 },
244 { "FK18", 0x0 },
245 { "FK19", 0x0 },
246 { "FK20", 0x0 },
247 { "FK21", 0x0 },
248 { "FK22", 0x0 },
249 { "FK23", 0x0 },
250 { "FK24", 0x0 },
251 { "MDSW", 0x138 },
252 { "ALT", 0x0 },
253 { "META", 0x0 },
254 { "SUPR", 0x0 },
255 { "HYPR", 0x0 },
256 { "I208", 0x122 },
257 { "I209", 0x122 },
258 { "I210", 0x0 },
259 { "I211", 0x0 },
260 { "I212", 0x0 },
261 { "I213", 0x0 },
262 { "I214", 0x140 },
263 { "I215", 0x122 },
264 { "I216", 0x169 },
265 { "I217", 0x0 },
266 { "I218", 0x137 },
267 { "I219", 0x0 },
268 { "I220", 0x0 },
269 { "I221", 0x0 },
270 { "I222", 0x0 },
271 { "I223", 0x0 },
272 { "I224", 0x0 },
273 { "I225", 0x165 },
274 { "I226", 0x0 },
275 { "I227", 0x0 },
276 { "I228", 0x0 },
277 { "I229", 0x165 },
278 { "I230", 0x166 },
279 { "I231", 0x167 },
280 { "I232", 0x168 },
281 { "I233", 0x169 },
282 { "I234", 0x16a },
283 { "I235", 0x16b },
284 { "I236", 0x16c },
285 { "I237", 0x16d },
286 { "I238", 0x0 },
287 { "I239", 0x143 },
288 { "I240", 0x141 },
289 { "I241", 0x0 },
290 { "I242", 0x157 },
291 { "I243", 0x105 },
292 { "I244", 0x0 },
293 { "I245", 0x0 },
294 { "I246", 0x0 },
295 { "I247", 0x0 },
296 { "I248", 0x0 },
297 { "I249", 0x0 },
298 { "I250", 0x0 },
299 { "I251", 0x0 },
300 { "I252", 0x0 },
301 { "I253", 0x0 } */
302};
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette