views:

352

answers:

1

I have seen this question/answer:

http://stackoverflow.com/questions/719848/how-do-you-draw-text-on-a-canvas-tag-in-safari

But I looking for how to do it on an iphone. Does the iphone support it already?

Also, it'd be nice to see a web page that discusses what the current iphone os/browser supports regarding canvas, html 5 and other related web tech.

+2  A: 

Apple has an introduction at Safari Reference - Using Canvas and more details in the DOM Reference.

In general, the iphone canvas support is excellent and very useful.

EXCEPT for the missing text rendering, which I have heard will be available in a future OS upgrade.

While waiting, you can use Jim Studt's Canvas Text Function to display simple text on the Canvas.

For an example of how it looks, check out the Night Sky iPhone webapp which draws lines, text and images on the Canvas as well as saving and loading it from localStorage.

GeoNomad
So I guess that's how things are for now? In the webkit dom ref it shows "void fillText(/* 4 */); " as the function for filltext. To me that means they put that there so that the javascript doesn't choke when some code tries that cmd.Jim Studt's canvas text function works nicely. There are other options which let you have more font variety.
Neo42