// of auto-color picking up
#define SIMPLE_AUTOCOLOR
-// REMOVE the code about MPLMathText_Disabler if it does not complite at porting to ParaView-4.1
-#include <vtkMatplotlibMathTextUtilities.h>
-namespace
-{
- // Creation of this class disables vtkMatplotlibMathTextUtilities
- struct MPLMathText_Disabler : protected vtkMatplotlibMathTextUtilities
- {
- MPLMathText_Disabler()
- {
- vtkMatplotlibMathTextUtilities::MPLMathTextAvailable =
- vtkMatplotlibMathTextUtilities::UNAVAILABLE;
- }
- };
-}
-
namespace
{
// Declarations
/* load resources for all available meshers */
SMESH::InitAvailableHypotheses();
-
- MPLMathText_Disabler d; // disable vtkMatplotlibMathTextUtilities
}
//=============================================================================
*
*/
//=============================================================================
-bool SMESHGUI::automaticUpdate( SMESH::SMESH_Mesh_ptr theMesh,
- int* entities, bool* limitExceeded, int* hidden )
+bool SMESHGUI::automaticUpdate( SMESH::SMESH_IDSource_ptr theMesh,
+ int* entities, bool* limitExceeded, int* hidden, long* nbElements )
{
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
if ( !resMgr )
long updateLimit = resMgr->integerValue( "SMESH", "update_limit", 500000 );
bool incrementalLimit = resMgr->booleanValue( "SMESH", "incremental_limit", false );
- long requestedSize = theMesh->NbElements();
-
+ SMESH::long_array_var info = theMesh->GetMeshInfo();
+ long nbOdElems = info[SMDSEntity_0D];
+ long nbEdges = info[SMDSEntity_Edge] + info[SMDSEntity_Quad_Edge];
+ long nbFaces = info[SMDSEntity_Triangle] + info[SMDSEntity_Quad_Triangle] + info[SMDSEntity_BiQuad_Triangle] +
+ info[SMDSEntity_Quadrangle] + info[SMDSEntity_Quad_Quadrangle] + info[SMDSEntity_BiQuad_Quadrangle] +
+ info[SMDSEntity_Polygon];
+ long nbVolumes = info[SMDSEntity_Tetra] + info[SMDSEntity_Quad_Tetra] +
+ info[SMDSEntity_Hexa] + info[SMDSEntity_Quad_Hexa] + info[SMDSEntity_TriQuad_Hexa] +
+ info[SMDSEntity_Pyramid] + info[SMDSEntity_Quad_Pyramid] +
+ info[SMDSEntity_Penta] + info[SMDSEntity_Quad_Penta] +
+ info[SMDSEntity_Polyhedra] +
+ info[SMDSEntity_Hexagonal_Prism];
+ long nbBalls = info[SMDSEntity_Ball];
+
+ long requestedSize = nbOdElems + nbBalls + nbEdges + nbFaces + nbVolumes;
+ *nbElements = requestedSize;
+
*entities = SMESH_Actor::eAllEntity;
*hidden = 0;
if ( limitExceeded ) *limitExceeded = autoUpdate && exceeded;
if ( incrementalLimit ) {
- long nbOdElems = theMesh->Nb0DElements();
- long nbEdges = theMesh->NbEdges();
- long nbFaces = theMesh->NbFaces();
- long nbVolumes = theMesh->NbVolumes();
- long nbBalls = theMesh->NbBalls();
long total = 0;
if ( nbOdElems > 0 ) {
void SMESHGUI::windows( QMap<int, int>& aMap ) const
{
aMap.insert( SalomeApp_Application::WT_ObjectBrowser, Qt::LeftDockWidgetArea );
+ aMap.insert( SalomeApp_Application::WT_NoteBook, Qt::LeftDockWidgetArea );
aMap.insert( SalomeApp_Application::WT_PyConsole, Qt::BottomDockWidgetArea );
}