]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - man/curs_window.3x
ncurses 6.3 - patch 20220724
[ncurses.git] / man / curs_window.3x
index a6090ffca63a35e0018151cd3b73f21c5713bdae..c786650ecf4dc062d9c675e0d76dc64955e0453d 100644 (file)
@@ -1,5 +1,5 @@
 .\"***************************************************************************
-.\" Copyright 2020,2021 Thomas E. Dickey                                     *
+.\" Copyright 2020-2021,2022 Thomas E. Dickey                                *
 .\" Copyright 1998-2015,2016 Free Software Foundation, Inc.                  *
 .\"                                                                          *
 .\" Permission is hereby granted, free of charge, to any person obtaining a  *
@@ -27,7 +27,7 @@
 .\" authorization.                                                           *
 .\"***************************************************************************
 .\"
-.\" $Id: curs_window.3x,v 1.24 2021/12/25 17:39:16 tom Exp $
+.\" $Id: curs_window.3x,v 1.27 2022/07/24 15:35:15 tom Exp $
 .TH curs_window 3X ""
 .de bP
 .ie n  .IP \(bu 4
 \fB#include <curses.h>\fP
 .sp
 \fBWINDOW *newwin(\fP
-      \fBint \fP\fInlines\fP\fB, int \fP\fIncols\fP\fB,\fP
-      \fBint \fP\fIbegin_y\fP\fB, int \fP\fIbegin_x\fP\fB);\fP
+      \fBint \fInlines\fB, int \fIncols\fB,\fR
+      \fBint \fIbegin_y\fB, int \fIbegin_x\fB);\fR
 .br
-\fBint delwin(WINDOW *\fP\fIwin\fP\fB);\fP
+\fBint delwin(WINDOW *\fIwin\fB);\fR
 .br
-\fBint mvwin(WINDOW *\fP\fIwin\fP\fB, int \fP\fIy\fP\fB, int \fP\fIx\fP\fB);\fP
+\fBint mvwin(WINDOW *\fIwin\fB, int \fIy\fB, int \fIx\fB);\fR
 .br
-\fBWINDOW *subwin(WINDOW *\fP\fIorig\fP\fB,\fP
-      \fBint \fP\fInlines\fP\fB, int \fP\fIncols\fP\fB,\fP
-      \fBint \fP\fIbegin_y\fP\fB, int \fP\fIbegin_x\fP\fB);\fP
+\fBWINDOW *subwin(WINDOW *\fIorig\fB,\fR
+      \fBint \fInlines\fB, int \fIncols\fB,\fR
+      \fBint \fIbegin_y\fB, int \fIbegin_x\fB);\fR
 .br
-\fBWINDOW *derwin(WINDOW *\fP\fIorig\fP\fB,\fP
-      \fBint \fP\fInlines\fP\fB, int \fP\fIncols\fP\fB,\fP
-      \fBint \fP\fIbegin_y\fP\fB, int \fP\fIbegin_x\fP\fB);\fP
+\fBWINDOW *derwin(WINDOW *\fIorig\fB,\fR
+      \fBint \fInlines\fB, int \fIncols\fB,\fR
+      \fBint \fIbegin_y\fB, int \fIbegin_x\fB);\fR
 .br
-\fBint mvderwin(WINDOW *\fP\fIwin\fP\fB, int \fP\fIpar_y\fP\fB, int \fP\fIpar_x\fP\fB);\fP
+\fBint mvderwin(WINDOW *\fIwin\fB, int \fIpar_y\fB, int \fIpar_x\fB);\fR
 .br
-\fBWINDOW *dupwin(WINDOW *\fP\fIwin\fP\fB);\fP
+\fBWINDOW *dupwin(WINDOW *\fIwin\fB);\fR
 .br
-\fBvoid wsyncup(WINDOW *\fP\fIwin\fP\fB);\fP
+\fBvoid wsyncup(WINDOW *\fIwin\fB);\fR
 .br
-\fBint syncok(WINDOW *\fP\fIwin\fP\fB, bool \fP\fIbf\fP\fB);\fP
+\fBint syncok(WINDOW *\fIwin\fB, bool \fIbf\fB);\fR
 .br
-\fBvoid wcursyncup(WINDOW *\fP\fIwin\fP\fB);\fP
+\fBvoid wcursyncup(WINDOW *\fIwin\fB);\fR
 .br
-\fBvoid wsyncdown(WINDOW *\fP\fIwin\fP\fB);\fP
+\fBvoid wsyncdown(WINDOW *\fIwin\fB);\fR
 .br
 .SH DESCRIPTION
 .SS newwin
@@ -256,8 +256,27 @@ is patterned on the XPG4 curses standard.
 The weaker XPG4 spec may result in slower updates.
 .SH PORTABILITY
 The XSI Curses standard, Issue 4 describes these functions.
+.PP
+X/Open Curses states regarding \fBdelwin\fP:
+.bP
+It must delete subwindows before deleting their parent.
+.bP
+If \fBdelwin\fP is asked to delete a parent window,
+it can only succeed if the curses library keeps a list of the subwindows.
+SVr4 curses kept a count of the number of subwindows rather than a list.
+It simply returned \fBERR\fP when asked to delete a subwindow.
+Solaris X/Open curses does not even make that check,
+and will delete a parent window which still has subwindows.
+.bP
+Since release 4.0 (1996), ncurses maintains a list of windows for each screen,
+and is able to recursively delete subwindows when asked to delete their parent.
+.bP
+NetBSD copied this feature of ncurses in 2003.
+.br
+PDCurses follows the scheme used in Solaris X/Open curses.
 .SH SEE ALSO
 \fBcurses\fP(3X),
+\fBcurs_initscr\fP(3X),
 \fBcurs_refresh\fP(3X),
 \fBcurs_touch\fP(3X),
 \fBcurs_variables\fP(3X)