patch 9.1.2143: wrong rendering of popups when overlapping wide char

Commit: 
https://github.com/vim/vim/commit/6ffe020b919e8d1f1e74a293ca301b3ce0a9ecc7
Author: Yasuhiro Matsumoto <[email protected]>
Date:   Mon Feb 9 19:08:24 2026 +0000

    patch 9.1.2143: wrong rendering of popups when overlapping wide char
    
    Problem:  When a popup window partially overlaps a wide character
              it results in truncated or garbage display.
    Solution: When a wide character is partially blocked by a popup, clear both
              cells in the screen buffer to prevent garbage (Yasuhiro 
Matsumoto).
    
    closes: #19271
    
    Signed-off-by: Yasuhiro Matsumoto <[email protected]>
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/runtime/doc/version9.txt b/runtime/doc/version9.txt
index c5ed3da00..462a04848 100644
--- a/runtime/doc/version9.txt
+++ b/runtime/doc/version9.txt
@@ -1,4 +1,4 @@
-*version9.txt* For Vim version 9.1.  Last change: 2026 Feb 08
+*version9.txt* For Vim version 9.1.  Last change: 2026 Feb 09
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -52532,4 +52532,14 @@ Patch 9.1.2141
 Problem:  Truncation when serializing libsodium encryption parameters.
 Solution: Correctly cast to long long type (Yasuhiro Matsumoto).
 
+Patch 9.1.2142
+Problem:  MS-Windows: mouse scroll events not handled for popups
+Solution: Do not return early (Mao-Yining)
+
+Patch 9.1.2143
+Problem:  When a popup window partially overlaps a wide character
+          it results in truncated or garbage display.
+Solution: When a wide character is partially blocked by a popup, clear both
+          cells in the screen buffer to prevent garbage (Yasuhiro Matsumoto).
+
  vim:tw=78:ts=8:noet:ft=help:norl:fdm=manual:nofoldenable
diff --git a/src/screen.c b/src/screen.c
index 57f37966c..3cd3ad39f 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -586,6 +586,9 @@ screen_line(
        // Do not redraw if under the popup menu.
        if (redraw_this && skip_for_popup(row, col + coloff))
            redraw_this = FALSE;
+       // Also skip the second cell for double-width characters.
+       if (redraw_this && char_cells == 2 && skip_for_popup(row, col + coloff 
+ 1))
+           redraw_this = FALSE;
 
        if (redraw_this)
        {
diff --git a/src/version.c b/src/version.c
index 6a6eaecb9..24f3ea3ce 100644
--- a/src/version.c
+++ b/src/version.c
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2143,
 /**/
     2142,
 /**/

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1vpWiw-003vze-Tv%40256bit.org.

Raspunde prin e-mail lui