Re-purposing KWaylandServer
Vlad Zahorodnii
vlad.zahorodnii at kde.org
Tue Mar 23 08:44:06 GMT 2021
Hi,
Currently, KWaylandServer library is a collection of convenience Qt
wrappers around Wayland protocols. The issue with such a design is that
the bulk of work needs to be still done in the compositor, for example
it still needs to deal with importing client buffers, setting up the
session, handling of input and drm devices, launching xwayland, etc.
I believe that a better design will involve offloading all non-kwin
features from kwin to kwaylandserver:
* kwin code base will be leaner. All window management features will be
in kwin, while low level specific bits will be well contained in
kwaylandserver
* it's a more reusable design in general; this allows writing domain
specific wayland compositors easier, for example for tv, mobile, etc
* the implementation of some wayland protocols will become a bit more
straightforward. At the moment, due to odd split of functionality
between kwin and kwaylandserver, it's not clear what the best way to
implement some protocols or features is, e.g. presentation feedback,
linux dma-buf, popup grabs, etc
* it's a safer design choice in long term. Currently, things go quite
well in kwin, but just in case something goes wrong and we decide to
start a new Wayland compositor, we won't have to write low level
components such as the DRM backend, input device handling, and so on
from scratch.
Thoughts?
Cheers,
Vlad
More information about the kwin
mailing list