Status: Untriaged
Owner: ----
CC:
editi...@chromium.org,
xiaoche...@chromium.org,
tedc...@chromium.org,
ama...@chromium.org Components: Blink>Editing>IME
OS: Linux Android Windows Chrome Mac Fuchsia
Pri: 3
Type: Bug
New issue 787598 by
rla...@chromium.org: Undo is super-wonky when typing with IME (e.g. most typing on Android)
https://bugs.chromium.org/p/chromium/issues/detail?id=787598Chrome Version: 64.0.3274.0 (Developer Build) unknown (32-bit)
OS: Android N
What steps will reproduce the problem?
(1) Set up an Android device with Gboard and also a physical keyboard. Enable showing the on-screen keyboard while the physical keyboard is connected.
(2) Go to
editpad.org and type a few words (on either keyboard).
(3) Repeatedly press Ctrl-Z on the physical keyboard to undo the typing.
What is the expected result?
Undo should work as it does on other platforms, where undo removes several words (e.g. a sentence) at a time.
What happens instead?
Undo undoes one character at a time, and causes the word with a character being removed from it to become selected.
This happens because InputMethodController::SetComposition() works by selecting the composition range (which closes out the previous TypingCommand, putting it on the undo stack; this is why undo happens one character at a time), replacing the selection, and then converting the selection back to a composition range (without updating the selection in the open TypingCommand; this is why undo selects the words).
I tested typing in Japanese on macOS and similar behavior resulted.
This bug would affect Android particularly badly (since pretty much all on-screen keyboards use composition ranges for composing text, even for alphabetic languages), except the only way I know of triggering undo on Android is pressing Ctrl-Z on a physical keyboard. If we ever want to expose undo in the UI, fixing this bug will become high-pri.
--
You received this message because:
1. You were specifically CC'd on the issue
2. You are auto-CC'd on all issues in component Blink>Editing>IME
You may adjust your notification preferences at:
https://bugs.chromium.org/hosting/settingsReply to this email to add a comment.