mirror of
https://github.com/neovim/neovim.git
synced 2025-09-12 14:28:18 +00:00
vim-patch:7.4.478: Use character lenght for 'showbreak'
vim-patch:7.4.478 Problem: Using byte length instead of character length for 'showbreak'. Solution: Compute the character length. (Marco Hinz) https://code.google.com/p/vim/source/detail?r=v7-4-478
This commit is contained in:
@@ -1058,8 +1058,11 @@ int win_lbr_chartabsize(win_T *wp, char_u *line, char_u *s, colnr_T col, int *he
|
|||||||
if (col >= (colnr_T)wp->w_width) {
|
if (col >= (colnr_T)wp->w_width) {
|
||||||
col -= wp->w_width;
|
col -= wp->w_width;
|
||||||
numberextra = wp->w_width - (numberextra - win_col_off2(wp));
|
numberextra = wp->w_width - (numberextra - win_col_off2(wp));
|
||||||
if (*p_sbr != NUL && col >= (colnr_T)STRLEN(p_sbr))
|
if (*p_sbr != NUL) {
|
||||||
col -= (colnr_T)STRLEN(p_sbr);
|
colnr_T sbrlen = (colnr_T)MB_CHARLEN(p_sbr);
|
||||||
|
if (col >= sbrlen)
|
||||||
|
col -= sbrlen;
|
||||||
|
}
|
||||||
if (numberextra > 0) {
|
if (numberextra > 0) {
|
||||||
col = col % numberextra;
|
col = col % numberextra;
|
||||||
}
|
}
|
||||||
|
@@ -188,7 +188,7 @@ static int included_patches[] = {
|
|||||||
//481,
|
//481,
|
||||||
//480,
|
//480,
|
||||||
//479,
|
//479,
|
||||||
//478,
|
478,
|
||||||
//477,
|
//477,
|
||||||
//476,
|
//476,
|
||||||
//475,
|
//475,
|
||||||
|
Reference in New Issue
Block a user