blue-systems / plasma-issues

plasma 5.6 - 5.xx (ongoing)
0 stars 0 forks source link

kwin: there seem to be no shadows on ANY non-kwin app? #157

Open star-buck opened 5 years ago

star-buck commented 5 years ago

seems like every app that isnt following kwins "we dont draw shadows, the app has to request them from us, and be prepared to do so in a my-way-or-the-highway way" paradigm is left without any shadows: screenshot_20190107_234734

I think this is totally backwards. Since from the start, BlueSystems was deeply into integration with improving the gtk-kcm to feature gtk3-themes as well, there will be a time where we need to rethink this stance at least for the vast majority of gtk-and-gtk-supporting applications.

zzag commented 5 years ago

Very difficult.

In order to support GTK's client-side decorations, KWin would need to support _GTK_FRAME_EXTENTS. That in its turn would introduce a bunch of other problems: it'll break KWin's core assumptions, it will break some effects, etc.

Another problem is that _GTK_FRAME_EXTENTS is not standardized, so there's a chance that GNOME folks can change their mind and use a brand new mechanism for CSD. IIRC, Martin proposed to standardize it. Maybe @davidedmundson can correct me on this one because I wasn't around during those times.

The worst part is that there is no way to hook up into GTK to add shadows, something what we did in oxygen-gtk2 and oxygen-gtk3, though it would only address widget style shadows.

Also, I'd like to mention that Martin recently wrote a post regarding KWin and CSD: https://blog.martin-graesslin.com/blog/2019/01/kwin-and-shadows-for-client-side-decorated-windows/ Relevant bug report: https://bugs.kde.org/show_bug.cgi?id=391917 Relevant GTK issue: https://gitlab.gnome.org/GNOME/gtk/issues/100

star-buck commented 5 years ago

Thanks Vlad. This is to brainstorm and analyzing current situation, not only for gtk on plasma, but overall.

Since e.g. the odio app is an electron based appimage, it would be nice to test how it behaves under gtk-based DEs like gnome or xfce or if its a universal issue.

davidedmundson commented 5 years ago

In X GTK_FRAME_EXTENTS is not standardised.

But then nor is _KDE_NET_WM_SHADOW which is way more convoluted, so we're not exactly in a good position to make comments. I don't like our system at all.

Under wayland both the GTK_FRAME_EXTENTS equivalent is standardised AND the negotiation of some of this deco crap is standardised too so potentially we don't even need it. So the situation does have some positivity in the longer term.

davidedmundson commented 5 years ago

@zzag in the short term, do you think it's feasible to have kdecoration have a mode to do just its shadows which we can enable with some kwin rules?

zzag commented 5 years ago

@zzag in the short term, do you think it's feasible to have kdecoration to just it's shadows which we can enable with some kwin rules?

In general, it makes sense to have a rule to force decoration shadows. On the other hand, decorations and shadows are bounded so I'm not sure about that. Especially, I'm concerned about rounded corners. Also, would it be an API break?

star-buck commented 5 years ago

so on gnome, the same appimage app does have a wondeful shadow rendered that seems exactly in line with their other rendered default shadows. Just posting this here for informational purposes: screenshot from 2019-01-08 17-29-55

vs. screenshot_20190108_230843