vim-patch:8.1.1926: redraw cursorline after putting line above #10849

Problem:    Cursorline not redrawn when putting a line above the cursor.
Solution:   Redraw when the curor line is below a change. (closes vim/vim#4862)
c2b97643a8
This commit is contained in:
Jan Edmund Lazo
2019-08-25 22:17:34 -04:00
committed by Justin M. Keyes
parent e3e0574cb3
commit ebc3070b7d

View File

@@ -289,8 +289,11 @@ static void changed_common(linenr_T lnum, colnr_T col, linenr_T lnume,
set_topline(wp, wp->w_topline);
}
// relative numbering may require updating more
if (wp->w_p_rnu) {
// Relative numbering may require updating more. Cursor line
// highlighting probably needs to be updated if it's below the
// change.
if (wp->w_p_rnu
|| (wp->w_p_cul && lnum <= wp->w_last_cursorline)) {
redraw_win_later(wp, SOME_VALID);
}
}