arduino / arduino-pro-ide

The Arduino IDE for advanced users and developers. Experimental alpha version.
https://www.arduino.cc
Other
883 stars 71 forks source link

Cannot type 3 & 9 on the number row #129

Closed kanokkorn closed 4 years ago

kanokkorn commented 5 years ago

Describe the bug Cannot type 3 & 9 on the number row

To Reproduce Steps to reproduce the behavior:

  1. press 3 or 9 on the number row

Expected behavior expected key to be working properly

Screenshots Type with on-screen keyboard

Desktop (please complete the following information):

Update

satiowadahc commented 5 years ago

Are you using a US keyboard layout? If you do a command line systeminfo what's the output of System locale and Input locale?

kanokkorn commented 5 years ago

Are you using a US keyboard layout? If you do a command line systeminfo what's the output of System locale and Input locale?

Yes, I'm using a US keyboard layout. Here is the output.

System Locale:             en-us;English (United States)
Input Locale:              en-us;English (United States)
OriginalAdric commented 4 years ago

Trying to clarify the issue: The 3 and 9 keys are being handled as PgDn and PgUp, respectively, both on the number row and numpad. The numpad behavior occurs regardless of Numlock status. The only difference in behavior I've observed is that Shift+3 and Shift+9 also select any text the cursor passes while Shift+Numpad3 and Shift+Numpad9 do not.

This occurs on my desktop Windows PC with full keyboard, both with physical keyboard and on-screen keyboard. This does not occur on my Surface Pro 3 with magnetic keyboard, either with physical or on-screen keyboards.

Sheel-1609 commented 4 years ago

Hi, i have the same problem on my HP laptop. @OriginalAdric is right this 9 and 3 are acting as page up and page down respectively. I have tried this with both US and UK keyboard styles the same problem persists. same with the numpad numbers. This problem also exists with an external keyboard.

flaviosg commented 4 years ago

I have the same problem. I'm using US English International Keyboad layout, with Windows 10. "9" key acts as PgUp and "3" key acts as PgDw. I can only type "3" using ALT+51 and "9" using ALT+57

Ometeo commented 4 years ago

Hi, I have the same problem with the French Keyboard layout, if it helps. OS : Windows 10 Keyboard : Razer Anansi

jankeromnes commented 4 years ago

I wasn't able to reproduce this bug in Arduino Pro v0.0.3, on both Windows 7 and Mac OS:

Maybe this bug is specific to Windows 10?

kittaakos commented 4 years ago

I could reproduce it neither on Windows 10 nor macOS; worked as expected with EN_US layout. I am going to try it again with a real Windows machine with a numpad.

kittaakos commented 4 years ago

It also works on Windows 7 with numpad. I have tried it with the physical and the on-screen keyboard too.

spoenemann commented 4 years ago

I cannot reproduce this on my Windows 10 machine.

@kanokkorn @OriginalAdric @Sheel-1609 @flaviosg @Ometeo Could you help analyzing the problem?

  1. https://w3c.github.io/uievents/tools/key-event-viewer.html (preferably with Chrome)
  2. Enter 39 in the input field
  3. Make a screenshot of the web page and attach here (if it's the same output as already posted by others, there's no need to post it again)
kanokkorn commented 4 years ago

I think I can reproduce this by

  1. changing the language to non-US layout
  2. type with a non-US layout
  3. switch back to US layout

Test on Windows 10 and Ubuntu 18.04 TLS but can't reproduce this bug on Ubuntu. I will test again on a different machine.

spoenemann commented 4 years ago

Finally I could reproduce this. Cause: the mapping returned by native-keymap contains an entry

    "Numpad3": {
        "vkey": "VK_NEXT"
    }

VK_NEXT is the Windows virtual key code for PageDown; this leads to a keybinding mapping where PageDown is replaced with 3.

spoenemann commented 4 years ago

This must be fixed in Theia: https://github.com/eclipse-theia/theia/issues/6872

spoenemann commented 4 years ago

Should be ok with the next update.