Hello everyone, i'm working with annotation layer and annotation feature.
I added an annotation feature to annotation layer. Now i want to get it's precise extent. I tried inpector.GetAnnotationProperties().Shape, but it returns a MapPoint, not the boundary of text. If i use inspector["Shape"] or inspector.GeometryAttribute.CurrentValue, it returns a polygon, but not exactly bound the text, like in image below:
9150b64a415bcb05924a.jpg
My question is, how to get annotation feature boundary, exactly cover the text, like this image
77bc59f0c3e149bf10f0.jpg
Solved! Go to Solution.
See GetDrawingOutline on the AnnotationLayer (inherited from BasicFeatureLayer) which has options for how detailed of a shape you'd like.
Have you tried the CIMTextGraphic.Shape ?
Yes, it returns a MapPoint. I also tried AnnotationFeature.GetGraphicOutline(), but it returns same polygon as inspector["Shape"].
See GetDrawingOutline on the AnnotationLayer (inherited from BasicFeatureLayer) which has options for how detailed of a shape you'd like.
It works perfectly. Thank you very much.