Canvas
Extends:
Constructor Summary
| Public Constructor | ||
| public |
|
|
Method Summary
| Public Methods | ||
| public |
circle(x: *, y: *, radius: *) |
|
| public |
clear(color: *) |
|
| public |
clearRect(x: *, y: *, width: *, height: *, color: *) |
|
| public |
clip() |
|
| public |
clone(): * |
|
| public |
ellipse(x: *, y: *, width: *, height: *) |
|
| public |
fill(color: *) |
|
| public |
line(x1: *, y1: *, x2: *, y2: *) |
|
| public |
polygon(arrX: *, arrY: *) |
|
| public |
roundedRect(x: *, y: *, width: *, height: *, radius: number) |
|
| public |
setAlpha(alpha: *) |
|
| public |
setColor(color: *) |
|
| public |
setFill(color: *) |
|
| public |
setStroke(color: *) |
|
| public |
stroke(color: *) |
|
Public Constructors
public constructor() source
Public Methods
public circle(x: *, y: *, radius: *) source
Params:
| Name | Type | Attribute | Description |
| x | * |
|
|
| y | * |
|
|
| radius | * |
|
public clear(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
public clearRect(x: *, y: *, width: *, height: *, color: *) source
Params:
| Name | Type | Attribute | Description |
| x | * | ||
| y | * | ||
| width | * | ||
| height | * | ||
| color | * |
public clip() source
public ellipse(x: *, y: *, width: *, height: *) source
Params:
| Name | Type | Attribute | Description |
| x | * | ||
| y | * | ||
| width | * | ||
| height | * |
Example:
// from http://stackoverflow.com/questions/2172798/how-to-draw-an-oval-in-html5-canvas
// draw by center
strokeEllipse(context, cx - w/2, cy - h/2, w, h);
public fill(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
public line(x1: *, y1: *, x2: *, y2: *) source
Params:
| Name | Type | Attribute | Description |
| x1 | * | ||
| y1 | * | ||
| x2 | * | ||
| y2 | * |
public polygon(arrX: *, arrY: *) source
Params:
| Name | Type | Attribute | Description |
| arrX | * | ||
| arrY | * |
public roundedRect(x: *, y: *, width: *, height: *, radius: number) source
Params:
| Name | Type | Attribute | Description |
| x | * | ||
| y | * | ||
| width | * | ||
| height | * | ||
| radius | number |
|
public setAlpha(alpha: *) source
Params:
| Name | Type | Attribute | Description |
| alpha | * |
public setColor(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
public setFill(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
public setStroke(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
public stroke(color: *) source
Params:
| Name | Type | Attribute | Description |
| color | * |
