Table of Contents

Enum PdfAnnotationIntent

Namespace
Syncfusion.Pdf.Interactive
Assembly
Syncfusion.Pdf.Portable.dll

Specifies the annotation text intent.

public enum PdfAnnotationIntent

Fields

FreeTextCallout = 0

The annotation is intended to function as a callout.

FreeTextTypeWriter = 1

The annotation is intended to function as a click-to-type or typewriter object.

None = 2

The intent is not set.

Examples

//Create a new PDF document.
PdfDocument document = new PdfDocument();
//Create a new page.
PdfPage page = document.Pages.Add();
//Create a new rectangle
RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30);
//Create a new line annotation.
PdfFreeTextAnnotation actionAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds);
//Set the text and font
actionAnnotation.MarkupText = "Text Annotation";
actionAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10);
//Set the line caption type.
actionAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout;
//Add this annotation to a new page.
page.Annotations.Add(actionAnnotation);
//Save the document to disk.
document.Save("Output.pdf");
//close the document
document.Close(true);
'Create a new PDF document.
Dim document As New PdfDocument()
'Create a new page.
Dim page As PdfPage = document.Pages.Add()
'Create a new rectangle
Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30)
'Create a new line annotation.
Dim actionAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds)
'Set the text and font
actionAnnotation.MarkupText = "Text Annotation"
actionAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10)
'Set the line caption type.
actionAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout
'Add this annotation to a new page.
page.Annotations.Add(actionAnnotation)
'Save the document to disk.
document.Save("Output.pdf")
'close the document
document.Close(True)

See Also