1 // Copyright (C) 2007-2010 CEA/DEN, EDF R&D, OPEN CASCADE
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 // VISU VISUGUI : GUI of VISU component
21 // File : VisuGUI_Table3dDlg.h
22 // Author : Laurent CORNABE & Hubert ROLLAND
24 #ifndef VISUGUI_TABLE3D_H
25 #define VISUGUI_TABLE3D_H
27 #include "VisuGUI_Prs3dDlg.h"
40 class SalomeApp_IntSpinBox;
41 class SalomeApp_DoubleSpinBox;
42 class VisuGUI_TextPrefDlg;
43 class VisuGUI_BarPrefDlg;
44 class SVTK_ViewWindow;
45 class SalomeApp_Module;
52 class VisuGUI_Table3DPane : public QWidget
57 VisuGUI_Table3DPane( QWidget* );
58 ~VisuGUI_Table3DPane();
60 void initFromPrsObject( VISU::PointMap3d_i* );
61 int storeToPrsObject( VISU::PointMap3d_i* );
63 VISU::PointMap3d_i* GetPrs();
66 void onPrsType( int );
71 SVTK_ViewWindow* myViewWindow;
72 VISU::PointMap3d_i* myPrs;
74 SalomeApp_DoubleSpinBox* ScaleSpn;
75 QGroupBox* GBPrsTypeBox;
76 QButtonGroup* GBPrsType;
77 SalomeApp_IntSpinBox* NbContoursSpn;
80 class VisuGUI_TableScalarBarPane : public QWidget
85 VisuGUI_TableScalarBarPane( QWidget* );
86 ~VisuGUI_TableScalarBarPane();
88 void setRange( double, double, bool );
89 void setDefaultRange( double, double );
91 void setPosAndSize( double, double, double, double, bool );
92 void setScalarBarData( int, int );
102 bool isLogarithmic();
103 void setLogarithmic( bool on );
104 // bool isToSave() {return CBSave ? CBSave->isChecked() : false;}
106 void storeToResources();
108 void initFromPrsObject( VISU::PointMap3d_i* );
109 int storeToPrsObject( VISU::PointMap3d_i* );
114 void changeDefaults( int );
115 void changeRange( int );
116 void XYChanged( double );
117 void changeScalarMode( int );
122 QGroupBox* RangeGroup;
123 QRadioButton* RBFrange;
124 QRadioButton* RBIrange;
128 QRadioButton* RBhori;
129 QRadioButton* RBvert;
131 SalomeApp_DoubleSpinBox* XSpin;
132 SalomeApp_DoubleSpinBox* YSpin;
134 SalomeApp_DoubleSpinBox* WidthSpin;
135 SalomeApp_DoubleSpinBox* HeightSpin;
137 SalomeApp_IntSpinBox* ColorSpin;
138 SalomeApp_IntSpinBox* LabelSpin;
142 QComboBox* myModeCombo;
143 QPushButton* myTextBtn;
144 QPushButton* myBarBtn;
145 VisuGUI_TextPrefDlg* myTextDlg;
146 VisuGUI_BarPrefDlg* myBarDlg;
148 double myHorX, myHorY, myHorW, myHorH;
149 double myVerX, myVerY, myVerW, myVerH;
150 int myHorTS, myHorLS, myHorBW, myHorBH;
151 int myVerTS, myVerLS, myVerBW, myVerBH;
152 bool myIsStoreTextProp;
155 VISU::PointMap3d_i* myBarPrs;
160 ///////////////////////////////////////////////////////
162 class VisuGUI_Table3DDlg : public QDialog
167 VisuGUI_Table3DDlg( SalomeApp_Module* );
168 ~VisuGUI_Table3DDlg();
170 virtual void initFromPrsObject( VISU::PointMap3d_i* );
171 virtual int storeToPrsObject( VISU::PointMap3d_i* );
179 QTabWidget* myTabBox;
180 VisuGUI_Table3DPane* myIsoPane;
181 VisuGUI_TableScalarBarPane* myScalarBarPane;
183 SALOME::GenericObjPtr<VISU::PointMap3d_i> myPrsCopy;
186 #endif // VISUGUI_TABLE3D_H