pdfrx_web
    Preparing search index...

    Interface PdfHighlightObject

    A highlight returned by page- or document-level loadHighlights.

    interface PdfHighlightObject {
        actorId: string | null;
        appearanceImage:
            | { height: number; pixels: Uint8Array; width: number }
            | null;
        appearanceLines: readonly string[] | null;
        appearancePaths: readonly {
            fillColor: PdfAnnotationColor | null;
            fillMode: number;
            lineCap: number;
            lineJoin: number;
            segments: readonly {
                close: boolean;
                point: PdfAnnotationPoint;
                type: "line" | "move" | "bezier";
            }[];
            stroke: boolean;
            strokeColor: PdfAnnotationColor
            | null;
            strokeWidth: number;
        }[];
        appearanceRuns: | readonly (
            readonly {
                fontFace: string
                | null;
                image?: {
                    height: number;
                    pixels: Uint8Array;
                    scale: number;
                    width: number;
                };
                text: string;
                x: number;
            }[]
        )[]
        | null;
        appearanceTextStyles: readonly {
            fillColor: PdfAnnotationColor
            | null;
            fontSize: number;
            origin: PdfAnnotationPoint;
        }[];
        author: string
        | null;
        borderWidth: number;
        color: PdfAnnotationColor | null;
        contents: string | null;
        creationDate: string | null;
        flags: number;
        fontFace: string | null;
        fontSize: number | null;
        geometry: PdfAnnotationGeometry;
        id: string;
        interiorColor: PdfAnnotationColor | null;
        linkTarget: PdfLinkTarget | null;
        modificationDate: string | null;
        pageNumber: number;
        rect: PdfRect;
        revision: number;
        subject: string | null;
        subtype: "highlight";
        text: string | null;
        textAlign: "left" | "center" | "right";
        textColor: PdfAnnotationColor | null;
        textOrientation: PdfTextOrientation;
        textVerticalAlign: "top" | "middle" | "bottom";
    }

    Hierarchy (View Summary)

    Index
    actorId: string | null

    Stable application/user id of the last editor, separate from the display author.

    appearanceImage: { height: number; pixels: Uint8Array; width: number } | null

    RGBA image extracted from the annotation's normal appearance, or null.

    appearanceLines: readonly string[] | null
    appearancePaths: readonly {
        fillColor: PdfAnnotationColor | null;
        fillMode: number;
        lineCap: number;
        lineJoin: number;
        segments: readonly {
            close: boolean;
            point: PdfAnnotationPoint;
            type: "line" | "move" | "bezier";
        }[];
        stroke: boolean;
        strokeColor: PdfAnnotationColor
        | null;
        strokeWidth: number;
    }[]

    Vector paths extracted from the annotation's normal appearance stream.

    appearanceRuns:
        | readonly (
            readonly {
                fontFace: string
                | null;
                image?: {
                    height: number;
                    pixels: Uint8Array;
                    scale: number;
                    width: number;
                };
                text: string;
                x: number;
            }[]
        )[]
        | null
    appearanceTextStyles: readonly {
        fillColor: PdfAnnotationColor | null;
        fontSize: number;
        origin: PdfAnnotationPoint;
    }[]

    Text placement/style extracted from the normal appearance stream.

    author: string | null

    /T author/title.

    borderWidth: number

    Border width in points.

    color: PdfAnnotationColor | null

    Stroke/primary color, or null when unset.

    contents: string | null

    /Contents text (e.g. a note body or free-text content).

    creationDate: string | null

    Raw PDF date string, if any.

    flags: number

    Raw FPDF_ANNOT_FLAG_* bits (see PdfAnnotationFlag).

    fontFace: string | null
    fontSize: number | null

    FreeText font size in points, or null when inferred from an existing appearance.

    Subtype-specific geometry.

    id: string

    Identifier accepted by PdfPage.updateAnnotation() and PdfPage.removeAnnotation().

    /NM is the PDF annotation dictionary's "annotation name": a PDF-standard string intended to distinguish an annotation from other annotations on the same page (ISO 32000-2:2020, 12.5.2, Table 166). It is an internal identity, not the visible annotation contents or its page number. The engine stores generated and caller-supplied ids in /NM, so they survive PdfDocument.encodePdf() and can correlate update, remove, snapshot, persistence, and synchronization operations.

    For an existing annotation without /NM, the engine returns a page-local @<index> fallback. That fallback is positional rather than stable: after adding, removing, or replacing annotations on the page, call PdfPage.loadAnnotations() again before using it.

    interiorColor: PdfAnnotationColor | null

    Interior (fill) color, or null when unset.

    linkTarget: PdfLinkTarget | null

    URI or in-document destination for a Link annotation; null otherwise.

    modificationDate: string | null

    Raw PDF date string (D:…), if any.

    pageNumber: number

    1-based page number the annotation belongs to.

    rect: PdfRect

    Bounding rectangle in page coordinates.

    revision: number

    Monotonic per-annotation revision used for optimistic synchronization.

    subject: string | null

    /Subj subject.

    subtype: "highlight"
    text: string | null

    Highlighted page text, or null when text extraction was not requested or unavailable.

    textAlign: "left" | "center" | "right"

    Horizontal placement of FreeText content within its box.

    textColor: PdfAnnotationColor | null

    FreeText glyph color, or null when the annotation does not persist one.

    textOrientation: PdfTextOrientation

    Text direction for FreeText content; harmless metadata on other subtypes.

    textVerticalAlign: "top" | "middle" | "bottom"

    Vertical placement of FreeText content within its box.