kspread
kspread_dlg_cons.h
00001 /* This file is part of the KDE project 00002 Copyright (C) 2002-2003 Norbert Andres <nandres@web.de> 00003 (C) 2002 Ariya Hidayat <ariya@kde.org> 00004 (C) 2002 Philipp Mueller <philipp.mueller@gmx.de> 00005 (C) 2002 John Dailey <dailey@vt.edu> 00006 (C) 2000-2001 Werner Trobin <trobin@kde.org> 00007 (C) 2000-2001 Laurent Montel <montel@kde.org> 00008 (C) 1999-2002 David Faure <faure@kde.org> 00009 (C) 1999 Stephan Kulow <coolo@kde.org> 00010 (C) 1999 Reginald Stadlbauer <reggie@kde.org> 00011 (C) 1998-1999 Torben Weis <weis@kde.org> 00012 00013 This library is free software; you can redistribute it and/or 00014 modify it under the terms of the GNU Library General Public 00015 License as published by the Free Software Foundation; either 00016 version 2 of the License, or (at your option) any later version. 00017 00018 This library is distributed in the hope that it will be useful, 00019 but WITHOUT ANY WARRANTY; without even the implied warranty of 00020 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00021 Library General Public License for more details. 00022 00023 You should have received a copy of the GNU Library General Public License 00024 along with this library; see the file COPYING.LIB. If not, write to 00025 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00026 * Boston, MA 02110-1301, USA. 00027 */ 00028 00029 #ifndef __kspread_dlg_cons__ 00030 #define __kspread_dlg_cons__ 00031 00032 #include <qstringlist.h> 00033 #include <kdialogbase.h> 00034 00035 class QLineEdit; 00036 class QPushButton; 00037 class QComboBox; 00038 class QCheckBox; 00039 class QListBox; 00040 00041 namespace KSpread 00042 { 00043 class Sheet; 00044 class View; 00045 00046 class ConsolidateDialog : public KDialogBase 00047 { 00048 Q_OBJECT 00049 public: 00050 ConsolidateDialog( View* parent, const char* name ); 00051 ~ConsolidateDialog(); 00052 QStringList refs(); 00053 00054 public slots: 00055 virtual void slotOk(); 00056 virtual void slotCancel(); 00057 void slotAdd(); 00058 void slotRemove(); 00059 00060 void slotSelectionChanged(); 00061 void slotReturnPressed(); 00062 00063 protected: 00064 virtual void closeEvent ( QCloseEvent * ); 00065 00066 View* m_pView; 00067 QLineEdit* m_pRef; 00068 QListBox* m_pRefs; 00069 QComboBox* m_pFunction; 00070 QPushButton* m_pAdd; 00071 QPushButton* m_pRemove; 00072 QCheckBox* m_pRow; 00073 QCheckBox* m_pCol; 00074 QCheckBox* m_pCopy; 00075 00076 QString evaluate( const QString& formula, Sheet* sheet ); 00077 00078 enum { Sum = 0, Average, Count, Max, Min, Product, StdDev, Var }; 00079 }; 00080 00081 } // namespace KSpread 00082 00083 #endif

