From: Paul RASCLE Date: Sun, 10 May 2020 08:02:29 +0000 (+0200) Subject: porting to Ubuntu 20.04 native prerequisites X-Git-Tag: SH_V2_2_0~96 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=7e91d32b7456b50d4fe680317941da7b5590d4b1;p=modules%2Fhydro.git porting to Ubuntu 20.04 native prerequisites --- diff --git a/doc/salome/tutorial/conf.py.in b/doc/salome/tutorial/conf.py.in index bc2952fe..61af32dd 100644 --- a/doc/salome/tutorial/conf.py.in +++ b/doc/salome/tutorial/conf.py.in @@ -41,7 +41,7 @@ import sys, os # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. #extensions = ['sphinx.ext.extlinks'] -extensions = ['sphinx.ext.viewcode','sphinx.ext.pngmath'] +extensions = ['sphinx.ext.viewcode','sphinx.ext.imgmath'] # Add any paths that contain templates here, relative to this directory. #templates_path = ['_templates'] diff --git a/doc/salome/tutorial/english/conf.py.in b/doc/salome/tutorial/english/conf.py.in index 106c9b91..7ed0bc95 100644 --- a/doc/salome/tutorial/english/conf.py.in +++ b/doc/salome/tutorial/english/conf.py.in @@ -41,7 +41,7 @@ import sys, os # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. #extensions = ['sphinx.ext.extlinks'] -extensions = ['sphinx.ext.viewcode','sphinx.ext.pngmath'] +extensions = ['sphinx.ext.viewcode','sphinx.ext.imgmath'] # Add any paths that contain templates here, relative to this directory. #templates_path = ['_templates'] diff --git a/doc/salome/tutorial/local/conf.py b/doc/salome/tutorial/local/conf.py index a9076fb7..4a01399a 100644 --- a/doc/salome/tutorial/local/conf.py +++ b/doc/salome/tutorial/local/conf.py @@ -25,7 +25,7 @@ import sys, os # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = ['sphinx.ext.viewcode','sphinx.ext.pngmath']#,'sphinx.ext.graphviz'] +extensions = ['sphinx.ext.viewcode','sphinx.ext.imgmath']#,'sphinx.ext.graphviz'] # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] diff --git a/src/HYDROData/HYDROData_CalculationCase.cxx b/src/HYDROData/HYDROData_CalculationCase.cxx index adaeee14..2c64283c 100755 --- a/src/HYDROData/HYDROData_CalculationCase.cxx +++ b/src/HYDROData/HYDROData_CalculationCase.cxx @@ -77,7 +77,7 @@ #ifdef DEB_CALCULATION #include #include -#endif +#endif #define CALCULATION_REGIONS_PREF GetName() + "_Reg" #define CALCULATION_ZONES_PREF GetName() + "_Zone" #define CALCULATION_GROUPS_PREF GetName() + "_" @@ -107,7 +107,7 @@ HYDROData_CalculationCase::~HYDROData_CalculationCase() { } -void HYDROData_CalculationCase::SetName( const QString& theName ) +void HYDROData_CalculationCase::SetName( const QString& theName, bool isDefault ) { QString anOldCaseName = GetName(); if ( anOldCaseName != theName ) @@ -130,7 +130,7 @@ void HYDROData_CalculationCase::SetName( const QString& theName ) } } - HYDROData_Entity::SetName( theName ); + HYDROData_Entity::SetName( theName, isDefault ); } QStringList HYDROData_CalculationCase::DumpToPython( const QString& thePyScriptPath, @@ -141,7 +141,7 @@ QStringList HYDROData_CalculationCase::DumpToPython( const QString& thePyS QString aCalculName = GetObjPyName(); - AssignmentMode aMode = GetAssignmentMode(); + AssignmentMode aMode = GetAssignmentMode(); QString aModeStr = aMode==MANUAL ? "HYDROData_CalculationCase.MANUAL" : "HYDROData_CalculationCase.AUTOMATIC"; aResList << QString( "%0.SetAssignmentMode( %1 )" ).arg( aCalculName ).arg( aModeStr ); @@ -206,7 +206,7 @@ QStringList HYDROData_CalculationCase::DumpToPython( const QString& thePyS { // Now we restore the // - regions and zones order - DumpRegionsToPython( aResList, thePyScriptPath, theTreatedObjects, GetRegions() ); + DumpRegionsToPython( aResList, thePyScriptPath, theTreatedObjects, GetRegions() ); } // Export calculation case @@ -299,12 +299,12 @@ static void FilterEdgesByIncludeSelectionBoundaryPolygons( const HYDROData_Split Handle(HYDROData_BCPolygon) aBCPoly = Handle(HYDROData_BCPolygon)::DownCast( aBoundaryPolygons(i)); TopoDS_Shape aPolyTopShape = aBCPoly->GetTopShape(); int bType = aBCPoly->GetBoundaryType(); - if (bType == 2) + if (bType == 2) IncTools.Append(aPolyTopShape); else if (bType == 3) SelectionTools.Append(aPolyTopShape); } - + while( anIter.hasNext() ) { const HYDROData_SplitToZonesTool::SplitData& aSplitData = anIter.next(); @@ -334,14 +334,14 @@ static void SplitEdgesByBoundaryPolygons( const HYDROData_SplitToZonesTool::Spli Handle(HYDROData_BCPolygon) aBCPoly = Handle(HYDROData_BCPolygon)::DownCast( aBoundaryPolygons(i)); TopoDS_Shape aPolyTopShape = aBCPoly->GetTopShape(); int bType = aBCPoly->GetBoundaryType(); - if (bType == 1) + if (bType == 1) { CutTools.Append(aPolyTopShape); QString bp_name = aBCPoly->GetName(); BPolyToName.Bind(aPolyTopShape, bp_name); } } - + while( anIter.hasNext() ) { const HYDROData_SplitToZonesTool::SplitData& aSplitData = anIter.next(); @@ -368,7 +368,7 @@ static void SplitEdgesByBoundaryPolygons( const HYDROData_SplitToZonesTool::Spli TopoDS_Edge E = TopoDS::Edge(it.Value()); if (!E.IsNull()) { - HYDROData_SplitToZonesTool::SplitData SD(HYDROData_SplitToZonesTool::SplitData::Data_Edge, E, *name); + HYDROData_SplitToZonesTool::SplitData SD(HYDROData_SplitToZonesTool::SplitData::Data_Edge, E, *name); outBoundaryPolygonEdgesList.append(SD); } } @@ -381,7 +381,7 @@ static void PerformEdgeReplInZones(const HYDROData_SplitToZonesTool::SplitDataLi const NCollection_IndexedDataMap& ObjToRes, HYDROData_SplitToZonesTool::SplitDataList& outZoneList) { - HYDROData_SplitToZonesTool::SplitDataListIterator it( ZoneList ); + HYDROData_SplitToZonesTool::SplitDataListIterator it( ZoneList ); BRepTools_ReShape reshaper; for (;it.hasNext();) { @@ -415,7 +415,7 @@ static void PerformEdgeReplInZones(const HYDROData_SplitToZonesTool::SplitDataLi else continue; } - else + else continue; } reshaper.Replace(K, V); @@ -423,7 +423,7 @@ static void PerformEdgeReplInZones(const HYDROData_SplitToZonesTool::SplitDataLi TopoDS_Shape nS = reshaper.Apply(mS); HYDROData_SplitToZonesTool::SplitData aNS(aSplitData.Type, nS, aSplitData.ObjectNames); outZoneList.append(aNS); - } + } } static void CreateNewEdgeList( const HYDROData_SplitToZonesTool::SplitDataList& theEdges, @@ -509,16 +509,16 @@ void HYDROData_CalculationCase::Update() CreateNewEdgeList(anEdgesList, ObjToRes, newEdgesList1); // newEdgesList1.append(outBoundaryPolygonEdgesList); //append new list of groups - //filter out edges list by include&selection tools + //filter out edges list by include&selection tools FilterEdgesByIncludeSelectionBoundaryPolygons(newEdgesList1,aBoundaryPolygons,newEdgesList2); - + switch( GetAssignmentMode() ) { case MANUAL: - CreateRegionsDef( aDocument,aNewZonesList ); + CreateRegionsDef( aDocument,aNewZonesList ); break; case AUTOMATIC: - CreateRegionsAuto( aDocument,aNewZonesList ); + CreateRegionsAuto( aDocument,aNewZonesList ); break; } @@ -621,7 +621,7 @@ void HYDROData_CalculationCase::CreateRegionsAuto( const Handle(HYDROData_Docume anObjectsWithEmptyRegions.append( anObjName ); } } - + if( !anObjectsWithEmptyRegions.empty() ) { QString aData = anObjectsWithEmptyRegions.join( ", " ); @@ -646,8 +646,8 @@ void HYDROData_CalculationCase::CreateEdgeGroupsDef( const Handle(HYDROData_Docu if ( anObjName.isEmpty() ) continue; #ifdef DEB_CALCULATION - QString aStr = aSplitData.ObjectNames.join(" "); - cout << " CCase: Names = "<IsSubmersible() ) continue; - + if ( isAllNotSubmersible ) isAllNotSubmersible = false; @@ -1436,7 +1436,7 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var } } } // faces iterator - + aSewing.Perform(); TopoDS_Shape aSewedShape = aSewing.SewedShape(); @@ -1457,7 +1457,7 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var } } - + // If the sewed shape is empty - return false if ( aSewedShape.IsNull() || !TopoDS_Iterator( aSewedShape ).More() ) return false; @@ -1466,10 +1466,10 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var BRepTools::Write(aSewedShape ,"Sew.brep"); #endif // Publish the sewed shape QString aName = EXPORT_NAME; - GEOM::GEOM_Object_ptr aMainShape = + GEOM::GEOM_Object_ptr aMainShape = HYDROData_GeomTool::ExplodeShapeInGEOMandPublish( theGeomEngine, aSewedShape, aFacesToNameModif, aName, theGeomObjEntry ); - if ( aMainShape->_is_nil() ) + if ( aMainShape->_is_nil() ) return false; if ( theGroupsDefs.IsEmpty() ) @@ -1492,7 +1492,7 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var #ifdef DEB_CALCULATION cout << "\nOld shape(" << i << ") = " << aShape.TShape() < 0 ) { aGroupIndexes.Append( anIndex ); } else { -#ifdef DEB_CALCULATION +#ifdef DEB_CALCULATION TCollection_AsciiString aNam("Lost_"); if(!aMapOfSubShapes.Contains(aModifiedShape)) { for ( int anIndex = 1; anIndex <= aMapOfSubShapes.Extent(); anIndex++ ) @@ -1530,16 +1530,16 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var if ( !aGroupIndexes.IsEmpty() ) aGroupsData.Bind( aGroupDef.Name, aGroupIndexes ); } - + if ( !aGroupsData.IsEmpty() ) { - GEOM::GEOM_IGroupOperations_var aGroupOp = - theGeomEngine->GetIGroupOperations(); + GEOM::GEOM_IGroupOperations_var aGroupOp = + theGeomEngine->GetIGroupOperations(); NCollection_DataMap< TCollection_AsciiString, NCollection_Sequence >::Iterator aMapIt( aGroupsData ); for ( ; aMapIt.More(); aMapIt.Next() ) { - const TCollection_AsciiString& aGroupName = aMapIt.Key(); + const TCollection_AsciiString& aGroupName = aMapIt.Key(); const NCollection_Sequence& aGroupIndexes = aMapIt.Value(); GEOM::GEOM_Object_var aGeomGroup = aGroupOp->CreateGroup( aMainShape, TopAbs_EDGE ); @@ -1555,7 +1555,7 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var aGroupOp->UnionIDs( aGeomGroup, aGeomIndexes ); if ( aGroupOp->IsDone() ) { - SALOMEDS::SObject_var aGroupSO = + SALOMEDS::SObject_var aGroupSO = theGeomEngine->AddInStudy( aGeomGroup, aGroupName.ToCString(), aMainShape ); } } @@ -1691,7 +1691,7 @@ void HYDROData_CalculationCase::DumpRegionsToPython( QStringList& theResList, } } -bool HYDROData_CalculationCase::GetRule( int theIndex, +bool HYDROData_CalculationCase::GetRule( int theIndex, Handle(HYDROData_Entity)& theObject1, HYDROData_PriorityType& thePriority, Handle(HYDROData_Entity)& theObject2, @@ -1708,7 +1708,7 @@ bool HYDROData_CalculationCase::AddInterPoly( const Handle(HYDROData_PolylineXY) HYDROData_CalculationCase::DataTag aDataTag = DataTag_InterPoly; if ( HasReference( theInterPolyline, aDataTag ) ) - return false; + return false; AddReferenceObject( theInterPolyline, aDataTag ); @@ -1719,10 +1719,10 @@ bool HYDROData_CalculationCase::AddInterPoly( const Handle(HYDROData_PolylineXY) HYDROData_SequenceOfObjects HYDROData_CalculationCase::GetInterPolyObjects() const { - return GetReferenceObjects( DataTag_InterPoly ); + return GetReferenceObjects( DataTag_InterPoly ); } -void HYDROData_CalculationCase::RemoveInterPolyObject( const Handle(HYDROData_PolylineXY)& theInterPolyline ) +void HYDROData_CalculationCase::RemoveInterPolyObject( const Handle(HYDROData_PolylineXY)& theInterPolyline ) { if ( theInterPolyline.IsNull() ) return; @@ -1737,7 +1737,7 @@ bool HYDROData_CalculationCase::AddBoundaryPolygon( const Handle(HYDROData_BCPol HYDROData_CalculationCase::DataTag aDataTag = DataTag_BCPolygon; if ( HasReference( theBCPolygon, aDataTag ) ) - return false; + return false; AddReferenceObject( theBCPolygon, aDataTag ); @@ -1748,10 +1748,10 @@ bool HYDROData_CalculationCase::AddBoundaryPolygon( const Handle(HYDROData_BCPol HYDROData_SequenceOfObjects HYDROData_CalculationCase::GetBoundaryPolygons() const { - return GetReferenceObjects( DataTag_BCPolygon ); + return GetReferenceObjects( DataTag_BCPolygon ); } -void HYDROData_CalculationCase::RemoveBoundaryPolygon( const Handle(HYDROData_BCPolygon)& theBCPolygon ) +void HYDROData_CalculationCase::RemoveBoundaryPolygon( const Handle(HYDROData_BCPolygon)& theBCPolygon ) { if ( theBCPolygon.IsNull() ) return; diff --git a/src/HYDROData/HYDROData_CalculationCase.h b/src/HYDROData/HYDROData_CalculationCase.h index 479e49e5..2181cb5b 100644 --- a/src/HYDROData/HYDROData_CalculationCase.h +++ b/src/HYDROData/HYDROData_CalculationCase.h @@ -118,7 +118,7 @@ public: * Updates the name of this object. * Reimplemented to update the names of regions, zones and split groups. */ - HYDRODATA_EXPORT virtual void SetName( const QString& theName ); + HYDRODATA_EXPORT virtual void SetName( const QString& theName, bool isDefault = false ); /** * Dump Calculation object to Python script representation. @@ -137,7 +137,7 @@ public: */ HYDRODATA_EXPORT virtual HYDROData_SequenceOfObjects GetAllReferenceObjects() const; -public: +public: // Public methods to work with Calculation /** @@ -231,7 +231,7 @@ public: * because of new region becomes the new parent for this zone. * \return the created region */ - HYDRODATA_EXPORT virtual Handle(HYDROData_Region) AddNewRegion( const Handle(HYDROData_Zone)& theZone ); + HYDRODATA_EXPORT virtual Handle(HYDROData_Region) AddNewRegion( const Handle(HYDROData_Zone)& theZone ); /** @@ -256,7 +256,7 @@ public: * Removes reference region from calculation case. * \param theRegion the region to remove */ - HYDRODATA_EXPORT virtual void RemoveRegion( const Handle(HYDROData_Region)& theRegion ); + HYDRODATA_EXPORT virtual void RemoveRegion( const Handle(HYDROData_Region)& theRegion ); /** * Removes all reference regions from calculation case. @@ -287,11 +287,11 @@ public: /** * \brief Set the Container Name to use when not default (FactoryServer). - * \param theContainerName the name of the container used for GEOM + * \param theContainerName the name of the container used for GEOM * (to be used by scripts for distributed execution) */ HYDRODATA_EXPORT virtual void SetContainerName( const QString& theContainerName ); - + /** * Exports the calculation case data (shell and groups) to GEOM module. * \return the entry of the GEOM object (empty string in the case of error) @@ -312,7 +312,7 @@ public: QString& statMess) const; #endif -public: +public: // Public methods to work with Calculation services /** @@ -361,7 +361,7 @@ public: * \param theRegion reference region to check * \return result altitude value */ - HYDRODATA_EXPORT virtual NCollection_Sequence GetAltitudesForPoints( + HYDRODATA_EXPORT virtual NCollection_Sequence GetAltitudesForPoints( const NCollection_Sequence& thePoints, const Handle(HYDROData_Region)& theRegion, int theMethod = 0) const; @@ -372,7 +372,7 @@ public: * \param theZone reference zone to check * \return result altitude value */ - HYDRODATA_EXPORT virtual NCollection_Sequence GetAltitudesForPoints( + HYDRODATA_EXPORT virtual NCollection_Sequence GetAltitudesForPoints( const NCollection_Sequence& thePoints, const Handle(HYDROData_Zone)& theZone, int theMethod = 0) const; @@ -413,7 +413,7 @@ public: const Handle(HYDROData_Entity)& theObject2, HYDROData_Zone::MergeType theMergeType, HYDROData_CalculationCase::DataTag theDataTag ); - HYDRODATA_EXPORT bool GetRule( int theIndex, + HYDRODATA_EXPORT bool GetRule( int theIndex, Handle(HYDROData_Entity)& theObject1, HYDROData_PriorityType& thePriority, Handle(HYDROData_Entity)& theObject2, @@ -444,7 +444,7 @@ private: /** * Exports the given faces as shell and the given groups to GEOM module. * \param theGeomEngine GEOM module engine - * \param theFaces the list of faces to make shell + * \param theFaces the list of faces to make shell * \param theSplitGroups the list of groups * \return true in case of success */ @@ -454,7 +454,7 @@ private: const HYDROData_ShapesGroup::SeqOfGroupsDefs& theGroupsDefs, QString& theGeomObjEntry ) const; #endif - + void CreateRegionsDef( const Handle(HYDROData_Document)& theDoc, const HYDROData_SplitToZonesTool::SplitDataList& theZones ); void CreateRegionsAuto( const Handle(HYDROData_Document)& theDoc, @@ -470,7 +470,7 @@ private: void UpdateRegionsNames( const HYDROData_SequenceOfObjects& theRegions, const QString& theOldCaseName, const QString& theName ); - + void DumpRegionsToPython( QStringList& theResList, const QString& thePyScriptPath, MapOfTreatedObjects& theTreatedObjects, @@ -480,7 +480,7 @@ protected: friend class HYDROData_Iterator; /** - * Creates new object in the internal data structure. Use higher level objects + * Creates new object in the internal data structure. Use higher level objects * to create objects with real content. */ HYDRODATA_EXPORT HYDROData_CalculationCase(); diff --git a/src/HYDROData/HYDROData_Entity.h b/src/HYDROData/HYDROData_Entity.h index f5924f12..dcc67a82 100644 --- a/src/HYDROData/HYDROData_Entity.h +++ b/src/HYDROData/HYDROData_Entity.h @@ -153,7 +153,7 @@ public: /** * Updates the name of this object. */ - HYDRODATA_EXPORT void SetName( const QString& theName, bool isDefault = false ); + HYDRODATA_EXPORT virtual void SetName( const QString& theName, bool isDefault = false ); /** * Returns the name of this object valid for Python script. diff --git a/src/HYDROData/HYDROData_Object.cxx b/src/HYDROData/HYDROData_Object.cxx index 993519ab..13236c1a 100644 --- a/src/HYDROData/HYDROData_Object.cxx +++ b/src/HYDROData/HYDROData_Object.cxx @@ -43,7 +43,7 @@ HYDROData_Object::~HYDROData_Object() { } -void HYDROData_Object::SetName( const QString& theName ) +void HYDROData_Object::SetName( const QString& theName, bool isDefault) { //DEBTRACE("SetName"); QString anOldObjName = GetName(); @@ -70,7 +70,7 @@ void HYDROData_Object::SetName( const QString& theName ) HYDROData_Tool::UpdateChildObjectName( anOldObjName, theName, anAltitudeObj ); } - HYDROData_Entity::SetName( theName ); + HYDROData_Entity::SetName( theName, isDefault ); } void HYDROData_Object::Update() @@ -140,7 +140,7 @@ Handle(HYDROData_DummyObject3D) HYDROData_Object::GetObject3D() const { //DEBTRACE("GetObject3D"); Handle(HYDROData_DummyObject3D) anObject; - + TDF_Label aLabel = myLab.FindChild( DataTag_Object3D, false ); if ( !aLabel.IsNull() ) { @@ -206,13 +206,13 @@ int HYDROData_Object::GetGroupId( const Handle(HYDROData_ShapesGroup)& theGroup return aRes; } -bool HYDROData_Object::SetAltitudeObject( +bool HYDROData_Object::SetAltitudeObject( const Handle(HYDROData_IAltitudeObject)& theAltitude ) { DEBTRACE("SetAltitudeObject"); if ( theAltitude.IsNull() ) return false; - + Handle(HYDROData_IAltitudeObject) aPrevAltitude = GetAltitudeObject(); if (!aPrevAltitude.IsNull()) DEBTRACE("aPrevAltitude: " << aPrevAltitude->GetName()) @@ -232,7 +232,7 @@ bool HYDROData_Object::SetAltitudeObject( Handle(HYDROData_IAltitudeObject) HYDROData_Object::GetAltitudeObject() const { //DEBTRACE("GetAltitudeObject"); - return Handle(HYDROData_IAltitudeObject)::DownCast( + return Handle(HYDROData_IAltitudeObject)::DownCast( GetReferenceObject( DataTag_AltitudeObject ) ); } @@ -319,7 +319,7 @@ Handle(HYDROData_IAltitudeObject) HYDROData_Object::getChildAltitudeObject() con { //DEBTRACE("getChildAltitudeObject"); Handle(HYDROData_IAltitudeObject) anObject; - + TDF_Label aLabel = myLab.FindChild( DataTag_ChildAltitudeObject, false ); if ( !aLabel.IsNull() ) { diff --git a/src/HYDROData/HYDROData_Object.h b/src/HYDROData/HYDROData_Object.h index e3646b21..606cf2dc 100644 --- a/src/HYDROData/HYDROData_Object.h +++ b/src/HYDROData/HYDROData_Object.h @@ -57,7 +57,7 @@ public: * Updates the name of this object. * Reimplemented to update the names child groups. */ - HYDRODATA_EXPORT virtual void SetName( const QString& theName ); + HYDRODATA_EXPORT virtual void SetName( const QString& theName, bool isDefault = false ); /** * Update the geometry object. @@ -164,7 +164,7 @@ public: protected: /** - * Creates new object in the internal data structure. Use higher level objects + * Creates new object in the internal data structure. Use higher level objects * to create objects with real content. */ HYDRODATA_EXPORT HYDROData_Object( Geometry ); @@ -187,7 +187,7 @@ protected: /** * Checks and if necessary create child 3D object. - * Reimplement this function in your subclass if you + * Reimplement this function in your subclass if you * do not want to create child 3D object. */ HYDRODATA_EXPORT virtual void checkAndSetObject3D(); @@ -195,7 +195,7 @@ protected: /** * Returns the type of child altitude object. - * Base implementation returns KIND_UNKNOWN, it means that child altitude + * Base implementation returns KIND_UNKNOWN, it means that child altitude * object will not be created inside of checkAndSetAltitudeObject() function. * Reimplement this function in your subclass an return correct altitude * object type if you want to create child altitude object. diff --git a/src/HYDROPy/HYDROData_Entity.sip b/src/HYDROPy/HYDROData_Entity.sip index 2aedac54..42e8b332 100644 --- a/src/HYDROPy/HYDROData_Entity.sip +++ b/src/HYDROPy/HYDROData_Entity.sip @@ -188,7 +188,7 @@ public: /** * Updates the name of this object. */ - virtual void SetName(const QString& theName); + virtual void SetName(const QString& theName, bool isDefault = false ); /** * Updates object state. diff --git a/src/HYDROPy/HYDROData_IAltitudeObject.sip b/src/HYDROPy/HYDROData_IAltitudeObject.sip index e1e2742c..1e93fdcf 100644 --- a/src/HYDROPy/HYDROData_IAltitudeObject.sip +++ b/src/HYDROPy/HYDROData_IAltitudeObject.sip @@ -37,7 +37,7 @@ class HYDROData_IAltitudeObject : public HYDROData_Entity /Abstract/ case KIND_ALTITUDE: sipClass = sipClass_HYDROData_AltitudeObject; break; - + case KIND_STREAM_ALTITUDE: sipClass = sipClass_HYDROData_StreamAltitude; break; @@ -52,7 +52,7 @@ class HYDROData_IAltitudeObject : public HYDROData_Entity /Abstract/ #include %End -public: +public: // Public methods to work with altitudes. /** @@ -67,10 +67,10 @@ public: * \return altitude value */ virtual double GetAltitudeForPoint( const double theCoordX, - const double theCoordX ) const = 0 [double ( const gp_XY& )]; + const double theCoordX ) const = 0 [double ( const gp_XY&, int)]; %MethodCode gp_XY aPnt( a0, a1 ); - + Py_BEGIN_ALLOW_THREADS sipRes = sipCpp->GetAltitudeForPoint( aPnt ); Py_END_ALLOW_THREADS @@ -80,11 +80,11 @@ public: sipParseResultEx(sipGILState, sipErrorHandler, sipPySelf, sipMethod, sipResObj, "d", &sipRes); %End - + protected: /** - * Creates new object in the internal data structure. Use higher level objects + * Creates new object in the internal data structure. Use higher level objects * to create objects with real content. */ HYDROData_IAltitudeObject(); diff --git a/src/HYDROPy/HYDROData_IPolyline.sip b/src/HYDROPy/HYDROData_IPolyline.sip index 0960af1a..258577ce 100644 --- a/src/HYDROPy/HYDROData_IPolyline.sip +++ b/src/HYDROPy/HYDROData_IPolyline.sip @@ -51,7 +51,7 @@ public: enum SectionType{ SECTION_POLYLINE = 0, SECTION_SPLINE = 1 }; -public: +public: /** * Sets wire color for object. @@ -107,7 +107,7 @@ public: * \param theSectionIndex index of section * \param theSectionName new section name */ - virtual void SetSectionName( const int theSectionIndex, + virtual void SetSectionName( const int theSectionIndex, const TCollection_AsciiString& theSectionName ) = 0; /** @@ -121,7 +121,7 @@ public: * \param theSectionIndex index of section * \param theSectionType new section type */ - virtual void SetSectionType( const int theSectionIndex, + virtual void SetSectionType( const int theSectionIndex, const HYDROData_IPolyline::SectionType theSectionType ) = 0; /** @@ -135,7 +135,7 @@ public: * \param theSectionIndex index of section * \param theIsClosed new closures state */ - virtual void SetSectionClosed( const int theSectionIndex, + virtual void SetSectionClosed( const int theSectionIndex, const bool theIsClosed ) = 0; /** @@ -191,12 +191,12 @@ public: * only for section with this index * \return list of points */ - virtual HYDROData_IPolyline::PointsList GetPoints( const int theSectionIndex = -1 ) const = 0; + virtual HYDROData_IPolyline::PointsList GetPoints( const int theSectionIndex = -1, bool IsConvertToGlobal = false ) const = 0; protected: /** - * Creates new object in the internal data structure. Use higher level objects + * Creates new object in the internal data structure. Use higher level objects * to create objects with real content. */ HYDROData_IPolyline();