File indexing completed on 2024-04-21 03:41:49

0001 /*
0002     SPDX-FileCopyrightText: 2008 Danilo Balzaque <danilo.balzaque@ltia.fc.unesp.br>
0003     SPDX-FileCopyrightText: 2008 Tadeu Araujo <tadeu.araujo@ltia.fc.unesp.br>
0004 
0005     SPDX-License-Identifier: GPL-2.0-or-later
0006 */
0007 
0008 #ifndef STATISTICSBARWIDGET_H
0009 #define STATISTICSBARWIDGET_H
0010 
0011 #include <QWidget>
0012 
0013 class QProgressBar;
0014 class QLabel;
0015 
0016 /*! Constructs a QWidget bla bla bla
0017  *  \author Danilo Balzaque
0018  * */
0019 class StatisticsBarWidget : public QWidget
0020 {
0021     Q_OBJECT
0022 public:
0023     /** constructor */
0024     explicit StatisticsBarWidget(QWidget * parent = nullptr);
0025 
0026     /** destructor */
0027     ~StatisticsBarWidget() override;
0028 
0029     /** Update statisticsBar */
0030     void updateBar(int correct, int skipped, int total);
0031 
0032 protected:
0033 
0034 private:
0035     int m_correct;
0036     int m_skipped;
0037     int m_total;
0038 
0039     QFont defaultFont;
0040 
0041     QLabel * m_correctLabel;
0042     QLabel * m_skippedLabel;
0043     QLabel * m_incorrectLabel;
0044 
0045     QProgressBar * m_correctBar;
0046     QProgressBar * m_skippedBar;
0047     QProgressBar * m_incorrectBar;
0048 };
0049 
0050 #endif