ArchLinux touchpad configuration

ArchLinux touchpad configuration

Install packages

  1. Touchpad support:yay -s xf86-input-libinput

basic configuration

  1. Add to user group:sudo gpasswd -a $USER input
  2. Add click function:
  • Find the id of Touchpad, referred to as tid:xinput list
  • Find the device number of libinput Tapping Enabled, referred to as lnum:, xinput list-props devicedevice is the id of Touchpad
  • Turn on the click function:, xinput set-prop tid lnum 1replace tid and lnum with your own
  1. Simple configuration touchpad
  • /etc/X11/xorg.conf.d/40-libinput.conf Attribute interpretation
Attributes meaning
"Tapping" Enable click to send event
TappingButtonMap lmr, single finger left button, two finger right button, three finger middle button
DisableWhileTyping Typing does not detect mouse events
TappingDrag Click drag
  • Basic configuration file
Section "InputClass"
        Identifier "touchpad"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
        Option "Tapping" "on"
        Option "ButtonMapping" "1 3 0 4 5 6 7"
        Option "TappingButtonMap" "lmr"
        Option "DisableWhileTyping" "on"
        Option "TappingDrag" "on"
EndSection

Advanced configuration (gesture)

  1. Gesture support:yay -s libinput-gestures
    • Mapping tool: xdotool
  2. Configure gestures
  • copy configuration file:sudo cp /etc/libinput-gestures.conf ~/.config/libinput-gestures.conf
  • Change file permissions (will be lichanged to your own user name, echo $ USER to view)sudo chmod li:users ~/.cofig/libinput-gestures.conf
  1. debugging
  • Use libinput debug-events to monitor touchpad events libinput debug-events --device Device Node(Device Node checks according to the lnum number of libinput list-props above)
  • Use libinput debug-gui to monitor touchpad eventslibinput debug-gui --device Device Node
  1. reference

Guess you like

Origin www.cnblogs.com/luckyCoder/p/12732525.html