After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 776290 - GTK_CSD=0 does not disable CSD
GTK_CSD=0 does not disable CSD
Status: RESOLVED WONTFIX
Product: gtk+
Classification: Platform
Component: Backend: Wayland
3.22.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2016-12-19 19:42 UTC by cyphar
Modified: 2016-12-20 05:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
gtk3-make-csd-optional.patch (841 bytes, patch)
2016-12-19 19:42 UTC, cyphar
none Details | Review
screenshot of CSD vs no-CSD in sway (589.70 KB, image/png)
2016-12-20 04:33 UTC, cyphar
  Details

Description cyphar 2016-12-19 19:42:51 UTC
Created attachment 342234 [details] [review]
gtk3-make-csd-optional.patch

Currently there exists the GTK_CSD environment variable that is checked to decide whether CSD should be set for a particular window. However, it's used as a hint rather than as an instruction to an application.

In addition, even if an application does *not* specify it wants to use CSD, if you're using a backend other than X (such as Wayland) you will *still* get CSDs on your GTK+3 applications -- even though neither the user nor the application want it.

IMO the solution is to either always honour GTK_CSD if it's set, or remove the code that specifically makes Wayland _always_ use CSDs even if the application did not request to use them.

I've attached my attempt at a patch for this. PTAL. Note that Arch Linux has their own patch for this as well[1].

[1]: https://aur.archlinux.org/cgit/aur.git/plain/gtk3-make-csd-optional.patch?h=gtk3-optional-csd
Comment 1 Matthias Clasen 2016-12-19 19:45:51 UTC
This is not a bug. There is no alternative to CSD on Wayland, so we ignore the environment variable.
Comment 2 cyphar 2016-12-19 19:58:03 UTC
Currently sway (like i3 but for wayland) implements title bars for all processes, which means that CSD is currently making my terminal sessions look really dumb -- it has two title bars and the GNOME one takes up ~3cm from the top of my screen.

Maybe GNOME hasn't implemented any other alternatives, but alternative window managers clearly have.
Comment 3 cyphar 2016-12-20 04:33:02 UTC
Created attachment 342245 [details]
screenshot of CSD vs no-CSD in sway

Attached is a screenshot to show how silly CSD looks in sway.
Comment 4 Jonas Ådahl 2016-12-20 05:36:30 UTC
With the current set of public protocols there is no way to not show window decoration. Ways might very well be introduced in the future, but any client using only the upstream shell protocols simply cannot. If they do, it's by being non-compliant.