Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef VISUGUI_TABLE3D_H
00025 #define VISUGUI_TABLE3D_H
00026
00027 #include "VisuGUI_Prs3dDlg.h"
00028
00029 #include <QWidget>
00030 #include <string>
00031
00032 class QTabWidget;
00033 class QButtonGroup;
00034 class QGroupBox;
00035 class QComboBox;
00036 class QCheckBox;
00037 class QLineEdit;
00038 class QRadioButton;
00039 class QPushButton;
00040 class SalomeApp_IntSpinBox;
00041 class SalomeApp_DoubleSpinBox;
00042 class VisuGUI_TextPrefDlg;
00043 class VisuGUI_BarPrefDlg;
00044 class SVTK_ViewWindow;
00045 class SalomeApp_Module;
00046
00047 namespace VISU
00048 {
00049 class PointMap3d_i;
00050 };
00051
00052 class VisuGUI_Table3DPane : public QWidget
00053 {
00054 Q_OBJECT
00055
00056 public:
00057 VisuGUI_Table3DPane( QWidget* );
00058 ~VisuGUI_Table3DPane();
00059
00060 void initFromPrsObject( VISU::PointMap3d_i* );
00061 int storeToPrsObject( VISU::PointMap3d_i* );
00062
00063 VISU::PointMap3d_i* GetPrs();
00064
00065 private slots:
00066 void onPrsType( int );
00067
00068 private:
00069 bool myInitFromPrs;
00070
00071 SVTK_ViewWindow* myViewWindow;
00072 VISU::PointMap3d_i* myPrs;
00073
00074 SalomeApp_DoubleSpinBox* ScaleSpn;
00075 QGroupBox* GBPrsTypeBox;
00076 QButtonGroup* GBPrsType;
00077 SalomeApp_IntSpinBox* NbContoursSpn;
00078 };
00079
00080 class VisuGUI_TableScalarBarPane : public QWidget
00081 {
00082 Q_OBJECT
00083
00084 public:
00085 VisuGUI_TableScalarBarPane( QWidget* );
00086 ~VisuGUI_TableScalarBarPane();
00087
00088 void setRange( double, double, bool );
00089 void setDefaultRange( double, double );
00090 int getOrientation();
00091 void setPosAndSize( double, double, double, double, bool );
00092 void setScalarBarData( int, int );
00093 bool isIRange();
00094 double getMin();
00095 double getMax();
00096 double getX();
00097 double getY();
00098 double getWidth();
00099 double getHeight();
00100 int getNbColors();
00101 int getNbLabels();
00102 bool isLogarithmic();
00103 void setLogarithmic( bool on );
00104
00105
00106 void storeToResources();
00107
00108 void initFromPrsObject( VISU::PointMap3d_i* );
00109 int storeToPrsObject( VISU::PointMap3d_i* );
00110
00111 bool check();
00112
00113 private slots:
00114 void changeDefaults( int );
00115 void changeRange( int );
00116 void XYChanged( double );
00117 void changeScalarMode( int );
00118 void onTextPref();
00119 void onBarPref();
00120
00121 private:
00122 QGroupBox* RangeGroup;
00123 QRadioButton* RBFrange;
00124 QRadioButton* RBIrange;
00125 QLineEdit* MinEdit;
00126 QLineEdit* MaxEdit;
00127
00128 QRadioButton* RBhori;
00129 QRadioButton* RBvert;
00130
00131 SalomeApp_DoubleSpinBox* XSpin;
00132 SalomeApp_DoubleSpinBox* YSpin;
00133
00134 SalomeApp_DoubleSpinBox* WidthSpin;
00135 SalomeApp_DoubleSpinBox* HeightSpin;
00136
00137 SalomeApp_IntSpinBox* ColorSpin;
00138 SalomeApp_IntSpinBox* LabelSpin;
00139
00140 QCheckBox* CBSave;
00141 QCheckBox* CBLog;
00142 QComboBox* myModeCombo;
00143 QPushButton* myTextBtn;
00144 QPushButton* myBarBtn;
00145 VisuGUI_TextPrefDlg* myTextDlg;
00146 VisuGUI_BarPrefDlg* myBarDlg;
00147
00148 double myHorX, myHorY, myHorW, myHorH;
00149 double myVerX, myVerY, myVerW, myVerH;
00150 int myHorTS, myHorLS, myHorBW, myHorBH;
00151 int myVerTS, myVerLS, myVerBW, myVerBH;
00152 bool myIsStoreTextProp;
00153
00154 std::string myTitle;
00155 VISU::PointMap3d_i* myBarPrs;
00156
00157 bool myBusy;
00158 };
00159
00161
00162 class VisuGUI_Table3DDlg : public QDialog
00163 {
00164 Q_OBJECT
00165
00166 public:
00167 VisuGUI_Table3DDlg( SalomeApp_Module* );
00168 ~VisuGUI_Table3DDlg();
00169
00170 virtual void initFromPrsObject( VISU::PointMap3d_i* );
00171 virtual int storeToPrsObject( VISU::PointMap3d_i* );
00172
00173 protected slots:
00174 void accept();
00175 void onHelp();
00176 void onApply();
00177
00178 private:
00179 QTabWidget* myTabBox;
00180 VisuGUI_Table3DPane* myIsoPane;
00181 VisuGUI_TableScalarBarPane* myScalarBarPane;
00182
00183 SALOME::GenericObjPtr<VISU::PointMap3d_i> myPrsCopy;
00184 };
00185
00186 #endif // VISUGUI_TABLE3D_H