[whatwg] Document.title for SVG documents

Ian Hickson ian at hixie.ch
Mon Feb 3 11:44:28 PST 2014


On Sat, 1 Feb 2014, Cameron McCormack wrote:
>
> Currently, HTML defines Document.title on SVG documents to defer to 
> whatever the SVG specification defines for SVGDocument.title.  The 
> SVGDocument interface has gone away, so this will need to be updated. 
> From some basic testing, it looks like SVG needs the same behaviour as 
> HTML -- first <title> element in the document, plus the white space 
> collapsing behaviour.
> 
> Do you want to just handle that all in HTML?  I'm not sure there's much 
> value to duplicating either the searching for the title element or the 
> white space collapsing behaviour in SVG itself.

I'm all for handling it in one place. What precisely do you want the 
behaviour to be? (Consider HTML-in-SVG and SVG-in-HTML also -- "the first 
<svg:title> element" may come after "the first <html:title> element", and 
vice versa. Also consider when one or the other is "primary" but the 
relevant element is absent.)

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list