mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
vim-patch:8.1.0750: when the last sign is deleted the signcolumn may remain
Problem: When the last sign is deleted the signcolumn may not be removed
even though 'signcolumn' is "auto".
Solution: When deleting the last sign redraw the buffer. (Dominique Pelle,
closes vim/vim#3803, closes vim/vim#3804)
8144acbec3
This commit is contained in:
parent
fa07cc215d
commit
c5f3dbab35
@ -378,6 +378,9 @@ linenr_T buf_change_sign_type(
|
||||
|
||||
/// Gets a sign from a given line.
|
||||
///
|
||||
/// Return the type number of the sign at line number 'lnum' in buffer 'buf'
|
||||
/// which has the attribute specified by 'type'. Returns 0 if a sign is not
|
||||
/// found at the line number or it doesn't have the specified attribute.
|
||||
/// @param buf Buffer in which to search
|
||||
/// @param lnum Line in which to search
|
||||
/// @param type Type of sign to look for
|
||||
@ -466,7 +469,7 @@ linenr_T buf_delsign(
|
||||
xfree(sign);
|
||||
redraw_buf_line_later(buf, lnum);
|
||||
// Check whether only one sign needs to be deleted
|
||||
// If deleting a sign with a specific identifer in a particular
|
||||
// If deleting a sign with a specific identifier in a particular
|
||||
// group or deleting any sign at a particular line number, delete
|
||||
// only one sign.
|
||||
if (group == NULL
|
||||
@ -479,8 +482,8 @@ linenr_T buf_delsign(
|
||||
}
|
||||
}
|
||||
|
||||
/* When deleted the last sign needs to redraw the windows to remove the
|
||||
* sign column. */
|
||||
// When deleted the last sign needs to redraw the windows to remove the
|
||||
// sign column.
|
||||
if (buf->b_signlist == NULL) {
|
||||
redraw_buf_later(buf, NOT_VALID);
|
||||
changed_cline_bef_curs();
|
||||
@ -873,7 +876,7 @@ sign_list_by_name(char_u *name)
|
||||
|
||||
|
||||
/*
|
||||
* Place a sign at the specifed file location or update a sign.
|
||||
* Place a sign at the specified file location or update a sign.
|
||||
*/
|
||||
int sign_place(
|
||||
int *sign_id,
|
||||
|
Loading…
Reference in New Issue
Block a user