/[rdesktop]/sourceforge.net/trunk/rdesktop/doc/keymapping.txt
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /sourceforge.net/trunk/rdesktop/doc/keymapping.txt

Parent Directory Parent Directory | Revision Log Revision Log


Revision 104 - (hide annotations)
Sun Sep 1 10:22:14 2002 UTC (21 years, 9 months ago) by astrand
File MIME type: text/plain
File size: 3808 byte(s)
Added keymapping doc

1 astrand 104 Keyboard mapping
2     ================
3     This release of rdesktop uses a new, portable keyboard mapping
4     implementation. It should hopefully work on all X11 systems. This new
5     implementation only looks at X11 keysyms: Not on (nonportable)
6     keycodes or modifier status. This means that rdesktop will obey your
7     local keyboard configuration. For example, if you have swapped
8     CapsLock and Control, rdesktop will use this mapping.
9    
10     XKB is currently not used. It seems like a good idea to me, but since
11     some X servers (like Xvnc) does not support XKB, we still need to use
12     the plain old interface as well, at least.
13    
14     There are still some small problems.
15    
16     * NumLock handling: NumLock is switched off when typing a non-numlock
17     key. rdesktop does not know which keys are NumLock-dependent and
18     not. When you type a numlock-dependent key again, NumLock is
19     switched on on the server again. The only problem really is that the
20     NumLock indicator in Wordpad etc switches on and off when you type.
21    
22     * CapsLock: CapsLock changes are never sent to the RDP server. This is
23     a problem of the same type as NumLock: rdesktop does not know which
24     keys that are modified by CapsLock and which are not. So, the
25     CapsLock indicator in Wordpad etc will always be off.
26    
27     Composing/Multi_key is supported. For more information, see:
28    
29     MIT: $SRC/xc/nls/X11/locale/Compose/iso8859-1
30     XFree86: /usr/X11R6/lib/X11/locale/*/Compose
31     Solaris' Openwin: /usr/openwin/include/X11/Suncompose.h
32     /usr/openwin/lib/locale/*/Compose
33     Irix6: compose(5)
34    
35    
36     Keymap-files
37     ============
38     The keymaps are line based. There are three different types of lines:
39    
40     1) include-lines
41     Syntax:
42     include <another-map-file>
43    
44    
45     2) map-lines
46     Syntax:
47     map <hex-number>
48    
49     Map-lines specifies how the remote RDP server should interpret the
50     sent scancodes.
51    
52    
53     3) Translation-lines
54     Syntax:
55     <keysym-name> <scancode> [flags..]
56    
57     The scancode can be found in scancodes.h. Note: The scancode value for
58     extended keys can be calculated by OR:ing with 0x80. Example: The
59     Delete key have the scancode sequence 0xe0, 0x52. You can get the
60     scancode value to put into the map file by running:
61    
62     python -c "print hex(0x80 | 0x52)"
63    
64     If flags are "altgr", "shift", "numlock", the scancode sent for this
65     keysym will be prefix with AltGr, Shift or Numlock.
66    
67     If flags include "addupper", an translation for this keysyms uppercase
68     name will as well, in addition to the non-uppercase name. Example:
69    
70     x 2d addupper
71    
72     ...will add an translation for "X" automatically, just like if you
73     would specify:
74    
75     X 2d shift
76    
77     If flags include "localstate", the modifier to send will be determined
78     by the local modifier state.
79    
80    
81     4) enable_compose
82    
83     If any line starts with the keyword "enable_compose", rdesktop will
84     enable local Compose/Multi_key handling. Enabling this will often make
85     it impossible to compose characters with dead keys (on the remote
86     side). This is because when local compose support is enabled, dead
87     keys will not be sent to the remote side.
88    
89    
90     Suggested X11 keysym mapping on PCs
91     ===================================
92     Unfortunately, there is no standard for which keysyms a given key
93     should generate. If you have a PC-keyboard with Windows keys, I suggest this mapping:
94    
95     Keyboard keys:
96     CtrlLeft WinLeft AltLeft Space AltGr WinRight Menu CtrlRight
97    
98     ...should generate keysyms:
99     Control_L Hyper_L Alt_L space Mode_switch Hyper_R Menu Control_R
100    
101     Additionally:
102     Shift-Alt should produce Meta_L
103     Shift-AltGr should produce Multi_Key.
104    
105     Use a modifier-map like this:
106    
107     shift Shift_L (0x32), Shift_R (0x3e)
108     lock Caps_Lock (0x25)
109     control Control_L (0x42), Control_R (0x6d)
110     mod1 Alt_L (0x40)
111     mod2 Num_Lock (0x4d)
112     mod3 Mode_switch (0x71)
113     mod4 Hyper_L (0x73), Hyper_R (0x74)
114     mod5 Scroll_Lock (0x4e)

  ViewVC Help
Powered by ViewVC 1.1.26