From eb4ac85fb195b119ff86cf5c2b9741bb7fdd2d37 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Tue, 30 Jun 2015 09:08:44 +0100 Subject: [PATCH] Force setting of terminal hardware scroll region on resize It seems there is a race condition with VTE based terminals when created and resized almost immediatly (like when doing :new) where we end up with the hardware scroll region set to the old terminal size. --- src/ncurses_ui.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/ncurses_ui.cc b/src/ncurses_ui.cc index a2364fd3..d7c74940 100644 --- a/src/ncurses_ui.cc +++ b/src/ncurses_ui.cc @@ -444,6 +444,9 @@ void NCursesUI::check_resize(bool force) m_window = (NCursesWin*)newwin(ws.ws_row, ws.ws_col, 0, 0); m_dimensions = CharCoord{ws.ws_row-1, ws.ws_col}; + + if (const char* csr = tigetstr((char*)"csr")) + putp(tiparm(csr, 0, ws.ws_row)); } else kak_assert(false);