Three reasons for this removal:This will drastically reduce our support burden and give us the ability to focus on quality for the KDE Plasma stack and continue our feature-forward nature.
- Xorg server is deprecated since RHEL 9.0 and will be dropped in "a future major RHEL release".
- Graphics fallback modes are Wayland-friendly now with SimpleDRM enabled since F36.
- NVIDIA drivers (since v495~v515) support GBM for Wayland instead of EGLStreams. Wayland is fully supported on current NVIDIA drivers.
Wayland is what happens when issues with the dominant windowing protocol have been festering for decades. It throws away everything and establishes a core set of standards that must be adhered to, along with a (very large) set of extensions that can be optionally implemented. The website https://wayland.app/ shows all the protocols worth knowing, and a lot more on top of that. It’s kinda like Vulkan, in a sense: the core has the basics, and everything else is extensions that can be queried for by clients.
Wlroots is a library that writes all the code that I didn’t want to have to write, because it has too much math. It’s a generally unopinionated framework for building your own Wayland compositor that, while not perfect, does most of the heavy lifting for you. In writing Flyaway, most of the work so far has been figuring out how to put together the pieces that wlroots has given me; piping and such. Sadly, the documentation kinda sucks, but examples are plenty (e.g. sway and clay) and the developers have been very accessible and helpful when I’ve had questions.
Right now, I’m focused on implementing the XDG shell protocol that has all the desktop windowing functionality you expect, like maximizing/minimizing/tiling, and the wlroots-spearheaded wlr-layer-shell protocol for KDE/Budgie style panels and docks. The former is a must-have, and the latter is what I have determined is the best way for Budgie’s panel system to be ported to Wayland. The below is a small demonstration of what I’ve accomplished so far with wlr-layer-shell, using the gtk-layer-shell example binary.If you would like to learn more, you can read about it here.
One of the aspects of Budgie that we have to change in moving to Wayland is how open windows are tracked, needed primarily for the tasklist applets, but also for notification pausing and the night light feature. This is all handled by a module affectionately named Abomination, using the Wnck API. That won’t work for Wayland, so we need a solution. Enter libxfce4windowing, a library created by the folks at XFCE for their window tracking, which supports both X11 and Wayland. Leveraging this in Budgie allows us to much more quickly implement Wayland support, while also hopefully giving an idea of how to do this ourselves for Budgie 11, if needed.
Having not had much, if any, experience with the Wnck API and Abomination before, or really any experience with tracking windows, I needed a place to start fresh. Luckily, a new Simple Tasklist applet was already in early stages of development, providing a perfect place to learn how to use libxfce4windowing! So, that’s where I started: porting Simple Tasklist from Wnck to XFCE’s windowing library. And it was… easy. Once I learned that any currently open windows are added via signals *after* initialization instead of being ready immediately, it Just Worked ™. The API is very similar to that provided by Wnck, which makes translating between the two much easier. This might be because they use Wnck under the hood for the X11 implementation.
One thing I discovered that was a source of annoyance at first was the lack of a `Screen.get_active_workspace()` method like Wnck provides. Instead, you have to get the WorkspaceManager from the Screen, then get all the WorkspaceGroups, and then find the group that actually has your workspaces in it. Luckily for X11, there is only one group. It turns out that this is all because Wayland has a concept of workspace groups, which X11, or at least Wnck, does not. That makes me feel better about having to write 6 or 7 lines of code just to get the current Workspace.
With a solid foundation for Simple Tasklist, I then turned my attention to tackling Abomination and Icon Tasklist. My goal is to come up with an API similar to Abomination, but leveraging libxfce4windowing, and simplifying its operation. Abomination does some things with window class renaming and other logic and edge-casing to determine if a window belongs to the same application as other open windows. I am hoping to be able to do away with all of that, given all the problems it has caused us in the past. XFCE’s windowing library groups windows by class group, which is what we currently do in Abomination.
This part of the journey is still very much a work in progress, and there is a lot of reworking still to do. Every step brings us closer to being Wayland-ready, and that makes it all worth it. Big shout out to the folks at XFCE for writing a great cross-windowing-system library; it has been really easy to use!
Supporting The Project
Did you know that you can financially support the Buddies of Budgie project? Buddies of Budgie was founded to provide a home for Budgie Desktop and your financial contribution can go a long way to supporting our goals for development, providing opportunities for financial compensation, leveraging no-compromise Continuous Integration and Continuous Delivery systems for streamlining Budgie 10 and 11 development, and more