bpo-44942: Add numberpad enter bind to TK's simpleDialog#27498
bpo-44942: Add numberpad enter bind to TK's simpleDialog#27498Electro707 wants to merge 1 commit intopython:mainfrom
Conversation
|
That is not the right bpo number. |
Sorry about this. This PR doesn't have an issue/bug related to it as it's trivial. |
If this change isn't considered something that can be labeled as |
Sounds like a plan. Go for it! |
|
Here is an issue for this PR in the bug tracker: bpo-44942 |
gvanrossum
left a comment
There was a problem hiding this comment.
I'd like our resident IDLE dev, @terryjreedy, have a peek at this. Maybe the intended way to do this would be for the app to add the binding? Or, alternatively, we should do this throughout tkinter whenever <Return> is bound to an "OK" or "default" button? I notice plenty of <Return> elsewhere in tkinter but no <KP_Enter>. I don't have a keyboard with a separate keypad so I can't easily test what other things (built with Tcl/Tk or not) do.
|
For the behavior of other things on Windows (not built with Tcl/Tk) -- system dialog boxes all behave same way regardless of which enter key is pressed, as does any place with text entry/dialog box buttons on the major browsers and powershell/wsl/bash/putty prompts on Windows. Selecting a drop-down menu option using arrow keys+enter also works with either enter key. |
|
The patch is fine in itself, but I am dubious about the intended change. It is not needed on Windows and perhaps wrong elsewhere. See my msg399879 post on the issue. If the issue is rejected, this would be closed. |
|
Closing this PR due to the discussion over at bpo-44942. Thanks for all your help and discussion! |
This is a trivial PR that binds the numberpad enter button to
self.okin simpleDialog'sDialogclass, as Tk treats that the number-pad enter and the main-enter buttons separately.https://bugs.python.org/issue44942