add(nvim): lsp-signature

This commit is contained in:
Léana 江 2023-12-05 16:55:30 +01:00 committed by Léana 江
parent b9d1a0d9ce
commit 60bd3961e8
3 changed files with 11 additions and 2 deletions

View file

@ -76,9 +76,8 @@ local on_attach = function(client, bufno)
map("n", "<leader>r", vim.lsp.buf.rename, opts)
map("n", "<leader>f", function() vim.lsp.buf.format { async = true } end, opts)
local navic = require "nvim-navic"
if client.server_capabilities.documentSymbolProvider then
navic.attach(client, bufno)
require "nvim-navic".attach(client, bufno)
end
end
@ -96,6 +95,14 @@ function vim.lsp.util.open_floating_preview(contents, syntax, opts, ...)
return orig_util_open_floating_preview(contents, syntax, opts, ...)
end
-- Type signature
require "lsp_signature".setup {
doc_lines = 7,
bind = true,
border = border,
hint_enable = false,
}
-- Diagnostic display configuration
vim.diagnostic.config { virtual_text = false, severity_sort = true }