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. Cannot use the numeric keypad with Qt Apps
Forum Updated to NodeBB v4.3 + New Features

Cannot use the numeric keypad with Qt Apps

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 2 Posters 1.1k Views 1 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.
  • I Offline
    I Offline
    itanitarek10
    wrote on last edited by itanitarek10
    #1

    Hello,

    As the title states the numeric keypad on the right side of my keyboard does not work with Qt applications. I first thought it was an OS problem (using RHEL 8.4) because they would not work anywhere. But after using the

    setxkbmap -option keypad:pointerkeys
    

    command they would work on the OS when toggling num lock. However now that I can use it for the OS, they still do not work with Qt. How can I resolve this? I am using a 32-bit version of Qt 5.14.0 on RedHat 8.4.

    Thank you

    Edit: I found out that if I have numlock off and press shift + a key the number can be entered. However with numlock on, the keypad is (mostly) useless.

    1 Reply Last reply
    0
    • Kent-DorfmanK Offline
      Kent-DorfmanK Offline
      Kent-Dorfman
      wrote on last edited by
      #2

      use xev to verify the keycodes and keysyms being returned. Your problem is non-Qt specific. You have to address it in X11.

      https://tronche.com/gui/x/xlib/input/keyboard-encoding.html

      I light my way forward with the fires of all the bridges I've burned behind me.

      I 1 Reply Last reply
      0
      • Kent-DorfmanK Kent-Dorfman

        use xev to verify the keycodes and keysyms being returned. Your problem is non-Qt specific. You have to address it in X11.

        https://tronche.com/gui/x/xlib/input/keyboard-encoding.html

        I Offline
        I Offline
        itanitarek10
        wrote on last edited by itanitarek10
        #3

        @Kent-Dorfman Thanks for the link. After using xev I can see that the keycodes and keysyms are different for the numbers at the top row than on the keypad. However I still do not understand why Qt cannot pickup the keypad numbers with numlock enabled when the terminal and other X11 applications can.

        However, using the shift key + numlock disabled + a keypad number works with Qt.

        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