Programmatic drawing in Safari: wow
Posted on July 5, 2004
Filed Under /dev/null/ | 57 views |
From Dave “Safari” Hyatt:
Another extension we made to HTML is a new element called the canvas. This element is essentially an image element that supports programmatic drawing. The way it works is that you can invoke a method called getContext on the canvas and then you have access to a whole range of 2d drawing calls. This element is how the hands of the Dashboard clock are drawn in HTML. The canvas fully participates in CSS styling too, so you can give it borders or background images while still painting the foreground content programmatically.
That kicks some serious ass. App developers are used to having a generic Canvas class for custom drawing but to have that in a web page is just freakish.
Makes me wonder though: still standards-compliant?