Bug 506437

Summary: Invisible icons on selected (tool) buttons
Product: [Plasma] Breeze Reporter: Ingo Klöcker <kloecker>
Component: QStyleAssignee: Plasma Bugs List <plasma-bugs-null>
Status: REPORTED ---    
Severity: normal CC: noahadvs, uhhadd
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Invisible icon on focussed (raised) button in Kate's Find&Replace panel
Hard to see icon on focussed (pressed) button in Kate's Find&Replace panel

Description Ingo Klöcker 2025-07-01 13:42:18 UTC
Created attachment 182835 [details]
Invisible icon on focussed (raised) button in Kate's Find&Replace panel

In many applications the icons on buttons become invisible (or very hard to see) when the button gets focus. See for example the two screenshots showing tool (?) buttons in Kate's Find&Replace panel.

I think the problem is that Breeze uses the selected state for painting the icon so that KIconLoader recolors the icon with the highlight text color (white) which is wrong for buttons because selected buttons are not colored with the highlight color.
Comment 1 Ingo Klöcker 2025-07-01 13:43:09 UTC
Created attachment 182836 [details]
Hard to see icon on focussed (pressed) button in Kate's Find&Replace panel
Comment 2 Ingo Klöcker 2025-07-01 13:55:05 UTC
The problem doesn't occur with the Fusion style (likely because QCommonStyle never passes QIcon::Selected to the icon drawing).