Explicitly specify `all' as the default target(as it used to be), so as
[dragonfly.git] / lib / libncurses / man / curs_termattrs.3
1 .\"***************************************************************************
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_termattrs.3x,v 1.9 2003/12/27 18:37:47 tom Exp $
30 .\" $DragonFly: src/lib/libncurses/man/curs_termattrs.3,v 1.1 2005/03/12 19:13:54 eirikn Exp $
31 .TH curs_termattrs 3X ""
32 .SH NAME
33 \fBbaudrate\fR,
34 \fBerasechar\fR,
35 \fBerasewchar\fR,
36 \fBhas_ic\fR,
37 \fBhas_il\fR,
38 \fBkillchar\fR,
39 \fBkillwchar\fR,
40 \fBlongname\fR,
41 \fBterm_attrs\fR,
42 \fBtermattrs\fR,
43 \fBtermname\fR - \fBcurses\fR environment query routines
44 .SH SYNOPSIS
45 \fB#include <curses.h>\fR
46 .PP
47 \fBint baudrate(void);\fR
48 .br
49 \fBchar erasechar(void);\fR
50 .br
51 \fBint erasewchar(wchar_t *\fR\fIch\fR\fB);\fR
52 .br
53 \fBbool has_ic(void);\fR
54 .br
55 \fBbool has_il(void);\fR
56 .br
57 \fBchar killchar(void);\fR
58 .br
59 \fBint killwchar(wchar_t *\fR\fIch\fR\fB);\fR
60 .br
61 \fBchar *longname(void);\fR
62 .br
63 \fBattr_t term_attrs(void);\fR
64 .br
65 \fBchtype termattrs(void);\fR
66 .br
67 \fBchar *termname(void);\fR
68 .br
69 .SH DESCRIPTION
70 The \fBbaudrate\fR routine returns the output speed of the terminal.  The
71 number returned is in bits per second, for example \fB9600\fR, and is an
72 integer.
73 .PP
74 The \fBerasechar\fR routine returns the user's current erase character.
75 .PP
76 The \fBerasewchar\fR routine stores the current erase character
77 in the location referenced by \fIch\fR.
78 If no erase character has been defined, the routine fails
79 and the location referenced by \fIch\fR is not changed.
80 .PP
81 The \fBhas_ic\fR routine is true if the terminal has insert- and delete-
82 character capabilities.
83 .PP
84 The \fBhas_il\fR routine is true if the terminal has insert- and delete-line
85 capabilities, or can simulate them using scrolling regions.  This might
86 be used to determine if it would be appropriate to turn on physical
87 scrolling using \fBscrollok\fR.
88 .PP
89 The \fBkillchar\fR routine returns the user's current line kill character.
90 .PP
91 The \fBkillwchar\fR routine stores the current line-kill character
92 in the location referenced by \fIch\fR.
93 If no line-kill character has been defined,
94 the routine fails and the location referenced by \fIch\fR is not changed.
95 .PP
96 The \fBlongname\fR routine returns a pointer to a static area
97 containing a verbose description of the current terminal.  The maximum
98 length of a verbose description is 128 characters.  It is defined only
99 after the call to \fBinitscr\fR or \fBnewterm\fR.  The area is
100 overwritten by each call to \fBnewterm\fR and is not restored by
101 \fBset_term\fR, so the value should be saved between calls to
102 \fBnewterm\fR if \fBlongname\fR is going to be used with multiple
103 terminals.
104 .PP
105 If a given terminal doesn't support a video attribute that an
106 application program is trying to use, \fBcurses\fR may substitute a
107 different video attribute for it.
108 The \fBtermattrs\fR and \fBterm_attrs\fR functions
109 return a logical \fBOR\fR of all video attributes supported by the
110 terminal using \fIA_\fR and \fIWA_\fR constants respectively.
111 This information is useful when a \fBcurses\fR program
112 needs complete control over the appearance of the screen.
113 .PP
114 The \fBtermname\fR routine returns the terminal name used by \fBsetupterm\fR.
115 .SH RETURN VALUE
116 \fBlongname\fR and \fBtermname\fR return \fBNULL\fR on error.
117 .PP
118 Routines that return an integer return \fBERR\fR upon failure and \fBOK\fR
119 (SVr4 only specifies "an integer value other than \fBERR\fR") upon successful
120 completion.
121 .SH NOTES
122 Note that \fBtermattrs\fR may be a macro.
123 .SH PORTABILITY
124 The XSI Curses standard, Issue 4 describes these functions.  It changes the
125 return type of \fBtermattrs\fR to the new type \fBattr_t\fR.
126 Most versions of curses truncate the result returned by \fBtermname\fR to
127 14 characters.
128 .SH SEE ALSO
129 \fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_outopts\fR(3X)
130 .\"#
131 .\"# The following sets edit modes for GNU EMACS
132 .\"# Local Variables:
133 .\"# mode:nroff
134 .\"# fill-column:79
135 .\"# End: