summaryrefslogtreecommitdiffstats
path: root/src/drawline.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2023-02-19 14:34:37 +0000
committerBram Moolenaar <Bram@vim.org>2023-02-19 14:34:37 +0000
commita572b936ce7bbaf630b22a32c039738a783cdf41 (patch)
tree2c9c827718225f31e165149857858278069cb77b /src/drawline.c
parentf53e065bce1adff4bff202ed3ba9982ece90b745 (diff)
patch 9.0.1326: relative line number not updated with virtual text abovev9.0.1326
Problem: Relative line number not updated with virtual text above. Solution: Adjust the row for the line number for virtual text above. (closes #12004)
Diffstat (limited to 'src/drawline.c')
-rw-r--r--src/drawline.c9
1 files changed, 9 insertions, 0 deletions
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