JakeSidSmith / canvasimo

An HTML5 canvas drawing library, with 150+ useful methods, jQuery-like fluent interface, and cross-browser compatibility enhancements.
http://canvasimo.com
MIT License
16 stars 2 forks source link

Fill and stroke with color #24

Closed JakeSidSmith closed 8 years ago

JakeSidSmith commented 8 years ago

Fixes #23

More info about fill & stroke in #23

Allows calling fill and stroke like so

ctx.fill();
ctx.fill(fillRule);
ctx.fill(path, fillRule);
ctx.fill(color);
ctx.fill(path, color);
ctx.fill(path, fillRule, color);

ctx.stroke();
ctx.stroke(path);
ctx.stroke(color);
ctx.stroke(path, color);
pmg103 commented 8 years ago

Also use RegExp.test() since you only want a boolean