From: Loui Chang Date: Sun, 27 Feb 2011 21:29:35 +0000 (-0500) Subject: Initialise views and screens with nonzero size. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=ddae52065f967db43f4d9aa07340c950cdb2b433;p=tig.git Initialise views and screens with nonzero size. This fixes problems with ncurses 2.8 Signed-off-by: Loui Chang Signed-off-by: Jonas Fonseca --- diff --git a/tig.c b/tig.c index 8933e30..72bcf8b 100644 --- a/tig.c +++ b/tig.c @@ -2724,13 +2724,13 @@ resize_display(void) foreach_displayed_view (view, i) { if (!display_win[i]) { - display_win[i] = newwin(view->height, 0, offset, 0); + display_win[i] = newwin(view->height, view->width, offset, 0); if (!display_win[i]) die("Failed to create %s view", view->name); scrollok(display_win[i], FALSE); - display_title[i] = newwin(1, 0, offset + view->height, 0); + display_title[i] = newwin(1, view->width, offset + view->height, 0); if (!display_title[i]) die("Failed to create title window"); @@ -7096,7 +7096,7 @@ init_display(void) init_colors(); getmaxyx(stdscr, y, x); - status_win = newwin(1, 0, y - 1, 0); + status_win = newwin(1, x, y - 1, 0); if (!status_win) die("Failed to create status window");