canvas-extras
Advanced tools
Comparing version 1.0.2 to 1.0.3
{ | ||
"name": "canvas-extras", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Adds extra handy bits to canvas, including Progress Bars, rounded rectangles, and stadiums.", | ||
@@ -5,0 +5,0 @@ "main": "canvas-extras.js", |
@@ -17,3 +17,3 @@ canvas-extras adds extra handy bits to canvas, including Progress Bars, rounded rectangles, and stadiums. | ||
`ctx.progressBar(currentProgress, maxProgress, x, y, width, height, barFillColor, emptyFillColor)` | ||
ctx.progressBar(currentProgress, maxProgress, x, y, width, height, barFillColor, emptyFillColor) | ||
@@ -23,7 +23,7 @@ ##### Example | ||
```javascript | ||
ctx.beginPath(); | ||
ctx.progressBar(5, 10, 50, 50, 200, 100, 'orange'); | ||
ctx.endPath(); | ||
``` | ||
ctx.beginPath(); | ||
ctx.progressBar(5, 10, 50, 50, 200, 100, 'orange'); | ||
ctx.endPath(); | ||
``` | ||
@@ -36,12 +36,12 @@ This will yield this result: | ||
`ctx.roundRect(x,y, width, height, roundness)` | ||
ctx.roundRect(x,y, width, height, roundness)` | ||
##### Example | ||
```javascript | ||
ctx.beginPath(); | ||
ctx.fillStyle = '#aaaaaa'; | ||
ctx.roundRect(50,50, 100, 100, 25); | ||
ctx.fill(); | ||
ctx.closePath(); | ||
``` | ||
ctx.beginPath(); | ||
ctx.fillStyle = '#aaaaaa'; | ||
ctx.roundRect(50,50, 100, 100, 25); | ||
ctx.fill(); | ||
ctx.closePath(); | ||
``` | ||
@@ -48,0 +48,0 @@ This will yield this result: |
4077