1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-19 13:40:49 +03:00

Coding - Update Clang-format with more macroses (#677)

- Updates `.clang-format` to include `OCC_CATCH_SIGNALS`, `DEFINE_STANDARD_RTTIEXT`, and `Draw_Drawable3D_FACTORY` as statement macros
- Adds a GitHub action step to automatically remove empty lines after `Standard_DEPRECATED` macro declarations
- Reformats numerous files by removing blank lines after deprecated method declarations and improving macro formatting
This commit is contained in:
Pasukhin Dmitry
2025-08-16 20:50:50 +01:00
committed by GitHub
parent d1b00bf132
commit 314527f5c0
93 changed files with 169 additions and 282 deletions

View File

@@ -36,6 +36,9 @@ UseTab: Never
# OCCT specific settings
StatementMacros:
- Standard_FALLTHROUGH
- OCC_CATCH_SIGNALS
- DEFINE_STANDARD_RTTIEXT
- Draw_Drawable3D_FACTORY
- Standard_DEPRECATED
TypenameMacros:
- Handle

View File

@@ -56,6 +56,20 @@ runs:
clang-format -i -style=file $_
}
- name: Remove empty lines after Standard_DEPRECATED
if: steps.changed-files.outputs.has_files == 'true'
shell: pwsh
run: |
$files = Get-Content "changed_files.txt" | Where-Object { Test-Path $_ }
$files | ForEach-Object {
$content = Get-Content $_ -Raw
$pattern = '(Standard_DEPRECATED\("[a-z0-9\.,;\s\(\)_-]+"(?:[\s\n]+"[a-z0-9\.,;\s\(\)_-]+")?\)\n)\n+'
$newContent = $content -replace $pattern, '$1'
if ($content -ne $newContent) {
Set-Content -Path $_ -Value $newContent -NoNewline
}
}
- name: Check git status
id: git-check
if: steps.changed-files.outputs.has_files == 'true'

View File

@@ -264,7 +264,7 @@ Standard_Boolean IsImported(const Handle(TNaming_NamedShape)& NS)
it.Next();
if (!it.More())
return 0;
// plus d un shape.
// plus d un shape.
#ifdef OCCT_DEBUG
std::cout << "WARNING IMPORTED" << std::endl;
#endif

View File

@@ -1498,7 +1498,7 @@ static Standard_Boolean FilterByNeighbourgs(const TDF_Label& L,
TC = TopAbs_VERTEX;
// clang-format off
if (ShapeType == TopAbs_VERTEX) TC = TopAbs_VERTEX; // szy 31.03.10 - to process case when Candidate is of type Vertex
// clang-format on
// clang-format on
#ifdef OCCT_DEBUG_FNB
i = 1;

View File

@@ -49,7 +49,8 @@ void PCDM_StorageDriver::Write(const Handle(CDM_Document)& aDocument,
{
try
{
OCC_CATCH_SIGNALS Make(aDocument, thePersistentDocuments);
OCC_CATCH_SIGNALS
Make(aDocument, thePersistentDocuments);
}
catch (Standard_Failure const& anException)
{

View File

@@ -37,8 +37,7 @@
//=============================================================================
GeomToStep_MakeBSplineCurveWithKnots::GeomToStep_MakeBSplineCurveWithKnots(
const Handle(Geom_BSplineCurve)& BS,
const StepData_Factors& theLocalFactors)
{
const StepData_Factors& theLocalFactors){
#define Array1OfPnt_gen TColgp_Array1OfPnt
#include "GeomToStep_MakeBSplineCurveWithKnots_gen.pxx"
#undef Array1OfPnt_gen

View File

@@ -38,12 +38,11 @@
GeomToStep_MakeBSplineCurveWithKnotsAndRationalBSplineCurve::
GeomToStep_MakeBSplineCurveWithKnotsAndRationalBSplineCurve(
const Handle(Geom_BSplineCurve)& BS,
const StepData_Factors& theLocalFactors)
{
const StepData_Factors& theLocalFactors){
#define Array1OfPnt_gen TColgp_Array1OfPnt
#include "GeomToStep_MakeBSplineCurveWithKnotsAndRationalBSplineCurve_gen.pxx"
#undef Array1OfPnt_gen
}
}
//=============================================================================
// Creation d' une bspline_curve_with_knots_and_rational_bspline_curve de

View File

@@ -33,8 +33,7 @@
//=============================================================================
// Creation d' une line de prostep a partir d' une Lin de gp
//=============================================================================
GeomToStep_MakeLine::GeomToStep_MakeLine(const gp_Lin& L, const StepData_Factors& theLocalFactors)
{
GeomToStep_MakeLine::GeomToStep_MakeLine(const gp_Lin& L, const StepData_Factors& theLocalFactors){
#define Vec_gen gp_Vec
#include "GeomToStep_MakeLine_gen.pxx"
#undef Vec_gen
@@ -44,8 +43,8 @@ GeomToStep_MakeLine::GeomToStep_MakeLine(const gp_Lin& L, const StepData_Factors
// Creation d' une line de prostep a partir d' une Lin2d de gp
//=============================================================================
GeomToStep_MakeLine::GeomToStep_MakeLine(const gp_Lin2d& L, const StepData_Factors& theLocalFactors)
{
GeomToStep_MakeLine::GeomToStep_MakeLine(const gp_Lin2d& L,
const StepData_Factors& theLocalFactors){
#define Vec_gen gp_Vec2d
#include "GeomToStep_MakeLine_gen.pxx"
#undef Vec_gen

View File

@@ -34,7 +34,7 @@ void RWStepVisual_RWPresentationLayerUsage::ReadStep(
if (!data->CheckNbParams(num, 2, ach, "presentation_layer_usage"))
return;
// --- own fields
// --- own fields
#include <StepVisual_PresentationLayerAssignment.hxx>
#include <StepVisual_PresentationRepresentation.hxx>
Handle(StepVisual_PresentationLayerAssignment) pla;

View File

@@ -132,7 +132,6 @@ public:
Standard_EXPORT void SetFaceCulling(Graphic3d_TypeOfBackfacingModel theFaceCulling);
Standard_DEPRECATED("Deprecated method, FaceCulling() should be used instead")
Standard_Boolean IsDoubleSided() const
{
return myFaceCulling == Graphic3d_TypeOfBackfacingModel_DoubleSided;
@@ -140,7 +139,6 @@ public:
Standard_DEPRECATED("Deprecated method, SetFaceCulling() should be used "
"instead")
void SetDoubleSided(Standard_Boolean theIsDoubleSided)
{
SetFaceCulling(theIsDoubleSided ? Graphic3d_TypeOfBackfacingModel_DoubleSided

View File

@@ -214,7 +214,7 @@ static Standard_Boolean IsValidSurfType(const TopoDS_Face& theFace)
}
*/
#ifdef OCCT_DEBUG
// ModDbgTools_Write(theFace, "Surf");
// ModDbgTools_Write(theFace, "Surf");
#endif
return Standard_False;
}

View File

@@ -37,17 +37,16 @@ class gp_Trsf;
class DBRep_DrawableShape : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(DBRep_DrawableShape, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
DBRep_DrawableShape(const TopoDS_Shape& C,
const Draw_Color& FreeCol,
const Draw_Color& ConnCol,
const Draw_Color& EdgeCol,
const Draw_Color& IsosCol,
const Standard_Real size,
const Standard_Integer nbisos,
const Standard_Integer discret);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT DBRep_DrawableShape(const TopoDS_Shape& C,
const Draw_Color& FreeCol,
const Draw_Color& ConnCol,
const Draw_Color& EdgeCol,
const Draw_Color& IsosCol,
const Standard_Real size,
const Standard_Integer nbisos,
const Standard_Integer discret);
//! Changes the number of isoparametric curves in a shape.
Standard_EXPORT void ChangeNbIsos(const Standard_Integer NbIsos);

View File

@@ -384,9 +384,9 @@ void Draw_Appli(int argc, char** argv, const FDraw_InitAppli Draw_InitAppli)
::SetErrorMode(0);
#endif
// *****************************************************************
// init X window and create display
// *****************************************************************
// *****************************************************************
// init X window and create display
// *****************************************************************
#ifdef _WIN32
HWND hWnd = NULL;
#endif

View File

@@ -25,10 +25,9 @@ DEFINE_STANDARD_HANDLE(Draw_Number, Draw_Drawable3D)
class Draw_Number : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(Draw_Number, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
Draw_Number(const Standard_Real theV);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT Draw_Number(const Standard_Real theV);
Standard_Real Value() const { return myValue; }

View File

@@ -28,11 +28,10 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BSplineCurve, DrawTrSurf_Curve)
class DrawTrSurf_BSplineCurve : public DrawTrSurf_Curve
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BSplineCurve, DrawTrSurf_Curve)
Draw_Drawable3D_FACTORY public :
//! creates a drawable BSpline curve from a BSpline curve of package Geom.
Standard_EXPORT
DrawTrSurf_BSplineCurve(const Handle(Geom_BSplineCurve)& C);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable BSpline curve from a BSpline curve of package Geom.
Standard_EXPORT DrawTrSurf_BSplineCurve(const Handle(Geom_BSplineCurve)& C);
//! creates a drawable BSpline curve from a BSpline curve of package Geom.
Standard_EXPORT DrawTrSurf_BSplineCurve(const Handle(Geom_BSplineCurve)& C,

View File

@@ -28,11 +28,10 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BSplineCurve2d, DrawTrSurf_Curve2d)
class DrawTrSurf_BSplineCurve2d : public DrawTrSurf_Curve2d
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BSplineCurve2d, DrawTrSurf_Curve2d)
Draw_Drawable3D_FACTORY public :
//! creates a drawable BSpline curve from a BSpline curve of package Geom2d.
Standard_EXPORT
DrawTrSurf_BSplineCurve2d(const Handle(Geom2d_BSplineCurve)& C);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable BSpline curve from a BSpline curve of package Geom2d.
Standard_EXPORT DrawTrSurf_BSplineCurve2d(const Handle(Geom2d_BSplineCurve)& C);
Standard_EXPORT DrawTrSurf_BSplineCurve2d(const Handle(Geom2d_BSplineCurve)& C,
const Draw_Color& CurvColor,

View File

@@ -33,15 +33,14 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BSplineSurface, DrawTrSurf_Surface)
class DrawTrSurf_BSplineSurface : public DrawTrSurf_Surface
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BSplineSurface, DrawTrSurf_Surface)
Draw_Drawable3D_FACTORY public :
//! default drawing mode.
//! The isoparametric curves corresponding to the knots values are drawn.
//! The control points and the knots points are drawn.
//! The boundaries are yellow, the isoparametric curves are blues.
//! For the discretisation 50 points are computed in each parametric direction.
Standard_EXPORT
DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S);
Draw_Drawable3D_FACTORY
public:
//! default drawing mode.
//! The isoparametric curves corresponding to the knots values are drawn.
//! The control points and the knots points are drawn.
//! The boundaries are yellow, the isoparametric curves are blues.
//! For the discretisation 50 points are computed in each parametric direction.
Standard_EXPORT DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S);
//! The isoparametric curves corresponding to the knots values are drawn.
Standard_EXPORT DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S,

View File

@@ -27,11 +27,10 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BezierCurve, DrawTrSurf_Curve)
class DrawTrSurf_BezierCurve : public DrawTrSurf_Curve
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BezierCurve, DrawTrSurf_Curve)
Draw_Drawable3D_FACTORY public :
//! creates a drawable Bezier curve from a Bezier curve of package Geom.
Standard_EXPORT
DrawTrSurf_BezierCurve(const Handle(Geom_BezierCurve)& C);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable Bezier curve from a Bezier curve of package Geom.
Standard_EXPORT DrawTrSurf_BezierCurve(const Handle(Geom_BezierCurve)& C);
Standard_EXPORT DrawTrSurf_BezierCurve(const Handle(Geom_BezierCurve)& C,
const Draw_Color& CurvColor,

View File

@@ -27,11 +27,10 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BezierCurve2d, DrawTrSurf_Curve2d)
class DrawTrSurf_BezierCurve2d : public DrawTrSurf_Curve2d
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BezierCurve2d, DrawTrSurf_Curve2d)
Draw_Drawable3D_FACTORY public :
//! creates a drawable Bezier curve from a Bezier curve of package Geom2d.
Standard_EXPORT
DrawTrSurf_BezierCurve2d(const Handle(Geom2d_BezierCurve)& C);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable Bezier curve from a Bezier curve of package Geom2d.
Standard_EXPORT DrawTrSurf_BezierCurve2d(const Handle(Geom2d_BezierCurve)& C);
Standard_EXPORT DrawTrSurf_BezierCurve2d(const Handle(Geom2d_BezierCurve)& C,
const Draw_Color& CurvColor,

View File

@@ -27,11 +27,10 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_BezierSurface, DrawTrSurf_Surface)
class DrawTrSurf_BezierSurface : public DrawTrSurf_Surface
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_BezierSurface, DrawTrSurf_Surface)
Draw_Drawable3D_FACTORY public :
//! creates a drawable Bezier curve from a Bezier curve of package Geom.
Standard_EXPORT
DrawTrSurf_BezierSurface(const Handle(Geom_BezierSurface)& S);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable Bezier curve from a Bezier curve of package Geom.
Standard_EXPORT DrawTrSurf_BezierSurface(const Handle(Geom_BezierSurface)& S);
Standard_EXPORT DrawTrSurf_BezierSurface(const Handle(Geom_BezierSurface)& S,
const Standard_Integer NbUIsos,

View File

@@ -30,12 +30,11 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Curve, DrawTrSurf_Drawable)
class DrawTrSurf_Curve : public DrawTrSurf_Drawable
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Curve, DrawTrSurf_Drawable)
Draw_Drawable3D_FACTORY public :
//! creates a drawable curve from a curve of package Geom.
Standard_EXPORT
DrawTrSurf_Curve(const Handle(Geom_Curve)& C,
const Standard_Boolean DispOrigin = Standard_True);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable curve from a curve of package Geom.
Standard_EXPORT DrawTrSurf_Curve(const Handle(Geom_Curve)& C,
const Standard_Boolean DispOrigin = Standard_True);
Standard_EXPORT DrawTrSurf_Curve(const Handle(Geom_Curve)& C,
const Draw_Color& aColor,

View File

@@ -30,12 +30,11 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Curve2d, DrawTrSurf_Drawable)
class DrawTrSurf_Curve2d : public DrawTrSurf_Drawable
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Curve2d, DrawTrSurf_Drawable)
Draw_Drawable3D_FACTORY public :
//! creates a drawable curve from a curve of package Geom2d.
Standard_EXPORT
DrawTrSurf_Curve2d(const Handle(Geom2d_Curve)& C,
const Standard_Boolean DispOrigin = Standard_True);
Draw_Drawable3D_FACTORY
public:
//! creates a drawable curve from a curve of package Geom2d.
Standard_EXPORT DrawTrSurf_Curve2d(const Handle(Geom2d_Curve)& C,
const Standard_Boolean DispOrigin = Standard_True);
Standard_EXPORT DrawTrSurf_Curve2d(const Handle(Geom2d_Curve)& C,
const Draw_Color& aColor,

View File

@@ -29,10 +29,11 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Point, Draw_Drawable3D)
class DrawTrSurf_Point : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Point, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
DrawTrSurf_Point(const gp_Pnt& P, const Draw_MarkerShape Shape, const Draw_Color& Col);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT DrawTrSurf_Point(const gp_Pnt& P,
const Draw_MarkerShape Shape,
const Draw_Color& Col);
Standard_EXPORT DrawTrSurf_Point(const gp_Pnt2d& P,
const Draw_MarkerShape Shape,

View File

@@ -29,10 +29,9 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Polygon2D, Draw_Drawable2D)
class DrawTrSurf_Polygon2D : public Draw_Drawable2D
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Polygon2D, Draw_Drawable2D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
DrawTrSurf_Polygon2D(const Handle(Poly_Polygon2D)& P);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT DrawTrSurf_Polygon2D(const Handle(Poly_Polygon2D)& P);
Handle(Poly_Polygon2D) Polygon2D() const { return myPolygon2D; }

View File

@@ -29,10 +29,9 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Polygon3D, Draw_Drawable3D)
class DrawTrSurf_Polygon3D : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Polygon3D, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
DrawTrSurf_Polygon3D(const Handle(Poly_Polygon3D)& P);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT DrawTrSurf_Polygon3D(const Handle(Poly_Polygon3D)& P);
Handle(Poly_Polygon3D) Polygon3D() const { return myPolygon3D; }

View File

@@ -30,14 +30,13 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Surface, DrawTrSurf_Drawable)
class DrawTrSurf_Surface : public DrawTrSurf_Drawable
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Surface, DrawTrSurf_Drawable)
Draw_Drawable3D_FACTORY public :
//! default drawing mode
//! Just the middle isoparametric curves are drawn.
//! The boundaries are yellow, the isoparametric curves are blues.
//! For the discretisation 50 points are computed in each parametric direction.
Standard_EXPORT
DrawTrSurf_Surface(const Handle(Geom_Surface)& S);
Draw_Drawable3D_FACTORY
public:
//! default drawing mode
//! Just the middle isoparametric curves are drawn.
//! The boundaries are yellow, the isoparametric curves are blues.
//! For the discretisation 50 points are computed in each parametric direction.
Standard_EXPORT DrawTrSurf_Surface(const Handle(Geom_Surface)& S);
Standard_EXPORT DrawTrSurf_Surface(const Handle(Geom_Surface)& S,
const Standard_Integer Nu,

View File

@@ -33,10 +33,9 @@ DEFINE_STANDARD_HANDLE(DrawTrSurf_Triangulation, Draw_Drawable3D)
class DrawTrSurf_Triangulation : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(DrawTrSurf_Triangulation, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
DrawTrSurf_Triangulation(const Handle(Poly_Triangulation)& T);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT DrawTrSurf_Triangulation(const Handle(Poly_Triangulation)& T);
Handle(Poly_Triangulation) Triangulation() const { return myTriangulation; }

View File

@@ -27,10 +27,9 @@ DEFINE_STANDARD_HANDLE(HLRTest_Projector, Draw_Drawable3D)
class HLRTest_Projector : public Draw_Drawable3D
{
DEFINE_STANDARD_RTTIEXT(HLRTest_Projector, Draw_Drawable3D)
Draw_Drawable3D_FACTORY public :
Standard_EXPORT
HLRTest_Projector(const HLRAlgo_Projector& P);
Draw_Drawable3D_FACTORY
public:
Standard_EXPORT HLRTest_Projector(const HLRAlgo_Projector& P);
const HLRAlgo_Projector& Projector() const { return myProjector; }

View File

@@ -127,11 +127,9 @@ public:
const Handle(TColStd_HArray1OfReal)& Parameters() const { return myParameters; }
Standard_DEPRECATED("Deprecated method, SetNode() should be used instead")
TColStd_Array1OfInteger& ChangeNodes() { return myNodes; }
Standard_DEPRECATED("Deprecated method, SetParameter() should be used instead")
TColStd_Array1OfReal& ChangeParameters() { return myParameters->ChangeArray1(); }
private:

View File

@@ -335,15 +335,12 @@ public:
Standard_EXPORT void SetNormals(const Handle(TShort_HArray1OfShortReal)& theNormals);
Standard_DEPRECATED("Deprecated method, Triangle() should be used instead")
const Poly_Array1OfTriangle& Triangles() const { return myTriangles; }
Standard_DEPRECATED("Deprecated method, SetTriangle() should be used instead")
Poly_Array1OfTriangle& ChangeTriangles() { return myTriangles; }
Standard_DEPRECATED("Deprecated method, SetTriangle() should be used instead")
Poly_Triangle& ChangeTriangle(const Standard_Integer theIndex)
{
return myTriangles.ChangeValue(theIndex);

View File

@@ -40,10 +40,7 @@ public:
}
//! Method Relieve() was replaced by Close() in Message_ProgressScope
void Relieve()
{
Close();
}
void Relieve() { Close(); }
private:
//! Message_ProgressRange should be passed to constructor instead of Message_ProgressIndicator.

View File

@@ -363,7 +363,6 @@ public:
//! if they contain exactly the same keys.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean IsEqual(const NCollection_Map& theOther) const
{
return NCollection_MapAlgo::IsEqual<NCollection_Map>(*this, theOther);
@@ -373,7 +372,6 @@ public:
//! This function checks if this map contains all keys of another map.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean Contains(const NCollection_Map& theOther) const
{
return NCollection_MapAlgo::Contains<NCollection_Map>(*this, theOther);
@@ -385,7 +383,6 @@ public:
//! (result of the boolean operation) can also be passed as one of operands.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
void Union(const NCollection_Map& theLeft, const NCollection_Map& theRight)
{
NCollection_MapAlgo::Union<NCollection_Map>(*this, theLeft, theRight);
@@ -397,7 +394,6 @@ public:
//! True if contents of this map is changed.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean Unite(const NCollection_Map& theOther)
{
return NCollection_MapAlgo::Unite<NCollection_Map>(*this, theOther);
@@ -406,7 +402,6 @@ public:
//! Returns true if this and theMap have common elements.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean HasIntersection(const NCollection_Map& theMap) const
{
return NCollection_MapAlgo::HasIntersection<NCollection_Map>(*this, theMap);
@@ -418,7 +413,6 @@ public:
//! boolean operation) can also be used as one of operands.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
void Intersection(const NCollection_Map& theLeft, const NCollection_Map& theRight)
{
NCollection_MapAlgo::Intersection<NCollection_Map>(*this, theLeft, theRight);
@@ -430,7 +424,6 @@ public:
//! of this map is changed.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean Intersect(const NCollection_Map& theOther)
{
return NCollection_MapAlgo::Intersect<NCollection_Map>(*this, theOther);
@@ -442,7 +435,6 @@ public:
//! one. All previous content of this Map is cleared.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
void Subtraction(const NCollection_Map& theLeft, const NCollection_Map& theRight)
{
NCollection_MapAlgo::Subtraction<NCollection_Map>(*this, theLeft, theRight);
@@ -455,7 +447,6 @@ public:
//! Returns True if contents of this map is changed.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean Subtract(const NCollection_Map& theOther)
{
return NCollection_MapAlgo::Subtract<NCollection_Map>(*this, theOther);
@@ -467,7 +458,6 @@ public:
//! cleared. This map (result of the boolean operation) can also be used as one of operands.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
void Difference(const NCollection_Map& theLeft, const NCollection_Map& theRight)
{
NCollection_MapAlgo::Difference<NCollection_Map>(*this, theLeft, theRight);
@@ -479,7 +469,6 @@ public:
//! True if contents of this map is changed.
Standard_DEPRECATED("This method will be removed right after 7.9. release. Use methods from "
"NCollection_MapAlgo.hxx instead.")
Standard_Boolean Differ(const NCollection_Map& theOther)
{
return NCollection_MapAlgo::Differ<NCollection_Map>(*this, theOther);

View File

@@ -63,21 +63,18 @@ inline bool Standard_Atomic_CompareAndSwap(volatile int* theValue,
// enforced.
Standard_DEPRECATED("Standard_Atomic_Increment will be removed in OCCT 8.0.0")
int Standard_Atomic_Increment(volatile int* theValue)
{
return __sync_add_and_fetch(theValue, 1);
}
Standard_DEPRECATED("Standard_Atomic_Decrement will be removed in OCCT 8.0.0")
int Standard_Atomic_Decrement(volatile int* theValue)
{
return __sync_sub_and_fetch(theValue, 1);
}
Standard_DEPRECATED("Standard_Atomic_CompareAndSwap will be removed in OCCT 8.0.0")
bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int theNewValue)
{
return __sync_val_compare_and_swap(theValue, theOldValue, theNewValue) == theOldValue;
@@ -102,21 +99,18 @@ extern "C"
// Note that we safely cast int* to long*, as they have same size and endian-ness
Standard_DEPRECATED("Standard_Atomic_Increment will be removed in OCCT 8.0.0")
int Standard_Atomic_Increment(volatile int* theValue)
{
return _InterlockedIncrement(reinterpret_cast<volatile long*>(theValue));
}
Standard_DEPRECATED("Standard_Atomic_Decrement will be removed in OCCT 8.0.0")
int Standard_Atomic_Decrement(volatile int* theValue)
{
return _InterlockedDecrement(reinterpret_cast<volatile long*>(theValue));
}
Standard_DEPRECATED("Standard_Atomic_CompareAndSwap will be removed in OCCT 8.0.0")
bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int theNewValue)
{
return _InterlockedCompareExchange(reinterpret_cast<volatile long*>(theValue),
@@ -131,21 +125,18 @@ bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int
#include <libkern/OSAtomic.h>
Standard_DEPRECATED("Standard_Atomic_Increment will be removed in OCCT 8.0.0")
int Standard_Atomic_Increment(volatile int* theValue)
{
return OSAtomicIncrement32Barrier(theValue);
}
Standard_DEPRECATED("Standard_Atomic_Decrement will be removed in OCCT 8.0.0")
int Standard_Atomic_Decrement(volatile int* theValue)
{
return OSAtomicDecrement32Barrier(theValue);
}
Standard_DEPRECATED("Standard_Atomic_CompareAndSwap will be removed in OCCT 8.0.0")
bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int theNewValue)
{
return OSAtomicCompareAndSwapInt(theOldValue, theNewValue, theValue);
@@ -161,21 +152,18 @@ bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int
#include <sys/atomics.h>
Standard_DEPRECATED("Standard_Atomic_Increment will be removed in OCCT 8.0.0")
int Standard_Atomic_Increment(volatile int* theValue)
{
return __atomic_inc(theValue) + 1; // analog of __sync_fetch_and_add
}
Standard_DEPRECATED("Standard_Atomic_Decrement will be removed in OCCT 8.0.0")
int Standard_Atomic_Decrement(volatile int* theValue)
{
return __atomic_dec(theValue) - 1; // analog of __sync_fetch_and_sub
}
Standard_DEPRECATED("Standard_Atomic_CompareAndSwap will be removed in OCCT 8.0.0")
bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int theNewValue)
{
return __atomic_cmpxchg(theOldValue, theNewValue, theValue) == 0;
@@ -187,21 +175,18 @@ bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int
#error "Atomic operation isn't implemented for current platform!"
#endif
Standard_DEPRECATED("Standard_Atomic_Increment will be removed in OCCT 8.0.0")
int Standard_Atomic_Increment(volatile int* theValue)
{
return ++(*theValue);
}
Standard_DEPRECATED("Standard_Atomic_Decrement will be removed in OCCT 8.0.0")
int Standard_Atomic_Decrement(volatile int* theValue)
{
return --(*theValue);
}
Standard_DEPRECATED("Standard_Atomic_CompareAndSwap will be removed in OCCT 8.0.0")
bool Standard_Atomic_CompareAndSwap(volatile int* theValue, int theOldValue, int theNewValue)
{
if (*theValue == theOldValue)

View File

@@ -189,7 +189,6 @@ public:
//! For compatibility, define down casting operator from non-base type, as deprecated
template <class T2>
Standard_DEPRECATED("down-casting from object of the same or unrelated type is meaningless")
static handle DownCast(
const handle<T2>& theObject,
typename opencascade::std::enable_if<!is_base_but_not_same<T2, T>::value, void*>::type = 0)
@@ -200,7 +199,6 @@ public:
//! For compatibility, define down casting operator from non-base type, as deprecated
template <class T2>
Standard_DEPRECATED("down-casting from object of the same or unrelated type is meaningless")
static handle DownCast(
const T2* thePtr,
typename opencascade::std::enable_if<!is_base_but_not_same<T2, T>::value, void*>::type = 0)
@@ -350,7 +348,6 @@ public:
template <class T2>
Standard_DEPRECATED("Passing non-const reference to handle of base type in function is unsafe; "
"use variable of exact type")
operator handle<T2>&()
{
// error "type is not a member of enable_if" will be generated if T2 is not sub-type of T

View File

@@ -188,7 +188,7 @@ void Standard_MMgrOpt::Initialize()
if (myNbPages < 100)
myNbPages = 1000;
// get system-dependent page size
// get system-dependent page size
#ifndef _WIN32
myPageSize = getpagesize();
if (!myPageSize)

View File

@@ -6216,7 +6216,7 @@ Fast_failed1:
b = multadd(b, 10, 0 MTb);
}
/* Round off last digit */
/* Round off last digit */
#ifdef Honor_FLT_ROUNDS
if (mode > 1)

View File

@@ -26,21 +26,21 @@
//! The package <TCollection> provides the services for the
//! transient basic data structures.
class Standard_DEPRECATED(
"Deprecated since OCCT 7.9, NCollection_Primes should be used instead of TCollection")
TCollection{public :
"Deprecated since OCCT 7.9, NCollection_Primes should be used instead of TCollection") TCollection
{
public:
DEFINE_STANDARD_ALLOC
DEFINE_STANDARD_ALLOC
//! Returns a prime number greater than <I> suitable
//! to dimension a Map. When <I> becomes great there
//! is a limit on the result (today the limit is
//! around 1 000 000). This is not a limit of the number of
//! items but a limit in the number of buckets. i.e.
//! there will be more collisions in the map.
static Standard_Integer NextPrimeForMap(const Standard_Integer I){
return NCollection_Primes::NextPrimeForMap(I);
}
}
;
//! Returns a prime number greater than <I> suitable
//! to dimension a Map. When <I> becomes great there
//! is a limit on the result (today the limit is
//! around 1 000 000). This is not a limit of the number of
//! items but a limit in the number of buckets. i.e.
//! there will be more collisions in the map.
static Standard_Integer NextPrimeForMap(const Standard_Integer I)
{
return NCollection_Primes::NextPrimeForMap(I);
}
};
#endif // _TCollection_HeaderFile

View File

@@ -2269,7 +2269,7 @@ void TopOpeBRepBuild_BuilderON::GFillONPartsWES2(const Handle(TopOpeBRepDS_Inter
gp_Vec ntOOFOR = FUN_tool_nggeomF(uv, OOFOR);
if (OOFOR.Orientation() == TopAbs_REVERSED)
ntOOFOR.Reverse();
// xxFCX :
// xxFCX :
#ifdef OCCT_DEBUG
// Standard_Real t1 =factor*BRep_Tool::Tolerance(Esd);
#endif

View File

@@ -388,7 +388,7 @@ Standard_Boolean GeomFill_NSections::D1(const Standard_Real V,
if (NullWeight)
return Standard_False;
// verif par diff finies sous debug sauf pour les surfaces periodiques
// verif par diff finies sous debug sauf pour les surfaces periodiques
#ifdef OCCT_DEBUG
if (!mySurface->IsVPeriodic())
{
@@ -498,7 +498,7 @@ Standard_Boolean GeomFill_NSections::D2(const Standard_Real V,
if (NullWeight)
return Standard_False;
// verif par diff finies sous debug sauf pour les surfaces periodiques
// verif par diff finies sous debug sauf pour les surfaces periodiques
#ifdef OCCT_DEBUG
if (!mySurface->IsVPeriodic())
{

View File

@@ -146,7 +146,6 @@ public:
public:
Standard_DEPRECATED("ModifyOffsetSurfaceMode() should be used instead")
Standard_Boolean& ModifyOffestSurfaceMode() { return myOffsetSurfaceMode; }
private:

View File

@@ -309,7 +309,8 @@ TopoDS_Shell ShapeFix_FaceConnect::Build(const TopoDS_Shell& shell,
{
try
{
OCC_CATCH_SIGNALS theSewer.Perform();
OCC_CATCH_SIGNALS
theSewer.Perform();
}
catch (Standard_Failure const&)
{

View File

@@ -1503,8 +1503,8 @@ void MAT2d_DrawCurve(const Handle(Geom2d_Curve)& aCurve, const Standard_Integer
else
dr = new DrawTrSurf_Curve2d(CurveDraw, Couleur, 500);
// dout << dr;
// dout.Flush();
// dout << dr;
// dout.Flush();
#endif
}

View File

@@ -93,7 +93,7 @@ public:
//! Exceptions StdFail_NotDone if no arc of circle is constructed.
Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom_TrimmedCurve) TheArc;

View File

@@ -70,7 +70,7 @@ public:
//! Returns the constructed arc of ellipse.
Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom_TrimmedCurve) TheArc;

View File

@@ -68,7 +68,7 @@ public:
//! Returns the constructed arc of hyperbola.
Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom_TrimmedCurve) TheArc;

View File

@@ -65,7 +65,7 @@ public:
//! Returns the constructed arc of parabola.
Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom_TrimmedCurve) TheArc;

View File

@@ -98,7 +98,7 @@ public:
//! StdFail_NotDone if no circle is constructed.
Standard_EXPORT const Handle(Geom_Circle)& Value() const;
operator const Handle(Geom_Circle) & () const { return Value(); }
operator const Handle(Geom_Circle)&() const { return Value(); }
private:
Handle(Geom_Circle) TheCircle;

View File

@@ -110,7 +110,7 @@ public:
//! StdFail_NotDone if no cone is constructed.
Standard_EXPORT const Handle(Geom_ConicalSurface)& Value() const;
operator const Handle(Geom_ConicalSurface) & () const { return Value(); }
operator const Handle(Geom_ConicalSurface)&() const { return Value(); }
private:
Handle(Geom_ConicalSurface) TheCone;

View File

@@ -106,7 +106,7 @@ public:
//! Exceptions StdFail_NotDone if no cylinder is constructed.
Standard_EXPORT const Handle(Geom_CylindricalSurface)& Value() const;
operator const Handle(Geom_CylindricalSurface) & () const { return Value(); }
operator const Handle(Geom_CylindricalSurface)&() const { return Value(); }
private:
Handle(Geom_CylindricalSurface) TheCylinder;

View File

@@ -75,7 +75,7 @@ public:
//! Exceptions StdFail_NotDone if no ellipse is constructed.
Standard_EXPORT const Handle(Geom_Ellipse)& Value() const;
operator const Handle(Geom_Ellipse) & () const { return Value(); }
operator const Handle(Geom_Ellipse)&() const { return Value(); }
private:
Handle(Geom_Ellipse) TheEllipse;

View File

@@ -85,7 +85,7 @@ public:
//! Exceptions StdFail_NotDone if no hyperbola is constructed.
Standard_EXPORT const Handle(Geom_Hyperbola)& Value() const;
operator const Handle(Geom_Hyperbola) & () const { return Value(); }
operator const Handle(Geom_Hyperbola)&() const { return Value(); }
private:
Handle(Geom_Hyperbola) TheHyperbola;

View File

@@ -70,7 +70,7 @@ public:
//! Exceptions StdFail_NotDone if no line is constructed.
Standard_EXPORT const Handle(Geom_Line)& Value() const;
operator const Handle(Geom_Line) & () const { return Value(); }
operator const Handle(Geom_Line)&() const { return Value(); }
private:
Handle(Geom_Line) TheLine;

View File

@@ -60,7 +60,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom_Transformation)& Value() const;
operator const Handle(Geom_Transformation) & () const { return Value(); }
operator const Handle(Geom_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -87,7 +87,7 @@ public:
//! Exceptions StdFail_NotDone if no plane is constructed.
Standard_EXPORT const Handle(Geom_Plane)& Value() const;
operator const Handle(Geom_Plane) & () const { return Value(); }
operator const Handle(Geom_Plane)&() const { return Value(); }
private:
Handle(Geom_Plane) ThePlane;

View File

@@ -55,7 +55,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom_Transformation)& Value() const;
operator const Handle(Geom_Transformation) & () const { return Value(); }
operator const Handle(Geom_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -46,7 +46,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom_Transformation)& Value() const;
operator const Handle(Geom_Transformation) & () const { return Value(); }
operator const Handle(Geom_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -67,7 +67,7 @@ public:
//! Returns the constructed line segment.
Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom_TrimmedCurve) TheSegment;

View File

@@ -47,7 +47,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom_Transformation)& Value() const;
operator const Handle(Geom_Transformation) & () const { return Value(); }
operator const Handle(Geom_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -78,7 +78,7 @@ public:
//! StdFail_NotDone if no trimmed cone is constructed.
Standard_EXPORT const Handle(Geom_RectangularTrimmedSurface)& Value() const;
operator const Handle(Geom_RectangularTrimmedSurface) & () const { return Value(); }
operator const Handle(Geom_RectangularTrimmedSurface)&() const { return Value(); }
private:
Handle(Geom_RectangularTrimmedSurface) TheCone;

View File

@@ -71,7 +71,7 @@ public:
//! StdFail_NotDone if no trimmed cylinder is constructed.
Standard_EXPORT const Handle(Geom_RectangularTrimmedSurface)& Value() const;
operator const Handle(Geom_RectangularTrimmedSurface) & () const { return Value(); }
operator const Handle(Geom_RectangularTrimmedSurface)&() const { return Value(); }
private:
Handle(Geom_RectangularTrimmedSurface) TheCyl;

View File

@@ -78,7 +78,7 @@ public:
//! Exceptions StdFail_NotDone if no arc of circle is constructed.
Standard_EXPORT const Handle(Geom2d_TrimmedCurve)& Value() const;
operator const Handle(Geom2d_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom2d_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom2d_TrimmedCurve) TheArc;

View File

@@ -70,7 +70,7 @@ public:
//! Returns the constructed arc of ellipse.
Standard_EXPORT const Handle(Geom2d_TrimmedCurve)& Value() const;
operator const Handle(Geom2d_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom2d_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom2d_TrimmedCurve) TheArc;

View File

@@ -69,7 +69,7 @@ public:
//! Returns the constructed arc of hyperbola.
Standard_EXPORT const Handle(Geom2d_TrimmedCurve)& Value() const;
operator const Handle(Geom2d_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom2d_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom2d_TrimmedCurve) TheArc;

View File

@@ -69,7 +69,7 @@ public:
//! Returns the constructed arc of parabola.
Standard_EXPORT const Handle(Geom2d_TrimmedCurve)& Value() const;
operator const Handle(Geom2d_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom2d_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom2d_TrimmedCurve) TheArc;

View File

@@ -102,7 +102,7 @@ public:
//! Exceptions StdFail_NotDone if no circle is constructed.
Standard_EXPORT const Handle(Geom2d_Circle)& Value() const;
operator const Handle(Geom2d_Circle) & () const { return Value(); }
operator const Handle(Geom2d_Circle)&() const { return Value(); }
private:
Handle(Geom2d_Circle) TheCircle;

View File

@@ -85,7 +85,7 @@ public:
//! Exceptions StdFail_NotDone if no ellipse is constructed.
Standard_EXPORT const Handle(Geom2d_Ellipse)& Value() const;
operator const Handle(Geom2d_Ellipse) & () const { return Value(); }
operator const Handle(Geom2d_Ellipse)&() const { return Value(); }
private:
Handle(Geom2d_Ellipse) TheEllipse;

View File

@@ -107,7 +107,7 @@ public:
//! Exceptions: StdFail_NotDone if no hyperbola is constructed.
Standard_EXPORT const Handle(Geom2d_Hyperbola)& Value() const;
operator const Handle(Geom2d_Hyperbola) & () const { return Value(); }
operator const Handle(Geom2d_Hyperbola)&() const { return Value(); }
private:
Handle(Geom2d_Hyperbola) TheHyperbola;

View File

@@ -69,7 +69,7 @@ public:
//! Exceptions StdFail_NotDone if no line is constructed.
Standard_EXPORT const Handle(Geom2d_Line)& Value() const;
operator const Handle(Geom2d_Line) & () const { return Value(); }
operator const Handle(Geom2d_Line)&() const { return Value(); }
private:
Handle(Geom2d_Line) TheLine;

View File

@@ -52,7 +52,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom2d_Transformation)& Value() const;
operator const Handle(Geom2d_Transformation) & () const { return Value(); }
operator const Handle(Geom2d_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -100,7 +100,7 @@ public:
//! Exceptions StdFail_NotDone if no parabola is constructed.
Standard_EXPORT const Handle(Geom2d_Parabola)& Value() const;
operator const Handle(Geom2d_Parabola) & () const { return Value(); }
operator const Handle(Geom2d_Parabola)&() const { return Value(); }
private:
Handle(Geom2d_Parabola) TheParabola;

View File

@@ -42,7 +42,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom2d_Transformation)& Value() const;
operator const Handle(Geom2d_Transformation) & () const { return Value(); }
operator const Handle(Geom2d_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -45,7 +45,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom2d_Transformation)& Value() const;
operator const Handle(Geom2d_Transformation) & () const { return Value(); }
operator const Handle(Geom2d_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -81,7 +81,7 @@ public:
//! Exceptions StdFail_NotDone if no line segment is constructed.
Standard_EXPORT const Handle(Geom2d_TrimmedCurve)& Value() const;
operator const Handle(Geom2d_TrimmedCurve) & () const { return Value(); }
operator const Handle(Geom2d_TrimmedCurve)&() const { return Value(); }
private:
Handle(Geom2d_TrimmedCurve) TheSegment;

View File

@@ -47,7 +47,7 @@ public:
//! Returns the constructed transformation.
Standard_EXPORT const Handle(Geom2d_Transformation)& Value() const;
operator const Handle(Geom2d_Transformation) & () const { return Value(); }
operator const Handle(Geom2d_Transformation)&() const { return Value(); }
protected:
private:

View File

@@ -930,10 +930,10 @@ void MeshVS_Mesh::HilightSelected(const Handle(PrsMgr_PresentationManager)& theP
if (HasPresentation())
aSelectionPrs->SetTransformPersistence(Presentation()->TransformPersistence());
//----------------
//----------------
// It is very important to call this parent method, because it check whether
// mySelectionPrs is created and if not, create it.
// It is very important to call this parent method, because it check whether
// mySelectionPrs is created and if not, create it.
#ifdef OCCT_DEBUG
OSD_Timer gTimer;

View File

@@ -851,7 +851,6 @@ public: //! @name methods to alter or retrieve current state
//! Bind specified texture set to current context taking into account active GLSL program.
Standard_DEPRECATED("BindTextures() with explicit GLSL program should be used instead")
Handle(OpenGl_TextureSet) BindTextures(const Handle(OpenGl_TextureSet)& theTextures)
{
return BindTextures(theTextures, myActiveProgram);

View File

@@ -282,7 +282,6 @@ public:
//! Initialize FBO for rendering into single/multiple color buffer and depth textures.
Standard_DEPRECATED("Obsolete method, use Init() taking Graphic3d_Vec2i")
bool Init(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theSizeX,
const Standard_Integer theSizeY,
@@ -299,7 +298,6 @@ public:
//! Initialize FBO for rendering into textures.
Standard_DEPRECATED("Obsolete method, use Init() taking Graphic3d_Vec2i")
bool Init(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theSizeX,
const Standard_Integer theSizeY,
@@ -316,7 +314,6 @@ public:
//! Initialize FBO for rendering into single/multiple color buffer and depth textures.
Standard_DEPRECATED("Obsolete method, use Init() taking Graphic3d_Vec2i")
bool Init(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theSizeX,
const Standard_Integer theSizeY,
@@ -333,7 +330,6 @@ public:
//! (Re-)initialize FBO with specified dimensions.
Standard_DEPRECATED("Obsolete method, use InitLazy() taking Graphic3d_Vec2i")
bool InitLazy(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theViewportSizeX,
const Standard_Integer theViewportSizeY,
@@ -350,7 +346,6 @@ public:
//! (Re-)initialize FBO with specified dimensions.
Standard_DEPRECATED("Obsolete method, use InitLazy() taking Graphic3d_Vec2i")
bool InitLazy(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theViewportSizeX,
const Standard_Integer theViewportSizeY,
@@ -369,7 +364,6 @@ public:
//! The Render Buffer Objects will be used for Color, Depth and Stencil attachments (as opposite
//! to textures).
Standard_DEPRECATED("Obsolete method, use InitWithRB() taking Graphic3d_Vec2i")
bool InitWithRB(const Handle(OpenGl_Context)& theGlCtx,
const Standard_Integer theSizeX,
const Standard_Integer theSizeY,

View File

@@ -259,7 +259,6 @@ public:
Standard_DEPRECATED("Deprecated method, OpenGl_TextureFormat should be passed instead of "
"separate parameters")
bool Init(const Handle(OpenGl_Context)& theCtx,
const Standard_Integer theTextFormat,
const unsigned int thePixelFormat,
@@ -278,7 +277,6 @@ public:
Standard_DEPRECATED("Deprecated method, theIsColorMap parameter should be explicitly "
"specified")
bool Init(const Handle(OpenGl_Context)& theCtx,
const Image_PixMap& theImage,
const Graphic3d_TypeOfTexture theType)
@@ -288,7 +286,6 @@ public:
Standard_DEPRECATED("Deprecated method, OpenGl_TextureFormat should be passed instead of "
"separate parameters")
bool Init3D(const Handle(OpenGl_Context)& theCtx,
const Standard_Integer theTextFormat,
const unsigned int thePixelFormat,

View File

@@ -31,9 +31,9 @@ public:
Handle(OpenGl_Texture) Texture;
Graphic3d_TextureUnit Unit;
operator const Handle(OpenGl_Texture) & () const { return Texture; }
operator const Handle(OpenGl_Texture)&() const { return Texture; }
operator Handle(OpenGl_Texture) & () { return Texture; }
operator Handle(OpenGl_Texture)&() { return Texture; }
TextureSlot()
: Unit(Graphic3d_TextureUnit_0)

View File

@@ -308,7 +308,6 @@ public:
//! @return true on success
Standard_DEPRECATED("Deprecated method, Font_FTFontParams should be used for passing "
"parameters")
bool Init(const NCollection_String& theFontPath,
unsigned int thePointSize,
unsigned int theResolution)
@@ -327,7 +326,6 @@ public:
//! @return true on success
Standard_DEPRECATED("Deprecated method, Font_FTFontParams should be used for passing "
"parameters")
bool Init(const NCollection_String& theFontName,
Font_FontAspect theFontAspect,
unsigned int thePointSize,

View File

@@ -162,7 +162,6 @@ public:
Standard_EXPORT void Format();
Standard_DEPRECATED("BottomLeft should be used instead")
const NCollection_Vec2<Standard_ShortReal>& TopLeft(const Standard_Integer theIndex) const
{
return BottomLeft(theIndex);

View File

@@ -57,7 +57,6 @@ public:
public:
Standard_DEPRECATED("Deprecated method, ToDrawEdges() should be used instead")
bool Edge() const { return ToDrawEdges(); }
};

View File

@@ -548,7 +548,6 @@ public:
public:
Standard_DEPRECATED("Deprecated method, FaceCulling() should be used instead")
bool ToSuppressBackFaces() const
{
return myFaceCulling == Graphic3d_TypeOfBackfacingModel_BackCulled
@@ -557,7 +556,6 @@ public:
Standard_DEPRECATED("Deprecated method, SetFaceCulling() should be used "
"instead")
void SetSuppressBackFaces(bool theToSuppress)
{
myFaceCulling = theToSuppress ? Graphic3d_TypeOfBackfacingModel_Auto
@@ -565,7 +563,6 @@ public:
}
Standard_DEPRECATED("Deprecated method, FaceCulling() should be used instead")
bool BackFace() const
{
return myFaceCulling == Graphic3d_TypeOfBackfacingModel_BackCulled
@@ -573,11 +570,9 @@ public:
}
Standard_DEPRECATED("Deprecated method, SetFaceCulling() should be used instead")
void AllowBackFace() { myFaceCulling = Graphic3d_TypeOfBackfacingModel_DoubleSided; }
Standard_DEPRECATED("Deprecated method, SetFaceCulling() should be used instead")
void SuppressBackFace() { myFaceCulling = Graphic3d_TypeOfBackfacingModel_Auto; }
protected:

View File

@@ -241,7 +241,6 @@ public:
//! Deactivates the reflective properties of the surface with specified reflection type.
Standard_DEPRECATED("Deprecated method, specific material component should be zerroed "
"instead")
void SetReflectionModeOff(const Graphic3d_TypeOfReflection theType)
{
if (!ReflectionMode(theType))

View File

@@ -88,7 +88,6 @@ public:
Standard_DEPRECATED("Deprecated since OCCT7.7, Graphic3d_DisplayPriority should be passed "
"instead of integer number to SetDisplayPriority()")
void SetDisplayPriority(const Standard_Integer thePriority)
{
SetDisplayPriority((Graphic3d_DisplayPriority)thePriority);
@@ -328,7 +327,6 @@ public:
Standard_Boolean theWithCheck = Standard_False);
Standard_DEPRECATED("Deprecated short-cut")
void Connect(const Handle(Graphic3d_Structure)& thePrs)
{
Connect(thePrs.get(), Graphic3d_TOC_DESCENDANT);
@@ -341,7 +339,6 @@ public:
Standard_EXPORT void Disconnect(Graphic3d_Structure* theStructure);
Standard_DEPRECATED("Deprecated alias for Disconnect()")
void Remove(const Handle(Graphic3d_Structure)& thePrs) { Disconnect(thePrs.get()); }
//! If Atype is TOC_DESCENDANT then suppress all
@@ -351,7 +348,6 @@ public:
Standard_EXPORT void DisconnectAll(const Graphic3d_TypeOfConnection AType);
Standard_DEPRECATED("Deprecated alias for DisconnectAll()")
void RemoveAll() { DisconnectAll(Graphic3d_TOC_DESCENDANT); }
//! Returns <ASet> the group of structures :

View File

@@ -314,7 +314,6 @@ public: //! @name object presence management (View affinity, Layer, Priority)
Standard_DEPRECATED("Deprecated since OCCT7.7, Graphic3d_DisplayPriority should be passed "
"instead of integer number to SetDisplayPriority()")
void SetDisplayPriority(const Handle(AIS_InteractiveObject)& theIObj,
const Standard_Integer thePriority)
{
@@ -574,7 +573,6 @@ public: //! @name Selection management
Standard_EXPORT Bnd_Box BoundingBoxOfSelection(const Handle(V3d_View)& theView) const;
Standard_DEPRECATED("BoundingBoxOfSelection() should be called with View argument")
Bnd_Box BoundingBoxOfSelection() const { return BoundingBoxOfSelection(Handle(V3d_View)()); }
//! Sets list of owner selected/deselected using specified selection scheme.
@@ -1230,7 +1228,6 @@ public: //! @name iso-line display attributes
public:
Standard_DEPRECATED("Deprecated method Display() with obsolete argument "
"theToAllowDecomposition")
void Display(const Handle(AIS_InteractiveObject)& theIObj,
const Standard_Integer theDispMode,
const Standard_Integer theSelectionMode,
@@ -1244,7 +1241,6 @@ public:
Standard_DEPRECATED("Deprecated method Load() with obsolete last argument "
"theToAllowDecomposition")
void Load(const Handle(AIS_InteractiveObject)& theObj,
Standard_Integer theSelectionMode,
Standard_Boolean)
@@ -1256,7 +1252,6 @@ public:
//! On dynamic detection by the mouse cursor, sensitive primitives are highlighted.
//! The highlight color of entities detected by mouse movement is white by default.
Standard_DEPRECATED("Deprecated method Hilight()")
void Hilight(const Handle(AIS_InteractiveObject)& theObj,
const Standard_Boolean theIsToUpdateViewer)
{
@@ -1326,7 +1321,6 @@ public:
//! selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void SetCurrentObject(const Handle(AIS_InteractiveObject)& theIObj,
const Standard_Boolean theToUpdateViewer)
{
@@ -1339,7 +1333,6 @@ public:
//! object, if 0 selection of the object is empty this method simply does nothing.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void AddOrRemoveCurrentObject(const Handle(AIS_InteractiveObject)& theObj,
const Standard_Boolean theIsToUpdateViewer)
{
@@ -1351,7 +1344,6 @@ public:
//! current objects; those selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void UpdateCurrent() { UpdateSelected(Standard_True); }
//! Returns true if there is a non-null interactive object in Neutral Point.
@@ -1370,7 +1362,6 @@ public:
//! selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void InitCurrent() { InitSelected(); }
//! Returns true if there is another object found by the scan of the list of current objects.
@@ -1386,7 +1377,6 @@ public:
//! selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void NextCurrent() { NextSelected(); }
//! Returns the current interactive object.
@@ -1407,7 +1397,6 @@ public:
//! selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void HilightCurrents(const Standard_Boolean theToUpdateViewer)
{
HilightSelected(theToUpdateViewer);
@@ -1418,7 +1407,6 @@ public:
//! selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void UnhilightCurrents(const Standard_Boolean theToUpdateViewer)
{
UnhilightSelected(theToUpdateViewer);
@@ -1429,7 +1417,6 @@ public:
//! objects; those selected in open local context, selected objects.
Standard_DEPRECATED("Local Context is deprecated - local selection should be used without Local "
"Context")
void ClearCurrents(const Standard_Boolean theToUpdateViewer) { ClearSelected(theToUpdateViewer); }
//! @return current mouse-detected shape or empty (null) shape, if current interactive object

View File

@@ -883,23 +883,18 @@ public:
public: //! @name deprecated methods
Standard_DEPRECATED("SetDeviationAngle() should be used instead")
void SetHLRAngle(const Standard_Real theAngle) { SetDeviationAngle(theAngle); }
Standard_DEPRECATED("DeviationAngle() should be used instead")
Standard_Real HLRAngle() const { return DeviationAngle(); }
Standard_DEPRECATED("SetDeviationAngle() should be used instead")
void SetHLRAngle() { SetDeviationAngle(); }
Standard_DEPRECATED("HasOwnDeviationAngle() should be used instead")
Standard_Boolean HasOwnHLRDeviationAngle() const { return HasOwnDeviationAngle(); }
Standard_DEPRECATED("PreviousDeviationAngle() should be used instead")
Standard_Real PreviousHLRDeviationAngle() const { return PreviousDeviationAngle(); }
protected:

View File

@@ -37,7 +37,6 @@ public:
Standard_EXPORT ~PrsMgr_Presentation();
Standard_DEPRECATED("Dummy to simplify porting - returns self")
Prs3d_Presentation* Presentation() { return this; }
//! returns the PresentationManager in which the presentation has been created.

View File

@@ -36,7 +36,6 @@ public:
//! owner theOwnerId, the circle theCircle, the boolean
//! theIsFilled and the number of points theNbPnts.
Standard_DEPRECATED("Deprecated constructor, theNbPnts parameter will be ignored")
Select3D_SensitiveCircle(const Handle(SelectMgr_EntityOwner)& theOwnerId,
const gp_Circ& theCircle,
const Standard_Boolean theIsFilled,

View File

@@ -180,7 +180,6 @@ public:
public:
Standard_DEPRECATED("Deprecated alias for OverlapsBox()")
Standard_Boolean Overlaps(const NCollection_Vec3<Standard_Real>& theBoxMin,
const NCollection_Vec3<Standard_Real>& theBoxMax,
SelectBasics_PickResult& thePickResult) const
@@ -189,7 +188,6 @@ public:
}
Standard_DEPRECATED("Deprecated alias for OverlapsBox()")
Standard_Boolean Overlaps(const NCollection_Vec3<Standard_Real>& theBoxMin,
const NCollection_Vec3<Standard_Real>& theBoxMax,
Standard_Boolean* theInside = NULL) const
@@ -198,14 +196,12 @@ public:
}
Standard_DEPRECATED("Deprecated alias for OverlapsPoint()")
Standard_Boolean Overlaps(const gp_Pnt& thePnt, SelectBasics_PickResult& thePickResult) const
{
return OverlapsPoint(thePnt, thePickResult);
}
Standard_DEPRECATED("Deprecated alias for OverlapsPoint()")
Standard_Boolean Overlaps(const gp_Pnt& thePnt) const { return OverlapsPoint(thePnt); }
Standard_DEPRECATED("Deprecated alias for OverlapsPolygon()")
@@ -214,7 +210,6 @@ public:
SelectBasics_PickResult& thePickResult) const;
Standard_DEPRECATED("Deprecated alias for OverlapsPolygon()")
Standard_Boolean Overlaps(const TColgp_Array1OfPnt& theArrayOfPts,
Standard_Integer theSensType,
SelectBasics_PickResult& thePickResult) const
@@ -223,7 +218,6 @@ public:
}
Standard_DEPRECATED("Deprecated alias for OverlapsSegment()")
Standard_Boolean Overlaps(const gp_Pnt& thePnt1,
const gp_Pnt& thePnt2,
SelectBasics_PickResult& thePickResult) const
@@ -232,7 +226,6 @@ public:
}
Standard_DEPRECATED("Deprecated alias for OverlapsTriangle()")
Standard_Boolean Overlaps(const gp_Pnt& thePnt1,
const gp_Pnt& thePnt2,
const gp_Pnt& thePnt3,

View File

@@ -160,7 +160,6 @@ public:
//! Returns selection state.
Standard_DEPRECATED("Deprecated method - IsSelected() should be used instead")
Standard_Integer State() const { return myIsSelected ? 1 : 0; }
//! Set the state of the owner.
@@ -215,12 +214,10 @@ public:
public:
//! Sets the selectable object.
Standard_DEPRECATED("Deprecated method - SetSelectable() should be used instead")
void Set(const Handle(SelectMgr_SelectableObject)& theSelObj) { SetSelectable(theSelObj); }
//! sets the selectable priority of the owner
Standard_DEPRECATED("Deprecated method - SetPriority() should be used instead")
void Set(const Standard_Integer thePriority) { SetPriority(thePriority); }
protected:

View File

@@ -1129,21 +1129,17 @@ public: //! @name deprecated methods
//! initializes an iteration on the active Lights.
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
void InitActiveLights() { myActiveLightsIterator.Initialize(myActiveLights); }
//! returns true if there are more active Light(s) to return.
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
Standard_Boolean MoreActiveLights() const { return myActiveLightsIterator.More(); }
//! Go to the next active Light (if there is not, ActiveLight will raise an exception)
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
void NextActiveLights() { myActiveLightsIterator.Next(); }
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
const Handle(V3d_Light)& ActiveLight() const { return myActiveLightsIterator.Value(); }
protected:

View File

@@ -453,22 +453,18 @@ public: //! @name grid management
public: //! @name deprecated methods
//! Returns Standard_True if a grid is activated in <me>.
Standard_DEPRECATED("Deprecated method - IsGridActive() should be used instead")
Standard_Boolean IsActive() { return IsGridActive(); }
//! Initializes an internal iterator on the active views.
Standard_DEPRECATED("Deprecated method - ActiveViews() should be used instead")
void InitActiveViews() { myActiveViewsIterator.Initialize(myActiveViews); }
//! Returns true if there are more active view(s) to return.
Standard_DEPRECATED("Deprecated method - ActiveViews() should be used instead")
Standard_Boolean MoreActiveViews() const { return myActiveViewsIterator.More(); }
//! Go to the next active view (if there is not, ActiveView will raise an exception)
Standard_DEPRECATED("Deprecated method - ActiveViews() should be used instead")
void NextActiveViews()
{
if (!myActiveViews.IsEmpty())
@@ -476,22 +472,18 @@ public: //! @name deprecated methods
}
Standard_DEPRECATED("Deprecated method - ActiveViews() should be used instead")
const Handle(V3d_View)& ActiveView() const { return myActiveViewsIterator.Value(); }
//! Initializes an internal iterator on the Defined views.
Standard_DEPRECATED("Deprecated method - DefinedViews() should be used instead")
void InitDefinedViews() { myDefinedViewsIterator.Initialize(myDefinedViews); }
//! returns true if there are more Defined view(s) to return.
Standard_DEPRECATED("Deprecated method - DefinedViews() should be used instead")
Standard_Boolean MoreDefinedViews() const { return myDefinedViewsIterator.More(); }
//! Go to the next Defined view (if there is not, DefinedView will raise an exception)
Standard_DEPRECATED("Deprecated method - DefinedViews() should be used instead")
void NextDefinedViews()
{
if (!myDefinedViews.IsEmpty())
@@ -499,41 +491,33 @@ public: //! @name deprecated methods
}
Standard_DEPRECATED("Deprecated method - DefinedViews() should be used instead")
const Handle(V3d_View)& DefinedView() const { return myDefinedViewsIterator.Value(); }
//! Initializes an internal iteratator on the active Lights.
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
void InitActiveLights() { myActiveLightsIterator.Initialize(myActiveLights); }
//! returns true if there are more active Light(s) to return.
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
Standard_Boolean MoreActiveLights() const { return myActiveLightsIterator.More(); }
//! Go to the next active Light (if there is not, ActiveLight() will raise an exception)
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
void NextActiveLights() { myActiveLightsIterator.Next(); }
Standard_DEPRECATED("Deprecated method - ActiveLights() should be used instead")
const Handle(V3d_Light)& ActiveLight() const { return myActiveLightsIterator.Value(); }
//! Initializes an internal iterattor on the Defined Lights.
Standard_DEPRECATED("Deprecated method - DefinedLights() should be used instead")
void InitDefinedLights() { myDefinedLightsIterator.Initialize(myDefinedLights); }
//! Returns true if there are more Defined Light(s) to return.
Standard_DEPRECATED("Deprecated method - DefinedLights() should be used instead")
Standard_Boolean MoreDefinedLights() const { return myDefinedLightsIterator.More(); }
//! Go to the next Defined Light (if there is not, DefinedLight() will raise an exception)
Standard_DEPRECATED("Deprecated method - DefinedLights() should be used instead")
void NextDefinedLights()
{
if (!myDefinedLights.IsEmpty())
@@ -541,7 +525,6 @@ public: //! @name deprecated methods
}
Standard_DEPRECATED("Deprecated method - DefinedLights() should be used instead")
const Handle(V3d_Light)& DefinedLight() const { return myDefinedLightsIterator.Value(); }
//! Dumps the content of me into the stream