Re: Today's stupid question: remapping AltGr to control?
On Tue, Jun 08, 2010 at 04:14:48PM +0100, David Gerard wrote: > I have a Dell Mini 9 running Ubuntu 10.04 (xorg-server > 2:1.7.6-2ubuntu7). I don't use the AltGr key *ever*, and am really > missing having a right Control key. > > Can I remap AltGr to be a control key? So far I've failed utterly with > xmodmap and xkeycaps. Failed xmodmap command: > > xmodmap -e "keysym Alt_R = Control_L" > > xkeycaps says that it thinks it's a Control but doesn't have a modifier. > > Can this actually be done? Xmodmap is ... not optimal. Applying the changes through an XKB keymap is more reliable and allows more changes. And in this case it's not much more complicated if you just want to switch the keys. Determine the keycodes with xev. Extract the keymap: $> xkbcomp ${DISPLAY} keymap.xkb Edit the keymap. At the top is the mapping from symbolic-names (eg ) to keycodes (eg 105). Within XKB all keys are addressed by symbolic names. You could just exchange the keycodes for AlgGr and Control. = 105; = 106; = 107; = 108; Load the keymap: $> xkbcomp keymap.xkb ${DISPLAY} For xmodmap, this might be helpful: https://bugs.freedesktop.org/show_bug.cgi?id=24552#c9 -- Greetings, Dirk ___ xorg@lists.freedesktop.org: X.Org support Archives: http://lists.freedesktop.org/archives/xorg Info: http://lists.freedesktop.org/mailman/listinfo/xorg Your subscription address: arch...@mail-archive.com
Re: Today's stupid question: remapping AltGr to control?
On Tue, Jun 8, 2010 at 11:14 AM, David Gerard wrote: > I have a Dell Mini 9 running Ubuntu 10.04 (xorg-server > 2:1.7.6-2ubuntu7). I don't use the AltGr key *ever*, and am really > missing having a right Control key. > > Can I remap AltGr to be a control key? So far I've failed utterly with > xmodmap and xkeycaps. Failed xmodmap command: > > xmodmap -e "keysym Alt_R = Control_L" > > xkeycaps says that it thinks it's a Control but doesn't have a modifier. > > Can this actually be done? > > > - d. > > Did you tried with the keycode instead of Alt_R ? Usually I use "xev" to get the keycode generated by the key and I map it with xmodmap -e. -- Philippe-Alexandre Lemelin ___ xorg@lists.freedesktop.org: X.Org support Archives: http://lists.freedesktop.org/archives/xorg Info: http://lists.freedesktop.org/mailman/listinfo/xorg Your subscription address: arch...@mail-archive.com
Today's stupid question: remapping AltGr to control?
I have a Dell Mini 9 running Ubuntu 10.04 (xorg-server 2:1.7.6-2ubuntu7). I don't use the AltGr key *ever*, and am really missing having a right Control key. Can I remap AltGr to be a control key? So far I've failed utterly with xmodmap and xkeycaps. Failed xmodmap command: xmodmap -e "keysym Alt_R = Control_L" xkeycaps says that it thinks it's a Control but doesn't have a modifier. Can this actually be done? - d. ___ xorg@lists.freedesktop.org: X.Org support Archives: http://lists.freedesktop.org/archives/xorg Info: http://lists.freedesktop.org/mailman/listinfo/xorg Your subscription address: arch...@mail-archive.com