38#ifndef HAVE_TCGETWINSIZE
39#ifdef HAVE_SYS_IOCTL_H
54 struct winsize w = { 0 };
56 int fd = open(
"/dev/tty", O_RDONLY);
59#ifdef HAVE_TCGETWINSIZE
62 ioctl(fd, TIOCGWINSZ, &w);
76 int screenrows = w.ws_row;
77 int screencols = w.ws_col;
82 if (cp && !mutt_str_atoi_full(cp, &screenrows))
89 if (cp && !mutt_str_atoi_full(cp, &screencols))
93 resizeterm(screenrows, screencols);
Convenience wrapper for the gui headers.
Convenience wrapper for the library headers.
const char * mutt_str_getenv(const char *name)
Get an environment variable.
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 (CURSES)
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.