From 5e79b99eea9eeff02cf87d42c51e1715c98789a5 Mon Sep 17 00:00:00 2001 From: Christoffer Aasted Date: Tue, 14 Feb 2023 22:48:55 +0100 Subject: [PATCH] lspOptions: diagLineHL --- autoload/lsp/lsp.vim | 4 ++++ doc/lsp.txt | 2 ++ plugin/lsp.vim | 1 - 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/autoload/lsp/lsp.vim b/autoload/lsp/lsp.vim index b2e90ea..42ce8bd 100644 --- a/autoload/lsp/lsp.vim +++ b/autoload/lsp/lsp.vim @@ -31,6 +31,10 @@ var ftypeServerMap: dict> = {} var lspInitializedOnce = false def LspInitOnce() + var lineHL: string = opt.lspOptions.diagLineHL + if lineHL->empty() + lineHL = 'MatchParen' + endif # Signs used for LSP diagnostics sign_define([{name: 'LspDiagError', text: 'E>', texthl: 'ErrorMsg', linehl: 'MatchParen'}, diff --git a/doc/lsp.txt b/doc/lsp.txt index bc3d47b..a026ee1 100644 --- a/doc/lsp.txt +++ b/doc/lsp.txt @@ -277,6 +277,8 @@ keepFocusInReferences Focus on the location list window after noDiagHoverOnLine Suppress diagnostic hover from appearing when the mouse is over the line instead of the signature. By default this is set to true. +diagLineHL Highlight used for diagnostic line. + Use `NONE` to disable. noNewlineInCompletion Suppress adding a new line on completion selection with . By default this is set to false. diff --git a/plugin/lsp.vim b/plugin/lsp.vim index c983f56..3f190b5 100644 --- a/plugin/lsp.vim +++ b/plugin/lsp.vim @@ -168,5 +168,4 @@ if has('gui_running') \ :LspHighlightClear endif endif - # vim: shiftwidth=2 softtabstop=2 -- 2.48.1