39 lines
860 B
C
Raw Normal View History

2017-07-23 16:40:24 +02:00
/******************************************************************************
* QSkinny - Copyright (C) 2016 Uwe Rathmann
* This file may be used under the terms of the 3-clause BSD License
*****************************************************************************/
#ifndef THEME_H
#define THEME_H 1
#include <QColor>
2018-08-03 08:15:28 +02:00
#include <QObject>
2017-07-23 16:40:24 +02:00
class Theme : public QObject
{
Q_OBJECT
Q_PROPERTY( QColor accent READ accent WRITE setAccent NOTIFY accentChanged )
Q_PROPERTY( QString skin READ skin WRITE setSkin NOTIFY skinChanged )
2018-08-03 08:15:28 +02:00
public:
2017-07-23 16:40:24 +02:00
Theme( QObject* parent = nullptr );
void setAccent( QColor color );
QColor accent() const;
void setSkin( const QString& );
QString skin() const;
2018-08-03 08:15:28 +02:00
Q_SIGNALS:
2017-07-23 16:40:24 +02:00
void accentChanged();
void skinChanged();
2018-08-03 08:15:28 +02:00
private:
2017-07-23 16:40:24 +02:00
void updateColors();
QColor m_accent;
};
#endif