| 1 | .\"***************************************************************************
|
|---|
| 2 | .\" Copyright (c) 1998-2000,2005 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_inchstr.3x,v 1.10 2005/05/15 16:54:53 tom Exp $
|
|---|
| 30 | .TH curs_inchstr 3X ""
|
|---|
| 31 | .na
|
|---|
| 32 | .hy 0
|
|---|
| 33 | .SH NAME
|
|---|
| 34 | \fBinchstr\fR,
|
|---|
| 35 | \fBinchnstr\fR,
|
|---|
| 36 | \fBwinchstr\fR,
|
|---|
| 37 | \fBwinchnstr\fR,
|
|---|
| 38 | \fBmvinchstr\fR,
|
|---|
| 39 | \fBmvinchnstr\fR,
|
|---|
| 40 | \fBmvwinchstr\fR,
|
|---|
| 41 | \fBmvwinchnstr\fR - get a string of characters (and attributes) from a \fBcurses\fR window
|
|---|
| 42 | .ad
|
|---|
| 43 | .hy
|
|---|
| 44 | .SH SYNOPSIS
|
|---|
| 45 | \fB#include <curses.h>\fR
|
|---|
| 46 |
|
|---|
| 47 | \fBint inchstr(chtype *chstr);\fR
|
|---|
| 48 | .br
|
|---|
| 49 | \fBint inchnstr(chtype *chstr, int n);\fR
|
|---|
| 50 | .br
|
|---|
| 51 | \fBint winchstr(WINDOW *win, chtype *chstr);\fR
|
|---|
| 52 | .br
|
|---|
| 53 | \fBint winchnstr(WINDOW *win, chtype *chstr, int n);\fR
|
|---|
| 54 | .br
|
|---|
| 55 | \fBint mvinchstr(int y, int x, chtype *chstr);\fR
|
|---|
| 56 | .br
|
|---|
| 57 | \fBint mvinchnstr(int y, int x, chtype *chstr, int n);\fR
|
|---|
| 58 | .br
|
|---|
| 59 | \fBint mvwinchstr(WINDOW *win, int y, int x, chtype *chstr);\fR
|
|---|
| 60 | .br
|
|---|
| 61 | \fBint mvwinchnstr(WINDOW *win, int y, int x, chtype *chstr, int n);\fR
|
|---|
| 62 | .br
|
|---|
| 63 | .SH DESCRIPTION
|
|---|
| 64 | These routines return a NULL-terminated array of \fBchtype\fR quantities,
|
|---|
| 65 | starting at the current cursor position in the named window and ending at the
|
|---|
| 66 | right margin of the window. The four functions with \fIn\fR as
|
|---|
| 67 | the last argument, return a leading substring at most \fIn\fR characters long
|
|---|
| 68 | (exclusive of the trailing (chtype)0).
|
|---|
| 69 | Constants defined in \fB<curses.h>\fR can be used with the \fB&\fR (logical
|
|---|
| 70 | AND) operator to extract the character or the attribute alone from any position
|
|---|
| 71 | in the \fIchstr\fR [see \fBcurs_inch\fR(3X)].
|
|---|
| 72 | .SH RETURN VALUE
|
|---|
| 73 | All routines return the integer \fBERR\fR upon failure and an integer value
|
|---|
| 74 | other than \fBERR\fR upon successful completion (the number of characters
|
|---|
| 75 | retrieved, exclusive of the trailing 0).
|
|---|
| 76 | .PP
|
|---|
| 77 | No error conditions are defined.
|
|---|
| 78 | If the \fIchstr\fP parameter is null,
|
|---|
| 79 | no data is returned,
|
|---|
| 80 | and the return value is zero.
|
|---|
| 81 | .SH NOTES
|
|---|
| 82 | Note that all routines except \fBwinchnstr\fR may be macros. SVr4 does not
|
|---|
| 83 | document whether the result string is 0-terminated; it does not document
|
|---|
| 84 | whether a length limit argument includes any trailing 0; and it does not
|
|---|
| 85 | document the meaning of the return value.
|
|---|
| 86 | .SH PORTABILITY
|
|---|
| 87 | These functions are described in the XSI Curses standard, Issue 4. It is no
|
|---|
| 88 | more specific than the SVr4 documentation on the trailing 0. It does specify
|
|---|
| 89 | that the successful return of the functions is \fBOK\fR.
|
|---|
| 90 | .SH SEE ALSO
|
|---|
| 91 | \fBcurses\fR(3X), \fBcurs_inch\fR(3X).
|
|---|
| 92 | .\"#
|
|---|
| 93 | .\"# The following sets edit modes for GNU EMACS
|
|---|
| 94 | .\"# Local Variables:
|
|---|
| 95 | .\"# mode:nroff
|
|---|
| 96 | .\"# fill-column:79
|
|---|
| 97 | .\"# End:
|
|---|