kspread_dlg_conditional.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef __kspread_dlg_conditional__
00024 #define __kspread_dlg_conditional__
00025
00026 #include <kdialogbase.h>
00027 #include <qwidget.h>
00028
00029 class QComboBox;
00030 class KLineEdit;
00031
00032 class KSpreadCell;
00033 class KSpreadStyle;
00034 class KSpreadView;
00035 #include "kspread_condition.h"
00036
00037 class KSpreadConditionalWidget : public QWidget
00038 {
00039 Q_OBJECT
00040
00041 public:
00042 KSpreadConditionalWidget( QWidget * parent = 0, const char * name = 0, WFlags fl = 0 );
00043 ~KSpreadConditionalWidget();
00044
00045 QComboBox * m_condition_1;
00046 QComboBox * m_style_1;
00047 KLineEdit * m_firstValue_1;
00048 KLineEdit * m_secondValue_1;
00049
00050 QComboBox * m_condition_2;
00051 QComboBox * m_style_2;
00052 KLineEdit * m_firstValue_2;
00053 KLineEdit * m_secondValue_2;
00054
00055 QComboBox * m_condition_3;
00056 QComboBox * m_style_3;
00057 KLineEdit * m_firstValue_3;
00058 KLineEdit * m_secondValue_3;
00059
00060 public slots:
00061 void slotTextChanged1( const QString & );
00062 void slotTextChanged2( const QString & );
00063 void slotTextChanged3( const QString & );
00064 };
00065
00066
00067 class KSpreadConditionalDlg : public KDialogBase
00068 {
00069 Q_OBJECT
00070 public:
00071 KSpreadConditionalDlg( KSpreadView * parent, const char * name,
00072 const QRect & marker );
00073
00074 void init();
00075
00076 public slots:
00077 void slotOk();
00078
00079 protected:
00080 KSpreadView * m_view;
00081 KSpreadConditionalWidget * m_dlg;
00082 QRect m_marker;
00083 KSpreadConditional m_result;
00084
00085 private:
00086 void init( KSpreadConditional const & tmp, int numCondition );
00087 Conditional typeOfCondition( QComboBox const * const cb ) const;
00088
00089 bool checkInputData( KLineEdit const * const edit1,
00090 KLineEdit const * const edit2 );
00091 bool checkInputData();
00092 bool getCondition( KSpreadConditional & newCondition, const QComboBox * cb,
00093 const KLineEdit * edit1, const KLineEdit * edit2,
00094 const QComboBox * sb, KSpreadStyle * style );
00095
00096 };
00097
00098 #endif
00099
This file is part of the documentation for kspread Library Version 1.4.2.