Salome HOME
This commit was generated by cvs2git to track changes on a CVS vendor
[modules/geom.git] / src / GEOMGUI / GeometryGUI_CheckShape.h
1 //  File      : GeometryGUI_CheckShape.h
2 //  Created   : Tue Mar 12 17:25:52 2002
3 //  Author    : Nicolas REJNERI
4 //  Project   : SALOME
5 //  Module    : GEOM
6 //  Copyright : Open CASCADE 2002
7 //  $Header$
8
9
10 #ifndef DIALOGBOX_CHECKSHAPE_H
11 #define DIALOGBOX_CHECKSHAPE_H
12
13 #include "SALOME_Selection.h"
14 #include "GEOM_ShapeTypeFilter.hxx"
15
16 #include <Precision.hxx>
17
18 #include <qvariant.h>
19 #include <qdialog.h>
20
21 class QVBoxLayout; 
22 class QHBoxLayout; 
23 class QGridLayout; 
24 class QButtonGroup;
25 class QGroupBox;
26 class QLabel;
27 class QLineEdit;
28 class QPushButton;
29 class QRadioButton;
30 class QTextView;
31 class GeometryGUI;
32
33 //=================================================================================
34 // class    : GeometryGUI_CheckShape
35 // purpose  :
36 //=================================================================================
37 class GeometryGUI_CheckShape : public QDialog
38
39     Q_OBJECT
40
41 public:
42     GeometryGUI_CheckShape( QWidget* parent = 0, const char* name = 0, SALOME_Selection* Sel = 0, bool modal = FALSE, WFlags fl = 0 );
43     ~GeometryGUI_CheckShape();
44
45 private:
46
47     void Init( SALOME_Selection* Sel ) ;
48     void closeEvent( QCloseEvent* e ) ;
49     void enterEvent ( QEvent * ) ;                         /* mouse enter the QWidget */
50     void Check(const TopoDS_Shape S) ;
51
52     GEOM::GEOM_Gen_var         myGeom ;                 /* Current GeomI object */
53     GeometryGUI*                  myGeomGUI ;              /* Current GeomGUI object */
54     SALOME_Selection*             mySelection ;            /* User shape selection */
55
56     int                           myConstructorId ;        /* Current constructor id = radio button id */
57     QLineEdit*                    myEditCurrentArgument;   /* Current LineEdit */
58
59     QButtonGroup* GroupConstructors;
60     QRadioButton* Constructor1;
61     QGroupBox* GroupConstructor1;
62     QLineEdit* LineEditC1A1;
63     QPushButton* SelectButtonC1A1;
64     QLabel* TextLabelC1A1;
65
66     QTextView* Text;
67     QString    SelectedName;
68
69     QGroupBox* GroupButtons;
70     QPushButton* buttonApply;
71     QPushButton* buttonOk;
72     QPushButton* buttonCancel;
73
74 private slots:
75
76     void ConstructorsClicked(int constructorId);
77     void ClickOnCancel();
78     void SetEditCurrentArgument() ;
79     void LineEditReturnPressed() ;
80     void SelectionIntoArgument() ;
81     void DeactivateActiveDialog() ;
82     void ActivateThisDialog() ;
83
84 protected:
85     QGridLayout* GeometryGUI_CheckShapeLayout;
86     QGridLayout* GroupConstructorsLayout;
87     QGridLayout* GroupConstructor1Layout;
88     QGridLayout* GroupButtonsLayout;
89 };
90
91 #endif // DIALOGBOX_CHECKSHAPE_H