mirror of
https://github.com/vim/vim.git
synced 2025-10-06 05:44:14 -04:00
patch 8.1.0671: cursor in the wrong column after auto-formatting
Problem: Cursor in the wrong column after auto-formatting. Solution: Check for deleting more spaces than adding. (closes #3748)
This commit is contained in:
@@ -1705,7 +1705,7 @@ open_line(
|
||||
if (flags & OPENLINE_MARKFIX)
|
||||
mark_col_adjust(curwin->w_cursor.lnum,
|
||||
curwin->w_cursor.col + less_cols_off,
|
||||
1L, (long)-less_cols);
|
||||
1L, (long)-less_cols, 0);
|
||||
}
|
||||
else
|
||||
changed_bytes(curwin->w_cursor.lnum, curwin->w_cursor.col);
|
||||
|
Reference in New Issue
Block a user