Weston shows subsurfaces of unmapped subsurfaces
This came up while debugging issues around the OBS Wayland port:
The spec states:
A sub-surface becomes mapped, when a non-NULL wl_buffer is applied and the parent surface is mapped. The order of which one happens first is irrelevant. A sub-surface is hidden if the parent becomes hidden, or if a NULL wl_buffer is applied. These rules apply recursively through the tree of surfaces.
On Weston it is possible to map a subsurface subB
of a subsurface subA
, even if subA
never got a buffer attached.
While this should be easy to fix, apparently the QT Wayland backend makes heavy use of bufferless "intermediate" subsurfaces - likely because it currently appears to work on all major compositors. I tested Mutter and Sway and assume KWin behaves similar. So fixing this should probably involve some coordination with the QT team and distributors (at least Fedora, which enables the QT Wayland backend by default).
Todo:
-
provide a cleaned up example client
see also https://bugreports.qt.io/browse/QTBUG-86229 and https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1412