首先,我在网上读了很多关于这个问题的帖子,但似乎没有一个对我有用。我从另一个用户那里得到了这个设置命令,这似乎是唯一对我有用的命令。我不知道如何在 Ubuntu 中设置它,因为通常我会在 中执行它~/.xinitrc
。
#get the device ID for the trackpad.
ibm_trackpad_id=$(xinput | grep 'TPPS' | cut -d"=" -f2 | cut -f1)
echo $ibm_trackpad_id > ~/temp/ibm_trackpad_id
#set desired params for trackpoint
sleep 2; xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation" 1
sleep 2; xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Button" 2
sleep 2; xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Timeout" 200
sleep 2; xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Axes" 6 7 4 5
sleep 2; xinput set-prop $ibm_trackpad_id "Device Accel Constant Deceleration" 0.15
答案1
创建一个名为 .xessionrc 的文件并将以下命令放入其中:
#get the device ID for the trackpad. We know it contains the string "TPPS"
ibm_trackpad_id=$(xinput | grep 'TPPS' | cut -d"=" -f2 | cut -f1)
echo $ibm_trackpad_id > ~/temp/ibm_trackpad_id
#set desired params for trackpoint
xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation" 1
xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Button" 2
xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Timeout" 200
xinput set-prop $ibm_trackpad_id "Evdev Wheel Emulation Axes" 7 6 5 4
xinput set-prop $ibm_trackpad_id "Device Accel Constant Deceleration" 0.10