import { ObjectManager } from "../../ObjectManager"; import { MarkupAnnotation, type MarkupAnnotationProperties } from "./MarkupAnnotation"; import { type Point } from "../../Types"; /** * Defines properies of a line annotation, that displays a single straight line on a page. * When opened, it displays a pop-up window containing the text of the associated note. */ export type InkAnnotationProperties = MarkupAnnotationProperties & { type: "ink"; /** * The line width in points. */ lineWidth?: number; /** * The line dash pattern. Null means a solid line. */ lineDashPattern?: number[]; /** * The list of lists of points, in which each list of points represents a stroked path. * The coordinates of points are relative to the upper left corner of the page's * media box, with the Y (vertical) coordinates increasing from top to bottom. * * Note that if the annotation is associated with more than one page, * the media box of the first of those pages is used to calculate the coordinates. */ paths?: Point[][]; }; /** * Represents a line annotation, that displays a single straight line on a page. * When opened, it displays a pop-up window containing the text of the associated note. */ export declare class InkAnnotation extends MarkupAnnotation { /** * Creates a new {@link InkAnnotation}. * * @param om - {@link ObjectManager} that controls the lifetime of the {@link InkAnnotation}. */ constructor(om: ObjectManager); /** * Creates a new {@link InkAnnotation}. */ constructor(); /** * Gets or sets the line width in points. */ get lineWidth(): number; /** * Gets or sets the line width in points. */ set lineWidth(value: number); /** * Gets or sets the line dash pattern. Null means a solid line. */ get lineDashPattern(): number[] | null; /** * Gets or sets the line dash pattern. Null means a solid line. */ set lineDashPattern(value: number[] | null); /** * Gets or sets the list of lists of points, in which each list of points represents a stroked path. * The coordinates of points are relative to the upper left corner of the page's * media box, with the Y (vertical) coordinates increasing from top to bottom. * * Note that if the annotation is associated with more than one page, * the media box of the first of those pages is used to calculate the coordinates. */ get paths(): Point[][] | null; /** * Gets or sets the list of lists of points, in which each list of points represents a stroked path. * The coordinates of points are relative to the upper left corner of the page's * media box, with the Y (vertical) coordinates increasing from top to bottom. * * Note that if the annotation is associated with more than one page, * the media box of the first of those pages is used to calculate the coordinates. */ set paths(value: Point[][] | null); /** * Gets or sets the list of lists of points, in which each list of points represents a stroked path * in PDF user space coordinates. * The positive X axis extends horizontally to the right, and the positive Y axis * extends vertically upward, with the origin usually in the lower left corner of the page. */ get pdfPaths(): Point[][] | null; /** * Gets or sets the list of lists of points, in which each list of points represents a stroked path * in PDF user space coordinates. * The positive X axis extends horizontally to the right, and the positive Y axis * extends vertically upward, with the origin usually in the lower left corner of the page. */ set pdfPaths(value: Point[][] | null); }