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. qplatforminputcontext.h file doesnot exist in qt 5.7

qplatforminputcontext.h file doesnot exist in qt 5.7

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
3 Posts 3 Posters 2.0k Views 2 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.
  • A Offline
    A Offline
    amruz
    wrote on last edited by kshegunov
    #1

    i am trying to use a virtual keyboard in raspberry pi using a cross compiled qt. i am trying it in my laptop first.

    when i am including the header

    #include<qpa/qplatforminputcontext.h>
    

    it is showing as
    "no such file or directory"

    i have tried by putting the following in the .pro file

    QT += gui-private
    
    greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
    

    and also the include path of the qpa file in my .pro.

    the header file qplatforminputcontext.h is present in qtbase->incude->qtgui->5.7.0->qpa

    why is it popping out such an error.
    can anyone please help me with this
    thanks in advance

    kshegunovK 1 Reply Last reply
    0
    • VRoninV Offline
      VRoninV Offline
      VRonin
      wrote on last edited by
      #2

      Any private part of Qt (for example this one) comes with a pretty clear disclaimer at the top:

      //
      //  W A R N I N G
      //  -------------
      //
      // This file is not part of the Qt API.  It exists purely as an
      // implementation detail.  This header file may change from version to
      // version without notice, or even be removed.
      //
      // We mean it.
      //
      

      "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
      ~Napoleon Bonaparte

      On a crusade to banish setIndexWidget() from the holy land of Qt

      1 Reply Last reply
      3
      • A amruz

        i am trying to use a virtual keyboard in raspberry pi using a cross compiled qt. i am trying it in my laptop first.

        when i am including the header

        #include<qpa/qplatforminputcontext.h>
        

        it is showing as
        "no such file or directory"

        i have tried by putting the following in the .pro file

        QT += gui-private
        
        greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
        

        and also the include path of the qpa file in my .pro.

        the header file qplatforminputcontext.h is present in qtbase->incude->qtgui->5.7.0->qpa

        why is it popping out such an error.
        can anyone please help me with this
        thanks in advance

        kshegunovK Offline
        kshegunovK Offline
        kshegunov
        Moderators
        wrote on last edited by kshegunov
        #3

        Have you tried checking if the file actually exists? I agree with @VRonin however that I don't see a good reason why you'd need the private headers to begin with. Here's what Thiago Macieira (Qt developer) says on the subject:

        The only reason to subclass one of Qt's QXxxxPrivate classes is if you're
        developing something as part of Qt.

        If you're feeling adventurous, you may want to access one of those classes,
        without deriving from them. But you're still accessing private API and you're
        subject to the "We mean it" comment in the header. Your binary will be tagged
        on Linux as "Qt5_PRIVATE_API" and Linux distros will give you a dirty look.

        Read and abide by the Qt Code of Conduct

        1 Reply Last reply
        2

        • Login

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