To: vim_dev@googlegroups.com Subject: Patch 8.2.4481 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.4481 Problem: Cmdline popup menu not removed when 'lazyredraw' is set. Solution: Temporarily reset 'lazyredraw' when removing the popup menu. (closes #9857) Files: src/cmdexpand.c, src/testdir/test_cmdline.vim, src/testdir/dumps/Test_wildmenu_pum_41.dump *** ../vim-8.2.4480/src/cmdexpand.c 2022-02-27 12:07:26.666960401 +0000 --- src/cmdexpand.c 2022-02-27 14:27:09.336166775 +0000 *************** *** 377,385 **** --- 377,389 ---- */ void cmdline_pum_remove(void) { + int save_p_lz = p_lz; + pum_undisplay(); VIM_CLEAR(compl_match_array); + p_lz = FALSE; // avoid the popup menu hanging around update_screen(0); + p_lz = save_p_lz; redrawcmd(); } *** ../vim-8.2.4480/src/testdir/test_cmdline.vim 2022-02-27 12:07:26.670960392 +0000 --- src/testdir/test_cmdline.vim 2022-02-27 14:27:33.928099924 +0000 *************** *** 2181,2186 **** --- 2181,2191 ---- set tabline=%!MyTabLine() set showtabline=2 endfunc + + func DoFeedKeys() + let &wildcharm = char2nr("\t") + call feedkeys(":edit $VIMRUNTIME/\\\ab\") + endfunc [CODE] call writefile(commands, 'Xtest') *************** *** 2378,2383 **** --- 2383,2394 ---- call term_sendkeys(buf, "\") call VerifyScreenDump(buf, 'Test_wildmenu_pum_40', {}) + " popup is cleared also when 'lazyredraw' is set + call term_sendkeys(buf, ":set showtabline=1 laststatus=1 lazyredraw\") + call term_sendkeys(buf, ":call DoFeedKeys()\") + call VerifyScreenDump(buf, 'Test_wildmenu_pum_41', {}) + call term_sendkeys(buf, "\") + call term_sendkeys(buf, "\\") call StopVimInTerminal(buf) call delete('Xtest') *** ../vim-8.2.4480/src/testdir/dumps/Test_wildmenu_pum_41.dump 2022-02-27 14:28:02.708022692 +0000 --- src/testdir/dumps/Test_wildmenu_pum_41.dump 2022-02-27 14:19:51.277549020 +0000 *************** *** 0 **** --- 1,10 ---- + | +0&#ffffff0@74 + |~+0#4040ff13&| @73 + |~| @73 + |~| @73 + |~| @73 + | +0#0000001#e0e0e08|a|b@1|r|e|v|i|a|t|e| @4| +0#4040ff13#ffffff0@58 + | +0#0000001#ffd7ff255|a|b|c|l|e|a|r| @7| +0#4040ff13#ffffff0@58 + | +0#0000001#ffd7ff255|a|b|o|v|e|l|e|f|t| @5| +0#4040ff13#ffffff0@58 + | +0#0000001#ffd7ff255|a|b|s|t|r|a|c|t| @6| +0#4040ff13#ffffff0@58 + |:+0#0000000&|a|b@1|r|e|v|i|a|t|e> @63 *** ../vim-8.2.4480/src/version.c 2022-02-27 12:31:48.591408426 +0000 --- src/version.c 2022-02-27 14:12:10.927741869 +0000 *************** *** 756,757 **** --- 756,759 ---- { /* Add new patch number below this line */ + /**/ + 4481, /**/ -- Two percent of zero is almost nothing. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///