User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36 Steps to reproduce: 1. Typing a Korean character inside a div tag with content-editabled. Actual results: Events will be raised like below. - TSF disabled : keydown -> compositionstart -> compositionupdate -> keyinput - TSF enabled : compositionstart -> compositionupdate -> keyinput Expected results: Whether TSF is enabled or not, it should work in the same way. Is there any intention that surpressing "keydown" event during composition?
Component: Untriaged → DOM: Events
Product: Firefox → Core
Per spec "During the composition session, all keydown and keyup events MAY be suppressed." https://w3c.github.io/uievents/#events-composition-event-key-events
though, I'd still expect the initial keydown
(In reply to Olli Pettay [:smaug] from comment #1) > Per spec "During the composition session, all keydown and keyup events MAY > be suppressed." > > https://w3c.github.io/uievents/#events-composition-event-key-events Yes. We've discussed "What key value is properly and expected if the key event will be handled by IME?". Then, WG decided that the spec doesn't define it and recommends not firing key events during composition. However, for compatibility with other browsers, firing keydown/keyup events might be better. This is bug 354358. So, this bug should take care only following issue. (In reply to Olli Pettay [:smaug] from comment #2) > though, I'd still expect the initial keydown Well, it depends on how IME API works. In TSF mode, we don't receive key messages before compositionstart with wndproc at least in this case. However, in TSF mode, we send key messages to TSF immediately after getting the message from the queue. So, it's not impossible to dispatch keyboard events but we need to implement a little bit hacky code... (In reply to Park, Chulmin from comment #0) > Whether TSF is enabled or not, it should work in the same way. Indeed, but I'm not sure it's worthwhile since we need a hacky code. > Is there any intention that surpressing "keydown" event during composition? If the web app isn't aware of IME, either keydown or keyup event handler may make IME unavailable. For avoiding such cases, we've not fired any key events during composition. (input event should be used for detecting modifying the editor, compositionupdate should be used for detecting will modifying the editor, instead, then, the web apps become aware of non-keyboard devices such as speech input, handwriting input)
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: "keydown" event is surpressed during composition on div tag when TSF(Text Services Framework) is enabled. → [TSF] preceding keydown event of compositionstart may not be fired in TSF mode
Component: Event Handling → Widget: Win32
OS: Unspecified → Windows
Hardware: Unspecified → All
I understand and agree with Comment 3. I will modify my code to not to use keydown event.
I think someone must close this issue, because all reached an agreement. Masayuki : Is there any issue with Park closes it? If not, I'll let Park know.
Please keep this bug open. Whether keydown and keyup should be fixed during composition or not becomes unstable in UI Events spec. I need to continue to discuss with the WG.
(In reply to Masayuki Nakano [:masayuki] (Mozilla Japan) from comment #6) > Please keep this bug open. Whether keydown and keyup should be fixed during > composition or not becomes unstable in UI Events spec. I need to continue to > discuss with the WG. Okay. Thanks for your fast reply. :)
You need to log in before you can comment on or make changes to this bug.