Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

Dialog.h

Go to the documentation of this file.
00001 //LabPlot : Dialog.h
00002 
00003 #ifndef DIALOG_H
00004 #define DIALOG_H
00005 
00006 #include <kdialog.h>
00007 #include <qvbox.h>
00008 #include <kpushbutton.h>
00009 #include <qgroupbox.h>
00010 #include <qcheckbox.h>
00011 #include <qtabwidget.h>
00012 #include <qvalidator.h>
00013 #include <klineedit.h>
00014 #include <klistbox.h>
00015 #include <kcolorbutton.h>
00016 #include <kcombobox.h>
00017 #include <knuminput.h>
00018 #include "Worksheet.h"
00019 
00020 #include "inputfilter.h"
00021 #include "binarytype.h"
00022 
00023 #ifdef HAVE_GL
00024 #include "qwt3d_surfaceplot.h"
00025 #endif
00026 
00027 class Dialog: public KDialog
00028 {
00029         Q_OBJECT
00030 public:
00031         Dialog(class MainWin *mw, const char *name);
00032         QVBox* surfaceStyle(QTabWidget *tw, bool fresh);
00033         QVBox* simpleStyle(QTabWidget *tw, Style *style, Symbol *symbol);
00034         void saveSimpleStyle();
00035         void saveSurfaceStyle();
00036         void saveErrorbarSettings();
00037 public slots:
00038         void setDestination(int v) {sheetcb->setCurrentItem(v); }               
00039         void setFilename(QString v) { filele->setText(v); }                     
00040         void setFilter(int v) { filtercb->setCurrentItem(v); }                  
00041         void setSimplify(bool b=true) { simplifycb->setChecked(b); }            
00042         void setEmpty(bool b=true) { emptycb->setChecked(b); }                  
00043         void setImportHeader(bool b=true) { headercb->setChecked(b); }          
00044         void setSameXColumn(bool b=true) { samexcb->setChecked(b); }            
00045         void setSeparator(int v) { sccb->setCurrentItem(v); }                   
00046         void setSeparator(QChar v) { sccb->setCurrentText(v); }                 
00047         void setComment(int v) { commcb->setCurrentItem(v); }                   
00048         void setComment(QChar v) { commcb->setCurrentText(v); }                 
00049         void setDataRange(int v, int e) { startle->setText(QString::number(v)); endle->setText(QString::number(e)); }
00051         void setStart(int v) {startle->setText(QString::number(v));}
00052         void setEnd(int v) {endle->setText(QString::number(v));}
00053 
00054         // binary data
00055         void setVars(int v) { varle->setText(QString::number(v)); }             
00056         void setBinaryType(int t) { binarytypecb->setCurrentItem(t); }          
00057         void setByteOrder(int b) { byteordercb->setCurrentItem(b); }            
00058 
00059         void setStyle(Style *s);                                                
00060         void setSymbol(Symbol *s);                                              
00061 protected:
00062         void resizeEvent(QResizeEvent *e);
00063         QVBox* annotateValuesTab(QTabWidget *tw, Graph *graph);
00064         QVBox* errorbarTab(QTabWidget *tw, Symbol *symbol);
00065         void importWidget(QVBox *vb,QString filename, InputFilter filter);
00066         void saveImportSettings();
00067         double getBinaryValue(QDataStream *d, BinaryType type);
00068         bool openColorMap(QString fn);
00069         void fillBrushBox(KComboBox *cb,SType t, QColor c,FType f, QColor s);
00070         QGroupBox *vbox, *gbox;
00071         class MainWin *mw;
00072         class Worksheet *p;
00073         class Spreadsheet *s;
00074 #ifdef HAVE_GL
00075         Qwt3D::ColorVector cv;
00076 #endif
00077         KPushButton *ok, *apply, *save, *cancel;
00078         KLineEdit *filele;                                              // used from various dialogs
00079         QLabel *fileinfo;
00080         KComboBox *cb2, *pencb, *brushcb, *sbrushcb;                    // simple
00081         KComboBox *symbolcb, *symbolfillcb;                             // simple
00082         KColorButton *color, *fcolor, *scolor, *sfcolor;                // simple
00083         QCheckBox *filled, *sortpointscb;                               // simple
00084         KIntNumInput *boxwidth, *width, *ssize;                         // simple
00085         QCheckBox *autobox, *ccb, *dcb, *coloredcb, *meshcb, *relativecb;       // surface
00086         KLineEdit *numberle, *thresholdle;                                      // surface
00087         KComboBox *dbrushcb;                                                    // surface
00088         KColorButton *contourcolor;                                             // surface
00089         KLineEdit *contourwidthle;                                              // surface
00090         KComboBox *typecb, *positioncb;                                         // annotatetab
00091         KIntNumInput *distance;                                                 // annotatetab
00092         KColorButton *ebarcolor, *ebarbcolor;                                   // errorbar
00093         KIntNumInput *ebarxsize, *ebarysize, *ebarwidth, *ebarbwidth;           // errorbar
00094         KComboBox *ebarstylecb, *ebarbstylecb, *ebarxtypecb, *ebarytypecb;      // errorbar
00095         QCheckBox *simplifycb, *emptycb, *headercb, *samexcb;                   // importWidget
00096         QLabel *seplabel, *commlabel, *startlabel, *endlabel;                   // importWidget
00097         KLineEdit *startle, *endle;                                             // importWidget
00098         KComboBox *filtercb, *sccb, *commcb;                                    // importWidget
00099         QLabel *varlabel, *binarytypelabel, *byteorderlabel;                    // importWidget : binary
00100         KComboBox *binarytypecb, *byteordercb;                                  // importWidget : binary
00101         KLineEdit *varle;
00102         KComboBox *sheetcb;                                     // for destination selection (list dialogs+function/data dialog)
00103 protected slots:
00104         void updateFileInfo();
00105         void selectFile();
00106         void fileInfo();
00107         void selectColormap();
00108         void adaptDataColors(const QString&);
00109         void updateFilter(int item);
00110         QStringList splitLine(QString line,QString sep, bool empty);
00111 private:
00112         void fillSymbolBox(QColor c, FType f, QColor s, int b);
00113         void fillSymbolFillBox(SType t, QColor c, QColor s, int b);
00114 private slots:
00115         void styleChanged();
00116         void symbolChanged();
00117 };
00118 
00119 #endif //DIALOG_H

Generated on Sat Oct 13 21:55:01 2007 for LabPlot by  doxygen 1.4.4