Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ get_wch(3X) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

beep(3X)

cbreak(3X)

curses(3X)

keypad(3X)

move(3X)

curses(5)

wchar(5)

get_wch(3X)                                                     get_wch(3X)

NAME
     getwch, mvgetwch, mvwgetwch, wgetwch - get a wide character from a
     terminal

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

     #include <curses.h>

     int getwch(wintt *ch);

     int mvgetwch(int y, int x, wintt *ch);

     int mvwgetwch(WINDOW *win, int y, int x, wintt *ch);

     int wgetwch(WINDOW *win, wintt *ch);

DESCRIPTION
     These functions read a character from the terminal associated with the
     current or specified window. If keypad() is enabled, these functions
     respond to the pressing of a function key by setting the object
     pointed to by ch to the corresponding KEY value defined in <curses.h>
     [see curses(5)] and returning KEYCODEYES.

     Processing of terminal input is subject to the general rules described
     in "X/Open Curses, Issue 4, Version 2, Section 3.5".

     If echoing is enabled, then the character is echoed as though it were
     provided as an input argument to addwch(), except for the following
     characters:

     <backspace>, <left-arrow> and the current erase character:
          The input is interpreted as specified in "X/Open Curses, Issue 4,
          Version 2, Section 3.4.3" and then the character at the resulting
          cursor position is deleted as though delch() were called, except
          that if the cursor was originally in the first column of the
          line, then the user is alerted as though beep() were called.

     Function keys:
          The user is alerted as though beep() were called. Information
          concerning the function keys is not returned to the caller.

     If the current or specified window is not a pad, and it has been moved
     or modified since the last refresh operation, then it will be
     refreshed before another character is read.

RETURN VALUE
     When these functions successfully report the pressing of a function
     key, they return KEYCODEYES. When they successfully report a wide
     character, they return OK. Otherwise, they return ERR.





Page 1                       Reliant UNIX 5.44                Printed 11/98

get_wch(3X)                                                     get_wch(3X)

ERRORS
     No errors are defined.

NOTES
     Applications should not define the escape key by itself as a single-
     character function.

     When using these functions, nocbreak() mode and echo() mode should not
     be used at the same time. Depending on the state of the terminal when
     each character is typed, the application may produce undesirable
     results.

SEE ALSO
     beep(3X), cbreak(3X), curses(3X), inswch(3X), keypad(3X), move(3X),
     curses(5), wchar(5).







































Page 2                       Reliant UNIX 5.44                Printed 11/98

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