From 4fbecbe54c02195bd4b2179b033e72be48062ec7 Mon Sep 17 00:00:00 2001 From: Chris Date: Sun, 19 Jun 2016 01:58:46 -0700 Subject: [PATCH] Fixes screen flickering on urxvt. Erase() is ncurses optimal for screen refresh. Clear() blanks the entire screen first, which produces a flickering output on urxvt. --- src/cui.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cui.cpp b/src/cui.cpp index ecda531..d5197a9 100644 --- a/src/cui.cpp +++ b/src/cui.cpp @@ -296,7 +296,7 @@ void show_ncurses(Line *lines[], int nproc) { getmaxyx(stdscr, rows, cols); /* find the boundaries of the screeen */ if (cols < 62) { - clear(); + erase(); mvprintw(0, 0, "The terminal is too narrow! Please make it wider.\nI'll wait..."); return; @@ -307,7 +307,7 @@ void show_ncurses(Line *lines[], int nproc) { proglen = cols - 55; - clear(); + erase(); mvprintw(0, 0, "%s", caption->c_str()); attron(A_REVERSE); mvprintw(2, 0,