QLineEdit using backspace on virtual keyboard causes keyboard to flash
-
Qt 6.10
I've created a blank QWidget project, added a QLineEdit with some test text. Ran project, click on the QLineEdit and when pressing backspace to delete the last character, the virtual keboard disappears and reappears.
Typing normally in the QLineEdit is all OK, just the backspace.
Android 15.
-
I can reproduce this, if I have an application with just one
QLineEditand nothing else.
I don't know of any (non-Qt) application that is identical, but I guess it would behave in the same way.
Deleting the last character makes the line edit loose input focus, triggered by Android.
Since there is only one window, it is immediately focused again.
That causes the flicker.If a single
QLineEditis your use case, I would probably subclass it and override ```focusOutEvent()`` -
Thanks, yes I may go the subclass route. It's not a behaviour that I've seen before in Qt. It seems odd that Android should make the control loose focus. When I say last character, it even does it when there are characters left. Anyway, thanks for you reply.