Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. I can't include QKeyEvent library
Qt 6.11 is out! See what's new in the release blog

I can't include QKeyEvent library

Scheduled Pinned Locked Moved Solved General and Desktop
5 Posts 4 Posters 2.9k 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.
  • RIVOPICOR Offline
    RIVOPICOR Offline
    RIVOPICO
    wrote on last edited by
    #1

    Hi i can't include this library show me this message:
    C1083: You can't open the file included : 'QKeyEvent': No such file or directory

    I included this:
    #include <QEvent>
    #include <QKeyEvent>

    raven-worxR 1 Reply Last reply
    0
    • RIVOPICOR RIVOPICO

      Hi i can't include this library show me this message:
      C1083: You can't open the file included : 'QKeyEvent': No such file or directory

      I included this:
      #include <QEvent>
      #include <QKeyEvent>

      raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by
      #2

      @RIVOPICO
      does #include <QtGui/QKeyEvent> work for you?
      Did you compile Qt yourself?

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      1 Reply Last reply
      1
      • U Offline
        U Offline
        Ugiat
        wrote on last edited by
        #3

        You must include QT += gui to your .pro file.

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

          make sure you have QT += gui in your pro and rerun qmake

          EDIT:
          I was too slow

          "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

          RIVOPICOR 1 Reply Last reply
          3
          • VRoninV VRonin

            make sure you have QT += gui in your pro and rerun qmake

            EDIT:
            I was too slow

            RIVOPICOR Offline
            RIVOPICOR Offline
            RIVOPICO
            wrote on last edited by RIVOPICO
            #5

            thx a lot

            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