import { IPaintObject, IPaintObjectDesigner, PaintObjectPropertyName, PaintObjectType } from "../../../ImageViewer/Layers/types"; import { IImageViewer } from "../../../ImageViewer/Models/IImageViewer"; import { Bounds, PointLocation } from "../../../ImageViewer/Models/SelectionBoxTypes"; import { GcSelectionBox } from "../../../ImageViewer/Tools/GcSelectionBox"; import { PaintToolbar } from "../PaintToolbar"; import { CanvasTextEditor } from "./CanvasTextEditor"; export declare class PaintObjectDesigner implements IPaintObjectDesigner { readonly id: string; paintObject: IPaintObject; position: PointLocation; owner: PaintToolbar; paneViewContentElement: HTMLDivElement; designerElement: HTMLDivElement; designerCanvas: HTMLCanvasElement; viewer: IImageViewer; readonly typeName: "PaintObjectDesigner" | "SelectedRegion"; private _selected; private _selectionBox?; private _startPosition?; private _endPosition?; private _dirtyValues; private _repainting; constructor(id: string, paintObject: IPaintObject, position: PointLocation, owner: PaintToolbar); _canvasTextEditor?: CanvasTextEditor; get paintObjectName(): PaintObjectType | ""; onPointerStart(point: PointLocation): void; onPointerMove(point1: PointLocation, keepSize?: boolean): void; onPointerEnd(point: PointLocation): boolean; applyDirtyValues(caller: string): void; private showInlineTextEditor; finishInlineEdits(): void; dispose(): void; updatePosition(point: PointLocation, moveDisatance?: { x: number; y: number; }): boolean; invalidate(): void; repaint(): Promise; resetToFactoryDefaults(): Promise; resizeToContent(): void; onBoundsChanged(skipSelectionUpdate?: boolean): Promise; /** * Positions the designer element accounting for canvas padding */ private positionDesignerElement; /** * Updates the physical and visual dimensions of the canvas * considering current padding and scale */ private updateCanvasSizeAndPosition; /** * Calculates dimensions including padding * @returns [width, height] tuple with padding applied */ private calculatePaddedDimensions; /** * Updates selection bounds if selection exists and update isn't skipped */ private updateSelectionBounds; /** * Notifies listeners about bounds change */ private notifyBoundsChanged; getPaintObjectProperty(propertyName: PaintObjectPropertyName): any | null; setPaintObjectProperty(propertyName: PaintObjectPropertyName, val: any, dirty?: boolean, caller?: string): boolean; get bounds(): Bounds; set bounds(bounds: Bounds); setBoundsInternal(bounds: Bounds, skipSelectionUpdate?: boolean, isDirty?: boolean, caller?: string): void; updateRotationTransform(): void; get paintCanvasScale(): number; get selected(): boolean; set selected(selected: boolean); setVisible(visible: boolean): void; setSelected(selected: boolean, skipUndo?: boolean, skipPropsUpdate?: boolean): void; get selectionBox(): GcSelectionBox; private _createUIControls; }