Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wayland support: rectangles are not transparent #54

Open
hiqua opened this issue Feb 17, 2021 · 6 comments
Open

Wayland support: rectangles are not transparent #54

hiqua opened this issue Feb 17, 2021 · 6 comments

Comments

@hiqua
Copy link

hiqua commented Feb 17, 2021

I recently tried keynav with Wayland (via Sway) on Debian Bullseye. It basically works, except that the rectangles (defining the area where we want to click) are not transparent, meaning that the UX is way worse than on Xorg.

To be clear, I don't know the technical details about the compatibility layers between Wayland and Xorg, I'm just talking about the end result as of now, on Sway, with the Debian packages.

I just wanted to report this in case people are looking intro migrating. keynav is too important for me, so I cannot migrate to Sway just yet.

@gumieri
Copy link

gumieri commented Mar 26, 2021

The reason why the "keynav" is not transparent is because it is being rendered a Xwayland display over the Wayland interface.
It is necessary to change how the Cairo is being used in the project to render it directly in the Wayland interface.

Also it is complicated to implement the "right" way to send the cursor event to the Window Manager (WM, in this case Sway). AFAIK each WM will have a different approach of how to do it.

I don't know enough of C, Cairo, EGL and Wayland to make it all together to make it work. But because I am interested in it I would like to the maintainer or anyone if also interested take a look at the https://github.com/emersion/slurp projet for helping in this effort.

@sim590
Copy link

sim590 commented Sep 8, 2021

@hiqua I'm curious as to how you managed to run keynav in Wayland. I've just started using Wayland on Sway and I have it setup pretty good. I have not disabled XWayland in the config, but when I run keynav, I get:

X Error of failed request:  BadAccess (attempt to access private resource denied)
  Major opcode of failed request:  33 (X_GrabKey)
  Serial number of failed request:  18
  Current serial number in output stream:  22

Do you know how to fix that?

@hiqua
Copy link
Author

hiqua commented Sep 8, 2021

@sim590 I didn't go into the details or tried to really make it work on a pure Wayland setup, which you might be closer to than I've been. Note that you can get your error if keynav is already running, see #48 (comment)

Otherwise I'd suggest to install i3 and to check that it's running there first. It will probably install a bunch of xorg dependencies along the way, which I might have had when I tested this under sway.

I probably won't be able to help you much more than that as I'm still running i3.

@sim590
Copy link

sim590 commented Sep 8, 2021

Otherwise I'd suggest to install i3 and to check that it's running there first. It will probably install a bunch of xorg dependencies along the way, which I might have had when I tested this under sway.

I've just started using wayland. I also have awesome on my computer which I've been using for the past couple of years and keynav is working fine on that setup.

@sim590
Copy link

sim590 commented Sep 8, 2021

Actually, I just found out that it was another already running instance that provoked this error. Normally, calling keynav just works on X, but on Wayland, I have to call it with the start command. But even though now I see keynav working, I'm having the same issue with the black rectangles instead of transparent ones.

@gabcoh
Copy link

gabcoh commented Sep 20, 2022

If you're still looking to run keynav on wayland, I just wrote keynav-wayland. It's still very early, and only supports a few basic commands, but I think the goal will be to be mostly compatible with this version. Whenever I get some more time I'll try to make more progress on that front.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants