mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
vim-patch:9.0.0316: screen flickers when 'cmdheight' is zero (#19991)
Problem: Screen flickers when 'cmdheight' is zero.
Solution: Redraw over existing text instead of clearing.
f73e5ba56f
This commit is contained in:
parent
e6af1cf250
commit
92bc11a891
@ -469,9 +469,10 @@ int update_screen(int type)
|
||||
}
|
||||
msg_grid_set_pos(Rows - (int)p_ch, false);
|
||||
msg_grid_invalid = false;
|
||||
} else if (msg_scrolled > Rows - 5) { // clearing is faster
|
||||
type = UPD_CLEAR;
|
||||
} else if (type != UPD_CLEAR) {
|
||||
if (msg_scrolled > Rows - 5) { // redrawing is faster
|
||||
type = UPD_NOT_VALID;
|
||||
} else {
|
||||
check_for_delay(false);
|
||||
grid_ins_lines(&default_grid, 0, msg_scrolled, Rows, 0, Columns);
|
||||
FOR_ALL_WINDOWS_IN_TAB(wp, curtab) {
|
||||
@ -499,6 +500,7 @@ int update_screen(int type)
|
||||
redraw_cmdline = true;
|
||||
redraw_tabline = true;
|
||||
}
|
||||
}
|
||||
msg_scrolled = 0;
|
||||
msg_scrolled_at_flush = 0;
|
||||
need_wait_return = false;
|
||||
|
@ -918,7 +918,7 @@ theend:
|
||||
// Restore cmdheight
|
||||
set_option_value("ch", 0L, NULL, 0);
|
||||
// Redraw is needed for command line completion
|
||||
redraw_all_later(UPD_CLEAR);
|
||||
redraw_all_later(UPD_NOT_VALID);
|
||||
|
||||
made_cmdheight_nonzero = false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user