- From: Anne van Kesteren <annevk@opera.com>
- Date: Wed, 12 Mar 2008 21:42:06 +0100
- To: "HTML WG" <public-html@w3.org>
Below are some use cases for SVG in text/html from Erik Dahlström. He's one of Opera's SVG monkeys.. implementors and is also on the SVG WG. I reworded some of them in the process so you can blame me for typos. (FWIW, I agree with the use cases :-)) Use case #1 ----------- It makes it easier to write scripts that operate on the document as a whole, for example so that you don't have to worry about getElementById() being called in the right content document. Use case #2 ----------- It makes it possible to have selfcontained SVG+HTML documents without the need for data: URIs. data: URIs are not sufficient as they can be limited in size, require additional processing, and will be in a separate frame (see also #1). Use case #3 ----------- It would eliminate the need for using XHTML when using SVG. This is important as it lowers the bar for deploying SVG on the Web significantly. The different media type and well-formedness constraints are proving to be problematic. Use case #4 ----------- It makes it possible to do retained-mode graphics without using external files. Use case #5 ----------- It makes it easier to do interactive graphics than with using <canvas>. SVG uses the DOM so paths, shapes, etc. can have event listeners registered and can be moved/interacted with/etc. on their own. Use case #6 ----------- It makes it possible to reference resources such as gradients, arbitrary clip-paths, symbols etc, from other SVG fragments in HTML. This makes documents more compact. Example: <html> <svg> <linearGradient id="somegradient" ...> ... </linearGradient> </svg> more html <svg> <rect fill="url(#somegradient)" .../> </svg> </html> -- Anne van Kesteren <http://annevankesteren.nl/> <http://www.opera.com/>
Received on Wednesday, 12 March 2008 20:41:47 UTC