W3C home > Mailing lists > Public > www-archive@w3.org > March 2009

Re: Making it possible to use an <svg> root in text/html

From: Henri Sivonen <hsivonen@iki.fi>
Date: Mon, 9 Mar 2009 11:43:56 +0200
Cc: www-archive@w3.org, www-svg <www-svg@w3.org>
Message-Id: <624EEBFD-02CD-4782-8E87-42D963119D23@iki.fi>
To: Dana Lee Ling <dleeling@comfsm.fm>
On Mar 6, 2009, at 08:03, Dana Lee Ling wrote:

> Robin Berjon wrote the following on 3/5/2009 8:51 PM:
>> On Mar 5, 2009, at 09:25 , Henri Sivonen wrote:
>>> I don't have an informed opinion yet on whether enabling <svg> as  
>>> root in text/html is a good idea.
>> Scratching my head a little, I see no good reason not to allow it.  
>> In fact, I think it would be a very good idea if we can work around  
>> some of the few kinks.
> As someone who uses a text editor to write SVG in XHTML+MathMl+SVG,  
> I am somewhat unclear on the use case for an <svg> root. Maybe I am  
> confused, but someone wants to start a document something like <! 
> DOCTYPE svg> followed by SVG elements with some HTML elements  
> embedded in amongst the SVG? There is a reason to do this?

There a some ad agency-created "high impact" marketing sites created  
in Flash. These tend to put text views inside a vector graphics  

To create similar sites with Open Web technologies, one might want to  
have an <svg> root and then HTML content in a <foreignObject>.  
However, the HTML bits would suffer from all the usual ill-formedness  
of HTML if pulled from a CMS built for text/html and not for XML, so  
text/html would work for such HTML islands better than image/svg+xml.

> A reason that simply using XHTML will not work?

There's no "simply" in using XHTML. :-) The (X)HTML bits could easily  
come from a system that can't guarantee well-formedness.

> Even when the page is dominantly an SVG graphic with a hunk of XHTML  
> code inserted as a foreignObject, http://www.comfsm.fm/~dleeling/kinesiology/runshine.xhtml 
> , I still do not see that the savings starting off in <svg>.

Having an SVG root has different behavior wrt. sizing the content to  
the view port.

Henri Sivonen
Received on Monday, 9 March 2009 09:44:55 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:33:35 UTC