Allow Super-tab to accept and cycle through suggestions #576
-
Feature DescriptionIn my current config using ["<Tab>"] = cmp.mapping(function(fallback)
local col = vim.fn.col(".") - 1
if cmp.visible() then
cmp.select_next_item()
elseif
col == 0 or vim.fn.getline("."):sub(col, col):match("%s")
then
fallback()
else
cmp.complete()
end
end, { "i", "s" }),
With this setup, my completion works as shown in this video: As you can see, pressing tab accepts the current suggestion and can also be used to cycle through the remaining suggestions. Is there a way to do this? Or can this behaviour be added? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Just to follow up on this: this has been asked in #6 and it was noted that the behaviour was broken in the release at the time. I've tested this today with the latest version of blink with the following config and it doesn't work as expected: opts = {
keymap = {
preset = "enter",
["<Tab>"] = { "accept", "select_next", "fallback" },
["<S-Tab>"] = { "select_prev", "fallback" },
}, If I swap the order of
Has this issue been fixed in the latest releases? Or is it considered broken? |
Beta Was this translation helpful? Give feedback.
-
When I have |
Beta Was this translation helpful? Give feedback.
Thanks! For anyone else looking at this, this is the configuration I have: