Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Qt 6
  4. TextField Android Keyboard Covering
Forum Updated to NodeBB v4.3 + New Features

TextField Android Keyboard Covering

Scheduled Pinned Locked Moved Unsolved Qt 6
1 Posts 1 Posters 298 Views
  • 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by A Former User
    #1

    Hello guys I'm working Android 10 with Qt 6.2. I have TextField clicking it opens the keyboard and overlays TextField. A person/institution called FalsinSoft has produced such a solution.

    QML: Resize controls when Android virtual keyboard come up

    sample project AndroidKeyboardSize

    Everything is ok, but there is a problem on the Java side (I don't know much about Java). The output is like this

    W System.err: java.lang.NullPointerException: Attempt to invoke virtual method 'android.view.View android.app.Activity.findViewById(int)' on a null object reference
    

    The error occurs on this line.

    Github Link

    Line

    final View AppRootView = ((ViewGroup)m_ActivityInstance.findViewById(android.R.id.content)).getChildAt(0);
    

    How can I fix this error? Or is there a different solution where we can scroll my QML screen when the keyboard is opened?

    @FalsinSoft

    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