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

Close the quickfix window altogether with the preview window #217

Open
ghost opened this issue May 16, 2017 · 1 comment
Open

Close the quickfix window altogether with the preview window #217

ghost opened this issue May 16, 2017 · 1 comment

Comments

@ghost
Copy link

ghost commented May 16, 2017

Is it possible to add a new feature to close the quick fix window altogether with the preview window?
Maybe just another keyboard shortcut in the quickfix window?

@ches ches added the question label Nov 5, 2017
@ches
Copy link
Collaborator

ches commented Nov 5, 2017

Hi, sorry for the very slow response—I'm not sure I understand the question.

ack.vim's notion of "preview" is a misnomer (i.e. it's not :help preview-window), the mappings like go in the quickfix list just open a normal buffer but leave the cursor in the results list. So you have the ability already to use mappings like O to open a result and close the results list at the same time, but if you mean that the behavior you want is like "close the quickfix list and reopen whatever buffer I was in before I started an ack.vim search", no that isn't currently possible.

You could probably implement something like this yourself by having a wrapper function/command that saves your current buffer number in a variable and then runs :Ack*, and a mapping to reopen it and :cclose.

This might be obviated if #135 was brought up-to-date and finished, which I think would be nice, but I haven't had time to try myself.

Let me know if I've misunderstood the question/feature request completely.

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

No branches or pull requests

1 participant