patch 9.1.1496: terminal: still not highlighting empty cells correctly
Commit:
https://github.com/vim/vim/commit/66b72f48c3f20e9223a5789ab28f8683ded4deba
Author: Christian Brabandt <[email protected]>
Date: Sun Jun 29 22:22:05 2025 +0200
patch 9.1.1496: terminal: still not highlighting empty cells correctly
Problem: terminal: still not highlighting empty cells correctly
(Yousef Mohammed, after v9.1.1489)
Solution: Use vcol instead of col
closes: #17632
Signed-off-by: Christian Brabandt <[email protected]>
diff --git a/src/drawline.c b/src/drawline.c
index afc048091..2388193b9 100644
--- a/src/drawline.c
+++ b/src/drawline.c
@@ -2774,7 +2774,7 @@ win_line(
skip_cells = 0;
#ifdef FEAT_TERMINAL
if (term_show_buffer(wp->w_buffer)
- && wlv.col == 0
+ && wlv.vcol == 0
&& wlv.win_attr == term_get_attr(wp, lnum, -1))
// reset highlighting attribute
wlv.win_attr = 0;
diff --git a/src/testdir/dumps/Test_terminal_empty_listchars2.dump
b/src/testdir/dumps/Test_terminal_empty_listchars2.dump
new file mode 100644
index 000000000..6df4d40aa
--- /dev/null
+++ b/src/testdir/dumps/Test_terminal_empty_listchars2.dump
@@ -0,0 +1,15 @@
+| +0#af5f00255#ffffff0@1|1| |h+0#0000001#a8a8a8255|e|l@1|o|
+0#0000000#ffffff0@65
+| +0#af5f00255&@1|2| | +0#0000001#a8a8a8255| +0#0000000#ffffff0@69
+| +0#af5f00255&@1|3| >h+0#0000000&|e+0#0000001#a8a8a8255|l@1|o|
+0#0000000#ffffff0@65
+|~+0#4040ff13&| @73
+|~| @73
+|~| @73
+|!+2#ffffff16#00e0003|s|h| |-|c| |"|p|r|i|n|t|f|
|'|h|e|l@1|o|\@1|n|\@1|n|h|e|l@1|o|'|"| |[|f|i|n|i|s|h|e|d|]| @11|3|,|1|
@11|A|l@1
+| +0#0000000#ffffff0@74
+|~+0#4040ff13&| @73
+|~| @73
+|~| @73
+|~| @73
+|~| @73
+|[+1#0000000&|N|o| |N|a|m|e|]| @47|0|,|0|-|1| @9|A|l@1
+|-+2&&@1| |V|I|S|U|A|L| |L|I|N|E| |-@1| +0&&@46|3| @9
diff --git a/src/testdir/test_terminal3.vim b/src/testdir/test_terminal3.vim
index 9aa90492c..7a2ecdbc1 100644
--- a/src/testdir/test_terminal3.vim
+++ b/src/testdir/test_terminal3.vim
@@ -1032,6 +1032,10 @@ func Test_terminal_visual_empty_listchars()
call term_wait(buf)
call term_sendkeys(buf, "V2k")
call VerifyScreenDump(buf, 'Test_terminal_empty_listchars', {})
+ call term_sendkeys(buf, "\<esc>")
+ call term_sendkeys(buf, ":set nu\<cr>")
+ call term_sendkeys(buf, "ggV2j")
+ call VerifyScreenDump(buf, 'Test_terminal_empty_listchars2', {})
call StopVimInTerminal(buf)
endfunc
diff --git a/src/version.c b/src/version.c
index 657d68ad2..2cf34ea33 100644
--- a/src/version.c
+++ b/src/version.c
@@ -719,6 +719,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1496,
/**/
1495,
/**/
--
--
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/E1uVyf6-00B45X-4v%40256bit.org.