]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/curs_inch.3x
ncurses 5.7 - patch 20091121
[ncurses.git] / man / curs_inch.3x
1 '\" t
2 .\"***************************************************************************
3 .\" Copyright (c) 1998,2006 Free Software Foundation, Inc.                   *
4 .\"                                                                          *
5 .\" Permission is hereby granted, free of charge, to any person obtaining a  *
6 .\" copy of this software and associated documentation files (the            *
7 .\" "Software"), to deal in the Software without restriction, including      *
8 .\" without limitation the rights to use, copy, modify, merge, publish,      *
9 .\" distribute, distribute with modifications, sublicense, and/or sell       *
10 .\" copies of the Software, and to permit persons to whom the Software is    *
11 .\" furnished to do so, subject to the following conditions:                 *
12 .\"                                                                          *
13 .\" The above copyright notice and this permission notice shall be included  *
14 .\" in all copies or substantial portions of the Software.                   *
15 .\"                                                                          *
16 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  *
17 .\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               *
18 .\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   *
19 .\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   *
20 .\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    *
21 .\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    *
22 .\" THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               *
23 .\"                                                                          *
24 .\" Except as contained in this notice, the name(s) of the above copyright   *
25 .\" holders shall not be used in advertising or otherwise to promote the     *
26 .\" sale, use or other dealings in this Software without prior written       *
27 .\" authorization.                                                           *
28 .\"***************************************************************************
29 .\"
30 .\" $Id: curs_inch.3x,v 1.13 2006/12/02 16:58:55 tom Exp $
31 .TH curs_inch 3X ""
32 .SH NAME
33 \fBinch\fR, \fBwinch\fR, \fBmvinch\fR, \fBmvwinch\fR
34 - get a character and attributes from a \fBcurses\fR window
35 .SH SYNOPSIS
36 \fB#include <curses.h>\fR
37 .sp
38 \fBchtype inch(void);\fR
39 .br
40 \fBchtype winch(WINDOW *win);\fR
41 .br
42 \fBchtype mvinch(int y, int x);\fR
43 .br
44 \fBchtype mvwinch(WINDOW *win, int y, int x);\fR
45 .br
46 .SH DESCRIPTION
47 These routines return the character, of type \fBchtype\fR, at the current
48 position in the named window.  If any attributes are set for that position,
49 their values are OR'ed into the value returned.  Constants defined in
50 \fB<curses.h>\fR can be used with the \fB&\fR (logical AND) operator to
51 extract the character or attributes alone.
52 .
53 .SS Attributes
54 The following bit-masks may be AND-ed with characters returned by \fBwinch\fR.
55 .
56 .TS
57 l l .
58 \fBA_CHARTEXT\fR        Bit-mask to extract character
59 \fBA_ATTRIBUTES\fR      Bit-mask to extract attributes
60 \fBA_COLOR\fR   Bit-mask to extract color-pair field information
61 .TE
62 .SH NOTES
63 Note that all of these routines may be macros.
64 .SH PORTABILITY
65 These functions are described in the XSI Curses standard, Issue 4.
66 .SH SEE ALSO
67 \fBcurses\fR(3X).
68 .PP
69 Comparable functions in the wide-character (ncursesw) library are
70 described in
71 \fBcurs_in_wch\fR(3X).
72 .\"#
73 .\"# The following sets edit modes for GNU EMACS
74 .\"# Local Variables:
75 .\"# mode:nroff
76 .\"# fill-column:79
77 .\"# End: