Make all search-result editors have no line numbers

And make that configurable
This commit is contained in:
Jackson Kearl 2019-12-04 10:02:23 -08:00
parent a56829c225
commit 0fd472271d
2 changed files with 5 additions and 2 deletions

View file

@ -19,6 +19,11 @@
"vscode:prepublish": "node ../../node_modules/gulp/bin/gulp.js --gulpfile ../../build/gulpfile.extensions.js compile-extension:search-result ./tsconfig.json"
},
"contributes": {
"configurationDefaults": {
"[search-result]": {
"editor.lineNumbers": "off"
}
},
"commands": [
{
"command": "searchResult.rerunSearch",

View file

@ -291,8 +291,6 @@ export const createEditorFromSearchResult =
const editor = await editorService.openEditor(possible);
const control = editor?.getControl()!;
control.updateOptions({ lineNumbers: 'off' });
const model = control.getModel() as ITextModel;
model.deltaDecorations([], results.matchRanges.map(range => ({ range, options: { className: 'searchEditorFindMatch', stickiness: TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges } })));