Kohei Yamada开发了一个Fusuma的应用程序,支持Linux上的多点触控手势,如果尚未安装ruby,就需要在机器上安装它。
首先检查当前用户是否是输入组的一部分。通过
sudo gpasswd -a $USER input
然后注销,并重新登录,现在安装xdotool和libinput工具。
sudo apt-get install libinput-tools
sudo apt-get install xdotool
如果尚未安装ruby,现在可以执行以下操作:
sudo apt install ruby
现在安装fusuma
gem install fusuma
决定你的手势
这是用所需的配置创建一个.yml
文件,如果想要标准的手势,你可以按照这些指令,或者随意调整来获得想要的手势。
转到主目录中的配置文件夹。
cd ~/.config
现在创建一个fusuma
的文件夹
mkdir fusuma
在那里创建一个config.yml
的文件
touch config.yml
现在可以使用你最喜欢的文本编辑器来输入这个文件的内容。
nano config.yml
如果使用GNOME,则复制,并粘贴以下说明,这是18.04中的默认环境。
swipe:
3:
left:
command: 'xdotool key alt+Right'
right:
command: 'xdotool key alt+Left'
up:
command: 'xdotool key super'
down:
command: 'xdotool key super'
4:
left:
command: 'xdotool key ctrl+alt+Down'
right:
command: 'xdotool key ctrl+alt+Up'
up:
command: 'xdotool key ctrl+alt+Down'
down:
command: 'xdotool key ctrl+alt+Up'
pinch:
in:
command: 'xdotool key ctrl+plus'
out:
command: 'xdotool key ctrl+minus'
threshold:
swipe: 0.4
pinch: 0.4
interval:
swipe: 0.8
pinch: 0.1
在此之后,你可以在终端中运行命令以测试它是否已安装
sudo fusuma
只需开始使用多点触控手势-在触摸板上轻扫。
现在你只需要在启动应用程序中添加Fusuma和命令。
希望这有帮助。
相关文章