Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef QXTPROGRESSLABEL_H
00026 #define QXTPROGRESSLABEL_H
00027
00028 #include <QLabel>
00029 #include "qxtglobal.h"
00030 #include "qxtpimpl.h"
00031
00032 class QxtProgressLabelPrivate;
00033
00034 class QXT_GUI_EXPORT QxtProgressLabel : public QLabel
00035 {
00036 Q_OBJECT
00037 QXT_DECLARE_PRIVATE(QxtProgressLabel);
00038 Q_PROPERTY(QString contentFormat READ contentFormat WRITE setContentFormat)
00039 Q_PROPERTY(QString timeFormat READ timeFormat WRITE setTimeFormat)
00040 Q_PROPERTY(int updateInterval READ updateInterval WRITE setUpdateInterval)
00041
00042 public:
00043 explicit QxtProgressLabel(QWidget* parent = 0, Qt::WindowFlags flags = 0);
00044 explicit QxtProgressLabel(const QString& text, QWidget* parent = 0, Qt::WindowFlags flags = 0);
00045 virtual ~QxtProgressLabel();
00046
00047 QString contentFormat() const;
00048 void setContentFormat(const QString& format);
00049
00050 QString timeFormat() const;
00051 void setTimeFormat(const QString& format);
00052
00053 int updateInterval() const;
00054 void setUpdateInterval(int msecs);
00055
00056 public Q_SLOTS:
00057 void setValue(int value);
00058 void refresh();
00059 void restart();
00060
00061 virtual void timerEvent(QTimerEvent* event);
00062 };
00063
00064 #endif // QXTPROGRESSLABEL_H