1 // Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License.
9 // This library is distributed in the hope that it will be useful
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 #ifndef DIALOGBOX_OFFSET_H
22 #define DIALOGBOX_OFFSET_H
24 #include "VTKViewer.h"
25 #include "VISU_Prs3d_i.hh"
37 vtkFloatingPointType myOffset[3];
41 myOffset[0] = myOffset[1] = myOffset[2] = 0;
44 OffsetStruct(vtkFloatingPointType theX,
45 vtkFloatingPointType theY,
46 vtkFloatingPointType theZ)
54 class VisuGUI_OffsetDlg: public QDialog
58 VisuGUI_OffsetDlg (VisuGUI* theModule);
59 ~VisuGUI_OffsetDlg() {};
61 void addPresentation (VISU::Prs3d_i* thePrs);
62 int getPrsCount() const { return myPrsList.count(); }
64 void setOffset (const vtkFloatingPointType* theOffset);
65 void getOffset (vtkFloatingPointType* theOffset) const;
66 bool isToSave() const;
72 virtual void accept();
73 virtual void reject();
78 void updateOffset (VISU::Prs3d_i* thePrs, vtkFloatingPointType* theOffset);
82 QtxDblSpinBox * myDxEdt;
83 QtxDblSpinBox * myDyEdt;
84 QtxDblSpinBox * myDzEdt;
85 QCheckBox * mySaveChk;
87 QPtrList<VISU::Prs3d_i> myPrsList;
88 QValueList<OffsetStruct> myOldOffsets;
91 #endif // DIALOGBOX_OFFSET_H