W3C home > Mailing lists > Public > www-svg@w3.org > April 2009

Re: Selectors, getElementsByTagName() and camelCase SVG

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Fri, 03 Apr 2009 08:48:25 -0400
Message-ID: <49D60599.3010308@mit.edu>
To: HTML WG <public-html@w3.org>, www-svg <www-svg@w3.org>
Cameron McCormack wrote:
>> Was that the question?  Or were you asking about the two proposals to  
>> modify this?
> Both, really.  It seemed like an agreement was being converged on, but
> it wasn’t apparent to me what exactly the changes being proposed were.

I don't think agreement is so much being converged on, but the only 
topic under discussion so far is what to do about nodes that are in an 
HTML (not XHTML) document, in the XHTML1 namespace, and have a localName 
that's not all lowercase.

> To me, it would seem to be confusing if getElementsByTagName() behaved
> differently depending on whether it was called on an HTML node or a
> different kind of node.  It would make more sense to me if it did case
> insensitive matching for an element in the subtree if it were an HTML
> element, and case sensitive otherwise (assuming we don’t want to make
> everything case insensitive in HTML documents, including foreign content
> nodes).  Also, I would expect selectors to just work case insensitively
> all the time.

Both of these are not compatible with current SVG content, right?  That 
is, if you drop existing SVG content into the middle of an HTML5 
document, doing the above would change the behavior of 
getElementsByTagName on nodes in the SVG, and would change the behavior 
of stylesheets the SVG links to.

That might be ok, but is worth careful thought.

The selectors thing would also be significantly slower, at least in Gecko.

Received on Friday, 3 April 2009 12:49:20 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:47:17 UTC