Salome HOME
NRI : Rename resources and library.
[modules/geom.git] / src / GEOMGUI / GeometryGUI_SewingDlg.h
1 //  File      : GeometryGUI_SewingDlg.h
2 //  Created   :
3 //  Author    : Lucien PIGNOLONI
4 //  Project   : SALOME
5 //  Module    : GeometryGUI
6 //  Copyright : OPEN CASCADE
7 //  $Header$
8
9 #ifndef DIALOGBOX_SEWING_H
10 #define DIALOGBOX_SEWING_H
11
12 #include "SALOME_Selection.h"
13 #include "GEOM_ShapeTypeFilter.hxx"
14
15 #include <Precision.hxx>
16
17 #include <qvariant.h>
18 #include <qdialog.h>
19
20 class QVBoxLayout; 
21 class QHBoxLayout; 
22 class QGridLayout; 
23 class QButtonGroup;
24 class QGroupBox;
25 class QLabel;
26 class QLineEdit;
27 class QPushButton;
28 class QRadioButton;
29 class GeometryGUI;
30
31
32 //=================================================================================
33 // class    : GeometryGUI_SewingDlg
34 // purpose  :
35 //=================================================================================
36 class GeometryGUI_SewingDlg : public QDialog
37
38     Q_OBJECT
39
40 public:
41     GeometryGUI_SewingDlg( QWidget* parent = 0, const char* name = 0, SALOME_Selection* Sel = 0, bool modal = FALSE, WFlags fl = 0 );
42     ~GeometryGUI_SewingDlg();
43
44 private:
45
46     void Init( SALOME_Selection* Sel ) ;
47     void closeEvent( QCloseEvent* e ) ;
48     void enterEvent ( QEvent * ) ;                          /* mouse enter the QWidget */
49
50     GEOM::GEOM_Gen_var         myGeom ;                  /* Current GeomI object */
51     GeometryGUI*                  myGeomGUI ;               /* Current GeomGUI object */
52     SALOME_Selection*             mySelection ;             /* User shape selection */
53     GEOM::GEOM_Gen::ListOfIOR  myListShapes ;
54     Standard_Real                 myPrecision ;
55     bool                          myOkListShapes ;          /* to check when arguments is defined */
56     int                           myConstructorId ;         /* Current constructor id = radio button id */
57     QLineEdit*                    myEditCurrentArgument;    /* Current LineEdit */
58
59     QButtonGroup* GroupConstructors;
60     QRadioButton* Constructor1;
61     QGroupBox* GroupButtons;
62     QPushButton* buttonApply;
63     QPushButton* buttonOk;
64     QPushButton* buttonCancel;
65     QGroupBox* GroupC1;
66     QLineEdit* LineEditC1A1;
67     QLineEdit* LineEditC1A2;
68     QPushButton* SelectButtonC1A1;
69     QLabel* TextLabelC1A1;
70     QLabel* TextLabelC1A2;
71
72 private slots:
73
74     void ConstructorsClicked(int constructorId);
75     void ClickOnOk();
76     void ClickOnCancel();
77     void ClickOnApply();
78     void SetEditCurrentArgument() ;
79     void LineEditReturnPressed() ;
80     void SelectionIntoArgument() ;
81     void DeactivateActiveDialog() ;
82     void ActivateThisDialog() ;
83
84 protected:
85     QGridLayout* GeometryGUI_SewingDlgLayout;
86     QGridLayout* GroupConstructorsLayout;
87     QGridLayout* GroupButtonsLayout;
88     QGridLayout* GroupC1Layout;
89 };
90
91 #endif // DIALOGBOX_SEWING_H