Font Stroke
Hi
Any chances to add the HTML5 "StrokeText" function in the me.font?
Other ideia is a function to draw "border" text, something like this:
http://jsfiddle.net/vNWn6/
Thanks!
oh nice, i actually never thought about using it, and the drawStroke is certainly a good idea on how to add it to the current me.Font class :)
Stroke is a fine idea! I am guessing we want to set strokeStyle and lineWidth in the constructor, like the fontStyle and fillStyle are. Then allow using strokeText independent of fillText. Just to provide more control to the user, because you get different results by calling these functions in different orders and such. :)
i would rather see both strokeStyle and fillStyle being public properties of me.Font but both initialised by default with the color parameter given in the constructor, and I would then add a me.Font.drawStroke() function
That seems reasonable.
Yes, the @obiot idea is reasonable.
Remembering that drawText and strokeText should be used with caution, because it's slower than drawImage ;)
http://simonsarris.com/blog/322-canvas-drawtext-considered-harmful
This was a quick one and without any risk on regression for the existing me.Font function, so I added this one to the 0.9.11 branch :P
This also reminded me that since me.Font is inheriting from me.Renderable (documentation was wrong on this btw), we already have an alpha property defined and we just need to use it accordingly (referring to one of the discussion in the forum)
Nice!