An application can request to have shadows painted around its window by KWin. This should be done by the GTK theme as well since otherwise the light-gray menus provide poor contrast above white contents. See the [breeze.git] / kstyle / breezeshadowhelper.cpp for how the Breeze Qt style does this. It's basically some X properties and/or a wayland protocol that is given pixmaps for each corner. Reproducible: Always
GTK 3 has certain issues of non-compliance with freedesktop.org standards which prevents a lot of these sorts of things from working properly in KWin. I'm not yet certain, but I think shadows around elements such as this would face the same issues we've seen with other elements like transparency and shadows around client-side decorations. GTK doesn't give the information for these boundaries in a way that reliably fits into KWin's structure. I've been told that rewriting KWin to handle this could take months and there's no guarantee it wouldn't break again immediately as GTK 3 handles many of these things outside of any agreed upon standard or specification. I'll look into it, but I think it's entirely likely we may have to accept this as a visual limitation until the broader issues surrounding GTK 3 are resolved.
In a related GTK bug report (https://bugzilla.gnome.org/show_bug.cgi?id=729794), Matthias Clasen--a lead GTK developer--says the following on this subject: "As you've found out, we already let the theme creators configure the applications appearance, including the shadows." I may be misunderstanding the scope of work, but it doesn't seem like there are necessarily any KWin changes needed here: just some tweaks to the theme itself to tell KWin to always draw the shadows.
A bit of necrobump but I agree with Nate. The shadows should be created and drawn as for any other client simply ignoring what gtk has set as shadow properties
This requires _GTK_FRAME_EXTENTS support, which is now planned for KWin--in a way that doesn't break other things, of course. :) I'm hoping this lands in Plasma 5.18. Marking as a duplicate of the bug tracking that work. *** This bug has been marked as a duplicate of bug 390550 ***