41#ifndef HAVE_TCGETWINSIZE
42#ifdef HAVE_SYS_IOCTL_H
57 struct winsize w = { 0 };
59 int fd = open(
"/dev/tty", O_RDONLY);
62#ifdef HAVE_TCGETWINSIZE
65 ioctl(fd, TIOCGWINSZ, &w);
79 int screenrows = w.ws_row;
80 int screencols = w.ws_col;
85 if (cp && !mutt_str_atoi_full(cp, &screenrows))
92 if (cp && !mutt_str_atoi_full(cp, &screencols))
96 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.