1 // Created on: 1996-01-09
2 // Created by: Denis PASCAL
3 // Copyright (c) 1996-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef _DrawDim_HeaderFile
18 #define _DrawDim_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_DefineAlloc.hxx>
22 #include <Standard_Handle.hxx>
24 #include <Standard_CString.hxx>
25 #include <Draw_Interpretor.hxx>
26 #include <Standard_Boolean.hxx>
27 #include <Standard_Real.hxx>
35 class DrawDim_Dimension;
37 class DrawDim_Distance;
39 class DrawDim_PlanarDimension;
40 class DrawDim_PlanarAngle;
41 class DrawDim_PlanarDistance;
42 class DrawDim_PlanarRadius;
43 class DrawDim_PlanarDiameter;
46 //! This package provides Drawable Dimensions.
48 //! The classes PlanarDimension and subclasses provide
49 //! services to build drawable dimensions between
50 //! point line and circle in a given 3d plane.
52 //! The classes Dimension and subclasses provide
53 //! services to build drawable dimensions between
54 //! plane and cylindrical surfaces.
64 Standard_EXPORT static void DrawShapeName (const TopoDS_Shape& ashape, const Standard_CString aname);
66 Standard_EXPORT static void AllCommands (Draw_Interpretor& I);
70 Standard_EXPORT static void PlanarDimensionCommands (Draw_Interpretor& I);
72 Standard_EXPORT static gp_Pnt Nearest (const TopoDS_Shape& aShape, const gp_Pnt& apoint);
74 //! false if <e> is not a linear edge
75 Standard_EXPORT static Standard_Boolean Lin (const TopoDS_Edge& e, gp_Lin& l, Standard_Boolean& infinite, Standard_Real& first, Standard_Real& last);
77 //! false if <e> is not a circular edge
78 Standard_EXPORT static Standard_Boolean Circ (const TopoDS_Edge& e, gp_Circ& l, Standard_Real& first, Standard_Real& last);
80 //! false if <f> is not a planar face
81 Standard_EXPORT static Standard_Boolean Pln (const TopoDS_Face& f, gp_Pln& p);
97 friend class DrawDim_Dimension;
98 friend class DrawDim_Angle;
99 friend class DrawDim_Distance;
100 friend class DrawDim_Radius;
101 friend class DrawDim_PlanarDimension;
102 friend class DrawDim_PlanarAngle;
103 friend class DrawDim_PlanarDistance;
104 friend class DrawDim_PlanarRadius;
105 friend class DrawDim_PlanarDiameter;
115 #endif // _DrawDim_HeaderFile