1 // Copyright (C) 2007-2023 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 // SMESH SMESHGUI : GUI for SMESH component
24 // File : SMESHGUI_Preferences_ScalarBarDlg.h
25 // Author : Nicolas REJNERI, Open CASCADE S.A.S.
27 #ifndef SMESHGUI_PREFERENCES_SCALARBARDLG_H
28 #define SMESHGUI_PREFERENCES_SCALARBARDLG_H
31 #include "SMESH_SMESHGUI.hxx"
48 class SMESHGUI_SpinBox;
49 class SalomeApp_IntSpinBox;
51 class LightApp_SelectionMgr;
55 class SMESHGUI_EXPORT SMESHGUI_Preferences_ScalarBarDlg : public QDialog
60 SMESHGUI_Preferences_ScalarBarDlg( SMESHGUI* );
62 static SMESHGUI_Preferences_ScalarBarDlg* myDlg;
65 ~SMESHGUI_Preferences_ScalarBarDlg();
67 static void ScalarBarProperties( SMESHGUI* );
69 void setOriginAndSize( const double,
73 void initScalarBarFromResources();
76 void applyThreshold(double min, double max);
77 void applyWireframeOff();
80 virtual void reject();
86 void onSelectionChanged();
88 void onMinMaxChanged();
89 void onOrientationChanged();
90 void onDistributionChanged( int );
91 void onDistributionActivated( bool );
95 LightApp_SelectionMgr* mySelectionMgr;
97 double myIniX, myIniY, myIniW, myIniH;
99 double DEF_VER_X, DEF_VER_Y, DEF_VER_H, DEF_VER_W;
100 double DEF_HOR_X, DEF_HOR_Y, DEF_HOR_H, DEF_HOR_W;
102 QGroupBox* myRangeGrp;
103 QLineEdit* myMinEdit;
104 QLineEdit* myMaxEdit;
105 QCheckBox* myLogarithmicCheck;
106 QCheckBox* myThresholdCheck;
107 QCheckBox* myWireframeOffCheck;
109 QGroupBox* myFontGrp;
110 QtxColorButton* myTitleColorBtn;
111 QComboBox* myTitleFontCombo;
112 QCheckBox* myTitleBoldCheck;
113 QCheckBox* myTitleItalicCheck;
114 QCheckBox* myTitleShadowCheck;
115 QtxColorButton* myLabelsColorBtn;
116 QComboBox* myLabelsFontCombo;
117 QCheckBox* myLabelsBoldCheck;
118 QCheckBox* myLabelsItalicCheck;
119 QCheckBox* myLabelsShadowCheck;
121 QGroupBox* myLabColorGrp;
122 SalomeApp_IntSpinBox* myColorsSpin;
123 SalomeApp_IntSpinBox* myLabelsSpin;
125 QGroupBox* myOrientationGrp;
126 QRadioButton* myVertRadioBtn;
127 QRadioButton* myHorizRadioBtn;
129 QGroupBox* myOriginDimGrp;
130 SMESHGUI_SpinBox* myXSpin;
131 SMESHGUI_SpinBox* myYSpin;
132 SMESHGUI_SpinBox* myWidthSpin;
133 SMESHGUI_SpinBox* myHeightSpin;
135 QGroupBox* myDistributionGrp;
136 QRadioButton* myDMonoColor;
137 QRadioButton* myDMultiColor;
138 QtxColorButton* myMonoColorBtn;
139 QLabel* myDistributionColorLbl;
141 QGroupBox* myButtonGrp;
142 QButtonGroup* myDistribColorGrp;
143 QPushButton* myOkBtn;
144 QPushButton* myApplyBtn;
145 QPushButton* myCancelBtn;
146 QPushButton* myHelpBtn;
148 QString myHelpFileName;
151 #endif // SMESHGUI_PREFERENCES_SCALARBARDLG_H