&& compl_first_match)
{
compl_shown_match = compl_first_match;
- if (compl_shows_dir_forward())
+ if (compl_shows_dir_forward() && !compl_autocomplete)
compl_shown_match = compl_first_match->cp_next;
}
}
--- /dev/null
+|v+0&#ffffff0| @73
+|v|i| @72
+|v|i|m| @71
+|v> @73
+|v+0#0000001#ffd7ff255| @13| +0#4040ff13#ffffff0@59
+|v+0#0000001#ffd7ff255|i| @12| +0#4040ff13#ffffff0@59
+|v+0#0000001#ffd7ff255|i|m| @11| +0#4040ff13#ffffff0@59
+|~| @73
+|~| @73
+|-+2#0000000&@1| |I|N|S|E|R|T| |-@1| +0&&@44|4|,|1| @10|A|l@1|
call test_override("char_avail", 0)
endfunc
+" Issue #18326
+func Test_fuzzy_select_item_when_acl()
+ CheckScreendump
+ let lines =<< trim [SCRIPT]
+ call setline(1, ["v", "vi", "vim"])
+ set autocomplete completeopt=menuone,noinsert,fuzzy autocompletedelay=300
+ [SCRIPT]
+ call writefile(lines, 'XTest_autocomplete_delay', 'D')
+ let buf = RunVimInTerminal('-S XTest_autocomplete_delay', {'rows': 10})
+
+ call term_sendkeys(buf, "Govi")
+ call VerifyScreenDump(buf, 'Test_fuzzy_autocompletedelay_1', {})
+
+ call term_sendkeys(buf, "\<Esc>Sv")
+ call VerifyScreenDump(buf, 'Test_fuzzy_autocompletedelay_2', {})
+ sleep 500m
+ call term_sendkeys(buf, "i")
+ call VerifyScreenDump(buf, 'Test_fuzzy_autocompletedelay_3', {})
+
+ call term_sendkeys(buf, "\<esc>")
+ call StopVimInTerminal(buf)
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab nofoldenable