Commit: patch 9.2.0424: popup: flicker when wildtrigger() refreshes the popup menu

0 views
Skip to first unread message

Christian Brabandt

unread,
9:45 AM (3 hours ago) 9:45 AM
to vim...@googlegroups.com
patch 9.2.0424: popup: flicker when wildtrigger() refreshes the popup menu

Commit: https://github.com/vim/vim/commit/ec8b8bd82a905f0faf1a73bf57381597f0e25654
Author: Yasuhiro Matsumoto <matt...@gmail.com>
Date: Fri May 1 13:29:01 2026 +0000

patch 9.2.0424: popup: flicker when wildtrigger() refreshes the popup menu

Problem: popup: flicker when wildtrigger() refreshes the popup menu
Solution: Wrap the pum teardown and cmdline redraw in synchronized
terminal output (Yasuhiro Matsumoto).

Reduces flicker when wildtrigger() refreshes the popup on every
keystroke and the cmdline is wrapped: the un-scroll inside
update_screen() and the re-scroll inside redrawcmd() are emitted as
one atomic terminal update.

closes: #20081

Signed-off-by: Yasuhiro Matsumoto <matt...@gmail.com>
Signed-off-by: Christian Brabandt <c...@256bit.org>

diff --git a/src/cmdexpand.c b/src/cmdexpand.c
index b7a17bbdd..a4891871f 100644
--- a/src/cmdexpand.c
+++ b/src/cmdexpand.c
@@ -465,6 +465,7 @@ cmdline_pum_remove(cmdline_info_T *cclp UNUSED, int defer_redraw)
RedrawingDisabled = 0;
#endif

+ term_set_sync_output(TERM_SYNC_OUTPUT_ENABLE);
pum_undisplay();
VIM_CLEAR(compl_match_array);
compl_match_arraysize = 0;
@@ -478,6 +479,7 @@ cmdline_pum_remove(cmdline_info_T *cclp UNUSED, int defer_redraw)
else
pum_call_update_screen();
redrawcmd();
+ term_set_sync_output(TERM_SYNC_OUTPUT_DISABLE);

// When a function is called (e.g. for 'foldtext') KeyTyped might be reset
// as a side effect.
diff --git a/src/version.c b/src/version.c
index dca517635..837b453d1 100644
--- a/src/version.c
+++ b/src/version.c
@@ -729,6 +729,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 424,
/**/
423,
/**/
Reply all
Reply to author
Forward
0 new messages