X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_MeshInfo.h;h=2edf2e58a42033271e1121d5b1fe1fe792cafd75;hb=7ea81bbe6e068500dbaf7ff693dd05f33b974c53;hp=54c1013244e38aa91b8250558b79eb28d0c5c461;hpb=7567e381c89598fdd72033cb6aff8c863434f6b8;p=modules%2Fsmesh.git diff --git a/src/SMESHGUI/SMESHGUI_MeshInfo.h b/src/SMESHGUI/SMESHGUI_MeshInfo.h index 54c101324..2edf2e58a 100644 --- a/src/SMESHGUI/SMESHGUI_MeshInfo.h +++ b/src/SMESHGUI/SMESHGUI_MeshInfo.h @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -6,7 +6,7 @@ // 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. +// 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 @@ -28,7 +28,11 @@ #include "SMESH_SMESHGUI.hxx" #include "SMESH_ControlsDef.hxx" -#include +#ifndef DISABLE_PLOT2DVIEWER + #include +#else + #include +#endif #include #include @@ -108,7 +112,8 @@ class SMESHGUI_EXPORT SMESHGUI_MeshInfo : public QFrame iSingle = 1, iTotal = iSingle, iLinear, - iQuadratic + iQuadratic, + iBiQuadratic }; typedef QList wlist; @@ -157,6 +162,7 @@ protected: { double myX, myY, myZ; XYZ() { myX = myY = myZ = 0.0; } + XYZ(double x, double y, double z) { myX = x; myY = y; myZ = z; } void add( double x, double y, double z ) { myX += x; myY += y; myZ += z; } void divide( double a ) { if ( a != 0.) { myX /= a; myY /= a; myZ /= a; } } double x() const { return myX; } @@ -175,6 +181,7 @@ protected: Connectivity nodeConnectivity( const SMDS_MeshNode* ); QString formatConnectivity( Connectivity, int ); XYZ gravityCenter( const SMDS_MeshElement* ); + XYZ normal( const SMDS_MeshElement* ); signals: void itemInfo( int ); @@ -225,6 +232,7 @@ public: protected: void contextMenuEvent( QContextMenuEvent* e ); void information( const QList& ); + void nodeInfo( const SMDS_MeshNode*, int, int, QTreeWidgetItem* ); void clearInternal(); private slots: @@ -242,7 +250,7 @@ class GrpComputor: public QObject Q_OBJECT; public: - GrpComputor( SMESH::SMESH_GroupBase_ptr, QTreeWidgetItem*, QObject* ); + GrpComputor( SMESH::SMESH_GroupBase_ptr, QTreeWidgetItem*, QObject*, bool = false); QTreeWidgetItem* getItem() { return myItem; } public slots: @@ -251,6 +259,7 @@ public slots: private: SMESH::SMESH_GroupBase_var myGroup; QTreeWidgetItem* myItem; + bool myToComputeSize; }; class SMESHGUI_EXPORT SMESHGUI_AddInfo : public QTreeWidget @@ -306,13 +315,16 @@ private: QwtPlot* createPlot( QWidget* ); void setFontAttributes( QWidget* ); void clearInternal(); +#ifndef DISABLE_PLOT2DVIEWER Plot2d_Histogram* getHistogram( SMESH::NumericalFunctor_ptr functor ); +#endif void computeNb( int ft, int iBut, int iWdg ); private slots: void computeAspectRatio(); void computeAspectRatio3D(); void computeFreeNodesInfo(); + void computeNodesNbConnInfo(); void computeDoubleNodesInfo(); void computeDoubleEdgesInfo(); void computeDoubleFacesInfo(); @@ -334,7 +346,7 @@ private: QwtPlot* myPlot3D; QList myButtons; QList myPredicates; - TNumFunctor myAspectRatio, myAspectRatio3D; + TNumFunctor myAspectRatio, myAspectRatio3D, myNodeConnFunctor; }; class SMESHGUI_EXPORT SMESHGUI_MeshInfoDlg : public QDialog @@ -383,6 +395,7 @@ private: SMESHGUI_AddInfo* myAddInfo; SMESHGUI_CtrlInfo* myCtrlInfo; SMESH_Actor* myActor; + Handle(SALOME_InteractiveObject) myIO; }; class SMESHGUI_EXPORT SMESHGUI_CtrlInfoDlg : public QDialog @@ -401,6 +414,8 @@ private slots: void activate(); void deactivate(); void updateSelection(); + void help(); + void dump(); private: SMESHGUI_CtrlInfo* myCtrlInfo;