Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getn_wstr(3X) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

curses(3X)

getstr(3X)

curses(5)

wchar(5)

getn_wstr(3X)                                                 getn_wstr(3X)

NAME
     getnwstr, getwstr, mvgetnwstr, mvgetwstr, mvwgetnwstr,
     mvwgetwstr, wgetnwstr, wgetwstr - get an array of wide characters
     and function key codes from a terminal

SYNOPSIS
     cc [flag ...] file ... -lcurses [library ...]

     #include <curses.h>

     int getnwstr(wchart *wstr, int n);

     int getwstr(wchart *wstr);

     int mvgetnwstr(int y, int x, wchart *wstr, int n);

     int mvgetwstr(int y, int x, wchart *wstr);

     int mvwgetnwstr(WINDOW *win, int y, int x, wchart *wstr, int n);

     int mvwgetwstr(WINDOW *win, int y, int x, wchart *wstr);

     int wgetnwstr(WINDOW *win, wchart *wstr, int n);

     int wgetwstr(WINDOW *win, wchart *wstr);

DESCRIPTION
     The effect of getwstr() is as though a series of calls to getwch()
     were made, until a newline character, end-of-line character, or end-
     of-file character is processed. An end-of-file character is represen-
     ted by WEOF, as defined in <wchar.h>. A newline or end-of-line is rep-
     resented as its wchart value. In all instances, the end of the string
     is terminated by a null wchart. The resulting values are placed in
     the area pointed to by wstr.

     The user's erase and kill characters are interpreted and affect the
     sequence of characters returned.

     The effect of wgetwstr() is as though a series of calls to wgetwch()
     were made.

     The effect of mvgetwstr() is as though a call to move() and then a
     series of calls to getwch() were made. The effect of mvwgetwstr() is
     as though a call to wmove() and then a series of calls to wgetwch()
     were made. The effect of mvgetnwstr() is as though a call to move()
     and then a series of calls to getwch() were made. The effect of
     mvwgetnwstr() is as though a call to wmove() and then a series of
     calls to wgetwch() were made.

     The getnwstr(), mvgetnwstr(), mvwgetnwstr() and wgetnwstr() func-
     tions read at most n characters, letting the application prevent over-
     flow of the input buffer.



Page 1                       Reliant UNIX 5.44                Printed 11/98

getn_wstr(3X)                                                 getn_wstr(3X)

RETURN VALUE
     Upon successful completion, these functions return OK. Otherwise, they
     return ERR.

ERRORS
     No errors are defined.

NOTES
     Reading a line that overflows the array pointed to by wstr with
     getwstr(), mvgetwstr(), mvwgetwstr() or wgetwstr() causes unde-
     fined results. The use of getnwstr(), mvgetnwstr(), mvwgetnwstr()
     or wgetnwstr(), respectively, is recommended.

     These functions cannot return KEY values as there is no way to dis-
     tinguish a KEY value from a valid wchart value.

SEE ALSO
     curses(3X), getwch(3X), getstr(3X), curses(5), wchar(5).




































Page 2                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026