W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2011

Re: ISSUE-137 (IME-keypress): Should keypress events fire when using an IME? [DOM3 Events]

From: Jacob Rossi <Jacob.Rossi@microsoft.com>
Date: Tue, 16 Aug 2011 23:56:19 +0000
To: "Kang-Hao (Kenny) Lu" <kennyluck@csail.mit.edu>, Masayuki Nakano <masayuki@d-toybox.com>
CC: "www-dom@w3.org" <www-dom@w3.org>
Message-ID: <D0BC8E77E79D9846B61A2432D1BA4EAE0341A939@TK5EX14MBXC287.redmond.corp.microsoft.com>
Hi Kenny,

Looks like we crossed paths here. Please see my mail regarding a clarification that I just made to the spec which supports Nakano-san's suggestion. [1]

Of the other events you mention, only textinput is defined in DOM Level 3 Events. The spec does in fact indicate that textinput should fire "resulting....from the processing of an input method editor." [2] Additionally, the exact sequence is given in an example. [3] Note that the keydown/keyup events in this sequence are optional. 

In general, I agree that no indication of text insertion or update should be given while processing an IME---this is why keypress and textinput should not fire during an IME composition.  Keydown/keyup do not indicate text insertion, rather they indicate the physical depression of a key. Depending on the particular IME and on system configurations, implementations may not be able to provide keydown/keyup like given in the example. The spec allows these to be suppressed in such cases.



[1] http://lists.w3.org/Archives/Public/www-dom/2011JulSep/0117.html
[2] http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#event-type-textinput 
[3] http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#keys-IME 

From: Kang-Hao (Kenny) Lu <kennyluck@csail.mit.edu>
Date: Wed, 17 Aug 2011 06:56:20 +0800
Message-ID: <4E4AF594.60308@csail.mit.edu>
To: Web Applications Working Group WG <public-webapps@w3.org>
CC: Masayuki Nakano <masayuki@d-toybox.com>
(11/08/09 16:57), Masayuki Nakano wrote:
> 3. Some web developers may not know well about IME behavior. Their web
> applications might break IME behavior by handling key events.
> I'd like to *suggest* that key events shouldn't be fired during IME
> composition, especially for #3.  If web developers want to know the
> timing of updating composition string, they can use compositionupdate
> or textinput. I think that these events are better for the purpose
> since IME composition string can be updated by clicking on candidate
> window, i.e., it doesn't cause key events.

A few Chinese web developers support Nakano-san's opinion here. In
addition, we are concerned about the situation with other events such as
input, textinput and change. We think these event *shouldn't* be fired
during IME composition, and we are not sure if that's already specced

Received on Tuesday, 16 August 2011 23:56:47 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:18 UTC