kchart

kchartSubTypeChartPage.h

00001 /* This file is part of the KDE project
00002    Copyright (C) 1999,2000 Matthias Kalle Dalheimer <kalle@kde.org>
00003 
00004    This library is free software; you can redistribute it and/or
00005    modify it under the terms of the GNU Library General Public
00006    License as published by the Free Software Foundation; either
00007    version 2 of the License, or (at your option) any later version.
00008 
00009    This library is distributed in the hope that it will be useful,
00010    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012    Library General Public License for more details.
00013 
00014    You should have received a copy of the GNU Library General Public License
00015    along with this library; see the file COPYING.LIB.  If not, write to
00016    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00017  * Boston, MA 02110-1301, USA.
00018 */
00019 
00020 
00021 #ifndef __KCHARTSUBTYPECHARTPAGE_H__
00022 #define __KCHARTSUBTYPECHARTPAGE_H__
00023 
00024 #include <qwidget.h>
00025 
00026 class KDChartParams;
00027 class QLabel;
00028 class QRadioButton;
00029 class QSpinBox;
00030 
00031 namespace KChart
00032 {
00033 
00034 class KChartParams;
00035 
00036 class KChartSubTypeChartPage : public QWidget
00037 {
00038     Q_OBJECT
00039 
00040 public:
00041     KChartSubTypeChartPage( KChartParams* params, QWidget* parent ) :
00042         QWidget( parent ), m_params( params ) {}
00043     virtual void init() = 0;
00044     virtual void apply() = 0;
00045 
00046 protected:
00047     KChartParams* m_params;
00048 };
00049 
00050 class KChartLineSubTypeChartPage : public KChartSubTypeChartPage
00051 {
00052     Q_OBJECT
00053 
00054 public:
00055     KChartLineSubTypeChartPage( KChartParams* params,
00056                                 QWidget* parent );
00057     virtual void init();
00058     virtual void apply();
00059 
00060 private slots:
00061     void slotChangeSubType( int type );
00062 
00063 private:
00064     QRadioButton* normal;
00065     QRadioButton* stacked;
00066     QRadioButton* percent;
00067     QLabel* exampleLA;
00068 };
00069 
00070 
00071 class KChartAreaSubTypeChartPage : public KChartSubTypeChartPage
00072 {
00073     Q_OBJECT
00074 
00075 public:
00076     KChartAreaSubTypeChartPage( KChartParams* params,
00077                                 QWidget* parent );
00078     virtual void init();
00079     virtual void apply();
00080 
00081 private slots:
00082     void slotChangeSubType( int type );
00083 
00084 private:
00085     QRadioButton* normal;
00086     QRadioButton* stacked;
00087     QRadioButton* percent;
00088     QLabel* exampleLA;
00089 };
00090 
00091 class KChartBarSubTypeChartPage : public KChartSubTypeChartPage
00092 {
00093     Q_OBJECT
00094 
00095 public:
00096     KChartBarSubTypeChartPage( KChartParams* params, QWidget* parent );
00097     virtual void init();
00098     virtual void apply();
00099 
00100 private slots:
00101     void slotChangeSubType( int type );
00102 
00103 private:
00104     QRadioButton  *normal;
00105     QRadioButton  *stacked;
00106     QRadioButton  *percent;
00107     QLabel        *exampleLA;
00108     QSpinBox      *m_numLines;
00109 };
00110 
00111 
00112 class KChartHiloSubTypeChartPage : public KChartSubTypeChartPage
00113 {
00114     Q_OBJECT
00115 
00116 public:
00117     KChartHiloSubTypeChartPage( KChartParams* params,
00118                                 QWidget* parent );
00119     virtual void init();
00120     virtual void apply();
00121 
00122 private slots:
00123     void slotChangeSubType( int type );
00124 
00125 private:
00126     QRadioButton* normal;
00127     QRadioButton* stacked;
00128     QRadioButton* percent;
00129     QLabel* exampleLA;
00130 };
00131 
00132 class KChartPolarSubTypeChartPage : public KChartSubTypeChartPage
00133 {
00134     Q_OBJECT
00135 
00136 public:
00137     KChartPolarSubTypeChartPage( KChartParams* params,
00138                                 QWidget* parent );
00139     virtual void init();
00140     virtual void apply();
00141 
00142 private slots:
00143     void slotChangeSubType( int type );
00144 
00145 private:
00146     QRadioButton* normal;
00147     QRadioButton* stacked;
00148     QRadioButton* percent;
00149     QLabel* exampleLA;
00150 };
00151 
00152 }  //KChart namespace
00153 
00154 #endif
KDE Home | KDE Accessibility Home | Description of Access Keys