disable diagnostic float window
This commit is contained in:
parent
a11811019c
commit
903112b0bb
@ -117,7 +117,6 @@ return {
|
|||||||
vim.keymap.set('n', '<A-o>', '<cmd>ClangdSwitchSourceHeader<CR>',
|
vim.keymap.set('n', '<A-o>', '<cmd>ClangdSwitchSourceHeader<CR>',
|
||||||
{ noremap = true, silent = false, desc = 'Switch Source/Header', buffer = bufnr })
|
{ noremap = true, silent = false, desc = 'Switch Source/Header', buffer = bufnr })
|
||||||
|
|
||||||
vim.cmd([[autocmd CursorHold <buffer> lua OpenDiagFloat()]])
|
|
||||||
|
|
||||||
-- Set some keybinds conditional on server capabilities
|
-- Set some keybinds conditional on server capabilities
|
||||||
if client.server_capabilities.documentFormattingProvider then
|
if client.server_capabilities.documentFormattingProvider then
|
||||||
@ -311,21 +310,7 @@ return {
|
|||||||
})
|
})
|
||||||
|
|
||||||
-- vim.diagnostic.config({ virtual_text = false })
|
-- vim.diagnostic.config({ virtual_text = false })
|
||||||
vim.diagnostic.config({
|
vim.diagnostic.config({ virtual_text = false })
|
||||||
virtual_text = false,
|
|
||||||
signs = true,
|
|
||||||
float = {
|
|
||||||
border = 'single',
|
|
||||||
format = function(diagnostic)
|
|
||||||
return string.format(
|
|
||||||
'%s (%s) [%s]',
|
|
||||||
diagnostic.message,
|
|
||||||
diagnostic.source,
|
|
||||||
diagnostic.code or diagnostic.user_data.lsp.code
|
|
||||||
)
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
end,
|
||||||
event = 'VeryLazy'
|
event = 'VeryLazy'
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user