LEADTOOLS Support
Document
Document SDK Examples
How To: Add Dotted Dashes Within AnnStroke Annotations
#1
Posted
:
Friday, July 14, 2017 5:09:09 PM(UTC)
Groups: Registered
Posts: 119
Was thanked: 4 time(s) in 4 post(s)
Sometimes you may not want to have plain lined annotations located within your documents that you are creating and sending. With the LEADTOOLS SDK you can edit the annotations to have dotted lines and more as the border of the annotation. Inside of the
AnnStroke Class are
public properties that can be used to edit the lined borders of the annotation.
Below you will find a small code snippet that shows how to add a StrokeDashArray to your annotation:
Code:
//Create rectangle object
AnnRectangleObject rectangle = new AnnRectangleObject();
//Change border to red
rectangle.Stroke = AnnStroke.Create(AnnSolidColorBrush.Create("Red"), LeadLengthD.Create(2));
//Create dotted/dashes for the border
rectangle.Stroke.StrokeDashArray = new double[] { 3, 1 };
//Fill the rectangle to yellow
rectangle.Fill = AnnSolidColorBrush.Create("Yellow");
//Set the size of the rectangle
rectangle.Rect = new LeadRectD(100, 100, 500, 500);
Results from above code:Nick Villalobos
Developer Support Engineer
LEAD Technologies, Inc.
LEADTOOLS Support
Document
Document SDK Examples
How To: Add Dotted Dashes Within AnnStroke Annotations
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.