]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/curs_bkgd.3x
ncurses 5.0
[ncurses.git] / man / curs_bkgd.3x
1 .\"***************************************************************************
2 .\" Copyright (c) 1998 Free Software Foundation, Inc.                        *
3 .\"                                                                          *
4 .\" Permission is hereby granted, free of charge, to any person obtaining a  *
5 .\" copy of this software and associated documentation files (the            *
6 .\" "Software"), to deal in the Software without restriction, including      *
7 .\" without limitation the rights to use, copy, modify, merge, publish,      *
8 .\" distribute, distribute with modifications, sublicense, and/or sell       *
9 .\" copies of the Software, and to permit persons to whom the Software is    *
10 .\" furnished to do so, subject to the following conditions:                 *
11 .\"                                                                          *
12 .\" The above copyright notice and this permission notice shall be included  *
13 .\" in all copies or substantial portions of the Software.                   *
14 .\"                                                                          *
15 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  *
16 .\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               *
17 .\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   *
18 .\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   *
19 .\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    *
20 .\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    *
21 .\" THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               *
22 .\"                                                                          *
23 .\" Except as contained in this notice, the name(s) of the above copyright   *
24 .\" holders shall not be used in advertising or otherwise to promote the     *
25 .\" sale, use or other dealings in this Software without prior written       *
26 .\" authorization.                                                           *
27 .\"***************************************************************************
28 .\"
29 .\" $Id: curs_bkgd.3x,v 1.12 1998/03/14 23:43:31 tom Exp $
30 .TH curs_bkgd 3X ""
31 .SH NAME
32 \fBbkgdset\fR, \fBwbkgdset\fR, \fBbkgd\fR,
33 \fBwbkgd\fR - \fBcurses\fR window background manipulation routines
34 ..
35 .SH SYNOPSIS
36 \fB#include <curses.h>\fR
37
38 \fBvoid bkgdset(const chtype ch);\fR
39 .br
40 \fBvoid wbkgdset(WINDOW *win, const chtype ch);\fR
41 .br
42 \fBint bkgd(const chtype ch);\fR
43 .br
44 \fBint wbkgd(WINDOW *win, const chtype ch);\fR
45 .br
46 \fBchtype getbkgd(WINDOW *win);\fR
47 .br
48 ..
49 .SH DESCRIPTION
50 The \fBbkgdset\fR and \fBwbkgdset\fR routines manipulate the
51 background of the named window.
52 The window background is a \fBchtype\fR consisting of
53 any combination of attributes (i.e., rendition) and a character.
54 The attribute part of the background is combined (OR'ed) with all non-blank
55 characters that are written into the window with \fBwaddch\fR.  Both
56 the character and attribute parts of the background are combined with
57 the blank characters.  The background becomes a property of the
58 character and moves with the character through any scrolling and
59 insert/delete line/character operations.
60
61 To the extent possible on a
62 particular terminal, the attribute part of the background is displayed
63 as the graphic rendition of the character put on the screen.
64
65 The \fBbkgd\fR and \fBwbkgd\fR functions
66 set the background property of the current or specified window
67 and then apply this setting to every character position in that window:
68
69 .RS
70 The rendition of every character on the screen is changed to
71 the new background rendition.
72
73 Wherever the former background character
74 appears, it is changed to the new background character.
75 .RE
76
77 The \fBgetbkgd\fR function returns the given window's current background
78 character/attribute pair.
79 ..
80 .SH RETURN VALUE
81 The routines \fBbkgd\fR and \fBwbkgd\fR return the integer \fBOK\fR.
82 The SVr4.0 manual says "or a non-negative integer if \fBimmedok\fR is set",
83 but this appears to be an error.
84 ..
85 .SH NOTES
86 Note that \fBbkgdset\fR and \fBbkgd\fR may be macros.
87 ..
88 .SH PORTABILITY
89 These functions are described in the XSI Curses standard, Issue 4.  The draft
90 does not include \fBconst\fR qualifiers on the arguments.  The standard
91 specifies that \fBbkgd\fR and \fBwbkgd\fR return \fBERR\fR, on failure. but
92 gives no failure conditions.
93 ..
94 .SH SEE ALSO
95 \fBcurses\fR(3X), \fBcurs_addch\fR(3X), \fBcurs_outopts\fR(3X)
96 .\"#
97 .\"# The following sets edit modes for GNU EMACS
98 .\"# Local Variables:
99 .\"# mode:nroff
100 .\"# fill-column:79
101 .\"# End: