40#ifndef HAVE_TCGETWINSIZE
41#ifdef HAVE_SYS_IOCTL_H
56 struct winsize w = { 0 };
58 int fd = open(
"/dev/tty", O_RDONLY);
61#ifdef HAVE_TCGETWINSIZE
64 ioctl(fd, TIOCGWINSZ, &w);
78 int screenrows = w.ws_row;
79 int screencols = w.ws_col;
84 if (cp && !mutt_str_atoi_full(cp, &screenrows))
91 if (cp && !mutt_str_atoi_full(cp, &screencols))
95 resizeterm(screenrows, screencols);
Convenience wrapper for the library headers.
const char * mutt_str_getenv(const char *name)
Get an environment variable.
Define wrapper functions around Curses.
void window_notify_all(struct MuttWindow *win)
Notify observers of changes to a Window and its children.
void mutt_resize_screen(void)
Update NeoMutt's opinion about the window size.
static struct winsize mutt_get_winsize(void)
Get the window size.
void rootwin_set_size(int cols, int rows)
Set the dimensions of the Root Window.