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

SearchViewlet is missing multi-line "surrounding context" #18791

Closed
PoisonousJohn opened this issue Jan 19, 2017 · 9 comments
Closed

SearchViewlet is missing multi-line "surrounding context" #18791

PoisonousJohn opened this issue Jan 19, 2017 · 9 comments
Labels
feature-request Request for new features or functionality *out-of-scope Posted issue is not in scope of VS Code search Search widget and operation issues
Milestone

Comments

@PoisonousJohn
Copy link

PoisonousJohn commented Jan 19, 2017

In Sublime text when you search something in the whole project, you can see the so called "surrounding context" in results. This feature is really helpful when you're searching in large projects.

Surrounding context in Sublime Text

It would be great to have this feature in vscode

@dbaeumer dbaeumer added the search Search widget and operation issues label Jan 20, 2017
@sandy081
Copy link
Member

We do show the surrounding context for search results in the search viewlet.

image

Since we show in viewlet, It is restricted only to the line of the match. But do not show previous or next lines if they do not have matches.

@sandy081 sandy081 added this to the Backlog milestone Jan 20, 2017
@sandy081 sandy081 added the feature-request Request for new features or functionality label Jan 20, 2017
@PoisonousJohn
Copy link
Author

@sandy081 yes, this is what I'm talking about. One line is not enough for context. And the lack of this feature stops me from choosing VSCode as the only editor I use. It's essential for large projects.

@PoisonousJohn PoisonousJohn changed the title Search results window is missing "surrounding context" Search results window is missing multi-line "surrounding context" Jan 20, 2017
@PoisonousJohn PoisonousJohn changed the title Search results window is missing multi-line "surrounding context" SearchViewlet is missing multi-line "surrounding context" Jan 20, 2017
@chesucr
Copy link

chesucr commented May 12, 2017

I agree with @ivanfateev . And I think it would be better to show the results in a new tab as a new text file like Sublime does. In this way we could do some search in this new text file again, it is very useful for big projects

@gitmatheus
Copy link

Having more than one line would be very helpful.

@sandy081 sandy081 removed their assignment Dec 4, 2017
@Luchanso
Copy link

Luchanso commented Mar 8, 2018

Yeah, it will be great feature for search

@a7madgamal
Copy link

wow I expected some config to set not an issue :(

@jb510
Copy link

jb510 commented Nov 26, 2018

related #59458

Note, what I want is exactly Sublime Text's behavior. Moving search to the bottom tab helps, but is still very cumbersome. Providing multi-line context will help, but I also want to see file paths and line numbers. Trust all of this is in 50464 for "someday".

@a7madgamal
Copy link

FYI there is a setting for line numbers

@roblourens
Copy link
Member

I don't think this fits in the search viewlet. It's not intended to be a place where you read your code, it's too narrow for that. But, when we support showing results in an editor, then we will have this.

@roblourens roblourens added the *out-of-scope Posted issue is not in scope of VS Code label Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Request for new features or functionality *out-of-scope Posted issue is not in scope of VS Code search Search widget and operation issues
Projects
None yet
Development

No branches or pull requests

9 participants