QtiPlot  0.9.8.2
Plot3DDialog.h
Go to the documentation of this file.
1 /***************************************************************************
2  File : Plot3DDialog.h
3  Project : QtiPlot
4  --------------------------------------------------------------------
5  Copyright : (C) 2004-2007 by Ion Vasilief
6  Email (use @ for *) : ion_vasilief*yahoo.fr
7  Description : Surface plot options dialog
8 
9  ***************************************************************************/
10 
11 /***************************************************************************
12  * *
13  * This program is free software; you can redistribute it and/or modify *
14  * it under the terms of the GNU General Public License as published by *
15  * the Free Software Foundation; either version 2 of the License, or *
16  * (at your option) any later version. *
17  * *
18  * This program is distributed in the hope that it will be useful, *
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
21  * GNU General Public License for more details. *
22  * *
23  * You should have received a copy of the GNU General Public License *
24  * along with this program; if not, write to the Free Software *
25  * Foundation, Inc., 51 Franklin Street, Fifth Floor, *
26  * Boston, MA 02110-1301 USA *
27  * *
28  ***************************************************************************/
29 #ifndef PLOT3DDIALOG_H
30 #define PLOT3DDIALOG_H
31 
32 #include "Graph3D.h"
33 #include <QCheckBox>
34 
35 class QGroupBox;
36 class QComboBox;
37 class QLabel;
38 class QTextEdit;
39 class QListWidget;
40 class QPushButton;
41 class QRadioButton;
42 class QSpinBox;
43 class QTabWidget;
44 class QWidget;
45 class QStringList;
46 class QStackedWidget;
47 class QDoubleSpinBox;
48 class ColorButton;
49 class TextFormatButtons;
50 class DoubleSpinBox;
51 class ColorMapEditor;
52 
53 using namespace Qwt3D;
54 
56 class Plot3DDialog : public QDialog
57 {
58  Q_OBJECT
59 
60 public:
61  Plot3DDialog( QWidget* parent, Qt::WFlags fl = 0 );
62  void setPlot(Graph3D *);
63 
64  void showTitleTab();
65  void showAxisTab();
66  void showGeneralTab();
67 
68 private slots:
69  void accept();
70  bool updatePlot();
71 
72  void pickTitleFont();
73  void viewAxisOptions(int axis);
74  QFont axisFont(int axis);
75  void pickAxisLabelFont();
76  void pickNumbersFont();
77 
78  void viewScaleLimits(int axis);
79  void disableMeshOptions();
80 
81  void worksheet();
82 
83  void initPointsOptionsStack();
84  void changeZoom(int);
85  void changeTransparency(int val);
86  void pickDataColorMap();
87  void updateColorMapFileGroupBox(bool);
88  void updateLinearColorMapGroupBox(bool);
89  void enableMajorGrids(bool on);
90  void enableMinorGrids(bool on);
91 
92 private:
93  void initConnections();
94  void initScalesPage();
95  void initAxesPage();
96  void initTitlePage();
97  void initGridPage();
98  void initColorsPage();
99  void initGeneralPage();
100  void initPrintPage();
101  void setColorMapPreview(const QString& fileName);
102 
103  void showBarsTab();
104  void showPointsTab(double rad, bool smooth);
105  void showConesTab(double rad, int quality);
106  void showCrossHairTab(double rad, double linewidth, bool smooth, bool boxed);
107 
109  QGroupBox *linearColorMapGroupBox, *colorMapFileGroupBox;
111  QFont titleFont, xAxisFont,yAxisFont,zAxisFont, numbersFont;
112  QStringList labels;
113  QDoubleSpinBox *boxMeshLineWidth;
114  QPushButton* buttonApply;
115  QPushButton* buttonOk;
116  QPushButton* buttonCancel;
117  QPushButton *btnTitleFont, *btnLabelFont;
118  QPushButton *btnNumbersFont, *btnTable, *btnColorMap;
119  ColorButton *btnBackground, *btnMesh, *btnAxes, *btnTitleColor, *btnLabels, *btnNumbers, *btnGrid, *btnGridMinor;
121  QTabWidget* generalDialog;
122  QWidget *scale, *colors, *general, *axes, *title, *bars, *points, *gridPage, *printPage;
123  DoubleSpinBox *boxFrom, *boxTo;
124  QTextEdit *boxTitle, *boxLabel;
125  QSpinBox *boxMajors, *boxMinors;
126  QGroupBox *TicksGroupBox, *AxesColorGroupBox;
127  QSpinBox *boxResolution, *boxDistance, *boxTransparency;
129  QCheckBox *boxLegend, *boxSmooth, *boxBoxed, *boxCrossSmooth, *boxOrthogonal;
130  QListWidget *axesList, *axesList2;
131  QComboBox *boxType, *boxPointStyle;
132  DoubleSpinBox *boxMajorLength, *boxMinorLength, *boxConesRad;
133  QSpinBox *boxZoom, *boxXScale, *boxYScale, *boxZScale, *boxQuality, *boxPrecision;
134  DoubleSpinBox *boxSize, *boxBarsRad, *boxCrossRad, *boxCrossLinewidth;
135  QStackedWidget *optionStack;
136  QWidget *dotsPage, *conesPage, *crossPage;
137  QCheckBox *boxBarLines, *boxFilledBars, *boxScaleOnPrint, *boxPrintCropmarks;
138  TextFormatButtons *titleFormatButtons, *axisTitleFormatButtons;
139  double zoom, xScale, yScale, zScale;
141  DoubleSpinBox *boxMajorGridWidth, *boxMinorGridWidth;
142  QComboBox *boxMajorGridStyle, *boxMinorGridStyle, *boxTickLabelsFormat;
143  QCheckBox *boxMajorGrids, *boxMinorGrids;
144  DoubleSpinBox *boxXRotation, *boxYRotation, *boxZRotation;
145 };
146 
147 #endif
DoubleSpinBox * boxZRotation
Definition: Plot3DDialog.h:144
TextFormatButtons * titleFormatButtons
Definition: Plot3DDialog.h:138
Graph3D * d_plot
Definition: Plot3DDialog.h:108
QTextEdit * boxTitle
Definition: Plot3DDialog.h:124
QComboBox * boxType
Definition: Plot3DDialog.h:131
QPushButton * buttonCancel
Definition: Plot3DDialog.h:116
QSpinBox * boxZScale
Definition: Plot3DDialog.h:133
ColorButton * btnTitleColor
Definition: Plot3DDialog.h:119
A customized QtColorPicker used for color selection.
Definition: ColorButton.h:39
QDoubleSpinBox * boxMeshLineWidth
Definition: Plot3DDialog.h:113
QPushButton * buttonOk
Definition: Plot3DDialog.h:115
QCheckBox * boxSmooth
Definition: Plot3DDialog.h:129
QFont zAxisFont
Definition: Plot3DDialog.h:111
QPushButton * buttonApply
Definition: Plot3DDialog.h:114
QCheckBox * boxMinorGrids
Definition: Plot3DDialog.h:143
QWidget * dotsPage
Definition: Plot3DDialog.h:136
Surface plot options dialog.
Definition: Plot3DDialog.h:56
A QDoubleSpinBox allowing to customize numbers display with respect to locale settings.
Definition: DoubleSpinBox.h:39
DoubleSpinBox * boxTo
Definition: Plot3DDialog.h:123
QCheckBox * boxScaleOnPrint
Definition: Plot3DDialog.h:137
QLabel * colorMapPreviewLabel
Definition: Plot3DDialog.h:110
QStackedWidget * optionStack
Definition: Plot3DDialog.h:135
QSpinBox * boxMinors
Definition: Plot3DDialog.h:125
QGroupBox * linearColorMapGroupBox
Definition: Plot3DDialog.h:109
3D graph widget.
Definition: Graph3D.h:62
QSpinBox * boxTransparency
Definition: Plot3DDialog.h:127
QListWidget * axesList2
Definition: Plot3DDialog.h:130
QString d_color_map_file
Definition: Plot3DDialog.h:140
DoubleSpinBox * boxMinorLength
Definition: Plot3DDialog.h:132
QTabWidget * generalDialog
Definition: Plot3DDialog.h:121
Widget with text format buttons (connected to a QTextEdit)
Definition: TextFormatButtons.h:38
DoubleSpinBox * boxMinorGridWidth
Definition: Plot3DDialog.h:141
DoubleSpinBox * boxSize
Definition: Plot3DDialog.h:134
QGroupBox * TicksGroupBox
Definition: Plot3DDialog.h:126
QPushButton * btnTitleFont
Definition: Plot3DDialog.h:117
QSlider * transparencySlider
Definition: Plot3DDialog.h:128
A complex widget allowing to customize a QwtLinearColorMap.
Definition: ColorMapEditor.h:47
QPushButton * btnTable
Definition: Plot3DDialog.h:118
double zScale
Definition: Plot3DDialog.h:139
ColorMapEditor * d_color_map_editor
Definition: Plot3DDialog.h:120
QWidget * title
Definition: Plot3DDialog.h:122
QComboBox * boxTickLabelsFormat
Definition: Plot3DDialog.h:142
QStringList labels
Definition: Plot3DDialog.h:112