X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGUI%2FNETGENPluginGUI_HypothesisCreator.h;h=cb7bd634768195657ca3c5ef72f3aff2605b3623;hb=043ee5d5fe3fb7063382138bf61ffeed0b8490c9;hp=3cbd96aa7f99d0f8210aa5c626f5c3db5a8b2376;hpb=40bc6ed7626de9ad8b941dc0b844ef9829c81842;p=plugins%2Fnetgenplugin.git diff --git a/src/GUI/NETGENPluginGUI_HypothesisCreator.h b/src/GUI/NETGENPluginGUI_HypothesisCreator.h index 3cbd96a..cb7bd63 100644 --- a/src/GUI/NETGENPluginGUI_HypothesisCreator.h +++ b/src/GUI/NETGENPluginGUI_HypothesisCreator.h @@ -1,56 +1,54 @@ -// NETGENPlugin GUI: GUI for plugged-in mesher NETGENPlugin +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // -// Copyright (C) 2003 CEA -// -// 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. -// -// 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 +// 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, or (at your option) any later version. // +// 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 // +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + +// NETGENPlugin GUI: GUI for plugged-in mesher NETGENPlugin // File : NETGENPluginGUI_HypothesisCreator.h // Author : Michael Zorin // Module : NETGENPlugin // $Header: - +// #ifndef NETGENPLUGINGUI_HypothesisCreator_HeaderFile #define NETGENPLUGINGUI_HypothesisCreator_HeaderFile -#ifdef WIN32 - #ifdef NETGENPLUGIN_GUI_EXPORTS - #define NETGENPLUGIN_GUI_EXPORT __declspec( dllexport ) - #else - #define NETGENPLUGIN_GUI_EXPORT __declspec( dllimport ) - #endif -#else - #define NETGENPLUGIN_GUI_EXPORT -#endif +#include "NETGENPluginGUI.h" #include -class QtxDblSpinBox; -class QtxComboBox; +#include + +class SMESHGUI_SpinBox; +class GeomSelectionTools; +class QComboBox; class QCheckBox; class QLineEdit; +class QTableWidget; typedef struct { - double myMaxSize, myGrowthRate, myNbSegPerEdge, myNbSegPerRadius; + double myMaxSize, myMinSize, myGrowthRate, myNbSegPerEdge, myNbSegPerRadius; int myFineness; - bool mySecondOrder, myAllowQuadrangles, myOptimize; + bool mySecondOrder, myAllowQuadrangles, myOptimize, mySurfaceCurvature, myFuseEdges; QString myName; + QString myMaxSizeVar, myMinSizeVar, myGrowthRateVar, myNbSegPerEdgeVar, myNbSegPerRadiusVar; } NetgenHypothesisData; /*! @@ -64,7 +62,8 @@ public: NETGENPluginGUI_HypothesisCreator( const QString& ); virtual ~NETGENPluginGUI_HypothesisCreator(); - virtual bool checkParams() const; + virtual bool checkParams(QString& msg) const; + virtual QString helpPage() const; protected: virtual QFrame* buildFrame (); @@ -77,24 +76,40 @@ protected: protected slots: virtual void onFinenessChanged(); + virtual void onSurfaceCurvatureChanged(); + virtual void onAddLocalSizeOnVertex(); + virtual void onAddLocalSizeOnEdge(); + virtual void onAddLocalSizeOnFace(); + virtual void onRemoveLocalSizeOnShape(); + virtual void onSetLocalSize(int,int); private: bool readParamsFromHypo( NetgenHypothesisData& ) const; bool readParamsFromWidgets( NetgenHypothesisData& ) const; bool storeParamsToHypo( const NetgenHypothesisData& ) const; + GeomSelectionTools* getGeomSelectionTools(); + void addLocalSizeOnShape(TopAbs_ShapeEnum); private: - QLineEdit* myName; - QtxDblSpinBox* myMaxSize; - QCheckBox* mySecondOrder; - QCheckBox* myOptimize; - QtxComboBox* myFineness; - QtxDblSpinBox* myGrowthRate; - QtxDblSpinBox* myNbSegPerEdge; - QtxDblSpinBox* myNbSegPerRadius; - QCheckBox* myAllowQuadrangles; + QLineEdit* myName; + SMESHGUI_SpinBox* myMaxSize; + SMESHGUI_SpinBox* myMinSize; + QCheckBox* mySecondOrder; + QCheckBox* myOptimize; + QComboBox* myFineness; + SMESHGUI_SpinBox* myGrowthRate; + SMESHGUI_SpinBox* myNbSegPerEdge; + SMESHGUI_SpinBox* myNbSegPerRadius; + QCheckBox* myAllowQuadrangles; + QCheckBox* mySurfaceCurvature; + QCheckBox* myFuseEdges; bool myIs2D; + bool myIsONLY; + + QTableWidget* myLocalSizeTable; + GeomSelectionTools* myGeomSelectionTools; + QMap myLocalSizeMap; }; #endif