-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Add Ability to Enable/Disable Shortcuts and Selection for LineEdit/TextEdit #31188
Add Ability to Enable/Disable Shortcuts and Selection for LineEdit/TextEdit #31188
Conversation
This issue also requests the same feature in TextEdit. |
ecd8805
to
37e620d
Compare
Needs a rebase to remove the merge commit and fix merge conflicts, otherwise I guess it should be ok to merge. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem to fix the linked issue? As it describes disabling selections not shortcuts.
In any case, you should only need to remove the shortcuts inside new method _generate_context_menu
leaving the main switch alone.
I've tried that before, but it does not seem to have any effect. The context menu will show or not show the shortcut keys... but the switch statement causes the shortcut keys to have effect regardless of whether the context menu has them or not. |
d8c3b6d
to
ba1a86f
Compare
Ahh my bad, I remember now, currently they are visual only. Related #29490, which will require shortcuts to handle echoed events before they can be changed. In that case, there are a couple missing:
|
ba1a86f
to
7fc5b77
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple notes left inline, It's also still possible to select with the mouse or shift + arrow keys within line_edit
.
This PR adds the ability to enable/disable shortcut keys and selection for LineEdit/TextEdit. It also updates the context menu when you disable/enable the shortcut keys or selection.
7fc5b77
to
b678d68
Compare
Thanks! |
This PR adds the ability to enable/disable shortcut keys and selection for LineEdit and TextEdit.
Closes: #31183