onivim / oni

Oni: Modern Modal Editing - powered by Neovim
https://www.onivim.io
MIT License
11.35k stars 301 forks source link

Add option to disable filtering capability for a given menu. #2065

Open CrossR opened 6 years ago

CrossR commented 6 years ago

One thing I've realised is that in the <C - /> menu, the vscode filtering logic actually breaks the search query, since it re-orders a search of thing I'm looking for into I'mlookingforthing which is fair enough for a fuzzy finder search but less so when searching through a file.

Perhaps we could update the menu API to allow setting this functionality?

bryphe commented 6 years ago

Ah ya, I think this would make sense. There was an API on the menu to set an explicit filter function: https://github.com/onivim/oni/blob/48d55d9b7444d045ce364aeba151e90541e3344e/browser/src/Services/Menu/Menu.ts#L150

(This would be another good case to split out the <C-/> functionality from the QuickOpen menu, so that we can specify a custom 'filter strategy'/reuse regex/etc for that!)