Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Special Interest Groups
  3. C++ Gurus
  4. Using QT with keyboard but without benefit of the mouse
QtWS25 Last Chance

Using QT with keyboard but without benefit of the mouse

Scheduled Pinned Locked Moved C++ Gurus
2 Posts 2 Posters 2.1k 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.
  • L Offline
    L Offline
    lsatenstein
    wrote on last edited by
    #1

    Under Linux I have to deliver an application that does not use the mouse. I believe I setup everything ok, and here is the problem.
    On one system, on program startup, the keyboard is active and the Qt MainWindow application recognizes the keyboard input as expected.

    On some other Linux systems, including the one on which I am developing, (I am trying different test platforms), the identical Qt from same 4.74 version and identical source code is blocked. By blocked, I mean that the application does not recognize keyboard entries until a) I use the alt-tab to move to another desktop and return, or b) if I click anywhere on active Qt application screen with the mouse, from then on the Qt application recognizes the keyboard.

    Any clues as to what I can do to circumvent this initialisation problem? The application is using buttons throughout. Tabbing to the button and hitting enter works once past initialisation.

    I am a true beginner in C++ (I come from 25 years of C programming), so I am experiencing a new world of C++ and Qt.

    This is my trains of thought, after reading about mouseevents.
    a) create a method in MainWindow::InitializeKeyboard() and have that method signal a mouseclick using coordinates of the first button. I believe that by doing this action, it will initialize the Qt code and also the keyboard recognition.

    b) Call for help from this forum

    c) Both a) and b).

    If you can help, I will be grateful. I am already late for resolving this problem.

    I will be cross posting to Installation and Deployment.

    Thanks in advance

    1 Reply Last reply
    0
    • EddyE Offline
      EddyE Offline
      Eddy
      wrote on last edited by
      #2

      Please don't post the same question twice in defferent subforums.

      I'm closing this one.

      Continue on "this thread":https://developer.qt.nokia.com/forums/viewthread/12092/ please.

      Qt Certified Specialist
      www.edalsolutions.be

      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