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

set <backspace> to remove suggestions first #36

Open
257 opened this issue Feb 14, 2015 · 3 comments
Open

set <backspace> to remove suggestions first #36

257 opened this issue Feb 14, 2015 · 3 comments

Comments

@257
Copy link

257 commented Feb 14, 2015

much like google chrome's addr bar and qt's autocompletion. there are many more examples. i've discussed this before here:
fish-shell/fish-shell#1419

@hchbaw
Copy link
Owner

hchbaw commented Feb 21, 2015

Sorry, I'm not sure what to do with fish-shell/fish-shell#1467 (add most_visited_path; a new suggestion category (see also 1465) ) about "set to remove suggestions first".

@257
Copy link
Author

257 commented Feb 21, 2015

apologies, wrong reference number. i updated the link; the correct link is:
fish-shell/fish-shell#1419

the idea is to have backspace delete suggestion part first in the following sense:
say user has typed 'bar' and there is a suggestion 'FOO' for it. so he sees barFOO completed for him but he hasn't typed the FOO part of it yet and in fact he doesn't want FOO. if fact he is aiming for barBAZ. so he hits backspace; what happens in auto-fu deletes rFOO. so looses the r. he types r one more time but auto-fu again completes to barFOO! and we have an comic loop. there is no way to stop this cycle short of hitting after r in order to stop the completion and then typing BAZ and only then going around and removing the space at the end.

others (qt, google-chrome/safari's address bar) have resolved this by not being intrusive in the sense that backspace will remove FOO from the above example and in doing so it won't interfere with user's typed string. furthermore it will cease to complete for the first char that user is going to send afterwards. that is, program remembers that FOO was rejected (a la backspace) and stops offering it.
also note that nothing of what user has typed gets deleted. if users wants to remove anything from bar he simply has to hit backspace one more time and r gets wiped this time and so on.

@257
Copy link
Author

257 commented Feb 21, 2015

i have updated my comment, this may not be reflected in email version sent out by github. please follow the web version. thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants