Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keyboard: Numpad Enter, a key that may be forgotten #319

Open
Demonese opened this issue May 12, 2022 · 4 comments
Open

Keyboard: Numpad Enter, a key that may be forgotten #319

Demonese opened this issue May 12, 2022 · 4 comments
Labels
enhancement input Related to GamePad, Keyboard, and Mouse

Comments

@Demonese
Copy link

There are two facts:

I used to think window messages couldn't differentiate between Enter and Numpad Enter, but:

  • Press Enter key
    image
  • Press Enter key on numpad
    image

This issue is also mentioned in the source code of Dear-ImGui (imgui_impl_win32).

Since my application was migrated from DirectInput to DirectXTK Keyboard, will the Numpad Enter key be officially supported in the future?

@Demonese
Copy link
Author

There many Undefined/Unassigned key codes in Virtual-Key Codes space, can we use them to store Numpad Enter?

@walbourn
Copy link
Member

Thanks for the report. I see that DirectInput had it's own enum that included DIK_NUMPADENTER, but there's no such virtual key defined (both return VK_RETURN).

I could emulate this with Win32, but I'll need to escalate this a bit since GameInput should also do this.

@walbourn walbourn added input Related to GamePad, Keyboard, and Mouse enhancement labels May 12, 2022
@walbourn
Copy link
Member

We are working to reserve 0x0E as VK_NUMPAD_RETURN to avoid any future conflicts.

@walbourn walbourn self-assigned this Oct 17, 2022
@Demonese
Copy link
Author

Constant Value Description
VK_RETURN 0x0D ENTER key
- 0x0E-0F Undefined
VK_SHIFT 0x10 SHIFT key
Maybe a good option, close to VK_RETURN. 👍

@walbourn walbourn pinned this issue Dec 11, 2022
@walbourn walbourn removed their assignment Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement input Related to GamePad, Keyboard, and Mouse
Projects
None yet
Development

No branches or pull requests

2 participants