Bug 403231 - [Wayland] Kwin Wayland cannot draw titlebars shadows correctly
Summary: [Wayland] Kwin Wayland cannot draw titlebars shadows correctly
Status: RESOLVED WORKSFORME
Alias: None
Product: kwin
Classification: Plasma
Component: aurorae (show other bugs)
Version: 5.13.2
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-01-15 11:54 UTC by tromzy
Modified: 2019-02-08 12:38 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:
vlad.zahorodnii: Wayland+
vlad.zahorodnii: X11+


Attachments
Black rectangle around the titlebar context popup (272.37 KB, image/png)
2019-01-15 11:54 UTC, tromzy
Details
Breeze Window decoration 1 (249.77 KB, image/png)
2019-02-08 12:30 UTC, tromzy
Details
Breeze Window decoration 2 (247.90 KB, image/png)
2019-02-08 12:31 UTC, tromzy
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tromzy 2019-01-15 11:54:28 UTC
Created attachment 117465 [details]
Black rectangle around the titlebar context popup

SUMMARY
On Wayland, if I right click a window title bar, the context menu has a weird black rectangle around itself, instead of its shadow. i tried several different window decoration themes and the same problem occurs everytime. See screenshot for result.

STEPS TO REPRODUCE
1. Start a Wayland session
2. Open any window
3. Right click the titlebar

OBSERVED RESULT
See screenshot ; weird black rectangle around the context popup.

EXPECTED RESULT
A shadow.

SOFTWARE/OS VERSIONS
Windows: 
MacOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.14.5
KDE Frameworks Version: 5.54
Qt Version: 5.12.0

ADDITIONAL INFORMATION
Comment 1 Vlad Zahorodnii 2019-01-15 12:29:50 UTC
If you're able to downgrade Qt, could you please try to reproduce the bug with Qt 5.11.X?
Comment 2 tromzy 2019-01-15 13:45:17 UTC
I still have 5.11 packages in my /var/cache/pacman/pkg/ folder, which one should I reinstall ? I don't feel like reinstalling ALL 5.11 packages...
Comment 3 Vlad Zahorodnii 2019-01-15 13:55:27 UTC
Oh, you're using Arch. Nevermind then, downgrading packages on Arch is PITA.
Comment 4 David Edmundson 2019-01-15 14:14:26 UTC
@Vlad, what were you thinking could be the cause that you wanted to test?
Comment 5 David Edmundson 2019-01-15 14:15:01 UTC
@tromzy as well as trying different window decos, see if changing the qstyle theme makes a difference.
Comment 6 Vlad Zahorodnii 2019-01-15 14:22:55 UTC
I started noticing this issue after upgrading to Qt 5.12. Though on X11, it's occasional.
Comment 7 tromzy 2019-01-15 14:23:17 UTC
Changing the Qt style makes a difference, but other problems occur too. The black rectangle problem seems to happen only with Kvantum Qt style ; other styles like Fusion or Breeze have their own set of glitches, but not the "rectangle for shadow" one.
Comment 8 Vlad Zahorodnii 2019-02-08 11:27:09 UTC
After updating Qt to 5.12.1, I no longer able to reproduce it.
Comment 9 tromzy 2019-02-08 11:28:51 UTC
I am on QT 5.12.1 too and the bug still occurs.
Comment 10 Vlad Zahorodnii 2019-02-08 11:32:16 UTC
> other styles like Fusion or Breeze have their own set of glitches

Are they still present?
Comment 11 tromzy 2019-02-08 11:38:55 UTC
Hmm, I just changed from  Kvantum to Breeze style ; the glitches are still present with Breeze ; but then I switched back from Breeze to Kvantum and... Problem solved ! It seems to draw the shadow correctly (although other problems remain, like the inability to close the context window, but that is probzbly another issue).
Comment 12 Vlad Zahorodnii 2019-02-08 11:53:17 UTC
(In reply to tromzy from comment #11)
> the glitches are still present with Breeze

What glitches exactly?
Comment 13 tromzy 2019-02-08 12:30:57 UTC
Created attachment 117923 [details]
Breeze Window decoration 1
Comment 14 tromzy 2019-02-08 12:31:20 UTC
Created attachment 117924 [details]
Breeze Window decoration 2
Comment 15 tromzy 2019-02-08 12:32:28 UTC
See the 2 screenshots I provided : on "Breeze window decoration 1", I just made a right click on the title bar : the entries are blue-ish.

On "Breeze window decoration 2", this is after I hovered every entry : they got even more blue.
Comment 16 Vlad Zahorodnii 2019-02-08 12:38:55 UTC
Hmm, that glitch looks unrelated to this report.

Anyway, I'm marking it as WORKSFORME. If you're still able to reproduce this bug, please file a bug report downstream (kvantum). If it turns out that's a problem in KWin (very unlikely), then please reopen this bug report.