mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
patch 9.0.2189: Wrong display with 'briopt=sbr' and 'nobreakindent'
Problem: Wrong display when 'breakindentopt' contains "sbr" and 'showbreak' and 'nobreakindent' are set. Solution: Always reset wlv->need_showbreak regardless of the values of 'breakindent' and 'showbreak', as they aren't checked when setting wlv->need_showbreak (zeertzjq) closes: #13785 Signed-off-by: zeertzjq <zeertzjq@outlook.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
parent
715a805889
commit
7e4f62a257
@ -524,9 +524,6 @@ handle_breakindent(win_T *wp, winlinevars_T *wlv)
|
|||||||
if (wlv->n_extra < 0)
|
if (wlv->n_extra < 0)
|
||||||
wlv->n_extra = 0;
|
wlv->n_extra = 0;
|
||||||
}
|
}
|
||||||
if (wp->w_skipcol > 0 && wlv->startrow == 0
|
|
||||||
&& wp->w_p_wrap && wp->w_briopt_sbr)
|
|
||||||
wlv->need_showbreak = FALSE;
|
|
||||||
|
|
||||||
// Correct start of highlighted area for 'breakindent',
|
// Correct start of highlighted area for 'breakindent',
|
||||||
if (wlv->fromcol >= wlv->vcol
|
if (wlv->fromcol >= wlv->vcol
|
||||||
@ -538,6 +535,10 @@ handle_breakindent(win_T *wp, winlinevars_T *wlv)
|
|||||||
if (wlv->tocol == wlv->vcol)
|
if (wlv->tocol == wlv->vcol)
|
||||||
wlv->tocol += wlv->n_extra;
|
wlv->tocol += wlv->n_extra;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (wp->w_skipcol > 0 && wlv->startrow == 0 && wp->w_p_wrap
|
||||||
|
&& wp->w_briopt_sbr)
|
||||||
|
wlv->need_showbreak = FALSE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -579,8 +580,6 @@ handle_showbreak_and_filler(win_T *wp, winlinevars_T *wlv)
|
|||||||
wlv->c_extra = NUL;
|
wlv->c_extra = NUL;
|
||||||
wlv->c_final = NUL;
|
wlv->c_final = NUL;
|
||||||
wlv->n_extra = (int)STRLEN(sbr);
|
wlv->n_extra = (int)STRLEN(sbr);
|
||||||
if (wp->w_skipcol == 0 || wlv->startrow != 0 || !wp->w_p_wrap)
|
|
||||||
wlv->need_showbreak = FALSE;
|
|
||||||
wlv->vcol_sbr = wlv->vcol + MB_CHARLEN(sbr);
|
wlv->vcol_sbr = wlv->vcol + MB_CHARLEN(sbr);
|
||||||
|
|
||||||
// Correct start of highlighted area for 'showbreak'.
|
// Correct start of highlighted area for 'showbreak'.
|
||||||
@ -599,6 +598,10 @@ handle_showbreak_and_filler(win_T *wp, winlinevars_T *wlv)
|
|||||||
wlv->char_attr = hl_combine_attr(wlv->char_attr, wlv->cul_attr);
|
wlv->char_attr = hl_combine_attr(wlv->char_attr, wlv->cul_attr);
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (wp->w_skipcol == 0 || wlv->startrow > 0 || !wp->w_p_wrap
|
||||||
|
|| !wp->w_briopt_sbr)
|
||||||
|
wlv->need_showbreak = FALSE;
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
|++0#4040ff13#ffffff0@8>+@65
|
|++0#4040ff13#ffffff0@2| +0#0000000#e0e0e08|9|8| |9@1> +0&#ffffff0@65
|
||||||
|[+3#0000000&|N|o| |N|a|m|e|]| |[|+|]| @43|1|,|2|9|1|-|3|1|0| @5|A|l@1
|
|[+3&&|N|o| |N|a|m|e|]| |[|+|]| @43|1|,|2|9|1|-|3|1|0| @5|A|l@1
|
||||||
| +0&&@74
|
| +0&&@74
|
||||||
|~+0#4040ff13&| @73
|
|~+0#4040ff13&| @73
|
||||||
|[+1#0000000&|N|o| |N|a|m|e|]| @47|0|,|0|-|1| @9|A|l@1
|
|[+1#0000000&|N|o| |N|a|m|e|]| @47|0|,|0|-|1| @9|A|l@1
|
||||||
|
@ -704,6 +704,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
2189,
|
||||||
/**/
|
/**/
|
||||||
2188,
|
2188,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user