#ifndef ELETIMER_H
#define ELETIMER_H

#include <QWidget>
#include <QDateTime>

class EleTimer : public QWidget {
    Q_OBJECT
public:
    explicit EleTimer(const QJsonObject&, QWidget *parent = nullptr);
    QDateTime targetTime;
    QString   text;
    QColor    textColor;
    QColor    backColor;
    QString   font;
    int       fontSize;
    bool      fontBold;
    bool      fontItalic;
    bool      fontUnderline;
    bool      isDown;
    bool      isMultiline;
    bool      hasDay;
    bool      hasHour;
    bool      hasMin;
    bool      hasSec;
    int secs = 0;
protected:
    void paintEvent(QPaintEvent *) override;
};

#endif // ELETIMER_H
