4 <STRONG>baudrate</STRONG>, <STRONG>erasechar</STRONG>, <STRONG>has_ic</STRONG>, <STRONG>has_il</STRONG>, <STRONG>killchar</STRONG>, <STRONG>longname</STRONG>,
5 <STRONG>termattrs</STRONG>, <STRONG>termname</STRONG> - <STRONG>curses</STRONG> environment query routines
10 <STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
12 <STRONG>int</STRONG> <STRONG>baudrate(void);</STRONG>
13 <STRONG>char</STRONG> <STRONG>erasechar(void);</STRONG>
14 <STRONG>int</STRONG> <STRONG>has_ic(void);</STRONG>
15 <STRONG>int</STRONG> <STRONG>has_il(void);</STRONG>
16 <STRONG>char</STRONG> <STRONG>killchar(void);</STRONG>
17 <STRONG>char</STRONG> <STRONG>*longname(void);</STRONG>
18 <STRONG>attr_t</STRONG> <STRONG>termattrs(void);</STRONG>
19 <STRONG>char</STRONG> <STRONG>*termname(void);</STRONG>
23 <H2>DESCRIPTION</H2><PRE>
24 The <STRONG>baudrate</STRONG> routine returns the output speed of the ter-
25 minal. The number returned is in bits per second, for
26 example <STRONG>9600</STRONG>, and is an integer.
28 The <STRONG>erasechar</STRONG> routine returns the user's current erase
31 The <STRONG>has_ic</STRONG> routine is true if the terminal has insert- and
32 delete- character capabilities.
34 The <STRONG>has_il</STRONG> routine is true if the terminal has insert- and
35 delete-line capabilities, or can simulate them using
36 scrolling regions. This might be used to determine if it
37 would be appropriate to turn on physical scrolling using
38 <STRONG>scrollok</STRONG>.
40 The <STRONG>killchar</STRONG> routine returns the user's current line kill
43 The <STRONG>longname</STRONG> routine returns a pointer to a static area
44 containing a verbose description of the current terminal.
45 The maximum length of a verbose description is 128 charac-
46 ters. It is defined only after the call to <STRONG>initscr</STRONG> or
47 <STRONG>newterm</STRONG>. The area is overwritten by each call to <STRONG>newterm</STRONG>
48 and is not restored by <STRONG>set_term</STRONG>, so the value should be
49 saved between calls to <STRONG>newterm</STRONG> if <STRONG>longname</STRONG> is going to be
50 used with multiple terminals.
52 If a given terminal doesn't support a video attribute that
53 an application program is trying to use, <STRONG>curses</STRONG> may sub-
54 stitute a different video attribute for it. The <STRONG>termattrs</STRONG>
55 function returns a logical <STRONG>OR</STRONG> of all video attributes sup-
56 ported by the terminal. This information is useful when a
57 <STRONG>curses</STRONG> program needs complete control over the appearance
63 <H2>RETURN VALUE</H2><PRE>
64 <STRONG>longname</STRONG> and <STRONG>termname</STRONG> return <STRONG>NULL</STRONG> on error.
66 Routines that return an integer return <STRONG>ERR</STRONG> upon failure
67 and <STRONG>OK</STRONG> (SVr4 only specifies "an integer value other than
68 <STRONG>ERR</STRONG>") upon successful completion.
73 Note that <STRONG>termattrs</STRONG> may be a macro.
77 <H2>PORTABILITY</H2><PRE>
78 The XSI Curses standard, Issue 4 describes these func-
79 tions. It changes the return type of <STRONG>termattrs</STRONG> to the new
80 type <STRONG>attr_t</STRONG>.
84 <H2>SEE ALSO</H2><PRE>
85 <STRONG><A HREF="ncurses.3x.html">curses(3X)</A></STRONG>, <STRONG><A HREF="curs_initscr.3x.html">curs_initscr(3X)</A></STRONG>, <STRONG><A HREF="curs_outopts.3x.html">curs_outopts(3X)</A></STRONG>