Version: 6.3.1

src/VISUGUI/VisuGUI_IsoSurfacesDlg.h

Go to the documentation of this file.
00001 // Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 //  VISU VISUGUI : GUI of VISU component
00024 //  File   : VisuGUI_IsoSurfacesDlg.h
00025 //  Author : Laurent CORNABE & Hubert ROLLAND
00026 //  Module : VISU
00027 //  $Header: /home/server/cvs/VISU/VISU_SRC/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h,v 1.12.2.2.6.1.8.1 2011-06-02 06:00:21 vsr Exp $
00028 //
00029 #ifndef VISUGUI_ISOSURFACESDLG_H
00030 #define VISUGUI_ISOSURFACESDLG_H
00031 
00032 #include "VisuGUI_Prs3dDlg.h"
00033 
00034 class QTabWidget;
00035 class QLineEdit;
00036 class SalomeApp_IntSpinBox;
00037 class QButtonGroup;
00038 class QtxColorButton;
00039 
00040 namespace VISU 
00041 {
00042   class IsoSurfaces_i;
00043 };
00044 
00045 class SalomeApp_Module;
00046 class VisuGUI_InputPane;
00047 
00048 class VisuGUI_IsoSurfPane : public QWidget
00049 {
00050   Q_OBJECT;
00051 
00052 public:
00053   enum { ScalarBarRange = 0, CustomRange };
00054 
00055 public:
00056   VisuGUI_IsoSurfPane (QWidget* parent,
00057                        VisuGUI_ScalarBarPane* theScalarPane);
00058   ~VisuGUI_IsoSurfPane() {};
00059 
00060   void initFromPrsObject(VISU::IsoSurfaces_i* thePrs);
00061   int storeToPrsObject(VISU::IsoSurfaces_i* thePrs);
00062 
00063   bool check();
00064 
00065   void setColor(const QColor& theColor);
00066   QColor color() const;
00067 
00068 protected slots:
00069   void onRangeButtonClicked( int );
00070   void onCBUpdate();
00071   void setColor();
00072 
00073 private:
00074   QButtonGroup*          myRangeGrp;
00075   QLineEdit*             MinIso;
00076   QLineEdit*             MaxIso;
00077   SalomeApp_IntSpinBox*  NbrIso;
00078   QCheckBox*             myUseMagnitude;
00079   QtxColorButton*        mySelColor;
00080   QCheckBox*             myUseLabels;
00081   SalomeApp_IntSpinBox*  myNbLabels;
00082   VisuGUI_ScalarBarPane* myScalarPane;
00083 };
00084 
00085 
00086 class VisuGUI_IsoSurfacesDlg : public VisuGUI_ScalarBarBaseDlg
00087 {
00088   Q_OBJECT;
00089 
00090 public:
00091   VisuGUI_IsoSurfacesDlg (SalomeApp_Module* theModule);
00092   ~VisuGUI_IsoSurfacesDlg();
00093 
00094   virtual void initFromPrsObject( VISU::ColoredPrs3d_i* thePrs,
00095                                   bool theInit );
00096 
00097   virtual int storeToPrsObject(VISU::ColoredPrs3d_i* thePrs);
00098 
00099 protected:
00100   virtual QString  GetContextHelpFilePath();
00101 
00102  protected slots:
00103   void accept();
00104 
00105 private:
00106   QTabWidget*            myTabBox;
00107   VisuGUI_IsoSurfPane*   myIsoPane;
00108   VisuGUI_InputPane*     myInputPane;
00109 
00110   SALOME::GenericObjPtr<VISU::IsoSurfaces_i> myPrsCopy;
00111 };
00112 
00113 #endif // VISUGUI_ISOSURFACESDLG_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