pencil.js
Version:
Nice modular interactive 2D drawing library.
41 lines (40 loc) • 1.27 kB
TypeScript
/**
* @module Arc
*/
/**
* Arc class
* <br><img src="./media/examples/arc.png" alt="arc demo"/>
* @class
* @extends Component
*/
export default class Arc extends Component {
/**
* @inheritDoc
* @param {Object} definition - Arc definition
* @return {Arc}
*/
static from(definition: any): Arc;
/**
* @type {LineOptions}
*/
static get defaultOptions(): any;
/**
* @type {LineCaps}
*/
static get caps(): any;
/**
* Arc constructor
* @param {PositionDefinition} positionDefinition - Center of arc
* @param {Number} [width=0] - Horizontal radius
* @param {Number} [height=0] - Vertical radius
* @param {Number} [startAngle=0] - Angle to start from (0 is top, 0.5 is bottom and 1 is full circle back to top)
* @param {Number} [endAngle=0.5] - Angle to end to (from startAngle and in clockwise rotation)
* @param {LineOptions} [options] - Drawing options
*/
constructor(positionDefinition: any, width?: number, height?: number, startAngle?: number, endAngle?: number, options?: any);
width: number;
height: number;
startAngle: number;
endAngle: number;
}
import Component from "@pencil.js/component";