Version: 6.3.1

src/SMESHGUI/SMESHGUI_FindElemByPointDlg.h

Go to the documentation of this file.
00001 // Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // This library is free software; you can redistribute it and/or
00004 // modify it under the terms of the GNU Lesser General Public
00005 // License as published by the Free Software Foundation; either
00006 // version 2.1 of the License.
00007 //
00008 // This library is distributed in the hope that it will be useful,
00009 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00010 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011 // Lesser General Public License for more details.
00012 //
00013 // You should have received a copy of the GNU Lesser General Public
00014 // License along with this library; if not, write to the Free Software
00015 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00016 //
00017 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00018 //
00019 
00020 #ifndef SMESHGUI_FindElemByPointDLG_H
00021 #define SMESHGUI_FindElemByPointDLG_H
00022 
00023 // SMESH includes
00024 #include "SMESH_SMESHGUI.hxx"
00025 
00026 #include "SMESHGUI_Dialog.h"
00027 #include "SMESHGUI_SelectionOp.h"
00028 
00029 #include CORBA_SERVER_HEADER(SMESH_Mesh)
00030 
00031 class QLineEdit;
00032 class QPushButton;
00033 class QListWidget;
00034 class QtxComboBox;
00035 class SMESHGUI_SpinBox;
00036 class SMESHGUI_MeshEditPreview;
00037 class SMESHGUI_FindElemByPointDlg;
00038 
00042 class SMESHGUI_EXPORT SMESHGUI_FindElemByPointOp: public SMESHGUI_SelectionOp
00043 {
00044   Q_OBJECT
00045 
00046 public:
00047   SMESHGUI_FindElemByPointOp();
00048   virtual ~SMESHGUI_FindElemByPointOp();
00049 
00050   virtual LightApp_Dialog*       dlg() const;  
00051 
00052 protected:
00053 
00054   virtual void                   startOperation();
00055   virtual void                   stopOperation();
00056 
00057   virtual void                   activateSelection();
00058 
00059 protected slots:
00060 
00061   virtual void                   onFind();
00062   virtual bool                   onApply();
00063 
00064 private slots:
00065 
00066   void                           onRejectedDlg();
00067   void                           onSelectionDone();
00068   void                           onElemSelected();
00069   void                           onElemTypeChange(int);
00070   void                           redisplayPreview();
00071 
00072 private:
00073   SMESHGUI_FindElemByPointDlg*     myDlg;
00074 
00075   SUIT_SelectionFilter*            myFilter;
00076   SMESHGUI_MeshEditPreview*        mySimulation; // to show point coordinates
00077   //SMESH_Actor*                   myMeshActor;  // to show found elements
00078   SMESH::SMESH_Mesh_var            myMesh;
00079   SMESH::MeshPreviewStruct_var     myPreview;
00080   Handle(SALOME_InteractiveObject) myMeshIO;
00081 };
00082 
00087 class SMESHGUI_EXPORT SMESHGUI_FindElemByPointDlg : public SMESHGUI_Dialog
00088 {
00089   Q_OBJECT
00090 
00091 public:
00092   SMESHGUI_FindElemByPointDlg();
00093 
00094 private:
00095   QWidget*                      createMainFrame( QWidget* );
00096 
00097   QLineEdit*                    myMeshName;
00098   SMESHGUI_SpinBox*             myX;
00099   SMESHGUI_SpinBox*             myY;
00100   SMESHGUI_SpinBox*             myZ;
00101   QtxComboBox*                  myElemTypeCombo;
00102   QPushButton*                  myFindBtn;
00103   QListWidget*                  myFoundList;
00104 
00105   QString                       myHelpFileName;
00106 
00107   friend class SMESHGUI_FindElemByPointOp;
00108 
00109 signals:
00110   void                           rejectedDlg();
00111 
00112 protected slots:
00113   virtual void                   reject();
00114 
00115 private slots:
00116 //void                          ButtonToggled( bool );
00117 };
00118 
00119 #endif // SMESHGUI_FindElemByPointDLG_H
Copyright © 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS