diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-09-06 17:26:18 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-09-06 17:26:18 +0000 |
commit | 8ce6de586f6d6ca2f543461d99c400afc6be6004 (patch) | |
tree | 726269df03a2f911f85d8745f76b5a5003e60cee /lib/libcurses/curs_addwstr.3 | |
parent | 132a69b33e674847717fae13debd5554a13a8cd0 (diff) |
Enable wide character support in ncurses. It is built into libcurses,
libform, libmenu, libpanel and each library is also linked to a
corresponding "w" version.
This is a major bump for all four libraries.
Thanks to landry, stsp, sthen, naddy, oga, Martin Pieuchot, and anyone
else I've forgotten for testing.
ok naddy krw deraadt
Diffstat (limited to 'lib/libcurses/curs_addwstr.3')
-rw-r--r-- | lib/libcurses/curs_addwstr.3 | 95 |
1 files changed, 95 insertions, 0 deletions
diff --git a/lib/libcurses/curs_addwstr.3 b/lib/libcurses/curs_addwstr.3 new file mode 100644 index 00000000000..474fc51a24b --- /dev/null +++ b/lib/libcurses/curs_addwstr.3 @@ -0,0 +1,95 @@ +.\" $OpenBSD: curs_addwstr.3,v 1.1 2010/09/06 17:26:17 nicm Exp $ +.\"*************************************************************************** +.\" Copyright (c) 2002-2005,2006 Free Software Foundation, Inc. * +.\" * +.\" Permission is hereby granted, free of charge, to any person obtaining a * +.\" copy of this software and associated documentation files (the * +.\" "Software"), to deal in the Software without restriction, including * +.\" without limitation the rights to use, copy, modify, merge, publish, * +.\" distribute, distribute with modifications, sublicense, and/or sell * +.\" copies of the Software, and to permit persons to whom the Software is * +.\" furnished to do so, subject to the following conditions: * +.\" * +.\" The above copyright notice and this permission notice shall be included * +.\" in all copies or substantial portions of the Software. * +.\" * +.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * +.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * +.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * +.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * +.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * +.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * +.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * +.\" * +.\" Except as contained in this notice, the name(s) of the above copyright * +.\" holders shall not be used in advertising or otherwise to promote the * +.\" sale, use or other dealings in this Software without prior written * +.\" authorization. * +.\"*************************************************************************** +.\" +.\" $Id: curs_addwstr.3,v 1.1 2010/09/06 17:26:17 nicm Exp $ +.TH curs_addwstr 3 "" +.na +.hy 0 +.SH NAME +\fBaddwstr\fR, +\fBaddnwstr\fR, +\fBwaddwstr\fR, +\fBwaddnwstr\fR, +\fBmvaddwstr\fR, +\fBmvaddnwstr\fR, +\fBmvwaddwstr\fR, +\fBmvwaddnwstr\fR \- add a string of wide characters to a \fBcurses\fR window and advance cursor +.ad +.hy +.SH SYNOPSIS +.nf +\fB#include <curses.h>\fR +.PP +\fBint addwstr(const wchar_t *\fR\fIwstr\fR\fB);\fR +.br +\fBint addnwstr(const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR +.br +\fBint waddwstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR +.br +\fBint waddnwstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR +.br +\fBint mvaddwstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR +.br +\fBint mvaddnwstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR +.br +\fBint mvwaddwstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR +.br +\fBint mvwaddnwstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR +.fi +.SH DESCRIPTION +These routines write the characters of the +(null-terminated) \fBwchar_t\fR character string +\fIwstr\fR on the given window. +It is similar to constructing a \fBcchar_t\fR for each wchar_t in the string, +then calling \fBwadd_wch\fR for the resulting \fBcchar_t\fR. +.PP +The \fImv\fR routines perform cursor movement once, before writing any +characters. +Thereafter, the cursor is advanced as a side-effect of writing to the window. +.PP +The four routines with \fIn\fR as the last argument +write at most \fIn\fR \fBwchar_t\fR characters. +If \fIn\fR is -1, then the entire string will be added, +up to the maximum number of characters that will fit on the line, +or until a terminating null is reached. +.SH RETURN VALUES +All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success. +.SH NOTES +Note that all of these routines except \fBwaddnwstr\fR may be macros. +.SH PORTABILITY +All these entry points are described in the XSI Curses standard, Issue 4. +.SH SEE ALSO +\fBcurses\fR(3), +\fBcurs_add_wch\fR(3) +.\"# +.\"# The following sets edit modes for GNU EMACS +.\"# Local Variables: +.\"# mode:nroff +.\"# fill-column:79 +.\"# End: |