/** * This class represents a circle on the canvas * @author Eirik Måseidvåg */ import { CanvasElementName } from '..'; import { CircleOptions, CircleStrokeStyle } from './types'; import CanvasElement from '../abstract/CanvasElement'; export default class Circle extends CanvasElement { /** * The inner fill of the circle. Represented as a hexadecimal number * E.g. 0xffffff (white) * @public */ fill: number; /** * The fill of the border of the circle. Represented as a hexadecimal number * E.g. 0xffffff (white) * @public */ borderFill: number; /** * The size of the border and radius line * @public */ size: number; /** * The style of the circles border * @public */ strokeStyle: CircleStrokeStyle; /** * Determines weather to display or hide the circles radius line * @public */ showRadius: boolean; /** * The opacity of the circles body. Represented by a float between 0 and 1 * @public */ fillOpacity: number; /** * The opacity of the circles border. Represented by a float between 0 and 1 * @public */ borderOpacity: number; /** * The radius rotation */ radiusRotation: number; /** * Radius of the circle */ radius: number; /** * Returns the type of this canvas element * @returns CanvasElementName.CIRCLE */ name: CanvasElementName; /** * Construct the object * @param options: CircleOptions */ constructor(options: CircleOptions); }