summaryrefslogtreecommitdiffstats
path: root/src/drawline.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-09-11 20:01:17 +0200
committerChristian Brabandt <cb@256bit.org>2023-09-11 20:01:17 +0200
commit6b9c2025496e415856ad70b819de83a48267c582 (patch)
treea4084c6fad75666ce787adb24511f9eac9aa6fa4 /src/drawline.c
parent4d00b835c49ffc5c416b65ca466d6ad695cbd3d2 (diff)
patch 9.0.1896: "below" virtual text doesn't work with 'rightleft'v9.0.1896
Problem: "below" virtual text doesn't work with 'rightleft'. Solution: Use column from right border with 'rightleft'. closes: #13071 Signed-off-by: Christian Brabandt <cb@256bit.org> Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Diffstat (limited to 'src/drawline.c')
-rw-r--r--src/drawline.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/drawline.c b/src/drawline.c
index 04e7ed8d5f..6f9044650a 100644
--- a/src/drawline.c
+++ b/src/drawline.c
@@ -2011,10 +2011,8 @@ win_line(
if (wlv.n_extra == 0 ||
(!wlv.extra_for_textprop
-#ifdef FEAT_PROP_POPUP
&& !(text_prop_type != NULL &&
text_prop_flags & PT_FLAG_OVERRIDE)
-#endif
))
{
text_prop_attr = 0;
@@ -2134,7 +2132,7 @@ win_line(
if (*ptr == NUL)
// don't combine char attr after EOL
text_prop_flags &= ~PT_FLAG_COMBINE;
-#ifdef FEAT_LINEBREAK
+# ifdef FEAT_LINEBREAK
if (above || below || right || !wrap)
{
// no 'showbreak' before "below" text property
@@ -2142,7 +2140,7 @@ win_line(
wlv.need_showbreak = FALSE;
wlv.dont_use_showbreak = TRUE;
}
-#endif
+# endif
if ((right || above || below || !wrap
|| padding > 0) && wp->w_width > 2)
{
@@ -2155,6 +2153,11 @@ win_line(
// exactly the same.
start_line = text_prop_position(wp, tp,
wlv.vcol,
+# ifdef FEAT_RIGHTLEFT
+ wp->w_p_rl
+ ? wp->w_width - wlv.col - 1
+ :
+# endif
wlv.col,
&wlv.n_extra, &wlv.p_extra,
&n_attr, &wlv.n_attr_skip,