宏碁笔记本电脑左控制键无法识别 ubuntu 18.04

宏碁笔记本电脑左控制键无法识别 ubuntu 18.04

我最近买了一台安装了 Ubuntu 16.04 的二手 Acer Aspire-ES1-511。我发现左 Ctrl 键不起作用,但右键可以工作。xev我发现按下左键时会显示 FocusOut 和 FocusIn 事件,而右键(正确)会显示 KeyPress 和 KeyRelease 事件。我查看了快捷方式设置,但什么也没找到。我查看了键盘配置,什么也没找到。我升级到了 Ubuntu 18.04.2 LTS,但没有任何变化。我寻找了“显示键盘布局”实用程序,但找不到,事实上,标题栏中也没有菜单选项用于更改键盘语言,如https://linoxide.com/linux-how-to/configure-keyboard-ubuntu/ 我尝试重置所有键盘快捷键,但没有什么效果。如果我使用 Ctrl-Alt-F3 切换到不同的虚拟终端,组合键被识别,并且 Ctrl-C 在提示符下按预期工作。

很清楚某物在 GUI 中修改了左 Ctrl 键的行为,但我无法识别什么正在做。

对于左 Ctrl 键,xev显示此输出:

FocusOut event, serial 34, synthetic NO, window 0x3000001,
    mode NotifyGrab, detail NotifyAncestor

FocusIn event, serial 34, synthetic NO, window 0x3000001,
    mode NotifyUngrab, detail NotifyAncestor

KeymapNotify event, serial 34, synthetic NO, window 0x0,
    keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0
           0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0

对于右侧的 Ctrl 键,xev显示此输出:

KeyPress event, serial 34, synthetic NO, window 0x3000001,
    root 0x13e, subw 0x0, time 3247932, (96,-19), root:(1249,175),
    state 0x0, keycode 105 (keysym 0xffe4, Control_R), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 37, synthetic NO, window 0x3000001,
    root 0x13e, subw 0x0, time 3248126, (96,-19), root:(1249,175),
    state 0x4, keycode 105 (keysym 0xffe4, Control_R), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

其他信息:

$ kbdcontrol
kbdcontrol: command not found

$ console-setup
console-setup: command not found

$ cat /etc/default/keyboard
# KEYBOARD CONFIGURATION FILE

# Consult the keyboard(5) manual page.

XKBMODEL="acer_laptop"
XKBLAYOUT="us"
XKBVARIANT=""
XKBOPTIONS=""

BACKSPACE="guess"

$ xmodmap -pm
xmodmap:  up to 4 keys per modifier, (keycodes in parentheses):

shift       Shift_L (0x32),  Shift_R (0x3e)
lock        Caps_Lock (0x42)
control     Control_L (0x25),  Control_R (0x69)
mod1        Alt_L (0x40),  Alt_R (0x6c),  Meta_L (0xcd)
mod2        Num_Lock (0x4d)
mod3      
mod4        Super_L (0x85),  Super_R (0x86),  Super_L (0xce),  Hyper_L (0xcf)
mod5        ISO_Level3_Shift (0x5c),  Mode_switch (0xcb)

$ uname -a
Linux acer-Aspire-ES1-511 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

我还应该提供哪些信息?

答案1

在与这个问题(断断续续)斗争了三个星期后,我今天偶然发现了根本原因。安装后,dconf-tools我可以运行dconf-editor,我查看了一下org.gnome.desktop.wm.keybindings,发现两个分配不是默认状态: toggle-shaded设置为'<Ctrl><Alt>s'(IIRC),move-to-workspace-12设置为'Control_L'。当我删除move-to-workspace-12分配时,左侧控制键立即开始正常工作。

请注意,toggle-shaded分配是一个正确构造的映射,但不是move-to-workspace-12:我认为有人打算分配<Ctrl>L'给该绑定,但是当他们将其设置为时'Control_L',他们破坏了键盘。

相关内容