]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/curs_bkgd.3x
ncurses 4.2
[ncurses.git] / man / curs_bkgd.3x
1 .\" $Id: curs_bkgd.3x,v 1.10 1996/07/20 23:48:30 tom Exp $
2 .TH curs_bkgd 3X ""
3 .
4 .SH NAME
5 \fBbkgdset\fR, \fBwbkgdset\fR, \fBbkgd\fR,
6 \fBwbkgd\fR - \fBcurses\fR window background manipulation routines
7 .
8 .SH SYNOPSIS
9 \fB#include <curses.h>\fR
10
11 \fBvoid bkgdset(const chtype ch);\fR
12 .br
13 \fBvoid wbkgdset(WINDOW *win, const chtype ch);\fR
14 .br
15 \fBint bkgd(const chtype ch);\fR
16 .br
17 \fBint wbkgd(WINDOW *win, const chtype ch);\fR
18 .br
19 \fBchtype getbkgd(WINDOW *win);\fR
20 .br
21 .
22 .SH DESCRIPTION
23 The \fBbkgdset\fR and \fBwbkgdset\fR routines manipulate the
24 background of the named window.
25 The window background is a \fBchtype\fR consisting of
26 any combination of attributes (i.e., rendition) and a character.
27 The attribute part of the background is combined (OR'ed) with all non-blank
28 characters that are written into the window with \fBwaddch\fR.  Both
29 the character and attribute parts of the background are combined with
30 the blank characters.  The background becomes a property of the
31 character and moves with the character through any scrolling and
32 insert/delete line/character operations.
33
34 To the extent possible on a
35 particular terminal, the attribute part of the background is displayed
36 as the graphic rendition of the character put on the screen.
37
38 The \fBbkgd\fR and \fBwbkgd\fR functions
39 set the background property of the current or specified window
40 and then apply this setting to every character position in that window:
41
42 .RS
43 The rendition of every character on the screen is changed to
44 the new background rendition.
45
46 Wherever the former background character
47 appears, it is changed to the new background character.
48 .RE
49
50 The \fBgetbkgd\fR function returns the given window's current background
51 character/attribute pair.
52 .
53 .SH RETURN VALUE
54 The routines \fBbkgd\fR and \fBwbkgd\fR return the integer \fBOK\fR.
55 The SVr4.0 manual says "or a non-negative integer if \fBimmedok\fR is set",
56 but this appears to be an error.
57 .
58 .SH NOTES
59 Note that \fBbkgdset\fR and \fBbkgd\fR may be macros.
60 .
61 .SH PORTABILITY
62 These functions are described in the XSI Curses standard, Issue 4.  The draft
63 does not include \fBconst\fR qualifiers on the arguments.  The standard
64 specifies that \fBbkgd\fR and \fBwbkgd\fR return \fBERR\fR, on failure. but
65 gives no failure conditions.
66 .
67 .SH SEE ALSO
68 \fBcurses\fR(3X), \fBcurs_addch\fR(3X), \fBcurs_outopts\fR(3X)
69 .\"#
70 .\"# The following sets edit modes for GNU EMACS
71 .\"# Local Variables:
72 .\"# mode:nroff
73 .\"# fill-column:79
74 .\"# End: