import { Color } from "@dt/core-ui"; import { PaintCommandName, PaintObjectParameters, PaintObjectPropertyName, PaintObjectType } from "../../../ImageViewer/Layers"; import { BasePaintObject } from "./BasePaintObject"; import { LineCapStyle } from "./ObjectTypes"; import { PointLocation } from "../../../ImageViewer/Models"; export declare abstract class LinePaintObjectBase extends BasePaintObject { startCapStyle: LineCapStyle; endCapStyle: LineCapStyle; capSize: number; capColor: Color; constructor(type: T, name: PaintCommandName, startPosition: PointLocation, lineColor: Color, lineWidth: number, opacity: number); /** * Returns the additional padding (in pixels) required around the object * to ensure all visual elements, such as styled line caps, are fully visible. * This takes into account the cap size, line width, and the object's rotation. * Used to correctly size the design-time canvas when rendering this object. */ get canvasPadding(): number; private updateBoundsFromPosition; private updatePositionFromBounds; /** * Draws the line and optionally styled caps on the destination canvas. */ draw(destCtx: CanvasRenderingContext2D, mainCtx: CanvasRenderingContext2D, backCtx: CanvasRenderingContext2D, params?: PaintObjectParameters): Promise; /** * Calculates how much to adjust the line endpoint based on cap style * to prevent the line from showing behind the cap. */ private getCapAdjustment; /** * Draws a cap (arrow or dot) at the given position and direction. */ private drawCap; /** * Updates object properties and internal state when modified. */ setProperty(propertyName: K, value: any): boolean; }