Til*_*lus 4 mouse scrolling libinput
如您所见,这是我的第一篇文章。所以,我已经尝试和研究了很多,但我仍然无法解决这个问题。
我真的很喜欢自然滚动,但不仅在我的触摸板上,而且在我的鼠标上 - 但这到目前为止还不起作用。我目前的设置是 Ubuntu 18.04.2,在 2012 年末(第一款 hidpi)MacBook 上使用 i3 wm,我使用性能 MX 罗技鼠标。这是我昨天安装的一个非常新的设置。
我确实使用突触反转了我的触摸板滚动并尝试使用 xmodkeys 修改我的鼠标键,但它不起作用。
xmodmap -e 'pointer = 1 2 3 5 4 6 7 8 9 10 11 12'
奇怪的是,当我用 xev 测试时,我的鼠标按钮实际上是倒置的(4 和 5),但这不会影响滚动行为。我也可以重新映射其他鼠标键,但滚动似乎无法改变。
xinput
? Virtual core pointer id=2 [master pointer (3)]
? ? Virtual core XTEST pointer id=4 [slave pointer (2)]
? ? Logitech Performance MX id=10 [slave pointer (2)]
? ? bcm5974 id=13 [slave pointer (2)]
? Virtual core keyboard id=3 [master keyboard (2)]
? Virtual core XTEST keyboard id=5 [slave keyboard (3)]
? Power Button id=6 [slave keyboard (3)]
? Video Bus id=7 [slave keyboard (3)]
? Power Button id=8 [slave keyboard (3)]
? Sleep Button id=9 [slave keyboard (3)]
? FaceTime HD Camera (Built-in): id=11 [slave keyboard (3)]
? Apple Inc. Apple Internal Keyboard / Trackpad id=12 [slave keyboard (3)]
xinput list-props 10
Device 'Logitech Performance MX':
Device Enabled (143): 1
Coordinate Transformation Matrix (145): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Natural Scrolling Enabled (278): 0
libinput Natural Scrolling Enabled Default (279): 0
libinput Scroll Methods Available (280): 0, 0, 1
libinput Scroll Method Enabled (281): 0, 0, 0
libinput Scroll Method Enabled Default (282): 0, 0, 0
libinput Button Scrolling Button (283): 2
libinput Button Scrolling Button Default (284): 2
libinput Middle Emulation Enabled (285): 0
libinput Middle Emulation Enabled Default (286): 0
libinput Accel Speed (287): 0.000000
libinput Accel Speed Default (288): 0.000000
libinput Accel Profiles Available (289): 1, 1
libinput Accel Profile Enabled (290): 1, 0
libinput Accel Profile Enabled Default (291): 1, 0
libinput Left Handed Enabled (292): 0
libinput Left Handed Enabled Default (293): 0
libinput Send Events Modes Available (263): 1, 0
libinput Send Events Mode Enabled (264): 0, 0
libinput Send Events Mode Enabled Default (265): 0, 0
Device Node (266): "/dev/input/event5"
Device Product ID (267): 1133, 4122
libinput Drag Lock Buttons (294): <no items>
libinput Horizontal Scroll Enabled (295): 1
Run Code Online (Sandbox Code Playgroud)
我希望得到任何支持,因为我真的很想自然地向后滚动:> 和平!
Pil*_*ot6 13
编辑 /usr/share/X11/xorg.conf.d/40-libinput.conf
Option "NaturalScrolling" "True"像这样在那里添加:
对于您的鼠标:
# Match on all types of devices but joysticks
Section "InputClass"
Identifier "libinput pointer catchall"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
Option "NaturalScrolling" "True"
EndSection
Run Code Online (Sandbox Code Playgroud)
对于您的触摸板:
Section "InputClass"
Identifier "libinput touchpad catchall"
MatchIsTouchpad "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
Option "NaturalScrolling" "True"
EndSection
Run Code Online (Sandbox Code Playgroud)
然后注销并重新申请。
小智 6
跑步xinput:
$ xinput\n\xe2\x8e\xa1 Virtual core pointer id=2 [master pointer (3)]\n\xe2\x8e\x9c \xe2\x86\xb3 Virtual core XTEST pointer id=4 [slave pointer (2)]\n\xe2\x8e\x9c \xe2\x86\xb3 DELL0945:00 27C6:01F0 Mouse id=11 [slave pointer (2)]\n\xe2\x8e\x9c \xe2\x86\xb3 DELL0945:00 27C6:01F0 Touchpad id=12 [slave pointer (2)]\n\xe2\x8e\x9c \xe2\x86\xb3 PS/2 Generic Mouse id=17 [slave pointer (2)]\n\xe2\x8e\xa3 Virtual core keyboard id=3 [master keyboard (2)]\n \xe2\x86\xb3 Virtual core XTEST keyboard id=5 [slave keyboard (3)]\n \xe2\x86\xb3 Video Bus id=6 [slave keyboard (3)]\n \xe2\x86\xb3 Video Bus id=7 [slave keyboard (3)]\n \xe2\x86\xb3 Power Button id=8 [slave keyboard (3)]\n \xe2\x86\xb3 Sleep Button id=9 [slave keyboard (3)]\n \xe2\x86\xb3 Integrated_Webcam_HD: Integrate id=10 [slave keyboard (3)]\n \xe2\x86\xb3 Intel HID events id=13 [slave keyboard (3)]\n \xe2\x86\xb3 Intel HID 5 button array id=14 [slave keyboard (3)]\n \xe2\x86\xb3 Dell WMI hotkeys id=15 [slave keyboard (3)]\n \xe2\x86\xb3 AT Translated Set 2 keyboard id=16 [slave keyboard (3)]\nRun Code Online (Sandbox Code Playgroud)\n找到您的触摸板设备并列出其属性:
\n$ xinput list-props "DELL0945:00 27C6:01F0 Touchpad"\nDevice 'DELL0945:00 27C6:01F0 Touchpad':\n Device Enabled (214): 1\n Coordinate Transformation Matrix (216): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000\n libinput Tapping Enabled (372): 1\n libinput Tapping Enabled Default (373): 0\n libinput Tapping Drag Enabled (374): 1\n libinput Tapping Drag Enabled Default (375): 1\n libinput Tapping Drag Lock Enabled (376): 0\n libinput Tapping Drag Lock Enabled Default (377): 0\n libinput Tapping Button Mapping Enabled (378): 1, 0\n libinput Tapping Button Mapping Default (379): 1, 0\n libinput Natural Scrolling Enabled (351): 0\n libinput Natural Scrolling Enabled Default (352): 0\n libinput Disable While Typing Enabled (380): 1\n libinput Disable While Typing Enabled Default (381): 1\n libinput Scroll Methods Available (353): 1, 1, 0\n libinput Scroll Method Enabled (354): 1, 0, 0\n libinput Scroll Method Enabled Default (355): 1, 0, 0\n libinput Click Methods Available (382): 1, 1\n libinput Click Method Enabled (383): 1, 0\n libinput Click Method Enabled Default (384): 1, 0\n libinput Middle Emulation Enabled (385): 0\n libinput Middle Emulation Enabled Default (386): 0\n libinput Accel Speed (360): 0.000000\n libinput Accel Speed Default (361): 0.000000\n libinput Accel Profiles Available (362): 1, 1\n libinput Accel Profile Enabled (363): 1, 0\n libinput Accel Profile Enabled Default (364): 1, 0\n libinput Left Handed Enabled (365): 0\n libinput Left Handed Enabled Default (366): 0\n libinput Send Events Modes Available (336): 1, 1\n libinput Send Events Mode Enabled (337): 0, 0\n libinput Send Events Mode Enabled Default (338): 0, 0\n Device Node (339): "/dev/input/event5"\n Device Product ID (340): 10182, 496\n libinput Drag Lock Buttons (367): <no items>\n libinput Horizontal Scroll Enabled (368): 1\n libinput Scrolling Pixel Distance (369): 15\n libinput Scrolling Pixel Distance Default (370): 15\n libinput High Resolution Wheel Scroll Enabled (371): 1\nRun Code Online (Sandbox Code Playgroud)\n将自然滚动启用属性设置为1:
$ xinput set-prop "DELL0945:00 27C6:01F0 Touchpad" "libinput Natural Scrolling Enabled" 1\nRun Code Online (Sandbox Code Playgroud)\n