CURSES - is a
pun on the name "cursor optimization".
The Curses library
forms a wrapper over working with raw terminal codes, and provides highly
flexible and efficient API (Application Programming Interface). It provides
functions to move the cursor, create windows, produce colors, play with mouse
etc. The Application programs need not worry about the underlying terminal capabilities.
Ncurses is a clone of the original System V Release
4.0 (SVr4) curses. It is a freely distributable library, fully compatible
with older version of curses. In short, it is a library of functions that
manages an application's display on character-cell terminals.
The ncurses library routines give the user a terminal-
independent method of updating character screens with
The curses package is a subroutine library for terminal-independent
screen-painting and input-event handling which presents a high level
screen model to the programmer, hiding differences between terminal
types and doing automatic optimization of output to change one screenfull
of text into another. Curses uses terminfo, which is a database format
that can describe the capabilities of thousands of different terminals.
The curses API may seem something of an archaism on UNIX desktops increasingly
dominated by X, Motif, and Tcl/Tk. Nevertheless, UNIX still supports tty lines
and X supports xterm; the curses API has the advantage of back-portability
to character-cell terminals, and simplicity. For an application that does not
require bit-mapped graphics and multiple fonts, an interface implementation using
curses will typically be a great deal simpler and less expensive than one using
an X toolkit.
Ncurses not only creates a wrapper over terminal capabilities, but also gives
a robust framework to create nice looking UI (User Interface)s in text mode.
It provides functions to create windows etc. Its sister libraries
provide an extension to the basic curses library. These libraries
usually come along with curses. One can create applications that contain multiple
windows, menus, panels and forms. Windows can be managed independently, can provide
'scrollability' and even can be hidden.
Menus provide the user with an easy command selection option. Forms allow the
creation of easy-to-use data entry and display windows. Panels extend the
capabilities of ncurses to deal with overlapping and stacked windows.