Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Getting NumLock and keyboard numeric keypad to work for button presses.



  • While I have been able to get the generic number sequence 0-9 working with my keyboard by using the Keys QML type:

        Keys.onDigit0Pressed: outValue+=0
        Keys.onDigit1Pressed: outValue+=1
        Keys.onDigit2Pressed: outValue+=2
        Keys.onDigit3Pressed: outValue+=3
        Keys.onDigit4Pressed: outValue+=4
        Keys.onDigit5Pressed: outValue+=5
        Keys.onDigit6Pressed: outValue+=6
        Keys.onDigit7Pressed: outValue+=7
        Keys.onDigit8Pressed: outValue+=8
        Keys.onDigit9Pressed: outValue+=9
    

    I was wondering how I might go about getting the numeric keyboard keys to work when the user has NumLock on, is that possible?


Log in to reply