feat(nvim): set rounded borders all around

This commit is contained in:
Bruno Carlin 2022-04-27 22:57:00 +02:00
parent 0907383db4
commit a72152ad32
3 changed files with 15 additions and 7 deletions

View file

@ -182,8 +182,8 @@ highlight {name="DiffText", fg=colors.blue, bg=colors.base02, attrs={attrs.bold}
-- ErrorMsg error messages on the command line -- ErrorMsg error messages on the command line
highlight {name="ErrorMsg", fg=colors.base03, bg=colors.red, attrs={attrs.bold}} highlight {name="ErrorMsg", fg=colors.base03, bg=colors.red, attrs={attrs.bold}}
-- VertSplit the column separating vertically split windows -- WinSeparator separators between window splits
highlight {name="VertSplit", fg=colors.base00, bg=colors.base00} highlight {name="WinSeparator", link="Normal"}
-- Folded line used for closed folds -- Folded line used for closed folds
highlight {name="Folded", fg=colors.base0, bg=colors.base02, sp=colors.base03, attrs={attrs.underline, attrs.bold}} highlight {name="Folded", fg=colors.base0, bg=colors.base02, sp=colors.base03, attrs={attrs.underline, attrs.bold}}
@ -243,7 +243,7 @@ highlight {name="NonText", fg=colors.base01, attrs={attrs.none}}
highlight {name="Normal", fg=colors.base0, bg=colors.back, attr={attrs.none}} highlight {name="Normal", fg=colors.base0, bg=colors.back, attr={attrs.none}}
-- NormalFloat Normal text in floating windows. -- NormalFloat Normal text in floating windows.
--KEEP DEFAULT : links to Pmenu highlight {name="NormalFloat", link="Normal"}
-- NormalNC normal text in non-current windows -- NormalNC normal text in non-current windows
--KEEP DEFAULT : cleared --KEEP DEFAULT : cleared

View file

@ -1,4 +1,4 @@
local cmp = require'cmp' local cmp = require('cmp')
local kind_icons = { local kind_icons = {
Text = "", Text = "",
@ -47,6 +47,10 @@ cmp.setup({
--vim.fn["vsnip#anonymous"](args.body) --vim.fn["vsnip#anonymous"](args.body)
end, end,
}, },
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
mapping = { mapping = {
['<C-b>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }), ['<C-b>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }),
['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }), ['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }),

View file

@ -5,6 +5,7 @@ vim.diagnostic.config({
}, },
float = { float = {
source = "always", -- Or "if_many" source = "always", -- Or "if_many"
border = "rounded",
}, },
signs = true, signs = true,
underline = true, underline = true,
@ -17,3 +18,6 @@ for type, icon in pairs(signs) do
local hl = "DiagnosticSign" .. type local hl = "DiagnosticSign" .. type
vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl }) vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl })
end end
vim.lsp.handlers["textDocument/hover"] = vim.lsp.with(vim.lsp.handlers.hover, { border = "rounded" })
vim.lsp.handlers["textDocument/signatureHelp"] = vim.lsp.with(vim.lsp.handlers.signature_help, { border = "rounded" })