Show command link button in respective color for windowsvista style

The command link button was shown in active color even when its disabled
while using windows vista style and the patch
e9cf618a9d0ead8711a5fbe563b1c7118c0143c8 further cause regression when
hovered over it.

This patch fixes it by setting color for corresponding color group in
windows vista style.

Pick-to: 6.5
Change-Id: I9a8f62f8c5895592571978ec7c9abccfc69e64a2
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 25c9f595465b5333f558b35a165e6940d834037d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Santhosh Kumar 2023-09-08 16:34:59 +02:00 committed by Qt Cherry-pick Bot
parent 406ad89a3b
commit 5e2caca64e

View File

@ -4667,9 +4667,8 @@ void QWindowsVistaStyle::polish(QWidget *widget)
buttonFont.setFamilies(QStringList{QLatin1String("Segoe UI")});
widget->setFont(buttonFont);
QPalette pal = widget->palette();
pal.setColor(QPalette::ButtonText, QColor(21, 28, 85));
pal.setColor(QPalette::BrightText, QColor(7, 64, 229));
pal.setResolveMask(0);
pal.setColor(QPalette::Active, QPalette::ButtonText, QColor(21, 28, 85));
pal.setColor(QPalette::Active, QPalette::BrightText, QColor(7, 64, 229));
widget->setPalette(pal);
}
#endif // QT_CONFIG(commandlinkbutton)