mirror of
https://github.com/ViViDboarder/vim-settings.git
synced 2025-01-08 09:07:36 +00:00
Fix c-space mapping for cmp
This commit is contained in:
parent
70c31d66eb
commit
3490deeb18
@ -16,14 +16,22 @@ function M.config_cmp()
|
|||||||
{name = "buffer"},
|
{name = "buffer"},
|
||||||
{name = "spell"},
|
{name = "spell"},
|
||||||
},
|
},
|
||||||
--[[
|
|
||||||
mapping = {
|
mapping = {
|
||||||
['<C-Space>'] = cmp.mapping({
|
['<C-d>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }),
|
||||||
i = cmp.mapping.complete(),
|
['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }),
|
||||||
c = cmp.mapping.select_next_item({ behavior = cmp.SelectBehavior.Insert }),
|
['<C-Space>'] = cmp.mapping(function()
|
||||||
|
if cmp.visible() then
|
||||||
|
cmp.select_next_item()
|
||||||
|
else
|
||||||
|
cmp.complete()
|
||||||
|
end
|
||||||
|
end, { 'i', 'c' }),
|
||||||
|
['<C-e>'] = cmp.mapping({
|
||||||
|
i = cmp.mapping.abort(),
|
||||||
|
c = cmp.mapping.close(),
|
||||||
}),
|
}),
|
||||||
|
['<CR>'] = cmp.mapping.confirm({ select = true }),
|
||||||
},
|
},
|
||||||
--]]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
-- Add a plug mapping to use in C-Space binding
|
-- Add a plug mapping to use in C-Space binding
|
||||||
|
Loading…
Reference in New Issue
Block a user