Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. QLineEdit using backspace on virtual keyboard causes keyboard to flash

QLineEdit using backspace on virtual keyboard causes keyboard to flash

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
4 Posts 3 Posters 429 Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    carlinski
    wrote on last edited by
    #1

    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.

    1 Reply Last reply
    0
    • Axel SpoerlA Offline
      Axel SpoerlA Offline
      Axel Spoerl
      Moderators
      wrote on last edited by
      #2

      I can reproduce this, if I have an application with just one QLineEdit and 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 QLineEdit is your use case, I would probably subclass it and override ```focusOutEvent()``

      Software Engineer
      The Qt Company, Oslo

      1 Reply Last reply
      1
      • C Offline
        C Offline
        carlinski
        wrote on last edited by
        #3

        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.

        1 Reply Last reply
        0
        • Andy314A Offline
          Andy314A Offline
          Andy314
          wrote on last edited by
          #4

          Hi carlinski, I struggle on the same problem. Have you solved it ?

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved