3 ms·
It's actually not a Gboard bug, but rather a side effect caused by a design choice of Gboard that Gboard tries to handle text editing in a normal text box by it
by suzhe 2y ago
It's actually not a Gboard bug, but rather a side effect caused by a design choice of Gboard that Gboard tries to handle text editing in a normal text box by itself whenever possible. For example Gboard handles the delete key event by itself and delete the letter before the cursor directly instead of sending the delete key event to the app and rely on the app to delete the letter.
Gboard does it in this way for many reasons, but the side effect is that the app should not use a normal text box and expect to receive all key events. It's different than using a physical keyboard on a desktop/laptop computer. That said, do not expect a virtual keyboard to behave in the same way as a physical keyboard.
The workaround mentioned in the article makes sense.
Another possible solution for apps that want to receive raw key events is to use a password input box instead of a normal text box.
- orf 2y ago> It's actually not a Gboard bug, but rather a side effect caused by a design choice of Gboard… It’s definitely a bug, because the design choice they made breaks invariants and causes buggy behaviour in otherwise functioning code. Otherwise it would be like saying “segfaulting randomly is actually not a bug, but rather a side effect caused by a design choice we made to have sloppy code and terrible memory management”.
- a2128 2y agoThis design choice is necessary because Android keyboards aren't just keyboards, they're input method editors. Software receiving simple codepoints as input works great on English desktop computers where every inputtable character can be neatly laid out on a QWERTY keyboard, but when it comes time to support more complex languages or even autocorrect it usually devolves into a hacky mess