Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
5275acd0e4
2 changed files with 6 additions and 0 deletions
|
@ -27,6 +27,7 @@ class ScStwAppThemeManager : public QObject
|
|||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(ScStwAppTheme* theme READ getTheme NOTIFY themeChanged)
|
||||
Q_PROPERTY(QString themeName READ getThemeName WRITE setTheme NOTIFY themeChanged)
|
||||
|
||||
public:
|
||||
explicit ScStwAppThemeManager(QObject *parent = nullptr);
|
||||
|
@ -45,6 +46,7 @@ signals:
|
|||
public slots:
|
||||
ScStwAppTheme* getTheme();
|
||||
Q_INVOKABLE bool setTheme(QString themeName);
|
||||
Q_INVOKABLE QString getThemeName();
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -174,3 +174,7 @@ QString ScStwAppThemeManager::lighter(QString color, double factor) {
|
|||
qcolor.setHsv(h,s,v * factor);
|
||||
return qcolor.name();
|
||||
}
|
||||
|
||||
QString ScStwAppThemeManager::getThemeName() {
|
||||
return this->currentTheme->getName();
|
||||
}
|
||||
|
|
Reference in a new issue