forked from qt-creator/qt-creator
QmlDesigner: Set the correct color for tooltips
A static palette is set for the QToolTip to apply the theme color. Change-Id: I9d7dd2290c1ac4feb5cdebc8388a611bc2b38add Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
|
||||
#include <QPainter>
|
||||
#include <QStyleOption>
|
||||
#include <QToolTip>
|
||||
|
||||
using namespace Utils;
|
||||
using namespace QmlDesigner;
|
||||
@@ -76,7 +77,12 @@ StudioStylePrivate::StudioStylePrivate(StudioStyle *q)
|
||||
color(Theme::DStoolbarBackground), // base
|
||||
color(Theme::DStoolbarBackground) // window
|
||||
);
|
||||
|
||||
stdPalette.setBrush(QPalette::ColorRole::ToolTipBase, color(Theme::DStoolbarBackground));
|
||||
stdPalette.setColor(QPalette::ColorRole::ToolTipText, color(Theme::DStextColor));
|
||||
}
|
||||
|
||||
QToolTip::setPalette(stdPalette);
|
||||
}
|
||||
|
||||
QList<const QObject *> StudioStylePrivate::animationTargets() const
|
||||
|
Reference in New Issue
Block a user