Closed AsciiWolf closed 10 months ago
the titlebar is libdecor. FreeDesktop defaults to SDL2 with libdecor, so all packages using that version of SDL2 have the same behaviour.
For reference, I changed it three months ago: https://github.com/flathub/io.github.dosbox-staging/commit/20331ddf26ebe24a976eff7950c8357636a626df
Use system title bars on Wayland
What Desktop Environment do you use? KDE's implementation of Client-Side Decorations an Server-Side Decorations is more mature and inline with the FreeDesktop standard. GNOME users are less well off.
the titlebar is libdecor. FreeDesktop defaults to SDL2 with libdecor, so all packages using that version of SDL2 have the same behaviour.
Ah, I am dumb. :-) Thanks for the explanation!
What Desktop Environment do you use? KDE's implementation of Client-Side Decorations an Server-Side Decorations is more mature and inline with the FreeDesktop standard. GNOME users are less well off.
Fully updated GNOME 45 on Fedora 39.
@AsciiWolf Gnome does not support server-side-decorations (SSD), and requires that all non-native gnome apps implement CSD (client-side-decorations). Therefore SDL2 needs a CSD implementation for which it uses libdecor.
Other desktop environments such as KDE do support SSD, and therefore don't need libdecor, and non-native apps will still have native title bars and controls.
Unfortunately the Gnome developers have put their foot down on this and have indicated not wanting to implement SSD.
Is there any way for libdecor to use decorations from system theme (such as Adwaita on GNOME)?
That would be something for https://gitlab.freedesktop.org/libdecor/libdecor
From what I found online:
libdecor has a GTK plugin, so it can draw GTK-based window decorations to Wayland clients.
So, native GTK window decorations should be possible. But for some reason, they do not work with Flatpak. It is possible that the GTK plugin is disabled at build time. Anyway, this is probably out-of-scope of this Flatpak and will have to be fixed in the fd.o runtime.
I wanted to double-check it... and we only have GNOME to blame. This is Dosbox on KDE 5.27
This is not about GNOME, but about the bundled libdecor in the fd.o runtime not having its GTK plugin enabled (because the plugin depends on GTK and fd.o does not include GTK libs). There is no point in discussing about server-side-decorations vs client-side-decorations. Anyway, as I pointed out, this needs to be fixed in the fd.o runtime if possible.
It is somewhat SSD related... You can't expect fd.o to include GTK plugins when they don't know if the host uses GTK. It might work if we compile against the GNOME SDK but that would then be detrimental to KDE users.
You can't expect fd.o to include GTK plugins when they don't know if the host uses GTK.
That is a false assumption (especially considering that majority of today's GNU/Linux users use GNOME). What is true however is that it would be problematic and pointless to include GTK (or Qt) directly in the fd.o runtime. Ideally, the GTK / GNOME plugin of libdecor should not require GTK, but I am not sure whether this is possible.
The DOSBox Staging Flatpak currently uses a non-native window title bar when running on Wayland:
Please, consider fixing this if possible. The easiest workaround to this issue is to change the
fallback-x11
socket tox11
.