rstudio/rstudio — pull request #235 by kevinushey (2014-11-29 00:21:01+00:00)
Title: file search widget

Not ready for merge, but ready for discussion -- @jjallaire, maybe we can chat on Monday?

![file-search](https://cloud.githubusercontent.com/assets/1976582/5232998/9ae2ea30-7719-11e4-888e-8928f0c1b241.gif)

This PR adds a file search widget that can (currently) be used as a more powerful method of obtaining filename completions. The general idea:

1. The user hits `CMD + SHIFT + P` to pop up the search widget,
2. The client gets all files available within the current project from the server,
3. The client narrows and displays the top ~20 matching results based on their query, using fuzzy matching,
4. The user can click or select a file entry to insert that into the source editor.

An obvious problem we see currently with e.g. RStudio is that long files will trail off-screen, but the fact that this works speedily even with RStudio itself means it should be useful for other projects as well.

The main reason I have this as a separate widget rather than as part of the built-in completion framework -- the current completion UI attempts to display _all_ available completions, so the user can scroll and whatnot as necessary. This widget is more restricted in that it _only_ displays the top 20 matches, and the onus is on the user to type a narrow enough query to identify the file they want (or at least narrow to 20 candidates).

Let me know if you think this would be useful, and have any other ideas for e.g. display, UI, and so on.