W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2011

[whatwg] HTML Editing Commands spec minor clarifications

From: Aryeh Gregor <Simetrical+w3c@gmail.com>
Date: Fri, 13 May 2011 12:14:40 -0400
Message-ID: <BANLkTimHN_55LY1PvsZuPj823HCRDP7zxQ@mail.gmail.com>
On Thu, May 12, 2011 at 5:15 PM, Tim Down <timdown at gmail.com> wrote:
> I did some simple tests yesterday that confirm that Gecko generally
> acts only the first range, and was slightly surprised. I would expect
> it to affect all ranges in the selection. However, when you select
> multiple table cells in Gecko (which always creates a range for each
> selected cell, regardless of whether or not you use the Ctrl key),
> calling document.execCommand() acts on each range. Only the state of
> the first range is taken into consideration when deciding what state
> the selection has, meaning that for a binary command such as Bold, all
> selected cells are switched to the opposite state to that of the first
> selected cell.

Yeah, this kind of crazy stuff is why I don't want to spec what Gecko
does.  I strongly suspect no one ever really thought about the
behavior, because multi-range selections almost never come up.  I'm
pretty sure typical authors stand no chance of realizing they exist,
either.  If I wind up speccing this, I'll make up something sensible.
Received on Friday, 13 May 2011 09:14:40 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:33 UTC