File indexing completed on 2024-05-26 04:23:43

0001 /**
0002  * SPDX-FileCopyrightText: 2001-2015 Klaralvdalens Datakonsult AB. All rights reserved.
0003  *
0004  * This file is part of the KD Chart library.
0005  *
0006  * SPDX-License-Identifier: GPL-2.0-or-later
0007  */
0008 
0009 #ifndef MAINWIDGET_H
0010 #define MAINWIDGET_H
0011 
0012 #include "Model.h"
0013 
0014 #include "ui_Controls.h"
0015 
0016 #include <QWidget>
0017 
0018 
0019 
0020 namespace KChart {
0021 class Plotter;
0022 }
0023 
0024 class Model;
0025 class QPushButton;
0026 class QRadioButton;
0027 
0028 class MainWidget : public QWidget
0029 {
0030     Q_OBJECT
0031 public:
0032     MainWidget();
0033 
0034 private Q_SLOTS:
0035     void functionToggled( bool checked );
0036     void addPointsButtonClicked();
0037 
0038 private:
0039     QWidget* m_controlsContainer;
0040     Ui::Controls m_controls;
0041     QVector< QRadioButton* > m_functionSelector;
0042     QVector< QPushButton* > m_addPointsButtons;
0043 
0044     KChart::Plotter* m_plotter;
0045     Model m_model;
0046 };
0047 
0048 #endif