wresize(3x) — Linux manual page

NAME | SYNOPSIS | DESCRIPTION | RETURN VALUE | NOTES | EXTENSIONS | PORTABILITY | HISTORY | AUTHORS | SEE ALSO | COLOPHON

wresize(3X)                   Library calls                   wresize(3X)

NAME         top

       wresize - resize a curses window

SYNOPSIS         top

       #include <curses.h>

       int wresize(WINDOW * win, int lines, int columns);

DESCRIPTION         top

       wresize, an ncurses extension to the curses library, reallocates
       storage for win, adjusting its dimensions to lines and columns.
       If either dimension is larger than its current value, ncurses
       fills the expanded part of the window with the window's background
       character as configured by wbkgdset(3X) (wide-character API:
       wbkgrndset(3X)).

RETURN VALUE         top

       wresize returns OK on success and ERR on failure.  It fails if
       either lines or columns is less than or equal to zero, or if an
       error occurs while (re)allocating memory for win.

NOTES         top

       The only restriction placed on the values of lines and columns is
       that they be greater than zero.  They are not compared to the
       dimensions of the curses screen; this keeps the logic of
       resizeterm(3X) simple.  The caller must ensure that win's
       dimensions fit within those of the screen.

EXTENSIONS         top

       wresize is an ncurses(3X) extension, and is not found in SVr4
       curses, 4.4BSD curses, or any other previous curses
       implementation.

PORTABILITY         top

       Applications employing ncurses extensions should condition their
       use on the visibility of the NCURSES_VERSION preprocessor macro.

       NetBSD curses adopted wresize in 2001 (release 1.5.3), and
       PDCurses in 2004 (version 2.7).

       It is not possible to resize windows with SVr4 curses.

HISTORY         top

       Thomas Dickey developed wresize as an extension to BSD curses in
       1988, and brought it to ncurses in mid-1995.

AUTHORS         top

       Thomas Dickey

SEE ALSO         top

       resizeterm(3X)

COLOPHON         top

       This page is part of the ncurses (new curses) project.
       Information about the project can be found at 
       ⟨https://invisible-island.net/ncurses/ncurses.html⟩.  If you have a
       bug report for this manual page, send it to bug-ncurses@gnu.org.
       This page was obtained from the tarball ncurses-6.6.tar.gz fetched
       from ⟨https://ftp.gnu.org/gnu/ncurses/⟩ on 2026-01-16.  If you
       discover any rendering problems in this HTML version of the page,
       or you believe there is a better or more up-to-date source for the
       page, or you have corrections or improvements to the information
       in this COLOPHON (which is not part of the original manual page),
       send a mail to man-pages@man7.org

ncurses @NCURSES_MAJOR@.@NCU... 2025-01-18                    wresize(3X)