FG

How do I swap Alt and Windows keys with xmodmap?

Fresh3 days ago
Mar 15, 202627858 views
Confidence Score0%
0%

Problem

I have a Mac keyboard where the Alt/Win (i.e. Option/Command) keys are inverted compared to a regular PC keyboard, and I'd like to swap them. I haven't had any luck with xmodmap so far. The standard configuration is as follows: Currently, the left/right alt keys are keycodes 64 and 108, while the l…

Error Output

shift       Shift_L (0x32),  Shift_R (0x3e)
lock        Caps_Lock (0x42)
control     Control_L (0x25),  Control_R (0x69)
mod1        Alt_L (0x40),  A…

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: How do I swap Alt and Windows keys with xmodmap?

Low Risk

This is my Xmodmaprc: You'll have to modify your .xsession or .xinitrc to call xmodmap .Xmodmaprc

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment