Updated window popups

This commit is contained in:
Christoffer Martinsson 2023-06-11 02:19:09 +02:00
parent 2a5580ba16
commit 268432243e

View File

@ -409,14 +409,16 @@ cmp.setup {
completion = { completeopt = 'menu,menuone,noinsert,noselect' }, completion = { completeopt = 'menu,menuone,noinsert,noselect' },
}, },
window = { window = {
-- completion = cmp.config.window.bordered(),
-- documentation = cmp.config.window.bordered(),
documentation = { documentation = {
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None', winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
border = "single", -- border = "single",
},
completion = {
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
border = "single",
}, },
-- completion = {
-- winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
-- border = "single",
-- },
}, },
snippet = { snippet = {
expand = function(args) expand = function(args)
@ -471,14 +473,16 @@ cmp.setup {
cmp.setup.cmdline({ '/', '?' }, { cmp.setup.cmdline({ '/', '?' }, {
mapping = cmp.mapping.preset.cmdline(), mapping = cmp.mapping.preset.cmdline(),
window = { window = {
documentation = { -- completion = cmp.config.window.bordered(),
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None', -- documentation = cmp.config.window.bordered(),
border = "single", -- documentation = {
}, -- winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
completion = { -- border = "single",
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None', -- },
border = "single", -- completion = {
}, -- winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
-- border = "single",
-- },
}, },
sources = { sources = {
{ name = 'buffer' } { name = 'buffer' }
@ -488,14 +492,16 @@ cmp.setup.cmdline({ '/', '?' }, {
cmp.setup.cmdline(':', { cmp.setup.cmdline(':', {
mapping = cmp.mapping.preset.cmdline(), mapping = cmp.mapping.preset.cmdline(),
window = { window = {
documentation = { -- completion = cmp.config.window.bordered(),
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None', -- documentation = cmp.config.window.bordered(),
border = "single", -- documentation = {
}, -- winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
completion = { -- border = "single",
winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None', -- },
border = "single", -- completion = {
}, -- winhighlight = 'Normal:Pmenu,FloatBorder:Pmenu,Search:None',
-- border = "single",
-- },
}, },
sources = cmp.config.sources({ sources = cmp.config.sources({
{ name = 'path' } { name = 'path' }
@ -598,7 +604,10 @@ vim.keymap.set('n', '<A-f>', ":Format<cr>", { desc = 'Format code', silent = tru
vim.keymap.set('n', '<leader>gg', ":LazyGitCurrentFile<cr>", { desc = 'Format code', silent = true }) vim.keymap.set('n', '<leader>gg', ":LazyGitCurrentFile<cr>", { desc = 'Format code', silent = true })
vim.keymap.set('n', '<C-m>', ":make<cr>", { desc = 'Format code', silent = true }) vim.keymap.set('n', '<C-m>', ":make<cr>", { desc = 'Format code', silent = true })
vim.keymap.set('n', '<C-n>', ":make clean<cr>", { desc = 'Format code', silent = true }) vim.keymap.set('n', '<C-n>', ":make clean<cr>", { desc = 'Format code', silent = true })
vim.keymap.set('n', '<leader>n', ":tabnew<cr>", { desc = 'Format code', silent = true })
vim.keymap.set('n', '<leader>c', ":tabclose<cr>", { desc = 'Format code', silent = true })
-- Customization for Pmenu -- Customization for Pmenu
-- vim.api.nvim_set_hl(0, "PmenuSel", { bg = "#555555", fg = "NONE" }) vim.api.nvim_set_hl(0, "PmenuSel", { bg = "#555555", fg = "NONE" })
-- vim.api.nvim_set_hl(0, "Pmenu", { fg = "#C5CDD9", bg = "#000000" }) vim.api.nvim_set_hl(0, "Pmenu", { fg = "#C5CDD9", bg = "#000000" })
vim.api.nvim_set_hl(0, "CmpItemAbbr", { fg = "#eeeeee", bg = "NONE" })