Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
addnstr(3XCURSES)	X/Open Curses Library Functions	     addnstr(3XCURSES)

NAME
       addnstr,	 addstr, mvaddnstr, mvaddstr, mvwaddnstr, mvwaddstr, waddnstr,
       waddstr - add a multi-byte character string (without  rendition)	 to  a
       window

SYNOPSIS
       cc [ flag... ] file... -I /usr/xpg4/include -L /usr/xpg4/lib \
       -R /usr/xpg4/lib	-lcurses [ library... ]

       c89 [ flag... ] file... -lcurses	[ library ... ]

       #include	<curses.h>

       int addnstr(const char *str, int	n);

       int addstr(const	char *str);

       int mvaddnstr(int y, int	x, const char *str, int	n);

       int mvaddstr(int	y, int x, const	char *str);

       int mvwaddnstr(WINDOW *win, int y, int x, const char *str, int n);

       int mvwaddstr(WINDOW *win, int y, int x,	const char *str);

       int waddstr(WINDOW *win,	const char *str);

       int waddnstr(WINDOW *win, const char *str, int n);

DESCRIPTION
       The  addstr()  function	writes	a null-terminated string of multi-byte
       characters to the stdscr	window at the  current	cursor	position.  The
       waddstr()  function performs an identical action, but writes the	 char-
       acter to	the window specified by	win.  The mvaddstr()  and  mvwaddstr()
       functions write the string to the  position indicated by	the x (column)
       and y (row) parameters (the  former to the stdscr window; the latter to
       window win).

       The addnstr(), waddnstr(), mvaddnstr(), and  mvwaddnstr() functions are
       similar but write at most n characters  to the window.  If  n  is  less
       than 0, the entire string is written.

       All of these functions advance the cursor after writing the string.

       These  functions	are functionally equivalent to calling the correspond-
       ing  function from the addch(3XCURSES) set of functions once  for  each
       character in  the string.  Refer	to the
	curses(3XCURSES) man page for a	complete description of	 special char-
       acter handling and of the interaction between the window	rendition  (or
       background character and	rendition) and the character written.

       Note  that  these functions differ from the addchstr() set of functions
       in that the addchstr(3XCURSES) functions	copy the string	as is (without
       combining  each	character  with	the window rendition or	the background
       character  and rendition.

PARAMETERS
       str	Is a pointer to	the character string that is to	be written  to
		the window.

       n	Is  the	maximum	number of characters to	be copied from str. If
		n is less than 0, the entire string is written or as  much  of
		it as fits on the line.

       y	Is  the	 y (row) coordinate of the starting position of	str in
		the window.

       x	Is the x (column) coordinate of	the starting position  of  str
		in  the	window.

       win	Is  a pointer to the window in which the string	is to be writ-
		ten.

RETURN VALUES
       On success, these functions return OK. Otherwise, they return ERR.

ERRORS
       None.

ATTRIBUTES
       See attributes(5) for descriptions of the following attributes:

       +-----------------------------+-----------------------------+
       |      ATTRIBUTE	TYPE	     |	    ATTRIBUTE VALUE	   |
       +-----------------------------+-----------------------------+
       |Interface Stability	     |Standard			   |
       +-----------------------------+-----------------------------+
       |MT-Level		     |Unsafe			   |
       +-----------------------------+-----------------------------+

SEE ALSO
       addch(3XCURSES),		addchstr(3XCURSES),	     curses(3XCURSES),
       libcurses(3XCURSES), attributes(5), standards(5)

SunOS 5.10			  5 Jun	2002		     addnstr(3XCURSES)

NAME | SYNOPSIS | DESCRIPTION | PARAMETERS | RETURN VALUES | ERRORS | ATTRIBUTES | SEE ALSO

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=waddstr&sektion=3xcurses&manpath=SunOS+5.10>

home | help