From 430d245bb94c634047e7b65232eb3e50e2b6e49a Mon Sep 17 00:00:00 2001 From: Zhao Yuhang <2546789017@qq.com> Date: ćšć, 21 12æ 2023 22:00:37 +0800 Subject: [PATCH] add more attrib --- src/stylesupport/styleagent.h | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/src/stylesupport/styleagent.h b/src/stylesupport/styleagent.h index 8474820..94afa33 100644 --- a/src/stylesupport/styleagent.h +++ b/src/stylesupport/styleagent.h @@ -19,12 +19,22 @@ explicit StyleAgent(QObject *parent = nullptr); ~StyleAgent() override; + enum SystemTheme { + Unknown, + Light, + Dark, + HighContrast, + }; + Q_ENUM(SystemTheme) + public: + SystemTheme systemTheme() const; + QVariant windowAttribute(QWindow *window, const QString &key) const; bool setWindowAttribute(QWindow *window, const QString &key, const QVariant &attribute); Q_SIGNALS: - void systemThemeChanged(); + void systemThemeChanged(); // Do we need wallpaper change notify? protected: StyleAgent(StyleAgentPrivate &d, QObject *parent = nullptr); -- Gitblit v1.9.1