Read-only attributes

Hi there

Sorry for all my questions today but I'm trying to get all of this out of my
mind for now :-)

Some time ago we had this discussion on svg-developers (see for example
http://groups.yahoo.com/group/svg-developers/message/22727,
http://groups.yahoo.com/group/svg-developers/message/22729,
http://groups.yahoo.com/group/svg-developers/message/22744) and we really
never settled on a correct answer.

The question was basically: when a property is read-only, for example
SVGLineElement.x1, is it allowed to do:
myLine.x1.baseVal.value = 10
or does the read-only "inherit" all the way down?

x1 is read-only, baseVal is read-only but value on a SVGLength is read/write
but with this addition:
Exceptions on setting
DOMException NO_MODIFICATION_ALLOWED_ERR: Raised on an attempt to change the
value of a readonly attribute.

So, should the statement above result in the line moving or an exception?

Sorry if this was answered before and I missed it.
/niklas

Received on Tuesday, 19 November 2002 11:53:38 UTC