Kleopatra: wrong color for some button texts in "high contrast white" setting
Closed, ResolvedPublic

Assigned To
Authored By
ebo
Mar 24 2025, 4:52 PM

Description

On Windows 10 with the high contrast setting "contrast white", the highlight color is purple an the Text white:

The buttons in Kleo do not honor this, e.g.:



The button on the left has a lighter purple because it's background color is fading in and out.
I suspect it is no good idea to have the pre-selected buttons change background color this way as the text color needs to change in this case, too.
The pre-selected Windows explorer buttons do not do this, they are simply purple with white text.

Edit 2025-10-01:
This is similar in Windows 11 with the high contrast design "Desert":


The dark brown background should trigger a light foreground color.

Details

Version
Gpg4win 4.4

Event Timeline

ebo triaged this task as Normal priority.Mar 24 2025, 4:52 PM
ebo created this task.

After T7587: Kleopatra: High contrast mode isn't respected anymore was fixed this is what the buttons look like in Gpg4win 5:

They are okay. The selected "Tout enregistrer" (Save all) button should look like "Ausgewählter Text", i.e. white text on violet (see the below screenshot of the Folder options dialog of Windows Explorer), but I think the contrast is okay. Hence, this bug exists only in the Qt 5 based releases Gpg4win 4.4 and VSD 3.3.

ikloecker moved this task from Backlog to WIP on the vsd34 board.
ebo assigned this task to ikloecker.
ebo updated the task description. (Show Details)

I had a look at Qt 5. All of Qt's Windows styles are broken with regards to button or menu item styling. They change the background color of the hovered and/or selected button, but they use the default foreground color of the common base style class for the text. I don't think that fixing the (obsolete) Windows styles is worth the effort. As workaround we should use the Fusion style if high-contrast is active.

ikloecker mentioned this in Unknown Object (Maniphest Task).Oct 6 2025, 9:16 AM
ikloecker changed the task status from Open to Testing.Oct 6 2025, 3:41 PM

If a high-contrast mode is enabled then Gpg4win 4.4 (and VSD 3.4) will use the Fusion style which works much better with high contrast than the Windows XP/Vista style with animations that was used previously.

ikloecker mentioned this in Unknown Object (Maniphest Task).Oct 13 2025, 9:49 AM

I think, this looks good to me on vsd-3.4.0-beta1294 @ win10. It's not high contrast though. Is this still ok?



Selected menu items in win11 / desert is fine now:

ikloecker mentioned this in Unknown Object (Maniphest Task).Jul 13 2026, 9:41 AM
timegrid changed the task status from Testing to Open.EditedTue, Aug 18, 12:59 PM
timegrid moved this task from QA to WIP on the vsd34 board.

Tested with vsd-3.4.0-beta1326 @ win10.

Issues found:

  • Icon color is still dark:
  • Colored icons don't change color:
  • Other text button font colors are now white, too:

Done:

  • Button font is now white:

The icons are fixed with Qt 6/KF6. There's no way to fix this for Qt 5/KF5.

Colored icons are no problem. If you check what Windows itself does (e.g. in Windows Explorer) you'll notice that it uses the same colorful icons regardless of high contrast.

ikloecker changed the task status from Open to Testing.Wed, Aug 19, 5:20 PM

The problem with white button text on white button background is fixed.

ikloecker mentioned this in Unknown Object (Maniphest Task).Mon, Aug 24, 9:33 AM

Looks good to me on vsd-3.4.0-beta1344 @ win10:


timegrid edited projects, added vsd34 (vsd-3.4.0); removed vsd34.