Wayland support
Hi there, I was wondering if you're open to me adding siwin as a windowing backend to your project.
Currently, you're using a forked version of Windy and it does not have proper Wayland support. As such, it defaults to X11. Siwin, on the other hand, has proper Wayland support along a bunch of extra protocols that a modern Linux desktop application can utilize. (Layer Shell, Idle Inhibit, etc.)
That’d be awesome! I’m not familiar with siwin. Is it cross platform or Wayland specific?
If it’s Wayland specific it might be better to add it to my windy fork as another backend. More apis could be added too.
I’ve been feeling the limitations of the windy implementation lately on macOS as well. I was considering looking into other cross platform windowing libs.
I’d be happy to switch or have optional backends. But it’d be nice to keep the windowing in a separate library.
I just looked at the siwin link. Definitely could work as a windowing backend to swap out windy/windex.
It's missing macos, but I could port over macos if it works alright.
Upon further inspection, it seems like the backend you inherited from Fidget is quite intertwined with windy/windex. It's quite the hassle to abstract away.
Upon further inspection, it seems like the backend you inherited from Fidget is quite intertwined with windy/windex. It's quite the hassle to abstract away.
Hmmm, yeah that makes sense. I was thinking it might be possible to use when blocks and to just directly swap out the windowing types. Abstracting it out seems like it'd be a pain.
I tried refactoring it so the windowing library was a bit more self contained. Got it all compiling, but the window just didn't want to show up. Everything should've been setup right, but nada.
I'll have to do it again but in smaller increments and to test each change.
https://github.com/elcritch/figuro/issues/124
@xTrayambak there's a new v0.15.0 branch where I'm working on adding a skeleton siwin windowing module. I'm not going to be able to implement it all, but figured I'd get a draft in place. I'll merge it soon, probably tomorrow.
The windowing stuff has been cleaned up and most of the windowing stuff is in a single moduel openglWindex.nim which I copied to openglSiwin.nim. However, siwin doesn't work on macs I think so I'm just going to get the most basic stuff done.
I refactored Figuro's mouse and keyboard events to be more similar to Siwin's design as well. But there's still some differences in how mouse events are handled, but nothing too crazy looking.
@xTrayambak all that to say if you wanna try getting siwin running on wayland it should be much easier now.
Unsupported things can probably just be a null-op. Items like setting window style / decorations for example that might just be a windy/windex thing.
I'm excited. 😸 I've been thinking of maybe working toward something similar to https://github.com/linkfrg/ignis but utilizing nim/figuro.
I've gotten a very basic Siwin backend working, but it'll take a while to implement everything. I'll just try to finish it and send a MR by tomorrow.