nvim: after/plugin/cmp: Update nvim-cmp settings
Support for use of floating windows for completion menus landed upstream. It introduced a new feature but also broke things. Having native_menu set completely breaks auto completion. While at it, add mapping for scrolling docs. Also add support for it in color scheme.
This commit is contained in:
parent
a83b07959d
commit
1f281f6bd7
|
@ -24,6 +24,8 @@ cmp.setup {
|
||||||
border = 'rounded'
|
border = 'rounded'
|
||||||
},
|
},
|
||||||
mapping = {
|
mapping = {
|
||||||
|
['<C-d>'] = cmp.mapping.scroll_docs(-4),
|
||||||
|
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
||||||
['<CR>'] = cmp.mapping.confirm({
|
['<CR>'] = cmp.mapping.confirm({
|
||||||
behavior = cmp.ConfirmBehavior.Replace,
|
behavior = cmp.ConfirmBehavior.Replace,
|
||||||
select = true
|
select = true
|
||||||
|
@ -50,5 +52,9 @@ cmp.setup {
|
||||||
name = 'path',
|
name = 'path',
|
||||||
priority = 5
|
priority = 5
|
||||||
},
|
},
|
||||||
|
},
|
||||||
|
experimental = {
|
||||||
|
native_menu = false,
|
||||||
|
ghost_text = { hl_group = 'Hint' },
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -711,6 +711,14 @@ local highlight_groups = {
|
||||||
pandocStrongEmphasis = { bg=black, fg=purple, style={'bold', 'italic' }},
|
pandocStrongEmphasis = { bg=black, fg=purple, style={'bold', 'italic' }},
|
||||||
pandocStrongInEmphasis = 'pandocStrongEmphasis',
|
pandocStrongInEmphasis = 'pandocStrongEmphasis',
|
||||||
pandocEmphasisInStrong = 'pandocStrongEmphasis',
|
pandocEmphasisInStrong = 'pandocStrongEmphasis',
|
||||||
|
|
||||||
|
--[[ 4.4.15 nvim-cmp ]]
|
||||||
|
CmpItemKind = {bg=black, fg=orange, style=NONE },
|
||||||
|
CmpItemMenu = {bg=black, fg=NONE, style=NONE },
|
||||||
|
CmpItemAbbr = {bg=black, fg=aqua, style=NONE },
|
||||||
|
CmpItemAbbrMatch = {bg=black, fg=red, style='bold' },
|
||||||
|
CmpItemAbbrMatchFuzzy = {bg=black, fg=aqua, style='bold' },
|
||||||
|
CmpItemAbbrDeprecated = {bg=black, fg=purple, style=NONE },
|
||||||
}
|
}
|
||||||
|
|
||||||
-- We do not care about terminals which do not support 256 colors
|
-- We do not care about terminals which do not support 256 colors
|
||||||
|
|
Loading…
Reference in a new issue