Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

PdfAnnotation

OfficeIMO.Pdf

Namespace
OfficeIMO.Pdf
Assembly
OfficeIMO.Pdf
Source revision
be6c300e4ab1 with working tree changes
Modifiers
sealed

Generic page annotation metadata read from a PDF page.

Inheritance

  • object
  • PdfAnnotation

Remarks

Native page coordinates use default user-space units: one unit is /UserUnit physical points (1/72 inch each), defaulting to 1. Local text/font and matrix values retain their native coordinate spaces. Explicit visual projections use their documented coordinates.

Usage

Explore 15 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 4

Properties

public int? ObjectNumber { get; } #

Indirect annotation object number, when the annotation is referenced indirectly.

public int? PageNumber { get; } #

One-based page number when known.

public string Subtype { get; } #

PDF annotation subtype name, for example Link, Text, FreeText, or Highlight.

public string? Contents { get; } #

Optional annotation contents metadata from /Contents.

public double X1 { get; } #

Left edge of the annotation rectangle in page user-space units.

public double Y1 { get; } #

Bottom edge of the annotation rectangle in page user-space units.

public double X2 { get; } #

Right edge of the annotation rectangle in page user-space units.

public double Y2 { get; } #

Top edge of the annotation rectangle in page user-space units.

public double Width { get; } #

Rectangle width in page user-space units.

public double Height { get; } #

Rectangle height in page user-space units.

public bool HasNormalAppearance { get; } #

True when the annotation dictionary exposes a normal appearance stream through /AP /N.

public string? AppearanceState { get; } #

Selected annotation appearance state from /AS, when present.

public string? ActionType { get; } #

Primary annotation action type from /A /S, when present.

public string? Uri { get; } #

URI target of the primary /A action when it has the URI action type and a readable valid target; otherwise null.

public IReadOnlyList<PdfAnnotationAdditionalAction> AdditionalActions { get; } #

Additional annotation actions from the /AA dictionary, when present.

public IReadOnlyList<PdfAnnotationChainedAction> ChainedActions { get; } #

Chained annotation actions discovered through /Next entries on /A or /AA action dictionaries.

public int? Flags { get; } #

Raw annotation flags from /F, when present.

public string? Name { get; } #

Annotation unique name from /NM, when present.

public string? Title { get; } #

Annotation title or author from /T, when present.

public string? Modified { get; } #

Annotation modification date string from /M, when present.

public IReadOnlyList<double> Color { get; } #

Annotation color components from /C, when readable.

public string? DefaultAppearance { get; } #

FreeText default appearance string from /DA, when present.

public string? DefaultStyle { get; } #

FreeText default style string from /DS, when present.

public string? RichContents { get; } #

FreeText rich contents string from /RC, when present.

public string? RichContentsPlainText { get; } #

Plain text extracted from FreeText /RC when rich contents are present and readable.

public double? EffectiveFontSize { get; } #

Effective FreeText font size resolved from /DA or /DS, when readable.

public OfficeColor? EffectiveTextColor { get; } #

Effective FreeText text color resolved from /DA or /DS, when readable.

public OfficeAlignment? EffectiveTextAlign { get; } #

Effective FreeText text alignment resolved from /Q or /DS, when readable.

public IReadOnlyList<double> InteriorColor { get; } #

Annotation interior color components from /IC, when readable.

public double? Opacity { get; } #

Annotation opacity from /CA, when present and valid.

public double? BorderWidth { get; } #

Annotation border width from /BS /W or /Border, when present and valid.

public string? BorderStyle { get; } #

Annotation border style resolved from /BS /S, when present.

public IReadOnlyList<double> BorderDashPattern { get; } #

Annotation border dash pattern from /BS /D, when present and valid.

public string? BorderEffectStyle { get; } #

Annotation border effect style from /BE /S, when present.

public double? BorderEffectIntensity { get; } #

Annotation border effect intensity from /BE /I, when present and valid.

public IReadOnlyList<double> RectangleDifferences { get; } #

FreeText rectangle differences from /RD as left, top, right, bottom values, when valid.

public IReadOnlyList<double> CalloutLine { get; } #

FreeText callout line coordinates from /CL, when present and valid.

public string? CalloutLineEnding { get; } #

FreeText callout line ending from /LE, when present.

public string? LineStartEnding { get; } #

Line or PolyLine start ending from /LE, when present.

public string? LineEndEnding { get; } #

Line or PolyLine end ending from /LE, when present.

public IReadOnlyList<double> QuadPoints { get; } #

Text-markup quad point coordinates from /QuadPoints, when present and valid.

public IReadOnlyList<double> LineCoordinates { get; } #

Line annotation coordinates from /L, when present and valid.

public IReadOnlyList<double> Vertices { get; } #

Polygon or PolyLine vertices from /Vertices, when present and valid.

public IReadOnlyList<IReadOnlyList<double>> InkList { get; } #

Ink annotation paths from /InkList, when present and valid.

public PdfAnnotationReviewInfo? Review { get; } #

Reply and review metadata, when the annotation defines any.

public bool HasFreeTextAppearanceMetadata { get; } #

True when the annotation exposes FreeText appearance metadata such as /DA, /DS, /RC, or /Q.

public bool HasVisualStyleMetadata { get; } #

True when the annotation exposes visual styling metadata beyond the rectangle and subtype.

public bool HasPathGeometryMetadata { get; } #

True when the annotation exposes path geometry such as /QuadPoints, /L, /Vertices, or /InkList.

public bool IsTextMarkup { get; } #

True for the text-markup subtypes Highlight, Underline, StrikeOut and Squiggly, whose /QuadPoints mark page text.

public bool HasColor { get; } #

True when the annotation has a readable color array.

public bool HasAction { get; } #

True when the annotation has a primary action dictionary.

public bool HasAdditionalActions { get; } #

True when the annotation has at least one additional action dictionary.

public bool HasChainedActions { get; } #

True when at least one chained /Next action was discovered for this annotation.

public int ChainedActionCount { get; } #

Number of chained /Next actions discovered for this annotation.

public bool IsInvisible { get; } #

True when the annotation has the PDF Invisible flag.

public bool IsHidden { get; } #

True when the annotation has the PDF Hidden flag.

public bool IsPrint { get; } #

True when the annotation has the PDF Print flag.

public bool IsNoZoom { get; } #

True when the annotation has the PDF NoZoom flag.

public bool IsNoRotate { get; } #

True when the annotation has the PDF NoRotate flag.

public bool IsNoView { get; } #

True when the annotation has the PDF NoView flag.

public bool IsReadOnly { get; } #

True when the annotation has the PDF ReadOnly flag.

public bool IsLocked { get; } #

True when the annotation has the PDF Locked flag.

public bool IsToggleNoView { get; } #

True when the annotation has the PDF ToggleNoView flag.

public bool IsLockedContents { get; } #

True when the annotation has the PDF LockedContents flag.