Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #286789
| From | Lionel Élie Mamane <lionel@mamane.lu> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | altwin:left_meta_win - emacs super and meta on same key |
| Date | 2026-05-21 12:30 +0200 |
| Message-ID | <MX8P7-6LF7-1@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Hi,
I'm using GNU Emacs from Debian package emacs-lucid version 1:30.1+1-6
on xorg version 1:7.7+24+deb13u1 with xkb-data version 2.42-1.
My keyboard is a Microsoft branded one, with menu, left and right
"Microsoft Windows logo" keys and emoji key, along with a top bar of
"multimedia" keys that are physically distinct from the F1-F12 keys.
My /etc/default/keyboard contains
XKBMODEL="microsoft4000"
XKBLAYOUT="us"
XKBVARIANT="euro"
XKBOPTIONS="altwin:left_meta_win,compose:menu"
BACKSPACE="guess"
I've been using altwin:left_meta_win since "forever", certainly since
I've had keyboard with "Microsoft Windows logo" keys, which might be
as long as I've been using GNU/Linux and X11, a few decades ago. Its
effect is to put the meta key on the left "Microsoft Windows logo"
key, so that I have separate Meta key (useful in Emacs) and Alt key
(that I use mainly for window manager bindings).
But now Emacs has started to treat the left Microsoft Windows logo key
as meta _and_ super at the same time, so that any binding in emacs
that uses Meta is unusable, because emacs will say I pressed M-s-FOO
when I pressed left Microsoft Windows logo key + FOO, which used to be
just M-FOO. For example, left Microsoft Windows logo key + d, instead
of being understood as M-d (bound to kill-word) is being understood as
M-s-d and emacs says "M-s-d is undefined".
I don't know if the change comes from an upgrade of emacs or of
xkb/xorg, as I rarely close my emacs (daemon) or my X11 session (I
rebooted for the latest high impact Linux security holes, my uptime
before that was > 300 days).
When I press and depress the left Microsoft Windows logo key with xev
having focus, the events are:
KeyPress event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60567700, (116,80), root:(1826,1536),
state 0x10, keycode 133 (keysym 0xffe7, Meta_L), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyRelease event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60567892, (116,80), root:(1826,1536),
state 0x50, keycode 133 (keysym 0xffe7, Meta_L), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
When I press left Microsoft Windows logo key + d with xev having
focus, the events are:
KeyPress event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60643492, (89,77), root:(1786,1513),
state 0x10, keycode 133 (keysym 0xffe7, Meta_L), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyPress event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60645396, (89,77), root:(1786,1513),
state 0x50, keycode 40 (keysym 0x64, d), same_screen YES,
XLookupString gives 1 bytes: (64) "d"
XmbLookupString gives 1 bytes: (64) "d"
XFilterEvent returns: False
KeyRelease event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60645580, (89,77), root:(1786,1513),
state 0x50, keycode 40 (keysym 0x64, d), same_screen YES,
XLookupString gives 1 bytes: (64) "d"
XFilterEvent returns: False
KeyRelease event, serial 37, synthetic NO, window 0x5c00001,
root 0x3cb, subw 0x0, time 60645756, (89,77), root:(1786,1513),
state 0x50, keycode 133 (keysym 0xffe7, Meta_L), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
showing that state bit 0x40 gets set on the "d" press.
"xmodmodmap" output:
shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25), Control_R (0x69)
mod1 Alt_L (0x40), Alt_L (0xcc)
mod2 Num_Lock (0x4d)
mod3 ISO_Level5_Shift (0xcb)
mod4 Meta_L (0x85), Super_R (0x86), Meta_L (0xcd), Super_L (0xce), Hyper_L (0xcf)
mod5 ISO_Level3_Shift (0x5c)
I tried "xmodmap -e 'remove mod4 = Super_R Super_L Hyper_L'" to get
mod4 Meta_L (0x85), Meta_L (0xcd)
+ start a new emacs, but it did not change anything.
I would really really appreciate any hint on how to fix this.
Thanks!
--
Lionel
Back to linux.debian.user | Previous | Next — Next in thread | Find similar
altwin:left_meta_win - emacs super and meta on same key Lionel Élie Mamane <lionel@mamane.lu> - 2026-05-21 12:30 +0200 Re: altwin:left_meta_win - emacs super and meta on same key Lionel Élie Mamane <lionel@mamane.lu> - 2026-05-21 13:00 +0200 Re: altwin:left_meta_win - emacs super and meta on same key Stefan Monnier <monnier@iro.umontreal.ca> - 2026-05-21 22:30 +0200 Re: altwin:left_meta_win - emacs super and meta on same key Max Nikulin <manikulin@gmail.com> - 2026-05-24 06:20 +0200
csiph-web