- From: Cameron McCormack <cam@mcc.id.au>
- Date: Wed, 19 Aug 2009 10:30:54 +1000
- To: Brian Birtles <birtles@gmail.com>
- Cc: www-svg <www-svg@w3.org>
Brian Birtles: > Thanks very much for looking into this Cameron. > > So now, under SVGLength.value / NO_MODIFICATION_ALLOWED_ERR, we have: > > Raised when the rectangle corresponds to a read only attribute or when the > object itself is read only. > > Firstly, I suspect that should be 'length' instead of 'rectangle'. Yep. :) > But more importantly, I'm not sure that it's correct. We shouldn't throw an > exception on setting SVGAnimatedLength.baseVal.value even though > SVGAnimatedLength.baseVal is a readonly attribute. Yet the text here implies > otherwise (remember that it is describing the behaviour of SVGLength.value > not SVGLength). > > I think the text should just be: > > Raised when the object is read only. > > Or, in keeping with the wording in SVG 1.1, perhaps: > > Raised on an attempt to change the value of a readonly object. I think the confusion is about what “when the length corresponds to a read only attribute” means. This is meant to mean when the SVGLength object corresponds to a DOM attribute (i.e., an Attr node in the DOM) that happens to be read only. Such read only nodes are mostly theoretical, though. I think they can occur when you have an XML document with entity references that the parser has not expanded (but which have been fetched). Descendants of such EntityReference nodes are read only. OK, I think that warrants an explanation in the spec. You are right that we want to have SVGAnimatedlength.baseVal.value be writable. > I think that fits with the text at the top of that section: > > An SVGLength object can be designated as read only, which means that > attempts to modify the object will result in an exception being thrown, as > described below. > > (Also, I think we said that setting SVGAnimatedLength.baseVal should > possibly fail silently depending on how readonly attributes in WebIDL are > bound to a particular language.) Yes. > Sorry to make such a fuss over this! I hope that's clear. No problem, thanks for the feedback. -- Cameron McCormack ≝ http://mcc.id.au/
Received on Wednesday, 19 August 2009 00:31:40 UTC