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

[whatwg] selection.modify behavior across platforms

From: Ehsan Akhgari <ehsan@mozilla.com>
Date: Mon, 28 Mar 2011 15:57:17 -0700 (PDT)
Message-ID: <452708751.79982.1301353037219.JavaMail.root@cm-mail03.mozilla.org>
> I'm not even sure. Spell correction code can certainly deal with that
> sort of differences so I don't see it as a critical problem.

For sure, whether the API behaves in a platform specific manner or not, web applications can get the other behavior if they need it.  I suggested the spell checker only as an example, suggesting that not all possible users of the API want to simulate user's keyboard events.

> What do you mean by "agnostic to the underlying platform"?

I mean the API having the same behavior no matter what platform the UA is running on.  Or, another way to put it, the web application getting the same behavior from the API no matter what platform the UA hosting the web application is running on.

> Regardless
> of whether eating space or not, modifying selection by word does
> emulate the selection behavior that can be otherwise invoked by users.
> So in that sense, this API is agnostic to the underlying platform.

No, since its behavior changes based on which platform the user viewing the web page is running at the moment.

> I'd also point out that queryCommandValue and queryCommandState in
> WebKit return different values depending on platforms.

Do you know more details on this?  Which commands have this platform specific behavior?  And why does Webkit do different things on different platforms here?

Cheers,
--
Ehsan Akhgari
ehsan at mozilla.com
http://ehsanakhgari.org/
Received on Monday, 28 March 2011 15:57:17 UTC

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