Bug 509066

Summary: Flathub screenshot images show background color and a second shadow
Product: [Applications] Discover Reporter: Thomas Bertels <tbertels>
Component: discoverAssignee: Plasma Bugs List <plasma-bugs-null>
Status: ASSIGNED ---    
Severity: minor CC: akselmo, aleixpol, nate
Priority: NOR Keywords: junior-jobs
Version First Reported In: 6.4.80   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
URL: https://docs.flathub.org/docs/for-app-authors/metainfo-guidelines/quality-guidelines#just-the-app-window
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: KolourPaint in Discover
KolourPaint in Gnome Software

Description Thomas Bertels 2025-09-03 11:45:33 UTC
Created attachment 184665 [details]
KolourPaint in Discover

SUMMARY
Flathub screenshots guidelines (see URL) say that they should include a shadow and thus be transparent.
But Discover doesn't support transparent background and adds its own shadow.
If an app screenshot image has a transparent background, Discover displays the background color instead of a transparent background.

STEPS TO REPRODUCE
1. Open Discover
2. Search KolourPaint
3. Open KolourPaint (Flathub version) app page

OBSERVED RESULT
The screenshots have a gray border and a second shadow.

EXPECTED RESULT
The screenshots shouldn't have any border and only one shadow.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 6.4.80
KDE Frameworks Version: 6.18.0
Qt Version: 6.9.2

ADDITIONAL INFORMATION
Firefox has a smaller shadow, but it's visible too.
Comment 1 Thomas Bertels 2025-09-03 11:46:38 UTC
Created attachment 184666 [details]
KolourPaint in Gnome Software
Comment 2 Akseli Lahtinen 2025-09-24 09:05:12 UTC
Can confirm this issue. Will have to bring it up with VDG.

Operating System: Fedora Linux 42
KDE Plasma Version: 6.5.80
KDE Frameworks Version: 6.19.0
Qt Version: 6.9.2
Kernel Version: 6.16.7-200.fc42.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 3600 6-Core Processor
Memory: 16 GiB of RAM (15.5 GiB usable)
Graphics Processor: AMD Radeon RX 6600
Comment 3 Nate Graham 2025-09-24 19:33:22 UTC
We implemented it this way to avoid looking bad with app screenshots that don't have a shadow. There are still tons that don't. The trade-off is that it looks a bit weird with app screenshots that *do* have a shadow.

If there was a way to accurately detect the presence of a shadow, we could conditionalize the code that adds an extra shadowed frame.

Can anyone think of a way to do that? Maybe if all four corners of the image have an alpha channel with any level of transparency?
Comment 4 Akseli Lahtinen 2025-09-25 09:12:21 UTC
(In reply to Nate Graham from comment #3)
> Can anyone think of a way to do that? Maybe if all four corners of the image
> have an alpha channel with any level of transparency?

To me this sounds a lot of trouble for minimal gain. I don't really understand why the current situation is a problem, anyway.
Comment 5 Nate Graham 2025-09-25 15:14:05 UTC
The problem is that if you're sensitive to this kind of thing, some screenshots basically have a double shadowed frame. Not everyone is sensitive to this, though.
Comment 6 Thomas Bertels 2025-09-26 08:45:59 UTC
The easiest way to fix this would be to stop adding a shadow to screenshots in Discover.

If the current situation isn't a problem, refraining from adding a shadow should be even less of a problem. ;)
With Flathub recommending to include a shadow in the screenshots, this will only get worse.
Comment 7 Nate Graham 2025-09-26 15:51:15 UTC
If we don't want to add some fancy logic to conditionally toggle the Discover-provided frame and shadow, we have to choose whose screenshots to make uglier.

I suppose there's some logic to not penalizing apps that made the effort to add proper window shadows.
Comment 8 Akseli Lahtinen 2025-09-29 11:49:18 UTC
> I suppose there's some logic to not penalizing apps that made the effort to add proper window shadows.

I agree: Make the ones following guidelines look good.
Comment 9 Thomas Bertels 2025-11-14 13:18:02 UTC
The relevant code seems to be in https://github.com/KDE/discover/blob/master/discover/qml/CarouselDelegate.qml
Comment 10 Bug Janitor Service 2025-12-05 19:22:02 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/discover/-/merge_requests/1217