W3C home > Mailing lists > Public > public-webapi@w3.org > May 2008

Re: Proposed errata for DOM2 Range regarding insertNode()

From: Olli Pettay <Olli.Pettay@helsinki.fi>
Date: Wed, 14 May 2008 14:43:34 +0300
Message-ID: <482AD066.1090106@helsinki.fi>
To: public-webapi@w3.org

Ian Hickson wrote:
> DOM2 Range says of the insertNode() method that "A node may be inserted
> into a Range using the following method". However, if the range is
> collapsed, according to a strict reading of the specification, calling
> insertNode() actually inserts the node _after_ the range. I propose that
> we change the spec to explicitly say that if you call insertNode() on a
> collapsed range, the end point offset is increased by one, as if the node
> was inserted before the end point,
inserted node can be document fragment in which case end offset should 
be increased more than one.

> which I believe to be the intent of the
> specification. This is implemented by Opera and WebKit already, and is
> tested by Acid3.
Gecko does what the current spec says.

> If the working group chair will forgive me, I suggest we set a deadline of
> May 21st (a week from today) at which point if there have been no
> objections raised we go ahead and make the change to the DOM2 errata.
Does web content rely on the current spec behavior?
Did Webkit or Opera change their behavior just to pass ACID3 (but not to 
follow Range spec)?

Received on Wednesday, 14 May 2008 11:44:24 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:16:26 UTC