Skip to content

wayland: Update to xdg-decoration protocol

Isaac Freund requested to merge ifreund/gtk:xdg-deco into gtk-3-24

Currently gtk uses the out of date and non-standardized server-decoration protocol from kde. This commit replaces the implementation of this old server-decoration protocol with an implementation of the xdg-decoration protocol standardized in the wayland-protocols repository.

The new protocol allows us to specify a preference, and so we always ask for CSD and initially enable CSD, only switching to SSD if the server disregards our preference.

Notable changes include:

  • A new GDK window state for SSD.

  • Deprecation of gdk_wayland_display_prefers_ssd(). The new protocol doesn't provide global state, so this function is deprecated and always returns false.

  • Renaming of gdk_wayland_window_announce_csd/ssd() to gdk_wayland_window_request_csd/ssd(). The semantics have changed with the new protocol and the old names are not merely wrong but misleading.

If this patch looks good, I'd be happy to send an MR for the master branch as well.

Merge request reports