QB64.org Forum
Active Forums => QB64 Discussion => Topic started by: TempodiBasic on January 20, 2019, 12:43:33 pm
-
Hi guys
Great QB64 that I'm still exploring...
now I'm focusing on the keyboard fast input allowed in QB64
well on my TOSHIBA Win key (that is on the left part of keyboard) and Menu key ( that is on the right part of keyboard between Alt Gr and Ctrl at right) give me different codes in respect to those showed into wiki pages for _KEYHIT and _KEYDOWN.
please run this code to see what feedback you have in your PC!
LOCATE 1, 10:
PRINT "Press a key, also Alt, Ctrl, Shift, Keypad... Escape to quit"
_LIMIT 10 ' WHY QB64 is so fast to need this? :-) PRINT " no key " ' no key and k = 0
I get 91 for MenuKey and 93 for WinKey...
and you?
Thanks for feedback
PS:
Win10, QB64 1.2 Dev e490b1a
-
Left Win key 91
Right Win key 92
Menu key 93 - I had to hook up an external keyboard to my laptop to get that one.
https://www.computerhope.com/jargon/w/winkey.htm (Just to see if we are defining these keys properly. Win key is on the left in the first illustration and the menu key is on the right.
Pete
-
Thanks Pete
you're right
91 for LeftWin Key
93 for Menu Key
I have no Right Win key on my ToSHIBA as you can see https://www.google.it/search?q=toshiba+satellite+c850-1lk&client=opera&hs=idj&source=lnms&tbm=isch&sa=X&ved=0ahUKEwi0nM_Uuf3fAhWSEBQKHTifCgsQ_AUIDygC&biw=1326&bih=665#imgrc=KoP-WMaIxKjX-M: (https://www.google.it/search?q=toshiba+satellite+c850-1lk&client=opera&hs=idj&source=lnms&tbm=isch&sa=X&ved=0ahUKEwi0nM_Uuf3fAhWSEBQKHTifCgsQ_AUIDygC&biw=1326&bih=665#imgrc=KoP-WMaIxKjX-M:)
Following your example I have now used an USB wireless Keyboard and I can get 92 for RightWin key and can confirm all codes that you have feedback.
Thanks
Now the question is: do we get the same results in desktop PC?
-
91, 92, 93, but it's impossible for me to register a DOWN even.
Windows 10 traps the key when it goes down, waiting for another keypress so it can do its thing, so QB64 only responds to the key UP event on my machine.
There's no such thing as a down and hold event. :P
None of the commands work at all for me with _KEYDOWN:
_LIMIT 60 ' so your PC fan won't explode with an endless loop
-
None of the commands work at all for me with _KEYDOWN:
Steve I agree
_LIMIT 60 ' so your PC fan won't explode with an endless loop
you can manage only Hit events after those of down event of system!