import { ICubicBezierControl } from "../Interface/ICubicBezierControl"; import { IRect } from "../Interface/IRect"; import { Point2D } from "./Point2D"; /** * Represents a cubic bezier line control */ export declare class CubicBezierControl { /** * Creates a new cubic bezier control based on extracting specific properties from any provided object * @param data - An `ICubicBezierControl` object with `c1` and `c2` point properties * @returns A new `CubicBezierControl` object */ static BuildFromJSON({ c1, c2 }: ICubicBezierControl): CubicBezierControl; c1: Point2D; c2: Point2D; constructor({ c1, c2 }: ICubicBezierControl); /** * Returns a new control created from bounding each point to the `Rect` object provided * @remarks This method bounds the control points to the rect with coordinates `[0, 0] x [r.width, r.height]`. * @param r - A bounding box * @returns A new `CubicBezierControl` object, with control coordinates bounded to the box */ boundToRect(r: IRect): CubicBezierControl; /** * Shifts the control by specified delta. * Modifies control in place. * @param dx - Delta to be added to the `x`-coordinate * @param dy - Delta to be added to the `y`-coordinate */ shift(dx: number, dy: number): void; /** * Creates a copy of this control * @returns A new `Point2D` object with copied coordinates */ copy(): CubicBezierControl; /** * Returns a string representation of the point in the format `"{x, y}"`. * @returns A string representation of the point */ toString(): string; /** * Returns a JSON representation of the point * @returns An `IPoint` object with `x` and `y` numeric properties. */ toJSON(): ICubicBezierControl; }