Created
March 25, 2011 06:32
-
-
Save brettz9/886450 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Using only direct canvas method wrappers (which use the same | |
| // name as official canvas methods): | |
| ctx.shadowColor('green').shadowBlur(2).shadowOffsetX(5).shadowOffsetY(10); | |
| // Using one utility method (at the end) amongst direct canvas method wrappers: | |
| ctx.shadowColor('green').shadowBlur(2).$shadowOffset(5, 10); | |
| // Using custom utility exclusively with its own simplified | |
| // non-canvas (but easily derived) syntax: | |
| ctx.$shadow({color:'green', blur:2, offset:[5, 10]}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment