From a572b936ce7bbaf630b22a32c039738a783cdf41 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sun, 19 Feb 2023 14:34:37 +0000 Subject: patch 9.0.1326: relative line number not updated with virtual text above Problem: Relative line number not updated with virtual text above. Solution: Adjust the row for the line number for virtual text above. (closes #12004) --- src/drawline.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/drawline.c') diff --git a/src/drawline.c b/src/drawline.c index 74c736c24d..5fe25f554f 100644 --- a/src/drawline.c +++ b/src/drawline.c @@ -1598,6 +1598,15 @@ win_line( } } } + + if (number_only) + { + // skip over rows only used for virtual text above + wlv.row += wlv.text_prop_above_count; + if (wlv.row > endrow) + return wlv.row; + wlv.screen_row += wlv.text_prop_above_count; + } #endif // 'nowrap' or 'wrap' and a single line that doesn't fit: Advance to the -- cgit v1.2.3