@avolutions/canvas-painter
Version:
CanvasPainter.js is a simple yet powerful JavaScript library for drawing basic shapes (rectangles, circles, etc.) on HTML5 Canvas with ease. Perfect for creating 2D graphics in your web projects.
12 lines (11 loc) • 380 B
TypeScript
import { IShapeOptions } from "./IShapeOptions.js";
/**
* Represents options for configuring a rectangle shape.
*/
export interface IRectangleOptions extends IShapeOptions {
/**
* If true, the rectangle will be centered at the provided position.
* If false or undefined, the rectangle will be positioned from the top-left corner.
*/
centered?: boolean;
}