blob: b2d768a441d927bd8fe0c97aeac001da0246bdc0 [file] [log] [blame]
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +05301.\"***************************************************************************
2.\" Copyright (c) 1998-2002,2003 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.19 2003/12/27 18:50:40 tom Exp $
30.TH curs_bkgd 3X ""
31.SH NAME
32\fBbkgdset\fR, \fBwbkgdset\fR,
33\fBbkgd\fR, \fBwbkgd\fR,
34\fBgetbkgd\fR - \fBcurses\fR window background manipulation routines
35.SH SYNOPSIS
36\fB#include <curses.h>\fR
37.PP
38\fBvoid bkgdset(chtype ch);\fR
39.br
40\fBvoid wbkgdset(WINDOW *win, chtype ch);\fR
41.br
42\fBint bkgd(chtype ch);\fR
43.br
44\fBint wbkgd(WINDOW *win, chtype ch);\fR
45.br
46\fBchtype getbkgd(WINDOW *win);\fR
47.br
48.SH DESCRIPTION
49The \fBbkgdset\fR and \fBwbkgdset\fR routines manipulate the
50background of the named window.
51The window background is a \fBchtype\fR consisting of
52any combination of attributes (i.e., rendition) and a character.
53The attribute part of the background is combined (OR'ed) with all non-blank
54characters that are written into the window with \fBwaddch\fR. Both
55the character and attribute parts of the background are combined with
56the blank characters. The background becomes a property of the
57character and moves with the character through any scrolling and
58insert/delete line/character operations.
59.PP
60To the extent possible on a particular terminal,
61the attribute part of the background is displayed
62as the graphic rendition of the character put on the screen.
63.PP
64The \fBbkgd\fR and \fBwbkgd\fR functions
65set the background property of the current or specified window
66and then apply this setting to every character position in that window:
67.PP
68.RS
69The rendition of every character on the screen is changed to
70the new background rendition.
71.PP
72Wherever the former background character
73appears, it is changed to the new background character.
74.RE
75.PP
76The \fBgetbkgd\fR function returns the given window's current background
77character/attribute pair.
78.SH RETURN VALUE
79The routines \fBbkgd\fR and \fBwbkgd\fR return the integer \fBOK\fR.
80The SVr4.0 manual says "or a non-negative integer if \fBimmedok\fR is set",
81but this appears to be an error.
82.SH NOTES
83Note that \fBbkgdset\fR and \fBbkgd\fR may be macros.
84.SH PORTABILITY
85These functions are described in the XSI Curses standard, Issue 4.
86It specifies that \fBbkgd\fR and \fBwbkgd\fR return \fBERR\fR on failure.
87but gives no failure conditions.
88.SH SEE ALSO
89\fBcurses\fR(3X),
90\fBcurs_addch\fR(3X),
91\fBcurs_attr\fR(3X),
92\fBcurs_outopts\fR(3X)
93.\"#
94.\"# The following sets edit modes for GNU EMACS
95.\"# Local Variables:
96.\"# mode:nroff
97.\"# fill-column:79
98.\"# End: