]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/curs_scanw.3x
ncurses 4.2
[ncurses.git] / man / curs_scanw.3x
1 .\" $Id: curs_scanw.3x,v 1.6 1997/12/14 01:04:36 tom Exp $
2 .TH curs_scanw 3X ""
3 .SH NAME
4 \fBscanw\fR, \fBwscanw\fR, \fBmvscanw\fR,
5 \fBmvwscanw\fR, \fBvwscanw\fR - convert formatted input from a
6 \fBcurses\fR widow
7 .SH SYNOPSIS
8 \fB#include <curses.h>\fR
9
10 \fBint scanw(char *fmt\fR [\fB, arg\fR] \fB...);\fR
11 .br
12 \fBint wscanw(WINDOW *win, char *fmt\fR [\fB, arg\fR] \fB...);\fR
13 .br
14 \fBint mvscanw(int y, int x, char *fmt\fR [\fB, arg\fR] \fB...);\fR
15 .br
16 \fBint mvwscanw(WINDOW *win, int y, int x,
17       char *fmt\fR [\fB, arg]\fR \fB...);\fR
18 .br
19 \fBint vwscanw(WINDOW *win, char *fmt, va_list varglist);\fR
20 .SH DESCRIPTION
21 The \fBscanw\fR, \fBwscanw\fR and \fBmvscanw\fR routines are analogous to
22 \fBscanf\fR [see \fBscanf\fR(3S)].  The effect of these routines is as though
23 \fBwgetstr\fR were called on the window, and the resulting line used as input
24 for \fBsscanf\fR(3).  Fields which do not map to a variable in the \fIfmt\fR
25 field are lost.
26
27 The \fBvwscanw\fR routine is similar to \fBvwprintw\fR in that it performs a
28 \fBwscanw\fR using a variable argument list.  The third argument is a
29 \fIva\fR_\fIlist\fR, a pointer to a list of arguments, as defined in
30 \fB<varargs.h>\fR.
31 .SH RETURN VALUE
32 \fBvwscanw\fR returns \fBERR\fR on failure and an integer equal to the
33 number of fields scanned on success.
34
35 Applications may use the return value from the \fBscanw\fR, \fBwscanw\fR,
36 \fBmvscanw\fR and \fBmvwscanw\fR routines to determine the number of fields
37 which were mapped in the call.
38 .SH PORTABILITY
39 The XSI Curses standard, Issue 4 describes these functions.  The function
40 \fBvwscanw\fR is marked TO BE WITHDRAWN, and is to be replaced by a function
41 \fBvw_scanw\fR using the \fB<stdarg.h>\fR interface.
42 .SH SEE ALSO
43 \fBcurses\fR(3X), \fBcurs_getstr\fR(3X), \fBcurs_printw\fR(3X), \fBscanf\fR(3S)
44 .\"#
45 .\"# The following sets edit modes for GNU EMACS
46 .\"# Local Variables:
47 .\"# mode:nroff
48 .\"# fill-column:79
49 .\"# End: