Ticket #40032

Apple keyboard numeric keypad support

오픈 날짜: 2020-02-17 01:18 마지막 업데이트: 2021-02-08 06:08

Reporter:
(Anonymous)
소유자:
Status:
Closed
Component:
(None)
MileStone:
(None)
Priority:
5 - Medium
Severity:
5 - Medium
Resolution:
Won't Fix
File:
1

Details

Apple keyboard numeric keypad support

Ticket History (3/8 Histories)

2020-02-17 01:18 Updated by: None
  • New Ticket "Apple keyboard numeric keypad support" created
2020-02-25 06:40 Updated by: backwardseric
댓글 올리기

The new release, 2.2.1.7c, makes changes to how keypresses are handled on the Mac. That should make the numeric keypad more usable (shift + keypad key should now run in that direction, for instance). If there are still problems with using the keypad with the newest release, please indicate what the specific problem is.

2020-02-25 06:45 Updated by: backwardseric
  • 소유자 Update from (None) to backwardseric
2021-01-21 02:20 Updated by: tanguband
댓글 올리기

Added shift key and control key key combinations to pref-mac.prf for use with the Apple keyboard numeric keypad.

See attached file

It works almost as desired, but "shift-KP_Equal" and "control-KP_Equal" do not work.

I checked the keyboard layout from the macro in the game

"KP_Equal" "shift-KP_Equal" "control-KP_Equal" are all displayed as just'='.

For example, " shift + numeric keypad '+' " is displayed as "shift-KP_Add".

If possible, I would appreciate it if you could modify it and adopt the file.

2021-01-21 07:40 Updated by: backwardseric
댓글 올리기

Reply To tanguband

Added shift key and control key key combinations to pref-mac.prf for use with the Apple keyboard numeric keypad.

What is the rationale for those? Is it to make those keys insensitive to whether ctrl or shift is also pressed? I could see having shift+key or ctrl+key mean something different than just key, but I'm not sure I understand having them mean the same thing (unless mistakenly pressing shift or ctrl with the key is common, then I could see setting it up that way).

It works almost as desired, but "shift-KP_Equal" and "control-KP_Equal" do not work. I checked the keyboard layout from the macro in the game "KP_Equal" "shift-KP_Equal" "control-KP_Equal" are all displayed as just'='.

For me, pressing '@' and then 4 to create a new macro, and then pressing '=', 'KP_equal', 'shift-KP_Equal', and 'control-KP_Equal' all report different keys pressed. This is with the English or Japanese version and an external Mac keyboard attached to Mac laptop. The Mac is configured to use the "U.S." keyboard layout.

Pressing '@' and then 8 to create a new keymap treats = and KP_Equal as the same ('=') but does not respond to shift-KP_equal or ctrl-KP_equal.

That basic behavior is probably not going to change. The Mac interface is largely copying what the Windows interface does when the numeric keypad is used: it sends an encoded version of the keystroke and the modifier keys as a macro trigger to the hengband core.

2021-01-21 10:08 Updated by: tanguband
댓글 올리기

The reason is that we want to assign the 'KP_equal' and 'shift-KP_Equal' keys to macro keys in the game.

Press '@' and then '4' to create the macro.

When you press '=', 'KP_equal', and 'shift-KP_Equal' respectively, all that appears in the 'trigger keys' is '='.

For example, if you press the other keys '/', 'KP_Divide' and 'shift-KP_Divide' respectively, the 'trigger keys' will be '/', 'KP_Divide' and 'shift-KP_Divide'.

For some reason, only the '=' key on the numeric keypad is not recognized as 'KP_equal'.

This seems to be caused by my environment.

I will assign the macro to another key and use it.

We will take care of this issue, so you can finish your investigation.

2021-02-08 06:08 Updated by: backwardseric
  • Status Update from Open to Closed
  • Resolution Update from None to Won't Fix
댓글 올리기

I've closed this ticket. It sounds like one of the issues (that KP_equal, shift0-KP_equal, control-KP_equal) may be specific to the keyboard layout (I couldn't reproduce it on the system I have using the "U.S." keyboard layout).

As for the other part of the ticket, incorporating the changes to pref-mac.prf, it still wasn't clear to me why those changes were a good idea (shift + keypad key mapping to the same as keypad key; control + keypad key mapping to the same as keypad key).

If you would still like the changes to pref-mac.prf included or encounter more problems with how keystrokes are passed to Hengband, please post an issue at the GitHub page, https://github.com/backwardsEric/hengband/issues .

Attachment File List

Edit

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Login