Closed GlitchyCrafting closed 1 year ago
This has been brought up previously as issue #271. At that time I commented that it was essentially unmaintained but it looks like it has been adopted and refactored since then. However, the documentation is still poor and from what I can tell it has to be run as root which makes it practically unusable. How do you run/use it?
This has been brought up previously as issue #271. At that time I commented that it was essentially unmaintained but it looks like it has been adopted and refactored since then. However, the documentation is still poor and from what I can tell it has to be run as root which makes it practically unusable. How do you run/use it?
In my testing it does not need to be run as root and was made to be a drop-in replacement for xdotool. All I did was replace xdotool with ydotool in the config and it worked as expected to sent keystrokes.
As the instructions say, when you raise a bug please provide the output of libinput-gestures -l
so I can see what environment you are using.
libinput-gestures: session unknown+wayland on Linux-6.0.8-arch1-1-x86_64-with-glibc2.36, python 3.10.8, libinput 1.22.0
Hash: 8d8b6a109b84473e049faaf97c63aa33
Gestures configured in ~/.config/libinput-gestures.conf:
swipe up 3 ydotool key super+Right
swipe down 3 ydotool key super+Left
swipe left 3 alacritty
libinput-gestures: device /dev/input/by-path/pci-0000:00:15.1-platform-i2c_designware.1-event-mouse(event12): ELAN0722:00 04F3:3139 Touchpad
libinput-gestures is installed.
libinput-gestures is set up as a desktop application.
libinput-gestures is currently running as a desktop application.
libinput-gestures is set to autostart as a desktop application.
libinput-gestures is using custom configuration file.
Sorry have been away for much of the last couple of months. Which desktop are you using and What does super+Right/Left
do?
I was trying to make a touchscreen-compatible Sway desktop config. Those were to switch between apps in portrait mode, similar to a Right/Left swipe on a phone's gesture-bar.
You say "All I did was replace xdotool with ydotool in the config and it worked as expected to sent keystrokes" but I can't see how that could possibly work because the README says you must be running the ydotoold
daemon. Are you running that?
Even when I run ydotoold
(and there is zero documentation how to do that) it reports nothing and I get no errors from ydotool
either but it does not work.
I didn't start the daemon if one was running. I don't have that system anymore, so I can't check.
Since the start of 2022, ydotool
has required ydotoold
so all I can think is that you were running a very old version.
Anyhow, given it does not seem to work at all in my tests, the lack of any messages, and the poor documentation then I am not going to add any suggestion about it in the README here.
I got ydotool working with libinput-gestures.
Currently ydotool 1.0.4 have a systemd user service file, which starts the ydotoold executable as the user (no root needed).
As for the configuration, ydotool accepts keycodes, refer to the file /usr/include/linux/input-event-codes.h
for that. For example, I have this in my configuration:
gesture swipe left 4 ydotool key 125:1 105:1 105:0 125:0 # super+left
Because keycode for super
is 125 and left
is 105. :1
is for key-press and :0
is for key-release.
It's definitely harder to configure than xdotool, apparently.
I noticed there was no mention of
ydotool
as an alternative toxdotool
on Wayland. It's not a complete replacement, but for gestures it has all it needs.