VirtualBox

Opened 8 years ago

Closed 8 years ago

#16648 closed defect (wontfix)

Linux VBox 5.1 ignores modifier key mapping (xmodmap) -> design decision, see work-arounds

Reported by: jamshark70 Owned by:
Component: GUI Version: VirtualBox 5.1.18
Keywords: keyboard modifier xmodmap Cc:
Guest type: Windows Host type: Linux

Description

In Ubuntu, I use xmodmap to make ctrl and alt easier to type.

Physical keyboard, bottom row from left: Ctrl, Super, Alt, spacebar, ...

Remapped: Super, Alt, Ctrl, spacebar

clear control
clear mod1
clear mod4
clear mod5
!!!! These are the codes for the way *I* want the keys
!!!! For some reason, if Super_L appears in mod1, it doesn't work.
!!!! Hitting Alt (originally Super) by itself *acts* like Super
!!!! So I have to rename the symbols here
keycode  64 = Control_L
keycode 108 = Control_R
keycode  37 = Super_L
keycode 105 = Super_R
keycode 133 = Alt_L
keycode 134 = Alt_R
keycode 135 = Menu
add control = Control_L Control_R
add mod1    = Alt_L Alt_R
add mod4    = Super_L Super_R

Under VirtualBox 4.8, the remapping carried through into the guest OS.

In VBox 5.1, the guest seems to be catching the keystrokes before the xkb/xmodmap layer, so the remapping is broken.

https://forums.virtualbox.org/viewtopic.php?f=7&t=64108&p=309293&hilit=xmodmap#p309293

Rationale: I have a repetitive strain injury, so it's important for me to avoid unnecessary muscle movement. Ctrl is the most commonly used modifier, but it's in the worst possible place on the keyboard -- and in fact, reaching for the Ctrl key with my pinky has been extremely stressful. I get a lot of relief from moving Ctrl to be basically under my thumb.

Now I have to retrain my muscle memory to use the physical Ctrl key, but only in a VirtualBox guest. It's very bizarre... and I can't understand why it was changed, because it used to work perfectly.

I suppose the developer perspective might be, "Well, we can't support all kinds of nonstandard configurations." But... this is an adaptation for a physical condition. Software should adapt to our needs, not the other way around.

Change History (2)

comment:1 by jamshark70, 8 years ago

Oh, my apologies, I meant to change the priority to minor. I do not consider this a major defect. It's annoying but not major ;)

comment:2 by Michael Thayer, 8 years ago

Resolution: wontfix
Status: newclosed
Summary: Linux VBox 5.1 ignores modifier key mapping (xmodmap)Linux VBox 5.1 ignores modifier key mapping (xmodmap) -> design decision, see work-arounds

This was an intentional decision taken to simplify how things work. I see at least two ways for you to deal with this. One is to do the re-mapping inside your guest systems, which is the intended way. The second is to use an undocumented feature<1> which was contributed long ago and which does the re-mapping inside of VirtualBox. I must warn that I am not aware of this having been tested for years.

<1> https://www.virtualbox.org/browser/vbox/trunk/src/VBox/Frontends/VirtualBox/src/platform/x11/XKeyboard-new.cpp?rev=66480#L262

Note: See TracTickets for help on using tickets.

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