diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/move.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nvim/move.c b/src/nvim/move.c index 7a4e98adc5..7cc368a36b 100644 --- a/src/nvim/move.c +++ b/src/nvim/move.c @@ -1816,7 +1816,9 @@ void scroll_cursor_top(int min_scroll, int always) } } check_topfill(curwin, false); - if (curwin->w_topline == curwin->w_cursor.lnum) { + if (curwin->w_topline != old_topline) { + reset_skipcol(curwin); + } else if (curwin->w_topline == curwin->w_cursor.lnum) { validate_virtcol(); if (curwin->w_skipcol >= curwin->w_virtcol) { // TODO(vim): if the line doesn't fit may optimize w_skipcol instead |