]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/dft_fgbg.3x
ncurses 5.0
[ncurses.git] / man / dft_fgbg.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 .\" Author: Thomas E. Dickey <dickey@clark.net> 1997
30 .\"
31 .\" $Id: dft_fgbg.3x,v 1.6 1998/03/14 23:43:15 tom Exp $
32 .TH use_default_colors 3X ""
33 .SH NAME
34 \fBdft_fgbg\fR \- use terminal's default colors
35 ..
36 .SH SYNOPSIS
37 \fB#include <curses.h>\fP
38
39 \fBint use_default_colors(void);\fP
40 ..
41 .SH DESCRIPTION
42 This is an extension to the curses library.
43 It is used with terminals that support ISO 6429 color, or equivalent.
44 These terminals allow the application to reset color to an unspecified
45 default value (e.g., with SGR 39 or SGR 49).
46 Because they are designed to support this, their design usually includes
47 features to change the default foreground or background colors so that
48 they do not match the assumption in XSI curses of white on black.
49 .PP
50 Applications that paint a colored background over the whole screen
51 are not adversely impacted by this type of terminal design.
52 However, there are applications that are designed to work with
53 the default background.
54 ..
55 .SH RETURN VALUE
56 The function returns the integer \fBERR\fP upon failure and \fBOK\fP on success.
57 It will fail if either the terminal does not support
58 the \fIorig_pair\fP or \fIorig_colors\fP capability.
59 If the \fIinitialize_pair\fP capability is found, this causes an
60 error as well.
61 ..
62 .SH NOTES
63 Associated with this extension, the \fBinit_pair\fR(3X) function accepts
64 negative arguments to specify default foreground or background
65 colors.
66 ..
67 .SH PORTABILITY
68 These routines are specific to ncurses.  They were not supported on
69 Version 7, BSD or System V implementations.  It is recommended that
70 any code depending on them be conditioned using NCURSES_VERSION.
71 ..
72 .SH SEE ALSO
73 \fBcurs_color\fR(3X),
74 \fBded\fP(1).
75 ..
76 .SH AUTHOR
77 Thomas Dickey (from an analysis of the requirements for color xterm
78 for XFree86 3.1.2C, February 1996).
79 .\"#
80 .\"# The following sets edit modes for GNU EMACS
81 .\"# Local Variables:
82 .\"# mode:nroff
83 .\"# fill-column:79
84 .\"# End: