]> git.ipfire.org Git - thirdparty/vim.git/commit
patch 9.1.1160: Ctrl-Y does not work well with "preinsert" when completing items v9.1.1160
authorglepnir <glephunter@gmail.com>
Fri, 28 Feb 2025 16:43:42 +0000 (17:43 +0100)
committerChristian Brabandt <cb@256bit.org>
Fri, 28 Feb 2025 16:43:42 +0000 (17:43 +0100)
commita2c5559f297a18dc1ce3c4f1f9fd6204aed321c9
tree967ce0e639922e9b9bc3a90bfd42ac2c175b04a5
parent3e2affc324034085a98356003b226bd4a6f6c1ad
patch 9.1.1160: Ctrl-Y does not work well with "preinsert" when completing items

Problem:  The 'preinsert' feature requires Ctrl-Y to confirm insertion,
          but Ctrl-Y only works when the popup menu (pum) is displayed.
          Without enforcing this dependency, it could lead to confusing
          behavior or non-functional features.

Solution: Modify ins_compl_has_preinsert() to check for both 'menu' and
          'menuone' flags when 'preinsert' is set. Update documentation
          to clarify this requirement. This avoids adding complex
          conditional behaviors. (glepnir)

fixes: #16728
closes: #16753

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/doc/options.txt
src/edit.c
src/insexpand.c
src/testdir/test_ins_complete.vim
src/version.c