CFx SDK Documentation  2020SP3
DbLeader.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2017, Open Design Alliance (the "Alliance").
3 // All rights reserved.
4 //
5 // This software and its documentation and related materials are owned by
6 // the Alliance. The software may only be incorporated into application
7 // programs owned by members of the Alliance, subject to a signed
8 // Membership Agreement and Supplemental Software License Agreement with the
9 // Alliance. The structure and organization of this software are the valuable
10 // trade secrets of the Alliance and its suppliers. The software is also
11 // protected by copyright law and international treaty provisions. Application
12 // programs incorporating this software must include the following statement
13 // with their copyright notices:
14 //
15 // This application incorporates Teigha(R) software pursuant to a license
16 // agreement with Open Design Alliance.
17 // Teigha(R) Copyright (C) 2002-2017 by Open Design Alliance.
18 // All rights reserved.
19 //
20 // By use of this software, its documentation or related materials, you
21 // acknowledge and accept the above terms.
23 
24 
25 
26 
27 #ifndef OD_DBLEOD_H
28 #define OD_DBLEOD_H 1
29 
30 #include "TD_PackPush.h"
31 
32 #include "DbCurve.h"
33 #include "DbDimStyleTableRecord.h"
34 
41 {
42 public:
44 
46 
50  virtual OdGeVector3d normal() const;
51 
55  virtual int numVertices() const;
56 
71  virtual bool appendVertex(
72  const OdGePoint3d& vertex);
73 
77  virtual void removeLastVertex();
78 
82  virtual OdGePoint3d firstVertex() const;
83 
87  virtual OdGePoint3d lastVertex() const;
88 
94  int vertexIndex) const;
95 
105  virtual bool setVertexAt(
106  int vertexIndex,
107  const OdGePoint3d& vertex);
108 
112  bool isArrowHeadEnabled() const;
113 
120  virtual bool hasArrowHead() const;
121 
125  virtual void enableArrowHead();
126 
130  virtual void disableArrowHead();
131 
135  virtual bool hasHookLine() const;
136 
141  virtual bool isHookLineOnXDir() const;
142 
146  virtual void setToSplineLeader();
147 
151  virtual void setToStraightLeader();
152 
156  virtual bool isSplined() const;
157 
162 
168  virtual void setDimensionStyle(
169  const OdDbHardPointerId& dimStyleId);
170 
190  virtual void attachAnnotation(
191  OdDbObjectId annoId);
192 
217  virtual void attachAnnotation(
218  OdDbObjectId annoId,
219  OdGeVector3d xDir,
220  double annotationWidth,
221  double annotationHeight,
222  bool hookLineOnXDir);
223 
228  virtual void detachAnnotation();
229 
233  virtual OdDbObjectId annotationObjId() const;
234 
238  virtual OdGeVector3d annotationXDir() const;
239 
259 
279  virtual void setAnnotationOffset(
280  const OdGeVector3d& offset);
281 
286  enum AnnoType
287  {
288  kMText = 0, // OdDbMText
289  kFcf = 1, // OdDbFcf
290  kBlockRef = 2, // OdDbBlockReference.
291  kNoAnno = 3 // No annotation.
292  //FELIX_CHANGE_BEGIN
293  , kText = 4 // OdDbText
294  //FELIX_CHANGE_END
295  };
296 
312 
316  double annoHeight() const;
317 
321  double annoWidth() const;
322 
333  virtual double dimasz() const;
334 
345  virtual OdCmColor dimclrd() const;
346 
362  virtual double dimgap() const;
363 
374  virtual OdDb::LineWeight dimlwd() const;
375 
388  virtual OdDbObjectId dimldrblk() const;
389 
406  virtual bool dimsah() const;
407 
428  virtual double dimscale() const;
429 
448  virtual int dimtad() const;
449 
460  virtual OdDbObjectId dimtxsty() const;
461 
472  virtual double dimtxt() const;
473 
480  virtual void setDimasz(
481  double val);
482 
489  virtual void setDimclrd(
490  const OdCmColor& val);
491 
503  virtual void setDimgap(
504  double val);
505 
514  virtual void setDimldrblk(
515  OdDbObjectId val);
516  virtual void setDimldrblk(
517  const OdString& val);
518 
525  virtual void setDimlwd(
526  OdDb::LineWeight val);
527 
540  virtual void setDimsah(
541  bool val);
542 
559  virtual void setDimscale(
560  double val);
561 
576  virtual void setDimtad(
577  int val);
578 
585  virtual void setDimtxsty(
586  OdDbObjectId val);
587 
594  virtual void setDimtxt(
595  double val);
596 
598  void* pClsid) const;
599 
601  OdDbDwgFiler* pFiler);
602 
603  virtual void dwgOutFields(
604  OdDbDwgFiler* pFiler) const;
605 
607  OdDbDxfFiler* pFiler);
608 
609  virtual void dxfOutFields(
610  OdDbDxfFiler* pFiler) const;
611 
612  virtual bool subWorldDraw(
613  OdGiWorldDraw* pWd) const ODRX_OVERRIDE;
614 
616  OdGiViewportDraw* pVd) const ODRX_OVERRIDE;
617 
619  OdRxObjectPtrArray& entitySet) const ODRX_OVERRIDE;
620 
621  virtual void subClose() ODRX_OVERRIDE;
622 
623  virtual OdUInt32 subSetAttributes(
624  OdGiDrawableTraits* pTraits) const ODRX_OVERRIDE;
625 
626  virtual bool isPlanar() const;
627 
628  virtual OdResult getPlane(
629  OdGePlane& plane,
630  OdDb::Planarity& planarity) const;
631 
632  virtual bool isClosed() const;
633 
634  virtual bool isPeriodic() const;
635 
636  virtual OdResult getStartParam(
637  double& startParam) const;
638 
639  virtual OdResult getEndParam (
640  double& endParam) const;
641 
642  virtual OdResult getStartPoint(
643  OdGePoint3d& startPoint) const;
644 
645  virtual OdResult getEndPoint(
646  OdGePoint3d& endPoint) const;
647 
648  virtual OdResult getPointAtParam(
649  double param,
650  OdGePoint3d& pointOnCurve) const ODRX_OVERRIDE;
651 
652  virtual OdResult getParamAtPoint(
653  const OdGePoint3d& pointOnCurve,
654  double& param) const ODRX_OVERRIDE;
655 
656  virtual OdResult subTransformBy(
657  const OdGeMatrix3d& xfm) ODRX_OVERRIDE;
658 
659  virtual OdResult subGetTransformedCopy(
660  const OdGeMatrix3d& xform,
661  OdDbEntityPtr& pEnt) const ODRX_OVERRIDE;
662 
663  virtual OdResult getDistAtParam( double param, double& dist ) const;
664 
665  virtual OdResult getParamAtDist( double dist, double& param ) const;
666 
667  virtual OdResult getFirstDeriv (
668  double param,
669  OdGeVector3d& firstDeriv) const;
670 
671  virtual OdResult getSecondDeriv (
672  double param,
673  OdGeVector3d& secondDeriv) const;
674 
675  virtual OdResult getArea(
676  double& area) const;
677 
678  TD_USING(OdDbCurve::getFirstDeriv);
679  TD_USING(OdDbCurve::getSecondDeriv);
680 
685  void subSetDatabaseDefaults(
686  OdDbDatabase *pDb,
687  bool doSubents);
688 
693  virtual OdResult evaluateLeader();
694 
695 
699  virtual void modifiedGraphics(
700  const OdDbObject* pObject);
701 
702  virtual void erased(
703  const OdDbObject* pObject,
704  bool erasing = true);
705 
715  void getDimstyleData(
716  OdDbDimStyleTableRecord *pRecord) const;
717 
728  void setDimstyleData(
729  const OdDbDimStyleTableRecord* pDimstyle);
730  void setDimstyleData(
731  OdDbObjectId dimstyleID);
732 
741  virtual void setPlane(
742  const OdGePlane& leaderPlane);
743 
744  OdResult subGetSubentPathsAtGsMarker( OdDb::SubentType type,
745  OdGsMarker gsMark,
746  const OdGePoint3d& ,
747  const OdGeMatrix3d& ,
748  OdDbFullSubentPathArray& subentPaths,
749  const OdDbObjectIdArray* pEntAndInsertStack ) const;
750  OdResult subGetGsMarkersAtSubentPath( const OdDbFullSubentPath& subPath,
751  OdGsMarkerArray& gsMarkers) const;
752 
753  enum gsMarkType {
754  kArrowMark = 3,
755  kLeaderLineMark = kArrowMark + 1
756  };
757 };
762 
763 #include "TD_PackPop.h"
764 
765 #endif
766 
OdDbLeader::dimtad
virtual int dimtad() const
OdResult
OdResult
Definition: OdResult.h:29
OdDbLeader::isArrowHeadEnabled
bool isArrowHeadEnabled() const
OdGePlane
Definition: GePlane.h:45
OdGeVector3d
Definition: GeVector3d.h:54
OdString
Definition: OdString.h:95
OdDbDatabase
Definition: DbDatabase.h:421
OdDbLeader::dimtxt
virtual double dimtxt() const
OdDbLeader::enableArrowHead
virtual void enableArrowHead()
OdDbDimStyleTableRecord
Definition: DbDimStyleTableRecord.h:316
OdDbLeader::setVertexAt
virtual bool setVertexAt(int vertexIndex, const OdGePoint3d &vertex)
OdDb::Planarity
Planarity
Definition: DbEntity.h:74
OdDbLeaderPtr
OdSmartPtr< OdDbLeader > OdDbLeaderPtr
Definition: DbLeader.h:761
OdDbLeader::annotationObjId
virtual OdDbObjectId annotationObjId() const
OdDbLeader::dimsah
virtual bool dimsah() const
OdDbLeader::annoWidth
double annoWidth() const
OdDbLeader::normal
virtual OdGeVector3d normal() const
type
GLuint GLsizei GLsizei GLint GLenum * type
Definition: gles2_ext.h:274
OdDbLeader::dimldrblk
virtual OdDbObjectId dimldrblk() const
OdDbLeader::setDimensionStyle
virtual void setDimensionStyle(const OdDbHardPointerId &dimStyleId)
OdDbObjectId
Definition: DbObjectId.h:99
OdDbLeader::setDimldrblk
virtual void setDimldrblk(OdDbObjectId val)
OdDbFullSubentPath
Definition: DbSubentId.h:49
OdDbLeader
Definition: DbLeader.h:41
OdDbLeader::AnnoType
AnnoType
Definition: DbLeader.h:287
OdDbLeader::lastVertex
virtual OdGePoint3d lastVertex() const
TD_USING
#define TD_USING(a)
Definition: OdPlatform.h:597
OdArray< OdRxObjectPtr >
OdDbLeader::annotationOffset
virtual OdGeVector3d annotationOffset() const
OdDbLeader::dimlwd
virtual OdDb::LineWeight dimlwd() const
OdDbLeader::setDimldrblk
virtual void setDimldrblk(const OdString &val)
TD_PackPop.h
OdGsMarker
ptrdiff_t OdGsMarker
Definition: OdPlatformSettings.h:889
OdDbLeader::dwgOutFields
virtual void dwgOutFields(OdDbDwgFiler *pFiler) const
OdUInt32
unsigned int OdUInt32
Definition: OdPlatformSettings.h:783
OdGeMatrix3d
Definition: GeMatrix3d.h:73
OdDbLeader::setDimclrd
virtual void setDimclrd(const OdCmColor &val)
ODRX_SEALED_VIRTUAL
#define ODRX_SEALED_VIRTUAL
Definition: OdPlatformSettings.h:119
OdDbLeader::annoHeight
double annoHeight() const
OdDbLeader::annoType
AnnoType annoType() const
OdDbLeader::isSplined
virtual bool isSplined() const
OdDbLeader::attachAnnotation
virtual void attachAnnotation(OdDbObjectId annoId, OdGeVector3d xDir, double annotationWidth, double annotationHeight, bool hookLineOnXDir)
OdDbLeader::attachAnnotation
virtual void attachAnnotation(OdDbObjectId annoId)
OdDbLeader::subWorldDraw
virtual bool subWorldDraw(OdGiWorldDraw *pWd) const ODRX_OVERRIDE
OdDbLeader::removeLastVertex
virtual void removeLastVertex()
OdDbLeader::setDimscale
virtual void setDimscale(double val)
OdSmartPtr< OdDbEntity >
OdGePoint3d
Definition: GePoint3d.h:55
offset
GLintptr offset
Definition: gles2_ext.h:183
DbCurve.h
OdDbLeader::setDimgap
virtual void setDimgap(double val)
true
true
Definition: DimVarDefs.h:2046
OdDbLeader::hasHookLine
virtual bool hasHookLine() const
OdDbLeader::setDimsah
virtual void setDimsah(bool val)
OdDbLeader::dxfInFields
virtual OdResult dxfInFields(OdDbDxfFiler *pFiler)
OdDbHardPointerId
Definition: DbObjectId.h:453
OdDbLeader::setDimtxsty
virtual void setDimtxsty(OdDbObjectId val)
OdDbLeader::hasArrowHead
virtual bool hasArrowHead() const
OdDbLeader::dwgInFields
virtual OdResult dwgInFields(OdDbDwgFiler *pFiler)
OdDbDxfFiler
Definition: DbFiler.h:194
TD_PackPush.h
OdDbLeader::dimtxsty
virtual OdDbObjectId dimtxsty() const
OdDbLeader::isHookLineOnXDir
virtual bool isHookLineOnXDir() const
OdDbLeader::dimasz
virtual double dimasz() const
OdDbLeader::subExplode
virtual OdResult subExplode(OdRxObjectPtrArray &entitySet) const ODRX_OVERRIDE
OdDbLeader::dxfOutFields
virtual void dxfOutFields(OdDbDxfFiler *pFiler) const
OdGiWorldDraw
Definition: GiWorldDraw.h:44
OdDbLeader::OdDbLeader
OdDbLeader()
OdDbLeader::appendVertex
virtual bool appendVertex(const OdGePoint3d &vertex)
OdDbLeader::dimclrd
virtual OdCmColor dimclrd() const
OdDbLeader::subClose
virtual void subClose() ODRX_OVERRIDE
OdDbLeader::ODDB_DECLARE_MEMBERS
ODDB_DECLARE_MEMBERS(OdDbLeader)
OdGiDrawableTraits
Definition: Gi.h:71
OdDbCurve
Definition: DbCurve.h:53
OdDbLeader::firstVertex
virtual OdGePoint3d firstVertex() const
OdDbLeader::setToStraightLeader
virtual void setToStraightLeader()
OdDbLeader::setDimtxt
virtual void setDimtxt(double val)
OdDb::LineWeight
LineWeight
Definition: OdaDefs.h:382
DbDimStyleTableRecord.h
OdDbLeader::detachAnnotation
virtual void detachAnnotation()
OdDb
Definition: Db2dPolyline.h:50
OdDbLeader::numVertices
virtual int numVertices() const
OdDbLeader::setDimtad
virtual void setDimtad(int val)
OdDbLeader::gsMarkType
gsMarkType
Definition: DbLeader.h:753
TOOLKIT_EXPORT
#define TOOLKIT_EXPORT
Definition: DbExport.h:40
ODRX_OVERRIDE
#define ODRX_OVERRIDE
Definition: OdPlatformSettings.h:114
OdDbLeader::setDimasz
virtual void setDimasz(double val)
OdDbLeader::vertexAt
virtual OdGePoint3d vertexAt(int vertexIndex) const
SubentType
SubentType
Definition: DbManagerSubentData.h:38
OdDbLeader::dimscale
virtual double dimscale() const
OdDbLeader::disableArrowHead
virtual void disableArrowHead()
OdDbLeader::setAnnotationOffset
virtual void setAnnotationOffset(const OdGeVector3d &offset)
OdDbLeader::subGetClassID
virtual OdResult subGetClassID(void *pClsid) const
OdDbLeader::annotationXDir
virtual OdGeVector3d annotationXDir() const
OdDbLeader::dimgap
virtual double dimgap() const
OdCmColor
Definition: CmColor.h:59
OdDbLeader::subViewportDraw
ODRX_SEALED_VIRTUAL void subViewportDraw(OdGiViewportDraw *pVd) const ODRX_OVERRIDE
OdDbLeader::setDimlwd
virtual void setDimlwd(OdDb::LineWeight val)
OdDbObject
Definition: DbObject.h:211
OdDbDwgFiler
Definition: DbFiler.h:1031
OdGiViewportDraw
Definition: GiViewportDraw.h:50
OdDbLeader::setToSplineLeader
virtual void setToSplineLeader()
OdDbLeader::dimensionStyle
virtual OdDbHardPointerId dimensionStyle() const
kText
@ kText
Definition: GiGeomEntTypes2.h:39