Bug 458476

Summary: Qt Theme bug on GNOME
Product: [Applications] okular Reporter: jamesedwards
Component: generalAssignee: Okular developers <okular-devel>
Status: REPORTED ---    
Severity: normal CC: hujq
Priority: NOR    
Version First Reported In: 22.08.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Picture of the broken theme compared to the correct theme application after downgrade.

Description jamesedwards 2022-08-29 16:37:53 UTC
Created attachment 151686 [details]
Picture of the broken theme compared to the correct theme application after downgrade.

SUMMARY

After the upgrade to version 22.08.0 via pacman the QT_QPA_PLATFORMTHEME environment variable override which I set to `gnome` seems to no longer be respected. The `gnome` theme is supposed to integrate QT applications visually into the Gnome desktop and should in this case result in a dark Adwaita-like theming. It is part of the package qgnomeplatform-qt5. 
However, the theme is a mashup of light background with dark buttons (see attachment). I use the GNOME DE version 42.4 with Wayland. Okular runs in XWayland as QT_QPA_PLATFORM=wayland is NOT set. This bug is only present in Okular, no other QT application (e.g. owncloud-client, qt5ct) work fine. The bug disappears after downgrading the okular package to version 22.04.3-1 from the Arch Linux repositories.

STEPS TO REPRODUCE
1. Install the current Arch Linux version
2. Install qgnomeplatform-qt5
3. Set the QT_QPA_PLATFORMTHEME=gnome environment variable
4. Open a pdf in okular

OBSERVED RESULT
The Okular QT theme is broken.

EXPECTED RESULT
The Okular QT theme should correspont to the one set in the QT_QPA_PLATFORMTHEME environment variable.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux Kernel: 5.19.4-arch1-1
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 5.97.0
Qt Version: 5.15.5 (built against 5.15.5)

ADDITIONAL INFORMATION