Details
-
Bug
-
Resolution: Fixed
-
P1: Critical
-
6.7.0 Beta1, dev
-
None
-
Windows 11 Pro 23H2 Build 22631.2861 (latest updates as of 06 Jan 24)
Lenovo ThinkPad E15 Gen2 AMD Ryzen 4700U Laptop
Visual Studio 2022 17.8.3, MSVC 19.38.33133.0
-
-
41854cfaa (dev), 65cd5a06a (6.7)
Description
While playing around with Qt 6.7beta1 I figured that both fusion and windows11 styles are currently broken for Light system color mode.
I am using the following code to set the icon colors on the colorSchemeChanged signal from QStyleHints:
const auto palette = QGuiApplication::palette(); ZFontIconOption::gColorDisabled = palette.color(QPalette::ColorGroup::Disabled, QPalette::ColorRole::ButtonText); ZFontIconOption::gColor = palette.color(QPalette::ColorRole::ButtonText);
With Qt 6.6.1 I get the following (IMHO correct) values:
Style: "fusion"
Color scheme: Qt::ColorScheme::Light
Disabled color: QColor(ARGB 1, 0.470588, 0.470588, 0.470588)
Normal color: QColor(ARGB 1, 0, 0, 0)
Color scheme: Qt::ColorScheme::Dark
Disabled color: QColor(ARGB 1, 0.615686, 0.615686, 0.615686)
Normal color: QColor(ARGB 1, 1, 1, 1)
However, Qt 6.7.0beta1 returns the following values:
Style: "fusion" Color scheme: Qt::ColorScheme::Light Disabled color: QColor(ARGB 0.894118, 0, 0, 0) Normal color: QColor(ARGB 0.894118, 0, 0, 0) Style: "fusion" Color scheme: Qt::ColorScheme::Dark Disabled color: QColor(ARGB 1, 0.499992, 0.499992, 0.499992) Normal color: QColor(ARGB 1, 1, 1, 1) Style: "windows11" Color scheme: Qt::ColorScheme::Dark Disabled color: QColor(ARGB 1, 0.499992, 0.499992, 0.499992) Normal color: QColor(ARGB 1, 1, 1, 1) Style: "windows11" Color scheme: Qt::ColorScheme::Light Disabled color: QColor(ARGB 0.894118, 0, 0, 0) Normal color: QColor(ARGB 0.894118, 0, 0, 0)
Note that the Disabled color in the Light mode in both styles is identical to the Normal color, therefore disabled icons will be shown (incorrectly) the same when using Qt 6.7 both with fusion and windows11 style.
I tested with qt6-dev from the online installer as well and get the same incorrect behaviour.
I have attached a small testcase which will show "INCORRECT VALUES" iin Light mode on my windows machine with 6.7+ as well with images that visualize the different behvaviour.
The testcase works without problems with Qt 6.6.1
Attachments
Issue Links
- relates to
-
QTBUG-126274 [REG: 6.7.1->6.7.2] Windows/Win11/Vista styles: designer: Spinbox values are shown doubled
-
- Closed
-