<!--
* t
****************************************************************************
- * Copyright (c) 1998-2004,2005 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-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 *
* sale, use or other dealings in this Software without prior written *
* authorization. *
****************************************************************************
- * @Id: ncurses.3x,v 1.76 2005/09/03 17:42:29 tom Exp @
+ * @Id: ncurses.3x,v 1.82 2006/12/24 14:44:05 tom Exp @
-->
<HTML>
<HEAD>
independent method of updating character screens with rea-
sonable optimization. This implementation is ``new
curses'' (ncurses) and is the approved replacement for
- 4.4BSD classic curses, which has been discontinued.
+ 4.4BSD classic curses, which has been discontinued. This
+ describes <STRONG>ncurses</STRONG> version 5.6 (patch 20070303).
- The <STRONG>ncurses</STRONG> routines emulate the <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG> library of
+ The <STRONG>ncurses</STRONG> routines emulate the <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG> library of
System V Release 4 UNIX, and the XPG4 curses standard (XSI
- curses) but the <STRONG>ncurses</STRONG> library is freely redistributable
+ curses) but the <STRONG>ncurses</STRONG> library is freely redistributable
in source form. Differences from the SVr4 curses are sum-
- marized under the EXTENSIONS and PORTABILITY sections
- below and described in detail in the respective EXTEN-
- SIONS, PORTABILITY and BUGS sections of individual man
+ marized under the <STRONG>EXTENSIONS</STRONG> and <STRONG>PORTABILITY</STRONG> sections
+ below and described in detail in the respective <STRONG>EXTEN-</STRONG>
+ <STRONG>SIONS</STRONG>, <STRONG>PORTABILITY</STRONG> and <STRONG>BUGS</STRONG> sections of individual man
pages.
- A program using these routines must be linked with the
- <STRONG>-lncurses</STRONG> option, or (if it has been generated) with the
- debugging library <STRONG>-lncurses_g</STRONG>. (Your system integrator
- may also have installed these libraries under the names
+ A program using these routines must be linked with the
+ <STRONG>-lncurses</STRONG> option, or (if it has been generated) with the
+ debugging library <STRONG>-lncurses_g</STRONG>. (Your system integrator
+ may also have installed these libraries under the names
<STRONG>-lcurses</STRONG> and <STRONG>-lcurses_g</STRONG>.) The ncurses_g library generates
trace logs (in a file called 'trace' in the current direc-
- tory) that describe curses actions.
+ tory) that describe curses actions. See also the section
+ on <STRONG>ALTERNATE</STRONG> <STRONG>CONFIGURATIONS</STRONG>.
The <STRONG>ncurses</STRONG> package supports: overall screen, window and
pad manipulation; output to windows and pads; reading ter-
Windows are referred to by variables declared as <STRONG>WINDOW</STRONG> <STRONG>*</STRONG>.
These data structures are manipulated with routines
described here and elsewhere in the <STRONG>ncurses</STRONG> manual pages.
- Among which the most basic routines are <STRONG>move</STRONG> and <STRONG>addch</STRONG>.
+ Among those, the most basic routines are <STRONG>move</STRONG> and <STRONG>addch</STRONG>.
More general versions of these routines are included with
names beginning with <STRONG>w</STRONG>, allowing the user to specify a
- window. The routines not beginning with <STRONG>w</STRONG> affect <STRONG>stdscr</STRONG>.)
+ window. The routines not beginning with <STRONG>w</STRONG> affect <STRONG>stdscr</STRONG>.
After using routines to manipulate a window, <STRONG>refresh</STRONG> is
called, telling <STRONG>curses</STRONG> to make the user's CRT screen look
_tracedump <STRONG><A HREF="curs_trace.3x.html">curs_trace(3x)</A></STRONG>*
_tracef <STRONG><A HREF="curs_trace.3x.html">curs_trace(3x)</A></STRONG>*
_tracemouse <STRONG><A HREF="curs_trace.3x.html">curs_trace(3x)</A></STRONG>*
+
add_wch <STRONG><A HREF="curs_add_wch.3x.html">curs_add_wch(3x)</A></STRONG>
add_wchnstr <STRONG><A HREF="curs_add_wchstr.3x.html">curs_add_wchstr(3x)</A></STRONG>
-
add_wchstr <STRONG><A HREF="curs_add_wchstr.3x.html">curs_add_wchstr(3x)</A></STRONG>
addch <STRONG><A HREF="curs_addch.3x.html">curs_addch(3x)</A></STRONG>
addchnstr <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>
get_wch <STRONG><A HREF="curs_get_wch.3x.html">curs_get_wch(3x)</A></STRONG>
get_wstr <STRONG><A HREF="curs_get_wstr.3x.html">curs_get_wstr(3x)</A></STRONG>
getbegyx <STRONG><A HREF="curs_getyx.3x.html">curs_getyx(3x)</A></STRONG>
+
getbkgd <STRONG><A HREF="curs_bkgd.3x.html">curs_bkgd(3x)</A></STRONG>
getbkgrnd <STRONG><A HREF="curs_bkgrnd.3x.html">curs_bkgrnd(3x)</A></STRONG>
-
getcchar <STRONG><A HREF="curs_getcchar.3x.html">curs_getcchar(3x)</A></STRONG>
getch <STRONG><A HREF="curs_getch.3x.html">curs_getch(3x)</A></STRONG>
getmaxyx <STRONG><A HREF="curs_getyx.3x.html">curs_getyx(3x)</A></STRONG>
mousemask <STRONG><A HREF="curs_mouse.3x.html">curs_mouse(3x)</A></STRONG>*
move <STRONG><A HREF="curs_move.3x.html">curs_move(3x)</A></STRONG>
mvadd_wch <STRONG><A HREF="curs_add_wch.3x.html">curs_add_wch(3x)</A></STRONG>
+
mvadd_wchnstr <STRONG><A HREF="curs_add_wchstr.3x.html">curs_add_wchstr(3x)</A></STRONG>
mvadd_wchstr <STRONG><A HREF="curs_add_wchstr.3x.html">curs_add_wchstr(3x)</A></STRONG>
-
mvaddch <STRONG><A HREF="curs_addch.3x.html">curs_addch(3x)</A></STRONG>
mvaddchnstr <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>
mvaddchstr <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>
mvwin_wch <STRONG><A HREF="curs_in_wch.3x.html">curs_in_wch(3x)</A></STRONG>
mvwin_wchnstr <STRONG><A HREF="curs_in_wchstr.3x.html">curs_in_wchstr(3x)</A></STRONG>
mvwin_wchstr <STRONG><A HREF="curs_in_wchstr.3x.html">curs_in_wchstr(3x)</A></STRONG>
+
mvwinch <STRONG><A HREF="curs_inch.3x.html">curs_inch(3x)</A></STRONG>
mvwinchnstr <STRONG><A HREF="curs_inchstr.3x.html">curs_inchstr(3x)</A></STRONG>
-
mvwinchstr <STRONG><A HREF="curs_inchstr.3x.html">curs_inchstr(3x)</A></STRONG>
mvwinnstr <STRONG><A HREF="curs_instr.3x.html">curs_instr(3x)</A></STRONG>
mvwinnwstr <STRONG><A HREF="curs_inwstr.3x.html">curs_inwstr(3x)</A></STRONG>
setterm <STRONG><A HREF="curs_terminfo.3x.html">curs_terminfo(3x)</A></STRONG>
setupterm <STRONG><A HREF="curs_terminfo.3x.html">curs_terminfo(3x)</A></STRONG>
slk_attr <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>*
+
slk_attr_off <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>
slk_attr_on <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>
-
slk_attr_set <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>
slk_attroff <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>
slk_attron <STRONG><A HREF="curs_slk.3x.html">curs_slk(3x)</A></STRONG>
waddchnstr <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>
waddchstr <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>
waddnstr <STRONG><A HREF="curs_addstr.3x.html">curs_addstr(3x)</A></STRONG>
+
waddnwstr <STRONG><A HREF="curs_addwstr.3x.html">curs_addwstr(3x)</A></STRONG>
waddstr <STRONG><A HREF="curs_addstr.3x.html">curs_addstr(3x)</A></STRONG>
-
waddwstr <STRONG><A HREF="curs_addwstr.3x.html">curs_addwstr(3x)</A></STRONG>
wattr_get <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>
wattr_off <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>
wscanw <STRONG><A HREF="curs_scanw.3x.html">curs_scanw(3x)</A></STRONG>
wscrl <STRONG><A HREF="curs_scroll.3x.html">curs_scroll(3x)</A></STRONG>
wsetscrreg <STRONG><A HREF="curs_outopts.3x.html">curs_outopts(3x)</A></STRONG>
+
wstandend <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>
wstandout <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>
-
wsyncdown <STRONG><A HREF="curs_window.3x.html">curs_window(3x)</A></STRONG>
wsyncup <STRONG><A HREF="curs_window.3x.html">curs_window(3x)</A></STRONG>
wtimeout <STRONG><A HREF="curs_inopts.3x.html">curs_inopts(3x)</A></STRONG>
NCURSES_ASSUMED_COLORS
Override the compiled-in assumption that the termi-
nal's default colors are white-on-black (see
- <STRONG><A HREF="assume_default_colors.3x.html">assume_default_colors(3x)</A></STRONG>). You may set the fore-
- ground and background color values with this environ-
- ment variable by proving a 2-element list: fore-
- ground,background. For example, to tell ncurses to
- not assume anything about the colors, set this to
+ <STRONG><A HREF="default_colors.3x.html">default_colors(3x)</A></STRONG>). You may set the foreground and
+ background color values with this environment vari-
+ able by proving a 2-element list:
+ foreground,background. For example, to tell ncurses
+ to not assume anything about the colors, set this to
"-1,-1". To make it green-on-black, set it to "2,0".
Any positive value from zero to the terminfo <STRONG>max_col-</STRONG>
<STRONG>ors</STRONG> value is allowed.
+ NCURSES_NO_HARD_TABS
+ <STRONG>Ncurses</STRONG> may use tabs as part of the cursor movement
+ optimization. In some cases, your terminal driver
+ may not handle these properly. Set this environment
+ variable to disable the feature. You can also adjust
+ your <STRONG>stty</STRONG> settings to avoid the problem.
+
+ NCURSES_NO_MAGIC_COOKIES
+ Some terminals use a magic-cookie feature which
+ requires special handling to make highlighting and
+ other video attributes display properly. You can
+ suppress the highlighting entirely for these termi-
+ nals by setting this environment variable.
+
NCURSES_NO_PADDING
Most of the terminal descriptions in the terminfo
database are written for real "hardware" terminals.
TERMPATH
If TERMCAP does not hold a file name then <STRONG>ncurses</STRONG>
- checks the TERMPATH symbol. This is a list of file-
- names separated by spaces or colons (i.e., ":") on
- Unix, semicolons on OS/2 EMX. If the TERMPATH symbol
- is not set, <STRONG>ncurses</STRONG> looks in the files /etc/termcap,
- /usr/share/misc/termcap and $HOME/.termcap, in that
- order.
+ checks the TERMPATH symbol. This is a list of
+ filenames separated by spaces or colons (i.e., ":")
+ on Unix, semicolons on OS/2 EMX. If the TERMPATH
+ symbol is not set, <STRONG>ncurses</STRONG> looks in the files
+ /etc/termcap, /usr/share/misc/termcap and
+ $HOME/.termcap, in that order.
The library may be configured to disregard the following
variables when the current user is the superuser (root),
$TERMINFO, $TERMINFO_DIRS, $TERMPATH, as well as $HOME.
+</PRE>
+<H2>ALTERNATE CONFIGURATIONS</H2><PRE>
+ Several different configurations are possible, depending
+ on the configure script options used when building
+ <STRONG>ncurses</STRONG>. There are a few main options whose effects are
+ visible to the applications developer using <STRONG>ncurses</STRONG>:
+
+ --disable-overwrite
+ The standard include for <STRONG>ncurses</STRONG> is as noted in <STRONG>SYN-</STRONG>
+ <STRONG>OPSIS</STRONG>:
+
+ <STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
+
+ This option is used to avoid filename conflicts when
+ <STRONG>ncurses</STRONG> is not the main implementation of curses of
+ the computer. If <STRONG>ncurses</STRONG> is installed disabling
+ overwrite, it puts its headers in a subdirectory,
+ e.g.,
+
+ <STRONG>#include</STRONG> <STRONG><ncurses/curses.h></STRONG>
+
+ It also omits a symbolic link which would allow you
+ to use <STRONG>-lcurses</STRONG> to build executables.
+
+ --enable-widec
+ The configure script renames the library and (if the
+ <STRONG>--disable-overwrite</STRONG> option is used) puts the header
+ files in a different subdirectory. All of the
+ library names have a "w" appended to them, i.e.,
+ instead of
+
+ <STRONG>-lncurses</STRONG>
+
+ you link with
+
+ <STRONG>-lncursesw</STRONG>
+
+ You must also define <STRONG>_XOPEN_SOURCE_EXTENDED</STRONG> when com-
+ piling for the wide-character library to use the
+ extended (wide-character) functions. The <STRONG>curses.h</STRONG>
+ file which is installed for the wide-character
+ library is designed to be compatible with the normal
+ library's header. Only the size of the <STRONG>WINDOW</STRONG> struc-
+ ture differs, and very few applications require more
+ than a pointer to <STRONG>WINDOW</STRONG>s. If the headers are
+ installed allowing overwrite, the wide-character
+ library's headers should be installed last, to allow
+ applications to be built using either library from
+ the same set of headers.
+
+ --with-shared
+
+ --with-normal
+
+ --with-debug
+
+ --with-profile
+ The shared and normal (static) library names differ
+ by their suffixes, e.g., <STRONG>libncurses.so</STRONG> and
+ <STRONG>libncurses.a</STRONG>. The debug and profiling libraries add
+ a "_g" and a "_p" to the root names respectively,
+ e.g., <STRONG>libncurses_g.a</STRONG> and <STRONG>libncurses_p.a</STRONG>.
+
+ --with-trace
+ The <STRONG>trace</STRONG> function normally resides in the debug
+ library, but it is sometimes useful to configure this
+ in the shared library. Configure scripts should
+ check for the function's existence rather than assum-
+ ing it is always in the debug library.
+
+
</PRE>
<H2>FILES</H2><PRE>
/usr/share/tabset
directory containing initialization files for the
- terminal capability database /usr/share/terminfo
- terminal capability database
+ terminal capability database /usr/share/terminfo ter-
+ minal capability database
</PRE>