1curs_printw(3X)                                                curs_printw(3X)
2
3
4

NAME

6       printw, wprintw, mvprintw, mvwprintw, vwprintw, vw_printw - print
7       formatted output in curses windows
8

SYNOPSIS

10       #include <curses.h>
11
12       int printw(const char *fmt, ...);
13       int wprintw(WINDOW *win, const char *fmt, ...);
14       int mvprintw(int y, int x, const char *fmt, ...);
15       int mvwprintw(WINDOW *win, int y, int x, const char *fmt, ...);
16       int vwprintw(WINDOW *win, const char *fmt, va_list varglist);
17       int vw_printw(WINDOW *win, const char *fmt, va_list varglist);
18

DESCRIPTION

20       The printw, wprintw, mvprintw and mvwprintw routines are  analogous  to
21       printf  [see printf(3)].  In effect, the string that would be output by
22       printf is output instead as though waddstr were used on the given  win‐
23       dow.
24
25       The  vwprintw  and  wv_printw  routines  are  analogous to vprintf [see
26       printf(3)] and perform a wprintw using a variable argument  list.   The
27       third  argument  is a va_list, a pointer to a list of arguments, as de‐
28       fined in <stdarg.h>.
29

RETURN VALUE

31       Routines that return an integer return ERR upon failure  and  OK  (SVr4
32       only  specifies "an integer value other than ERR") upon successful com‐
33       pletion.
34
35       X/Open defines no error conditions.  In this implementation,  an  error
36       may be returned if it cannot allocate enough memory for the buffer used
37       to format the results.  It will return an error if the  window  pointer
38       is null.
39
40       Functions  with  a  "mv"  prefix  first perform a cursor movement using
41       wmove, and return an error if the position is outside the window, or if
42       the window pointer is null.
43

PORTABILITY

45       The  XSI Curses standard, Issue 4 describes these functions.  The func‐
46       tion vwprintw is marked TO BE WITHDRAWN, and is to  be  replaced  by  a
47       function  vw_printw  using  the  <stdarg.h> interface.  The Single Unix
48       Specification, Version 2 states that vw_printw   is  preferred  to  vw‐
49       printw since the latter requires including <varargs.h>, which cannot be
50       used  in  the  same  file  as  <stdarg.h>.   This  implementation  uses
51       <stdarg.h> for both, because that header is included in <curses.h>.
52

SEE ALSO

54       curses(3X), printf(3), vprintf(3)
55
56
57
58                                                               curs_printw(3X)
Impressum