Class PdfLoadedTextMarkupAnnotation
Represents the loaded text markup annotation class.
Inheritance
System.Object
PdfLoadedTextMarkupAnnotation
Implements
System.ComponentModel.INotifyPropertyChanged
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Syncfusion.Pdf.Interactive
Assembly: Syncfusion.Pdf.Base.dll
Syntax
public class PdfLoadedTextMarkupAnnotation : PdfLoadedStyledAnnotation, IPdfWrapper, INotifyPropertyChanged
Examples
//Load an existing document.
PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf");
//Gets the annotation from loaded document.
PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation;
//Sets the PDF text markup annotation type
textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight
//Sets the text markup color
textMarkupAnnotation.TextMarkupColor=new PdfColor(Color.Blue);
//Save the document.
document.Save("TextMarkupAnnotation.pdf");
document.Close(true);
'Load an existing document.
Dim document As New PdfLoadedDocument("..\..\Annotations.pdf")
'Gets the annotation from loaded document.
Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation
'Sets the PDF text markup annotation type
textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight
'Sets the text markup color
textMarkupAnnotation.TextMarkupColor=New PdfColor(Color.Blue)
'Save the document.
document.Save("TextMarkupAnnotation.pdf")
document.Close(True)
Properties
BoundsCollection
Declaration
public List<RectangleF> BoundsCollection { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.List<System.Drawing.RectangleF> |
Comments
Gets the annotation comments history.
Declaration
public PdfLoadedPopupAnnotationCollection Comments { get; }
Property Value
Type | Description |
---|---|
PdfLoadedPopupAnnotationCollection | The Comments collection of the text markup annotation. |
Examples
//Load an existing document.
PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf");
//Load the existing PdfTextMarkupAnnotation
PdfLoadedTextMarkupAnnotation markup = document.Pages[0].Annotations[0] as PdfLoadedTextMarkupAnnotation;
//Get the comments collection
PdfLoadedPopupAnnotationCollection commentsCollection = markup.Comments;
//save the document
document.Save("TextMarkupAnnotation.pdf");
//Close the docuemnt
document.Close(true);
'Load an existing document.
Dim document As New PdfLoadedDocument("..\..\Annotations.pdf")
'Load the existing PdfTextMarkupAnnotation
Dim markup As PdfLoadedTextMarkupAnnotation = document.Pages(0).Annotations(0)
'Get the comments collection
Dim commentsCollection As PdfLoadedPopupAnnotationCollection = markup.Comments
Next
'save the document
document.Save("TextMarkupAnnotation.pdf")
'Close the document.
document.Close(True)
See Also
ReviewHistory
Gets the annotation review history.
Declaration
public PdfLoadedPopupAnnotationCollection ReviewHistory { get; }
Property Value
Type | Description |
---|---|
PdfLoadedPopupAnnotationCollection | The review history collection of the text markup annotation. |
Examples
//Load an existing document.
PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf");
//Load the existing PdfTextMarkupAnnotation
PdfLoadedTextMarkupAnnotation markup = document.Pages[0].Annotations[0] as PdfLoadedTextMarkupAnnotation;
//Get the review collection
PdfLoadedPopupAnnotationCollection reviewCollection = markup.ReviewHistory;
//save the document
document.Save("TextMarkupAnnotation.pdf");
//Close the docuemnt
document.Close(true);
'Load an existing document.
Dim document As New PdfLoadedDocument("..\..\Annotations.pdf")
'Load the existing PdfTextMarkupAnnotation
Dim markup As PdfLoadedTextMarkupAnnotation = document.Pages(0).Annotations(0)
'Get the review collection
Dim reviewCollection As PdfLoadedPopupAnnotationCollection = markup.ReviewHistory
Next
'save the document
document.Save("TextMarkupAnnotation.pdf")
'Close the document.
document.Close(True)
See Also
TextMarkupAnnotationType
Gets or sets the markup annotation Type.
Declaration
public PdfTextMarkupAnnotationType TextMarkupAnnotationType { get; set; }
Property Value
Type | Description |
---|---|
PdfTextMarkupAnnotationType |
Examples
//Load an existing document.
PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf");
//Gets the annotation from loaded document.
PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation;
//Sets the PDF text markup annotation type
textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight
//Save the document.
document.Save("TextMarkupAnnotation.pdf");
document.Close(true);
'Load an existing document.
Dim document As New PdfLoadedDocument("..\..\Annotations.pdf")
'Gets the annotation from loaded document.
Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation
'Sets the PDF text markup annotation type
textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight
'Save the document.
document.Save("TextMarkupAnnotation.pdf")
document.Close(True)
TextMarkupColor
Gets or sets the markup color
Declaration
public PdfColor TextMarkupColor { get; set; }
Property Value
Type | Description |
---|---|
PdfColor |
Examples
//Load an existing document.
PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf");
//Gets the annotation from loaded document.
PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation;
//Sets the text markup color
textMarkupAnnotation.TextMarkupColor=new PdfColor(Color.Blue);
//Save the document.
document.Save("TextMarkupAnnotation.pdf");
document.Close(true);
'Load an existing document.
Dim document As New PdfLoadedDocument("..\..\Annotations.pdf")
'Gets the annotation from loaded document.
Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation
'Sets the text markup color
textMarkupAnnotation.TextMarkupColor=New PdfColor(Color.Blue)
'Save the document.
document.Save("TextMarkupAnnotation.pdf")
document.Close(True)
Methods
Save()
Saves an annotation .
Declaration
protected override void Save()
Overrides
SetTitleText(String)
Sets the name of the field.
Declaration
public void SetTitleText(string text)
Parameters
Type | Name | Description |
---|---|---|
System.String | text |
Implements
System.ComponentModel.INotifyPropertyChanged