将xinput命令行转换为xorg.conf文件

时间:2018-08-24 17:13:18

标签: mouse x11

这是Centos 7系统。这不是使用libinput。

命令行xinput非常适合查看和设置鼠标设置和设备。这样可以减少鼠标的跳动:

$ xinput set-prop 'Logitech USB Optical Mouse' 'Device Accel Constant Deceleration' 2

我想让所有用户永久使用。我尝试将其放入/etc/X11/xorg.conf.d/50-mouse.conf文件,如下所示:

Section "InputClass"
        Identifier "Logitech USB Optical Mouse"
        MatchIsPointer "yes"
# set the following to 1 1 0 respectively to disable acceleration.
        Option "AccelerationNumerator" "2"
        Option "AccelerationDenominator" "1"
        Option "AccelerationThreshold" "4"
EndSection

我不理解参数“ AccelerationDenominator”和“ AccelerationNumerator”,在这里猜测值。

我完全在做错事,我无法确定X11甚至注意到了鼠标文件。每次我重新启动系统时,系统都会使用相同的旧鼠标设置,在xinput中显示为

$ xinput list-props 13
Device 'Logitech USB Optical Mouse':
    Device Enabled (151):   1
    Coordinate Transformation Matrix (153): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
    Device Accel Profile (298): 0
    Device Accel Constant Deceleration (299):   1.000000
    Device Accel Adaptive Deceleration (300):   1.000000
    Device Accel Velocity Scaling (301):    10.000000
    Device Product ID (270):    1133, 49271
    Device Node (271):  "/dev/input/event7"
    Evdev Axis Inversion (302): 0, 0
    Evdev Axes Swap (304):  0
    Axis Labels (305):  "Rel X" (161), "Rel Y" (162), "Rel Vert Wheel" (297)
    Button Labels (306):    "Button Left" (154), "Button Middle" (155), "Button Right" (156), "Button Wheel Up" (157), "Button Wheel Down" (158), "Button Horiz Wheel Left" (159), "Button Horiz Wheel Right" (160), "Button Side" (291), "Button Extra" (292), "Button Forward" (293), "Button Back" (294), "Button Task" (295), "Button Unknown" (273), "Button Unknown" (273), "Button Unknown" (273), "Button Unknown" (273)
    Evdev Scrolling Distance (307): 1, 1, 1
    Evdev Middle Button Emulation (278):    0
    Evdev Middle Button Timeout (279):  50
    Evdev Middle Button Button (280):   2
    Evdev Third Button Emulation (281): 0
    Evdev Third Button Emulation Timeout (282): 1000
    Evdev Third Button Emulation Button (283):  3
    Evdev Third Button Emulation Threshold (284):   20
    Evdev Wheel Emulation (285):    0
    Evdev Wheel Emulation Axes (286):   0, 0, 4, 5
    Evdev Wheel Emulation Inertia (287):    10
    Evdev Wheel Emulation Timeout (288):    200
    Evdev Wheel Emulation Button (289): 4
    Evdev Drag Lock Buttons (290):  0

我可能需要一些系统配置细节。该系统只有一个有线通用鼠标,但是在列出的设备中,它正在调用一系列Logitech无线设备:

$ xinput --list
⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Logitech Unifying Device. Wireless PID:101b   id=11   [slave  pointer  (2)]
⎜   ↳ Logitech Unifying Device. Wireless PID:2008   id=12   [slave  pointer  (2)]
⎜   ↳ Logitech USB Optical Mouse                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)]
    ↳ Power Button                              id=7    [slave  keyboard (3)]
    ↳ DELL Dell USB Entry Keyboard              id=8    [slave  keyboard (3)]
    ↳ BCC950 ConferenceCam                      id=9    [slave  keyboard (3)]
    ↳ Logitech BCC950 ConferenceCam             id=10   [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=14   [slave  keyboard (3)]

0 个答案:

没有答案