API Documentation > Interfaces > Interface Annotation
Interface Annotation
Description
This interface represent various type of annotations such as Dimension,Note,Symbols,SetDatumTag,Surface Finish.
Direct Known Subclasses:
User Guide References:
Methods Inherited from Interface com.ptc.wfc.wfcLayerState.LayerItem :
Methods Inherited from Interface com.ptc.pfc.pfcBase.ActionSource :
Methods Inherited from Interface com.ptc.pfc.pfcObject.Parent :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.ParameterOwner :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WParameterOwner :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.RelationOwner :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WRelationOwner :
Methods Inherited from Interface com.ptc.pfc.pfcObject.Child :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.ModelItem :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WModelItem :
Method Summary
void
Converts annotation created before Creo 4.0 or created using deprecated APIs ProGtolCreate or ProSetdatumtagCreate.
void
Displays annotation which is temporarily undisplayed byAnnotation.Undisplay(). This method must be called after making changes in an annotation.
void
DisplayInDrawing (Drawing DrawingModel, /*optional*/ View2D DrawingView, /*optional*/ ComponentPath CompPath)
Displays annotation owned by solid and shown in drawing which is temporarily undisplayed byAnnotation.Undisplay(). This method must be called after making changes in an annotation.
/*optional*/ AnnotationElement
LICENSE: 222
LICENSE: 222
boolean
Gets Security Marking option for Notes and Symbols
/*optional*/ AnnotationTextStyle
LICENSE: 222
Get textstyle information of annotation.
/*optional*/ AnnotationTextStyle
GetTextStyleInDrawing (Drawing Drawing, /*optional*/ ComponentPath CompPath, /*optional*/ View2D View)
LICENSE: 222
Get textstyle information of annotation in specified drawing.
boolean
LICENSE: 222
boolean
LICENSE: 222
boolean
IsShown ( /*optional*/ Drawing DrawingModel)
Checks if annotation is shown in owner or specified drawing.
boolean
Identifies if the annotation is created on or attached to a cross-sectional edge.
boolean
Returns if the annotation is created before Creo 4.0 or is created using deprecated APIs ProGtolCreate or ProSetdatumtagCreate and needs conversion. CallAnnotation.ConvertLegacy() only if this API returns true.
void
Rotate (double Angle)
LICENSE: 222
void
SetSecurityMarking (boolean Marking)
Gets Security Marking option for Notes and Symbols
void
LICENSE: 222
Get textstyle information of annotation.
void
SetTextStyleInDrawing (AnnotationTextStyle TextStyle, Drawing Drawing, /*optional*/ ComponentPath CompPath, /*optional*/ View2D View)
LICENSE: 222
Set textstyle information of annotation in specified drawing.
void
ShowInDrawing (View2D DrawingView, /*optional*/ ComponentPath CompPath)
Show annotation owned by solid in a drawing.
void
Undisplays annotation temporarily. This method must be called before making any changes in an annotation.
void
UndisplayInDrawing (Drawing DrawingModel, /*optional*/ ComponentPath CompPath)
Undisplays annotation owned by solid and shown in drawing temporarily. This method must be called before making any changes in an annotation.
void
Update ( /*optional*/ Drawing DrawingModel)
Updates the display of the annotation, but does not actually display it anywhere. If the annotation is not currently displayed (because its hidden by layer status or inactive geometry) the text extracted from the annotation with mode pfcDIM_DISPLAY_NUMERIC may include callout symbols instead of the text shown to the user. This method will tell Creo Parametric to update the contents of the annotation to cross-reference these callout values.
void
LICENSE: 222
Updates the attachment of the drawing annotation and makes it associative to the attachment of the annotation in the 3D model.
void
LICENSE: 222
Updates the position of the drawing annotation and makes it associative to the position of the annotation in the 3D model.
Method Detail
ShowInDrawing
void
ShowInDrawing
(View2D DrawingView, /*optional*/ ComponentPath CompPath)
Show annotation owned by solid in a drawing.
Exceptions thrown (but not limited to):
XToolkitNoChange - The annotation is already shown in the target model.
XToolkitInvalidMatrix - The annotation cannot be shown due to orientation conflicts in the view.
XToolkitNoLicense - License check failure.
XToolkitNotDisplayed - Annotation is present on hidden or blank layer and so can't be shown.
User Guide References:
Parameters:
DrawingView
A drawing view where annotation will be shown.
CompPath
Component path for solid owner.
Returns:
Display
void
Display
()
Displays annotation which is temporarily undisplayed by Annotation.Undisplay(). This method must be called after making changes in an annotation.
Exceptions thrown (but not limited to):
XToolkitInvalidMatrix - The annotation cannot be shown due to orientation conflicts in theview.
XToolkitNoLicense - License check failure.
XToolkitNotDisplayed - Annotation is present on hidden or blank layer and so can't be shown.
User Guide References:
Returns:
DisplayInDrawing
void
DisplayInDrawing
(Drawing DrawingModel, /*optional*/ View2D DrawingView, /*optional*/ ComponentPath CompPath)
Displays annotation owned by solid and shown in drawing which is temporarily undisplayed by Annotation.Undisplay(). This method must be called after making changes in an annotation.
Exceptions thrown (but not limited to):
XToolkitInvalidMatrix - The annotation cannot be shown due to orientation conflicts in theview.
XToolkitNoLicense - License check failure.
XToolkitNotDisplayed - Annotation is present on hidden or blank layer and so can't be shown.
User Guide References:
Parameters:
DrawingModel
Drawing where annotation is shown.
DrawingView
Drawing view where annotation is temporarily displayed. Pass null to toggle in existing view.
CompPath
Component path of solid owner.
Returns:
Undisplay
void
Undisplay
()
Undisplays annotation temporarily. This method must be called before making any changes in an annotation.
Exceptions thrown (but not limited to):
XToolkitNoLicense - License check failure.
User Guide References:
Returns:
UndisplayInDrawing
void
UndisplayInDrawing
(Drawing DrawingModel, /*optional*/ ComponentPath CompPath)
Undisplays annotation owned by solid and shown in drawing temporarily. This method must be called before making any changes in an annotation.
Exceptions thrown (but not limited to):
XToolkitNoLicense - License check failure.
User Guide References:
Parameters:
DrawingModel
Drawing view where annotation is shown.
CompPath
Component path of solid owner.
Returns:
IsShown
boolean
IsShown
( /*optional*/ Drawing DrawingModel)
Checks if annotation is shown in owner or specified drawing.
Exceptions thrown (but not limited to):
XToolkitNoLicense - License check failure.
Parameters:
DrawingModel
Drawing.
Returns:
Update
void
Update
( /*optional*/ Drawing DrawingModel)
Updates the display of the annotation, but does not actually display it anywhere. If the annotation is not currently displayed (because its hidden by layer status or inactive geometry) the text extracted from the annotation with mode pfcDIM_DISPLAY_NUMERIC may include callout symbols instead of the text shown to the user. This method will tell Creo Parametric to update the contents of the annotation to cross-reference these callout values.
This method currently supports '3D model notes' and 'detail notes' only.
User Guide References:
Parameters:
DrawingModel
The drawing where it is to be displayed. Pass null if the owner of the annotation is the same as the model where it would be displayed.
Returns:
GetTextStyle
/*optional*/ AnnotationTextStyle
GetTextStyle
()
Get textstyle information of annotation.
Exceptions thrown (but not limited to):
XToolkitNotFound - No shown version of annotation was found in the drawing
XToolkitAmbiguous - Multiple shown versions of the annotation were found with different text styles.
User Guide References:
Returns:
TextStyle.
SetTextStyle
void
SetTextStyle
(AnnotationTextStyle TextStyle)
Get textstyle information of annotation.
Exceptions thrown (but not limited to):
XToolkitNotFound - No shown version of annotation was found in the drawing
User Guide References:
Parameters:
TextStyle
TextStyle
Returns:
GetTextStyleInDrawing
/*optional*/ AnnotationTextStyle
GetTextStyleInDrawing
(Drawing Drawing, /*optional*/ ComponentPath CompPath, /*optional*/ View2D View)
Get textstyle information of annotation in specified drawing.
Exceptions thrown (but not limited to):
XToolkitNotFound - No shown version of annotation was found in the drawing
XToolkitAmbiguous - Multiple shown versions of the annotation were found with different text styles.
User Guide References:
Parameters:
Drawing
Drawing.
CompPath
Component path of owner solid.
View
Reserved for future expansion. Pass null.
Returns:
TextStyle
SetTextStyleInDrawing
void
SetTextStyleInDrawing
(AnnotationTextStyle TextStyle, Drawing Drawing, /*optional*/ ComponentPath CompPath, /*optional*/ View2D View)
Set textstyle information of annotation in specified drawing.
Exceptions thrown (but not limited to):
XToolkitNotFound - No shown version of annotation was found in the drawing
User Guide References:
Parameters:
TextStyle
TextStyle.
Drawing
Drawing.
CompPath
Component path of owner solid.
View
Reserved for future expansion. Pass null.
Returns:
UpdateAttachment
void
UpdateAttachment
(Drawing Drawing)
Updates the attachment of the drawing annotation and makes it associative to the attachment of the annotation in the 3D model.
Exceptions thrown (but not limited to):
XToolkitNotFound - The annotation is not shown in the drawing.
User Guide References:
Parameters:
Drawing
The drawing
Returns:
UpdatePosition
void
UpdatePosition
(Drawing Drawing)
Updates the position of the drawing annotation and makes it associative to the position of the annotation in the 3D model.
Exceptions thrown (but not limited to):
XToolkitNotFound - The annotation is not shown in the drawing.
User Guide References:
Parameters:
Drawing
The drawing
Returns:
IsAssociative
boolean
IsAssociative
(Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNotFound - The annotation is not shown in the drawing.
User Guide References:
Parameters:
Drawing
Returns:
GetAttachmentAssociativity
GetAttachmentAssociativity
(Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNotFound - The annotation is not shown in the drawing.
User Guide References:
Parameters:
Drawing
Returns:
GetAnnotationElement
/*optional*/ AnnotationElement
GetAnnotationElement
()
Exceptions thrown (but not limited to):
XToolkitNotFound - The annotation is not contained in any annotation element.
XToolkitNotExist - The annotation element owner of the annotation does not exist.
User Guide References:
Returns:
IsInactive
boolean
IsInactive
()
Exceptions thrown (but not limited to):
XToolkitNoLicense - License check failure.
User Guide References:
Returns:
Rotate
void
Rotate
(double Angle)
Exceptions thrown (but not limited to):
XToolkitBadContext - The annotation does not support assigned rotation angles.
XToolkitCantWrite - Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
Angle
Returns:
ConvertLegacy
void
ConvertLegacy
()
Converts annotation created before Creo 4.0 or created using deprecated APIs ProGtolCreate or ProSetdatumtagCreate.
Exceptions thrown (but not limited to):
XToolkitNoChange - The annotation is not legacy.
User Guide References:
Returns:
NeedsConversion
boolean
NeedsConversion
()
Returns if the annotation is created before Creo 4.0 or is created using deprecated APIs ProGtolCreate or ProSetdatumtagCreate and needs conversion. Call Annotation.ConvertLegacy() only if this API returns true.
User Guide References:
Returns:
TRUE if the annotation needs conversion FALSE if the annotation is already converted
GetSecurityMarking
boolean
GetSecurityMarking
()
Gets Security Marking option for Notes and Symbols
User Guide References:
Returns:
If true then specified annotation is marked for security check
SetSecurityMarking
void
SetSecurityMarking
(boolean Marking)
Gets Security Marking option for Notes and Symbols
User Guide References:
Parameters:
Marking
True if the annotation refers a cross-section geometry.
Returns:
IsUsingXSecReference
boolean
IsUsingXSecReference
()
Identifies if the annotation is created on or attached to a cross-sectional edge.
User Guide References:
Returns:
True if the annotation refers a cross-section geometry.
Was this helpful?