HTML and CSS Reference
In-Depth Information
Figure 3-1. fillText in action
The context.strokeText() function (as shown in Figure 3-2 ) is similar, but it specifies the
outline of text strokes to the canvas. The color used to render the stroke is set in the con-
text.strokeColor property;thefontusedissetinthe context.font property.Thefunction
call looks like:
strokeText ([ text ],[ x ],[ y ],[ maxWidth ])
where:
text
text
The text to render on the canvas.
x
The x position of the text on the canvas.
Search WWH ::




Custom Search