vim-patch:8.1.0706: introduce :redrawtabline #10570

Problem:    Tabline is not always redrawn when something that is used in
            'tabline' changes.
Solution:   Add ":redrawtabline" so that a plugin can at least cause the
            redraw when needed.
e12bab3144
This commit is contained in:
Jan Edmund Lazo
2019-07-22 06:25:07 -04:00
committed by Justin M. Keyes
parent f8684bf6b9
commit 39549159fe
6 changed files with 61 additions and 9 deletions

View File

@@ -7874,6 +7874,22 @@ static void ex_redrawstatus(exarg_T *eap)
ui_flush();
}
// ":redrawtabline": force redraw of the tabline
static void ex_redrawtabline(exarg_T *eap FUNC_ATTR_UNUSED)
{
const int r = RedrawingDisabled;
const int p = p_lz;
RedrawingDisabled = 0;
p_lz = false;
draw_tabline();
RedrawingDisabled = r;
p_lz = p;
ui_flush();
}
static void close_redir(void)
{
if (redir_fd != NULL) {