A character is read from the terminal associated with the window win. Depending on the setting of
cbreak, this will be after one character (
CBREAKmode), or after the first newline (
noechohas been set, the character will also be echoed into win.
read-char, do not set both
echo) at the same time. Depending on the state of the terminal driver when each character is typed, the program may produce undesirable results.
The character, of type chtype, at the current position in window win is returned. If any attributes are set for that position, their values will be OR'ed into the value returned.