linux/其他系统用触控板在多屏幕之间快速移动鼠标指针 - Go语言中文社区

linux/其他系统用触控板在多屏幕之间快速移动鼠标指针


多个显示屏之间快速切换,又不想总是使用鼠标,寻找解决方案

本人笔记本(右侧)+显示屏(左侧):

  • 需求: 总是用鼠标移动才能快速移动到另一个屏幕上,快捷键直接移动
    分析: 直接搜索结果并没有,拆分需求: 快捷键设置+鼠标坐标设置
    结果: 系统ubuntu自带的快捷键设置+sudo apt install xdotool(ps:其他系统自行尝试)

  • 步骤
    1.sudo apt install xdotool
    2.添加系统快捷键:
    在这里插入图片描述
    设置两个快捷键:
    在这里插入图片描述
    接下来可以快乐的玩耍,每次使用快捷键就能让鼠标直接定位到对应的位置了

ps: 关于坐标,自己可以先根据自己的屏幕多尝试几次,大概两个坐标在两个屏幕的中间即可

// 2021-07-16 更新: 增加通过触控板三指左右滑动直接操作(快捷键还有有点不方便)
安装和配置参考官网: fusuma
配置文件,注意权限配置好:

sudo gpasswd -a $USER input
newgrp input

放上我的配置:

swipe:
  3:
    left:
      command: "xdotool key alt+Left" # History forward
    right:
      command: "xdotool key alt+Right" # History back
    up:
      command: "xdotool key super" # Activity
    down:
      command: "xdotool key super" # Activity
  4:
    left:
      command: "xdotool key ctrl+alt+Down" # Switch to next workspace
    right:
      command: "xdotool key ctrl+alt+Up" # Switch to previous workspace
    up:
      command: "xdotool key ctrl+alt+Down" # Switch to next workspace
    down:
      command: "xdotool key ctrl+alt+Up" # Switch to previous workspace
pinch:
  in:
    command: "xdotool keydown ctrl click 4 keyup ctrl" # Zoom in
  out:
    command: "xdotool keydown ctrl click 5 keyup ctrl" # Zoom out

根据该配置,现在便可以三指左滑鼠标指针瞬间到左边屏幕,右滑到右边屏幕了

ps: 配置开机启动,ubuntu自带:
在这里插入图片描述

版权声明:本文来源CSDN,感谢博主原创文章,遵循 CC 4.0 by-sa 版权协议,转载请附上原文出处链接和本声明。
原文链接:https://blog.csdn.net/qq_35244529/article/details/118360388
站方申明:本站部分内容来自社区用户分享,若涉及侵权,请联系站方删除。
  • 发表于 2021-11-27 21:15:22
  • 阅读 ( 876 )
  • 分类:Linux

0 条评论

请先 登录 后评论

官方社群

GO教程

猜你喜欢