Kubuntu 20.04与扩展显示。笔记本电脑屏幕没有触觉。外部屏幕是触摸屏。当触摸外部屏幕的中心时,鼠标指向两个屏幕之间的边界。它的计算,好像触摸屏的宽度是两个屏幕的宽度在一起。
如何使触摸屏只适合外部屏幕?而且,这是一个便携式屏幕。所以我想在断开之间做永久的改变。
sza@sza-Lenovo-ThinkBook-15-IIL:~$ xinput
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ Logitech M705 id=12 [slave pointer (2)]
⎜ ↳ Logitech K750 id=13 [slave pointer (2)]
⎜ ↳ G2Touch Multi-Touch by G2TSP id=9 [slave pointer (2)]
⎜ ↳ Elan Touchpad id=14 [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)]
↳ Integrated Camera: Integrated C id=11 [slave keyboard (3)]
↳ Ideapad extra buttons id=15 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=16 [slave keyboard (3)]
↳ Logitech K750 id=17 [slave keyboard (3)]
sza@sza-Lenovo-ThinkBook-15-IIL:~$ xinput list-props 9
Device 'G2Touch Multi-Touch by G2TSP':
Device Enabled (172): 1
Coordinate Transformation Matrix (174): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Calibration Matrix (312): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Calibration Matrix Default (313): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Send Events Modes Available (295): 1, 0
libinput Send Events Mode Enabled (296): 0, 0
libinput Send Events Mode Enabled Default (297): 0, 0
Device Node (298): "/dev/input/event4"
Device Product ID (299): 10900, 22093
sza@sza-Lenovo-ThinkBook-15-IIL:~$ xrandr
Screen 0: minimum 320 x 200, current 3840 x 1080, maximum 16384 x 16384
eDP-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 344mm x 194mm
1920x1080 60.06*+ 60.01 59.97 59.96 59.93
...
DP-1 connected 1920x1080+1920+0 (normal left inverted right x axis y axis) 344mm x 195mm
1920x1080 60.00*+ 50.00 59.94 30.00 29.97
...
HDMI-1 disconnected (normal left inverted right x axis y axis)发布于 2020-11-12 10:14:21
您可能会发现以下xinput选项值得关注:
--map-to-output device crtc
Restricts the movements of the absolute device to the RandR
crtc. The output name must match a currently connected output
(see xrandr(1)). If the NVIDIA binary driver is detected or
RandR 1.2 or later is not available, a Xinerama output may be
specified as "HEAD-N", with N being the Xinerama screen number.
This option has no effect on relative devices.根据您提供的信息,下面的命令可以满足您的需要:
xinput --map-to-output "G2Touch Multi-Touch by G2TSP" DP-1如果这个命令能满足您的要求,您可以设置udev来运行触摸屏。但是,当直接调用xinput时, 将无法工作,因为udev是一个运行在X之外的系统服务。 需要在X内创建一个监视脚本,udev可以通知它。
inotify-tools。lsusb获取触摸屏的设备id。 将以idVendor:idProduct的形式显示(例如,2a94:564 d)。/etc/udev/rules.d/10-touchscreen.rules:ACTION=="add",SUBSYSTEM=="usb",ATTRS{idVendor}=="2a94",ATTRS{idProduct}==“564 d”,RUN+=“触摸/tmp/触摸屏-附加”See还:
杰克丹尼尔斯指出表示KDE有与图形平板电脑相关的输入设置。 是为我的Wacom平板电脑工作的,而不是我的笔记本触摸屏。如果这种设置适用于您的外部触摸屏,那么设置起来将比我前面描述的要容易得多。



发布于 2020-11-12 19:27:16
我也做同样的事,但笔记本电脑就是触觉。也使用kubuntu。如果你进入系统设置>输入设备>图形平板电脑。在那里,您选择了名为" Touch“的选项卡,然后选择了名为"Map to Screen”的选项。点击"Toggle屏幕“来选择你想让触摸聚焦的屏幕。默认情况下,它在两个屏幕上都被选中。
此外,您可以检查此网站,以创建一个脚本,将允许您自动选择监视器在启动。
https://networks.guru/2018/11/23/using-dual-monitor-dual-touch-screens-on-ubuntu/
只有在启动系统时,脚本才能工作。如果断开屏幕或更改为单个屏幕,则该触摸可能会恢复为“共享”。仍然试图弄清楚如何使更改永久化或修改脚本以包括屏幕更改和连接/断开。
https://askubuntu.com/questions/1291566
复制相似问题