4 <!-- Manpage converted by man2html 3.0.1 -->
8 <B>baudrate</B>, <B>erasechar</B>, <B>has_ic</B>, <B>has_il</B>, <B>killchar</B>, <B>longname</B>,
9 <B>termattrs</B>, <B>termname</B> - <B>curses</B> environment query routines
13 <H2>SYNOPSIS</H2><PRE>
14 <B>#include</B> <B><curses.h></B>
16 <B>int</B> <B>baudrate(void);</B>
17 <B>char</B> <B>erasechar(void);</B>
18 <B>bool</B> <B>has_ic(void);</B>
19 <B>bool</B> <B>has_il(void);</B>
20 <B>char</B> <B>killchar(void);</B>
21 <B>char</B> <B>*longname(void);</B>
22 <B>attr_t</B> <B>termattrs(void);</B>
23 <B>char</B> <B>*termname(void);</B>
27 <H2>DESCRIPTION</H2><PRE>
28 The <B>baudrate</B> routine returns the output speed of the ter-
29 minal. The number returned is in bits per second, for
30 example <B>9600</B>, and is an integer.
32 The <B>erasechar</B> routine returns the user's current erase
35 The <B>has_ic</B> routine is true if the terminal has insert- and
36 delete- character capabilities.
38 The <B>has_il</B> routine is true if the terminal has insert- and
39 delete-line capabilities, or can simulate them using
40 scrolling regions. This might be used to determine if it
41 would be appropriate to turn on physical scrolling using
44 The <B>killchar</B> routine returns the user's current line kill
47 The <B>longname</B> routine returns a pointer to a static area
48 containing a verbose description of the current terminal.
49 The maximum length of a verbose description is 128 charac-
50 ters. It is defined only after the call to <B>initscr</B> or
51 <B>newterm</B>. The area is overwritten by each call to <B>newterm</B>
52 and is not restored by <B>set_term</B>, so the value should be
53 saved between calls to <B>newterm</B> if <B>longname</B> is going to be
54 used with multiple terminals.
56 If a given terminal doesn't support a video attribute that
57 an application program is trying to use, <B>curses</B> may sub-
58 stitute a different video attribute for it. The <B>termattrs</B>
59 function returns a logical <B>OR</B> of all video attributes sup-
60 ported by the terminal. This information is useful when a
61 <B>curses</B> program needs complete control over the appearance
64 The <B>termname</B> routine returns the value of the
65 environmental variable <B>TERM</B> (truncated to 14 characters).
69 <H2>RETURN VALUE</H2><PRE>
70 <B>longname</B> and <B>termname</B> return <B>NULL</B> on error.
72 Routines that return an integer return <B>ERR</B> upon failure
73 and <B>OK</B> (SVr4 only specifies "an integer value other than
74 <B>ERR</B>") upon successful completion.
79 Note that <B>termattrs</B> may be a macro.
83 <H2>PORTABILITY</H2><PRE>
84 The XSI Curses standard, Issue 4 describes these func-
85 tions. It changes the return type of <B>termattrs</B> to the new
90 <H2>SEE ALSO</H2><PRE>
91 <B><A HREF="ncurses.3x.html">curses(3x)</A></B>, <B><A HREF="curs_initscr.3x.html">curs_initscr(3x)</A></B>, <B><A HREF="curs_outopts.3x.html">curs_outopts(3x)</A></B>
130 Man(1) output converted with
131 <a href="http://www.oac.uci.edu/indiv/ehood/man2html.html">man2html</a>