API Reference > OdDb Classes > OdDbLeader Class > OdDbLeader Methods > attachAnnotation Method > OdDbLeader::attachAnnotation Method (OdDbObjectId, OdGeVector3d, double, double, bool)
OdDbLeader::attachAnnotation Method (OdDbObjectId, OdGeVector3d, double, double, bool)
Syntax
C++
virtual void attachAnnotation(OdDbObjectId annoId, OdGeVector3d xDir, double annotationWidth, double annotationHeight, bool hookLineOnXDir);
Parameters 
Description 
OdDbObjectId annoId 
[in] The Object ID of the annotation entity.  
OdGeVector3d xDir 
[in] WCS X-axis of the annotation entity.  
double annotationWidth 
[in] Annotation entity width.  
double annotationHeight 
[in] Annotation entity height.  
bool hookLineOnXDir 
[in] True to set hookline codirectional with the OCS X-axis of this annotation entity, or false to set it antidirectional with it. 

Sets the annotation entity of this Leader entity (DXF 340). 

 

This Leader entity is appended to the persistent reactor list of the annotation entity. 

The annotation entity must be one of, or a subclass of one of, the following 

 

Name 
Entity type 
Description 
kMText 
OdDbMText 
MText 
kFcf 
OdDbFcf 
Feature control frame (Tolerance) 
kBlockRef 
OdDbBlockReference 
Block reference 

 

Other than annoId, the parameters are usually set with evaluateLeader().

Copyright © 2002–2020. Open Design Alliance. All rights reserved.