将我的 OpenSuSE Leap 从 15.2 升级到 15.3 后,我发现 Compose 键(键码:135)不再起作用。实际上,xev
不再将其识别为Multi_key
,而是NoSymbol
:
KeyPress event, serial 40, synthetic NO, window 0x7800001,
root 0x561, subw 0x0, time 8470151, (923,367), root:(923,396),
state 0x10, keycode 135 (keysym 0x0, NoSymbol), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
注意:该键实际上标有Compose
,因为它是 Sun Type 7 键盘的一部分。在$XKB/keycodes/evdev
文件中,我有这两行代码(其中第二行已被我禁用,因为它适用于带有菜单键的常规 PC 键盘):
<COMP> = 135;
// alias <MENU> = <COMP>;
该$XKB/symbols/compose
文件已使用以下块升级:
partial modifier_keys
xkb_symbols "comp" {
key <COMP> { type[Group1]="TWO_LEVEL", [ Multi_key, Multi_key ] };
};
当前setxkbmap
配置如下所示:
╭─jacek@epica ~
╰─➤ setxkbmap -print -verbose 10 127 ↵
Setting verbose level to 10
locale is C
Trying to load rules file ./rules/evdev...
Trying to load rules file /usr/share/X11/xkb/rules/evdev...
Success.
Applied rules from evdev:
rules: evdev
model: pc105
layout: de
variant: pl
options: compose:comp,terminate:ctrl_alt_bksp,altwin:meta_win,lv3:ralt_switch
Trying to build keymap using the following components:
keycodes: evdev+aliases(qwertz)
types: complete
compat: complete
symbols: pc+de(pl)+inet(evdev)+terminate(ctrl_alt_bksp)+altwin(meta_win)+level3(ralt_switch)+terminate(ctrl_alt_bksp)
geometry: pc(pc105)
xkb_keymap {
xkb_keycodes { include "evdev+aliases(qwertz)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+de(pl)+inet(evdev)+terminate(ctrl_alt_bksp)+altwin(meta_win)+level3(ralt_switch)+terminate(ctrl_alt_bksp)" };
xkb_geometry { include "pc(pc105)" };
};
我可以compose:comp
很清楚地看到这个选项。所以:这里有什么问题?
好的,我自己找到了罪魁祸首:OpenSuSE 的更新服务 (resp.
zypper
)会覆盖xkb
配置文件,因此自己编辑它们通常是个坏主意!您只需在下一次 X11 更新中恢复您的改编。