HP-UX Reference (11i v1 00/12) - 3 Library Functions N-Z (vol 7)

__________________________________________________________________________________________________________________________________________________________________________________________________
__________________________________________________________________________________________________________________________________________________________________________________________________
STANDARD Printed by: Nora Chuang [nchuang] STANDARD
/build/1111/BRICK/man3/nan.3m
________________________________________________________________
___ ___
n
nl(3X) nl(3X)
(CURSES)
NAME
nl, nonl — enable/disable newline translation
SYNOPSIS
#include <curses.h>
int nl(void);
int nonl(void);
DESCRIPTION
The nl() function enables a mode in which carriage return is translated to newline on input. The
nonl() function disablesthe above translation. Initially, the above translation is enabled.
RETURN VALUE
Upon successful completion, these functions return OK. Otherwise, they return ERR.
ERRORS
No errors are defined.
APPLICATION USAGE
The default translation adapts the terminal to environments in which newline is the line termination char-
acter. However, by disabling the translation with
nonl(), the application can sense the pressing of the
carriage return key.
SEE ALSO
<curses.h>.
CHANGE HISTORY
First released in X/Open Curses, Issue 2.
X/Open Curses, Issue 4
The entry is rewritten for clarity. The argument list for the nl() and nonl() functions is explicitly
declared as void.
Section 3578 1 HP-UX Release 11i: December 2000
___
___