blob: 313c1f8e710d4407b82f1495ab6e56729c90f7bb [file] [log] [blame]
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +05301-------------------------------------------------------------------------------
micky3879b9f5e72025-07-08 18:04:53 -04002-- Copyright 2020,2021 Thomas E. Dickey --
3-- Copyright 1998-2006,2007 Free Software Foundation, Inc. --
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +05304-- --
5-- Permission is hereby granted, free of charge, to any person obtaining a --
6-- copy of this software and associated documentation files (the --
7-- "Software"), to deal in the Software without restriction, including --
8-- without limitation the rights to use, copy, modify, merge, publish, --
9-- distribute, distribute with modifications, sublicense, and/or sell copies --
10-- of the Software, and to permit persons to whom the Software is furnished --
11-- to do so, subject to the following conditions: --
12-- --
13-- The above copyright notice and this permission notice shall be included --
14-- in all copies or substantial portions of the Software. --
15-- --
16-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS --
17-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF --
18-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN --
19-- NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, --
20-- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR --
21-- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE --
22-- USE OR OTHER DEALINGS IN THE SOFTWARE. --
23-- --
24-- Except as contained in this notice, the name(s) of the above copyright --
25-- holders shall not be used in advertising or otherwise to promote the --
26-- sale, use or other dealings in this Software without prior written --
27-- authorization. --
28-------------------------------------------------------------------------------
micky3879b9f5e72025-07-08 18:04:53 -040029-- $Id: README-first,v 1.11 2021/06/17 21:20:30 tom Exp $
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053030-------------------------------------------------------------------------------
31 C++ interface to ncurses routines
32-----------------------------------------------------------------------
33
34This directory contains the source code for several C++ classes which
35ease the use of writing ncurses-based programs. The code was originally
36derived from the libg++ CursesWindow class, but rewritten for ncurses.
37
38The classes simplify the use of window specific functions by
39encapsulating them in the window object. Function overloading is
40used in order to narrow the interface. For example, you do not have the
41distinction between `printw' and `mvprintw' anymore.
42
43A second benefit is the removal of all #defines which are included in
44the curses.h file. This is a steady cause of trouble because many
45common identifiers are used. Instead now all #defines are inline
46functions, which also allows strict type checking of arguments.
47
micky3879b9f5e72025-07-08 18:04:53 -040048The next enhancement is color support. It was originally provided by a
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053049derived class. This caused some trouble if you think about Panels or
50Menus and Forms with colors. We decided to put color support into the
51base class so that any derived class may use color support also.
52The implementation chosen here is directed to unrestricted use
53of mixes of color and monochrome windows. The original NCursesColorWindow
54class is maintained for compatibility reasons.
55
56The last point to mention is the support of other packages that are
57distributed with the ncurses package: the panels library, the menu library
58and the form library. This support is provided by the NCursesPanel class,
59which is also derived from the NCursesWindow class and the NCursesMenu
60and NCursesForm classes which are derived from NCursesPanel. This allows
61building interfaces with windows.
62
63Please see the example program for a quick introduction.
64
65Note that at this point, there is no documentation for these classes.
66Hopefully some will be written in the not too distant future. For now,
67to find out how to use the classes, read the code and the example program.
68
69Suggestions for enhancements and contributions of code (and docs) are
70welcome. Please let us know which functionality you miss.
71
72Original author:
73 Eric Newton <newton@rocky.oswego.edu> for FSF's libg++
74
75Authors of first ncurses based release (NCursesWindow, NCursesPanel):
76 Ulrich Drepper <drepper@ira.uka.de>
77 and Anatoly Ivasyuk <anatoly@nick.csh.rit.edu>
78
79Authors of this release:
80 Juergen Pfeifer
81 Thomas E. Dickey