X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FVISUGUI%2FVisuGUI_IsoSurfacesDlg.h;h=5178611ead7a0d24caf7088420cdbef6d07a0f01;hb=a7edb65d31987757e10356fb9c06ef67d1c56957;hp=5e3b1c51ad91e6d1a436282cada39f30ea06a6e1;hpb=e967b0415406f4f86ca2c9489abc8554b4c15dae;p=modules%2Fvisu.git diff --git a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h index 5e3b1c51..5178611e 100644 --- a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h +++ b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h @@ -1,96 +1,113 @@ -// VISU VISUGUI : GUI of VISU component +// Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS // -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. // -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. // -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // -// -// + +// VISU VISUGUI : GUI of VISU component // File : VisuGUI_IsoSurfacesDlg.h // Author : Laurent CORNABE & Hubert ROLLAND // Module : VISU // $Header$ - +// #ifndef VISUGUI_ISOSURFACESDLG_H #define VISUGUI_ISOSURFACESDLG_H -#include "VisuGUI_ScalarBarDlg.h" -#include "VISU_IsoSurfaces_i.hh" +#include "VisuGUI_Prs3dDlg.h" -#include -#include -#include -#include -#include -#include -#include +class QTabWidget; +class QLineEdit; +class SalomeApp_IntSpinBox; +class QButtonGroup; +class QtxColorButton; + +namespace VISU +{ + class IsoSurfaces_i; +}; class SalomeApp_Module; +class VisuGUI_InputPane; -class VisuGUI_IsoSurfPane : public QVBox +class VisuGUI_IsoSurfPane : public QWidget { Q_OBJECT; - public: - VisuGUI_IsoSurfPane (QWidget* parent); +public: + enum { ScalarBarRange = 0, CustomRange }; + +public: + VisuGUI_IsoSurfPane (QWidget* parent, + VisuGUI_ScalarBarPane* theScalarPane); ~VisuGUI_IsoSurfPane() {}; void initFromPrsObject(VISU::IsoSurfaces_i* thePrs); int storeToPrsObject(VISU::IsoSurfaces_i* thePrs); - void setScalarBarPane(VisuGUI_ScalarBarPane* theScalarPane) {myScalarPane = theScalarPane;} - VisuGUI_ScalarBarPane* getScalarBarPane() {return myScalarPane;} - bool check(); - protected slots: - void onCBUpdate(); + void setColor(const QColor& theColor); + QColor color() const; - private: - QLineEdit* MinIso; - QLineEdit* MaxIso; - QSpinBox* NbrIso; +protected slots: + void onRangeButtonClicked( int ); + void onCBUpdate(); + void setColor(); + +private: + QButtonGroup* myRangeGrp; + QLineEdit* MinIso; + QLineEdit* MaxIso; + SalomeApp_IntSpinBox* NbrIso; + QCheckBox* myUseMagnitude; + QtxColorButton* mySelColor; + QCheckBox* myUseLabels; + SalomeApp_IntSpinBox* myNbLabels; VisuGUI_ScalarBarPane* myScalarPane; }; -class VisuGUI_IsoSurfacesDlg : public QDialog +class VisuGUI_IsoSurfacesDlg : public VisuGUI_ScalarBarBaseDlg { Q_OBJECT; - public: +public: VisuGUI_IsoSurfacesDlg (SalomeApp_Module* theModule); - ~VisuGUI_IsoSurfacesDlg() {}; + ~VisuGUI_IsoSurfacesDlg(); + + virtual void initFromPrsObject( VISU::ColoredPrs3d_i* thePrs, + bool theInit ); - void initFromPrsObject(VISU::IsoSurfaces_i* thePrs) - {myScalarPane->initFromPrsObject(thePrs); myIsoPane->initFromPrsObject(thePrs);} + virtual int storeToPrsObject(VISU::ColoredPrs3d_i* thePrs); - int storeToPrsObject(VISU::IsoSurfaces_i* thePrs) - {return myScalarPane->storeToPrsObject(thePrs) && myIsoPane->storeToPrsObject(thePrs);} +protected: + virtual QString GetContextHelpFilePath(); protected slots: void accept(); - void reject(); - void onHelp(); - private: +private: + QTabWidget* myTabBox; VisuGUI_IsoSurfPane* myIsoPane; - VisuGUI_ScalarBarPane* myScalarPane; + VisuGUI_InputPane* myInputPane; + + SALOME::GenericObjPtr myPrsCopy; }; #endif // VISUGUI_ISOSURFACESDLG_H