import { Rect } from "../../Core/Rect"; import { RegionData } from "../../Core/RegionData"; import { IAnchorMixin } from "../../Interface/IAnchorMixin"; import { EventListeners } from "../../Interface/IEventDescriptor"; import { IRegionCallbacks } from "../../Interface/IRegionCallbacks"; import { AnchorsComponent } from "../Component/AnchorsComponent"; export declare class BezierController implements IAnchorMixin { private anchorComponent; private paper; private paperRect; private regionData; private anchorsNode; private callbacks; /** * The array of bezier control point elements. */ private controlPoints; /** * Bezier control ghost anchor */ private controlGhostAnchor; private activeControlPointId?; private createAnchor; private subscribeToEvents; private dragOrigin?; private isDragged; constructor(anchorComponent: AnchorsComponent, paper: Snap.Paper, paperRect: Rect, regionData: RegionData, anchorsNode: Snap.Element, callbacks: IRegionCallbacks, createAnchor: (paper: Snap.Paper, x: number, y: number, style?: string, r?: number) => Snap.Element, subscribeToEvents: (listeners: EventListeners) => void); buildAnchors(): void; redraw(): void; private updateControlPoints; private subscribeControlPointToEvents; /** * Helper function to create a bezier control point. * @param paper - The `Snap.Paper` object to draw on. * @param x - The `x`-coordinate of the anchor. * @param y - The `y`-coordinate of the anchor. * @param r - The radius of the anchor. */ private createControlPoint; /** * Helper function to create a bezier control point tangent line. * @param paper - The `Snap.Paper` object to draw on. * @param polylinePoints - Points to draw line on */ private createControlPointTangent; /** * Create Snap elements for control point and control point tangent line, in a group. * @param index - Index of line segment/control data * @param line - Line segment * @param control - Bezier control * @param pointName - `"c1" | "c2"` The point name id of the bezier control * @returns Group containing the control point element and its tangent line. */ private createControlPointGroup; /** * Creates SnapSVG UI of control points of each bezier control. */ private buildControlPoints; private subscribeControlGhostToEvents; private getActiveControlPoint; private updateRegion; }