Skip to content

Show quick open results as preview while navigating through them #8939

Open

Description

@drew-wallace
  • VSCode Version: 1.3.0
  • OS Version: Windows 10 64bit & Mac OS X 10.11.3

Steps to Reproduce:

  1. Open the Quick Open box
  2. Type a file name that returns several results
  3. A new Preview editor pops up and receives focus with the first result loaded into it
  4. Scroll through the results in the Quick Open box and the Preview editor changes to the file that's highlighted
  5. Selecting a result will fully open the file. Canceling can close the Preview editor or leave it open. I'd prefer if it closed the preview.

Activity

  1. added
    feature-request
    workbench-tabs
    on Jul 8, 2016
  2. added
    ux
    on Jul 8, 2016
  3. bgashler1 commented on Jul 12, 2016

    @bgashler1
    Contributor

    I myself have been wanting this very same thing. I tend to open several files up front, and then I have to double-click each one.

    I think that opening something via Quick Open as a fully-opened file makes sense in this case, because if you had the opportunity to see a preview and still committed via enter or a click to open it then you probably intend to keep it around for a while.

  4. drew-wallace commented on Jul 12, 2016

    @drew-wallace
    Author

    Just to be clear, the point of this is to see the contents of a file as I scroll through the results of Quick Open. As far as permanently opening a file from quick open, that would be good too.

  5. stevencl commented on Jul 20, 2016

    @stevencl
    Member

    Previewing files as you move up and down the list of results makes a lot of sense. For files that are currently open we would bring them to the front.

  6. bgashler1 commented on Jul 20, 2016

    @bgashler1
    Contributor

    UX meeting notes
    We agreed that this is a compelling interaction need. We considered how competing products handle this, and we found that Visual Studio IDE handles it best. We will apply the relevant Quick Open interaction patterns:

    • Quick Open will now create a preview editor (or leverage the already open one, if one exists) to show you a preview of each item you focus on in the list.
    • Upon hitting Enter, the open editor will be kept open (i.e. no longer preview).
    • If a user hits Esc or clicks away from the Quick Open command palette…
      • The command palette will close and whichever open editor you were on before previewing will be brought back in view.
      • The preview editor will remain and whatever you last were looking at in Quick Open will also remain inside that preview editor—exception: if you were already on a preview editor when you opened Quick Open and previewed some items but never selected any (e.g. escaped out of it) then we will restore whatever you previously had open in that preview tab, since that would indicate that the preview tab is likely something you want to keep and not replace. Otherwise, if you didn't already have a preview editor open before previewing in Quick Open pressing Esc will remove the preview editor as if nothing happened.

    Bold = addition
    Strikethrough = deletion

  7. smuuf commented on Aug 22, 2016

    @smuuf

    I'm glad I found this issue (under this not-so-much clear title), so I don't have to create it myself.

    I just got annoyed by this behaviour of closing files - I evidently wanted to have opened - for the 451th time in the last two weeks.

    Please, let's make it into the next release. :)

  8. wprater commented on Oct 17, 2016

    @wprater
    Contributor

    Ive spent some time working through this. Have a good understanding of the organization of the editorPart, groups, stack model, etc. Pushing up a PR, but I'd really like to fix some UX issues below.

    The preview editor will remain and whatever you last were looking at in Quick Open will also remain inside that preview editor—exception: if you were on a preview editor when you opened Quick Open and previewed some items but never selected any (e.g. escaped out of it) then we will restore whatever you previously had open in that preview tab, since that would indicate that the preview tab is likely something you want to keep and not replace.

    I think a better UX would be to close a preview editor if there were none open. Hitting escape should remove all side effects e.g. opening a new preview editor.

    Upon hitting Enter, the open editor will be kept open (i.e. no longer preview).

    Would we prefer to honor the user preference workbench.editor.enablePreviewFromQuickOpen (this is how Ive implemented it)

  9. wprater commented on Oct 17, 2016

    @wprater
    Contributor

    Another UX issue that I discovered while previewing in a current previewEditor: the scroll positions are lost.

    We could keep track of a selection/cursor when opening with TextEditorOptions, however, this feels kind of kludgy to keep track of this just if we are swapping the contents of a preview editor. An easier approach could be to render a tab-less editor that would be show while previewing files that are not find in the current editor groups.

    Thoughts?

  10. drew-wallace commented on Oct 17, 2016

    @drew-wallace
    Author

    Sublime preserves the cursor position of each file, and when you preview that file, it shows the cursor in that position. If you haven't visited that file before, it defaults to the top of the file.

  11. 76 remaining items

  12. jbrodriguez commented on Apr 13, 2024

    @jbrodriguez

    you're right, yes, not as straightforward, but does the job

  13. joshmu commented on Apr 13, 2024

    @joshmu

    Julian Torres (@macintacos) the Quick Search (experimental) is similar to Periscope in regards to file previews as you navigate across results. The biggest difference would be that Periscope provides access to more of ripgrep. eg: pattern matching, file type & sub folder filtering, etc. You can personalise this to your needs and create abbreviations for your common searches.

    If there is no interest in those type of advanced grep features then Quick Search would be sufficient

  14. h0jeZvgoxFepBQ2C commented on Apr 30, 2024

    @h0jeZvgoxFepBQ2C

    Julian Torres (@macintacos) but the quicksearch feature which you mention, does not work when you go to "open file" search dialogue or? Just for full text seach, not for file search.

  15. macintacos commented on Apr 30, 2024

    @macintacos

    h0jeZvgoxFepBQ2C right. I wasn't saying that that feature in VSCode takes care of this issue. I was just saying that that feature is very similar to the Periscope extension that was linked to earlier in the thread.

    I don't think that the issue described in the original description is "solved", by any means.

  16. musjj commented on Jun 11, 2024

    @musjj

    Would love to have this feature in the editor picker (when you press Ctrl+Tab) too.

  17. LucianCrainic commented on Sep 9, 2024

    @LucianCrainic

    Any news from the dev team on this ? A built in telescope in vscode would make the programming experience soo much better...

  18. Alan-MQ commented on Oct 14, 2024

    @Alan-MQ

    Can anyone help me with this? I've managed to create something similar with a simple script, but I'm unsure how to retrieve the file name from the dropdown menu and display the corresponding content. Currently, I'm trying to build a proxy server, use a VSCode plugin to send UDP packets, and have my script receive those packets to display the content. However, it's becoming quite complicated. Is there a simpler way to achieve this?
    repo ==> https://github.com/Alan-MQ/vscode-setting

    Image

  19. popielasty commented on Oct 14, 2024

    @popielasty

    Bump, still waiting ;)

  20. LucianCrainic commented on Oct 14, 2024

    @LucianCrainic

    Hi Maqing (@Alan-MQ) would you make this open? Looks like you got to an interesting point and i would love to take a look and see if i can help in anyway since i am really looking for this feature in VScode and it's the reason why i am still not switching from nvim to vscode.

  21. Alan-MQ commented on Oct 14, 2024

    @Alan-MQ

    Hi @Alan-MQ would you make this open? Looks like you got to an interesting point and i would love to take a look and see if i can help in anyway since i am really looking for this feature in VScode and it's the reason why i am still not switching from nvim to vscode.

    yeah , sure I've updated that comment, check it out, and feel free to let me know if I missed something~~

  22. BorisKaravasilev commented on Nov 21, 2024

    @BorisKaravasilev

    It would indeed be very useful to automatically show the preview of a searched file.

    Are there any chances of this being prioritized any time soon TylerLeonhardt? :)

  23. HolbyFPV commented on Dec 2, 2024

    @HolbyFPV

    https://github.com/jpcrs/binocular

    Might be a good workaround if you can get it to work. I wasn't having any luck on Windows, despite having all the dependencies.

  24. haxybaxy commented on Mar 20, 2025

    @haxybaxy

    Hey guys, I just made this extension that allows you to preview the files while fuzzy searching through them, as well as fuzzy search and preview for most recent files opened: https://marketplace.visualstudio.com/items?itemName=zaidalsaheb.search-preview

    This is my first time doing something like this, any feedback would be appreciated

  25. haxybaxy commented on May 15, 2025

    @haxybaxy

    Hey guys, I just made this extension that allows you to preview the files while fuzzy searching through them, as well as fuzzy search and preview for most recent files opened: marketplace.visualstudio.com/items?itemName=zaidalsaheb.search-preview

    This is my first time doing something like this, any feedback would be appreciated

    If any of you are still looking for a fix for this, I've since updated this extension a lot and made it a ton better:

    • Uses fzf under the hood so the search is really fast
    • You can browse your most recent files like the oldfiles search in telescope
    • Oldfiles search persists between sessions
    • Works with all file types

    I'm also actively maintaining it so if you have any feature requests or so you can leave them here:
    https://github.com/haxybaxy/search-preview

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

Metadata

Metadata

Labels

feature-requestquick-openux

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions