]> ncurses.scripts.mit.edu Git - ncurses.git/blob - Ada95/html/man/curs_inchstr.3x.html
ncurses 4.2
[ncurses.git] / Ada95 / html / man / curs_inchstr.3x.html
1 <HTML>
2 <BODY>
3 <PRE>
4        <STRONG>inchstr</STRONG>,   <STRONG>inchnstr</STRONG>,   <STRONG>winchstr</STRONG>,   <STRONG>winchnstr</STRONG>,   <STRONG>mvinchstr</STRONG>,
5        <STRONG>mvinchnstr</STRONG>, <STRONG>mvwinchstr</STRONG>, <STRONG>mvwinchnstr</STRONG>  -  get  a  string  of
6        characters (and attributes) from a <STRONG>curses</STRONG> window
7
8
9 </PRE>
10 <H2>SYNOPSIS</H2><PRE>
11        <STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
12
13        <STRONG>int</STRONG> <STRONG>inchstr(chtype</STRONG> <STRONG>*chstr);</STRONG>
14        <STRONG>int</STRONG> <STRONG>inchnstr(chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
15        <STRONG>int</STRONG> <STRONG>winchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
16        <STRONG>int</STRONG> <STRONG>winchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
17        <STRONG>int</STRONG> <STRONG>mvinchstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
18        <STRONG>int</STRONG> <STRONG>mvinchnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
19        <STRONG>int</STRONG> <STRONG>mvwinchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
20        <STRONG>int</STRONG>  <STRONG>mvwinchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG>
21        <STRONG>int</STRONG> <STRONG>n);</STRONG>
22
23
24 </PRE>
25 <H2>DESCRIPTION</H2><PRE>
26        These routines return a NULL-terminated  array  of  <STRONG>chtype</STRONG>
27        quantities, starting at the current cursor position in the
28        named window and ending at the right margin of the window.
29        The  four  functions with <EM>n</EM> as the last argument, return a
30        leading substring at most <EM>n</EM> characters long (exclusive  of
31        the  trailing (chtype)0).  Constants defined in <STRONG><curses.h></STRONG>
32        can be used with the <STRONG>&</STRONG> (logical AND) operator  to  extract
33        the  character or the attribute alone from any position in
34        the <EM>chstr</EM> [see <STRONG><A HREF="curs_inch.3x.html">curs_inch(3X)</A></STRONG>].
35
36
37 </PRE>
38 <H2>RETURN VALUE</H2><PRE>
39        All routines return the integer <STRONG>ERR</STRONG> upon  failure  and  an
40        integer  value  other  than <STRONG>ERR</STRONG> upon successful completion
41        (the number of  characters  retrieved,  exclusive  of  the
42        trailing 0).
43
44
45 </PRE>
46 <H2>NOTES</H2><PRE>
47        Note  that  all  routines  except <STRONG>winchnstr</STRONG> may be macros.
48        SVr4 does not document whether the result string is 0-ter-
49        minated; it does not document whether a length limit argu-
50        ment includes any trailing 0; and it does not document the
51        meaning of the return value.
52
53
54 </PRE>
55 <H2>PORTABILITY</H2><PRE>
56        These  functions are described in the XSI Curses standard,
57        Issue 4.  It is no more specific than the SVr4  documenta-
58        tion on the trailing 0.  It does specify that the success-
59        ful return of the functions is <STRONG>OK</STRONG>.
60
61
62 </PRE>
63 <H2>SEE ALSO</H2><PRE>
64        <STRONG><A HREF="ncurses.3x.html">curses(3X)</A></STRONG>, <STRONG><A HREF="curs_inch.3x.html">curs_inch(3X)</A></STRONG>.
65
66
67
68 </PRE>
69 </BODY>
70 </HTML>