PdfAnnotation class sealed
Base class for all PDF annotation types.
Use a switch expression on the concrete subtype to access type-specific
fields:
switch (annotation) {
PdfMarkupAnnotation(:final quadPoints, :final color) => ...,
PdfLinkAnnotation(:final uri) => ...,
_ => ...,
}
Common fields
Every annotation carries pageIndex, flags, and optionally rect, color, contents, author, and modifiedDate. Type-specific fields live only on the appropriate subclass.
Coordinate system
rect is in raw PDF page coordinates (bottom-left origin). Callers that
need screen coordinates must apply FPDF_PageToDevice() themselves.
Properties
-
The annotation author (
/Tdictionary entry), ornullif absent.final - color → PdfColor?
-
The annotation colour, or
nullif no colour entry is present.final - contents → String?
-
The annotation's
Contentsstring, ornullif absent.final - flags → int
-
Raw
FPDF_ANNOT_FLAG_*bitmask.final - hashCode → int
-
The hash code for this object.
no setterinherited
- modifiedDate → PdfDate?
-
The last-modified date (
/Mdictionary entry), ornullif absent.final - pageIndex → int
-
Zero-based index of the page this annotation belongs to.
final
- popup → PdfPopupAnnotation?
-
Inlined popup annotation data, or
nullif this annotation has no popup.final - rect → PdfRect?
-
The bounding rectangle in PDF page coordinates, or
nullif unavailable.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited