34 |
|
|
35 |
|
|
36 |
Keymap files |
Keymap files |
37 |
============= |
============ |
38 |
The keymap-files have two-letter names. These follows ISO 639 |
The names of the keymaps follows RFC1766. |
|
(2-letter codes). ISO639 can be found at |
|
|
http://www.w3.org/WAI/ER/IG/ert/iso639.htm |
|
39 |
|
|
40 |
(You can find a translation from Windows keyboard layout numbers to |
(You can find a translation from Windows keyboard layout numbers to |
41 |
keymap names by looking at |
keymap names by looking at |
124 |
mod3 Mode_switch (0x71) |
mod3 Mode_switch (0x71) |
125 |
mod4 Hyper_L (0x73), Hyper_R (0x74) |
mod4 Hyper_L (0x73), Hyper_R (0x74) |
126 |
mod5 Scroll_Lock (0x4e) |
mod5 Scroll_Lock (0x4e) |
127 |
|
|
128 |
|
|
129 |
|
Updating / writing keymap files |
130 |
|
=============================== |
131 |
|
When writing new or updating keymap files, please use comments and |
132 |
|
blanks, to increase readability. The "sv" keymap is a good template. |
133 |
|
|
134 |
|
When you need to add a translation to a keymap file, do: |
135 |
|
|
136 |
|
1. Get the "key number" for this key, by looking at keynums.png. |
137 |
|
|
138 |
|
2. Take a look at scancodes.h, and look for |
139 |
|
SCANCODE_KEY_<my-key-number>. The scancode value is at the end of |
140 |
|
the line. If the line contains (SCANCODE_EXTENDED | 0xsomething), |
141 |
|
then you should OR 0x80 to this value. For example, you can do: |
142 |
|
|
143 |
|
python -c "print hex(0x80 | 0xsomething)" |
144 |
|
|
145 |
|
3. Put the scancode (from step 2) and keysym name (found in the |
146 |
|
error message) into the keymap file. |