我正在运行 lubuntu,并尝试禁用触摸屏,但当我尝试使用 xinput 时,计算机显示“无法连接到 X 服务器
答案1
如果你从 tty 执行此操作,则应提供 DISPLAY 环境变量
lol4t0@lol4t0-nix:~$ DISPLAY=:1 xinput
Unable to connect to X server
lol4t0@lol4t0-nix:~$ DISPLAY=:0 xinput
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ SYNA8006:00 06CB:CD8B Touchpad id=11 [slave pointer (2)]
⎜ ↳ TPPS/2 Elan TrackPoint id=15 [slave pointer (2)]
⎜ ↳ SYNA8006:00 06CB:CD8B Mouse id=10 [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)]
↳ Intel HID events id=13 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=14 [slave keyboard (3)]
↳ sof-hda-dsp Headset Jack id=12 [slave keyboard (3)]
↳ Integrated Camera: Integrated C id=9 [slave keyboard (3)]
↳ ThinkPad Extra Buttons id=16 [slave keyboard (3)]
↳ Video Bus id=7 [slave keyboard (3)]
↳ Sleep Button id=8 [slave keyboard (3)]