Delete the previous word with Ctrl+W in the shell's filter fields - #9514
Open
BrouZie wants to merge 1 commit into
Open
Delete the previous word with Ctrl+W in the shell's filter fields#9514BrouZie wants to merge 1 commit into
BrouZie wants to merge 1 commit into
Conversation
Ctrl+W is the terminal's werase and readline's unix-word-rubout, but it did nothing in the searchable panels: with Ctrl held Qt sends 0x17, which their printable-character catch-all drops. Fold it into the branches that already handle Ctrl+U and Ctrl+Backspace, so all five filter surfaces pick it up through the shared helper.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The filter field already takes
Ctrl+Uto clear itself - that is the terminal'skill-line.
Ctrl+Wis its sibling on the other half of that pair (werase, orunix-word-ruboutin readline), and today it does nothing. This adds it, doingthe same word delete
Ctrl+Backspacealready does.Five lines in
shell/Commons/Util.qml: both conditions it needs already existedand only needed widening, so there is no new code path and still one copy of the
word-delete expression. The two helpers are shared, so it lands in the menu,
clipboard, emojis, image picker and reminders at once, with no changes at the
call sites.
Ctrl+Won an empty filter stays inert, so the menu'sBackspace/Leftback-navigation is untouched.
Ctrl+Shift+Wstays inert too, matching the wayCtrl+Uis matched today../test/all: 1 of 221 test files failed (bar-icon-geometry-test.sh). The samefailure happens on a clean origin/quattro and on the feature-branch. Referenced
is a video of a live test:
ctrl-w.mp4