我使用 ubuntu 18.04 和 libinput 作为驱动程序。滚动不适用于我的系统。我尝试过更改自然滚动和两指滚动选项的所有组合,但它仍然不起作用。我运行了这个命令
xinput --list-props 12
12 是我系统中的触摸板设备 ID 以上命令的输出
Device 'SynPS/2 Synaptics TouchPad':
Device Enabled (171): 1
Coordinate Transformation Matrix (173): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Tapping Enabled (324): 1
libinput Tapping Enabled Default (325): 0
libinput Tapping Drag Enabled (326): 1
libinput Tapping Drag Enabled Default (327): 1
libinput Tapping Drag Lock Enabled (328): 0
libinput Tapping Drag Lock Enabled Default (329): 0
libinput Tapping Button Mapping Enabled (330): 1, 0
libinput Tapping Button Mapping Default (331): 1, 0
libinput Natural Scrolling Enabled (306): 1
libinput Natural Scrolling Enabled Default (307): 0
libinput Disable While Typing Enabled (332): 1
libinput Disable While Typing Enabled Default (333): 1
libinput Scroll Methods Available (308): 1, 1, 0
libinput Scroll Method Enabled (309): 1, 0, 0
libinput Scroll Method Enabled Default (310): 1, 0, 0
libinput Click Methods Available (334): 1, 1
libinput Click Method Enabled (335): 0, 1
libinput Click Method Enabled Default (336): 1, 0
libinput Middle Emulation Enabled (313): 0
libinput Middle Emulation Enabled Default (314): 0
libinput Accel Speed (315): 0.151079
libinput Accel Speed Default (316): 0.000000
libinput Left Handed Enabled (320): 0
libinput Left Handed Enabled Default (321): 0
libinput Send Events Modes Available (291): 1, 1
libinput Send Events Mode Enabled (292): 0, 0
libinput Send Events Mode Enabled Default (293): 0, 0
Device Node (294): "/dev/input/event6"
Device Product ID (295): 2, 7
libinput Drag Lock Buttons (322): <no items>
libinput Horizontal Scroll Enabled (323): 1
我的理解是因为在此列表中没有 libinput Vertical Scroll 选项,我尝试了以下命令
sudo xinput set-prop 12 "310" 1,1,0
我尝试了上面的命令所有不同的组合,但每次都会给出相同的错误
X Error of failed request: BadAccess (attempt to access private resource denied)
Major opcode of failed request: 131 (XInputExtension)
Minor opcode of failed request: 57 ()
Serial number of failed request: 19
Current serial number in output stream: 20
如果使用任何其他包可以解决它,请建议一些解决方案或任何替代方案。
答案1
您正在尝试设置只读属性“libinput Scroll Method Enabled Default”。您可能想要设置属性“libinput Scroll Method Enabled”,即 309(您也可以只使用字符串而不是数字)。