X-Git-Url: https://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=doc%2Fhtml%2FAda95.html;h=043b9de5d2ca56c8f6cdf122c0e6795db1ff62fd;hb=41068edef084c39be0cecdf949d9b538d925f42c;hp=89073216eec15d871ddd8986b910887dfb680cfe;hpb=b1f61d9f3aa244512045a6b02e759825d7049d34;p=ncurses.git
diff --git a/doc/html/Ada95.html b/doc/html/Ada95.html
index 89073216..043b9de5 100644
--- a/doc/html/Ada95.html
+++ b/doc/html/Ada95.html
@@ -1,54 +1,68 @@
-
+
-
Ada95 Binding for ncurses
Ada95 Binding for ncurses
-The ncurses Ada95 binding is © 1996-2000 by
-Jürgen Pfeifer.
-
-
-Permission is hereby granted to reproduce and distribute this
-binding by any means and for any fee, whether alone or as part
-of a larger distribution, in source or in binary form, PROVIDED
-this notice is included with any such distribution, and is not
-removed from any of its header files. Mention of ncurses and the
-author of this binding in any applications linked with it is
-highly appreciated.
-
-This binding comes AS IS with no warranty, implied or expressed.
-
+by Jürgen Pfeifer.
+
General Remarks
- This document describes Version 01.00 of the binding.
-- The functionality is modelled to be compatible with the ncurses
+
- The functionality is modeled to be compatible with the ncurses
package, a clone of the SVr4 curses model.
I did the development on an Intel box running the latest stable release of
-Linux, ncurses and the most recent released
+Linux, ncurses and the most recent released
GNU Ada Translator
gnat versions. For any older versions of ncurses and gnat
it is not guaranteed to work.
- You must have the m4 macroprocessor to build this package.
If you don't have this program, you can get the FSF version
-here.
+here.
- Ada programs are supposed to be readable. One of my
-favourite methods to make code readable is to use expressive
+favorite methods to make code readable is to use expressive
names for the identifiers. You can find a list of a mapping
of the cryptic curses names to the Ada names in this table.
-- This is not a typical one-2-one interface mapping. It is
-close to one-2-one on the functional level. Each (n)curses function
+
- This is not a typical one-to-one interface mapping. It is
+close to one-to-one on the functional level. Each (n)curses function
has it's counterpart with a more or less similar formal parameter list
-in the binding. It is not one-2-one with respect to the datatypes.
+in the binding. It is not one-to-one with respect to the datatypes.
I tried to make records out of the flat chtype and similar structures,
so you don't have to do bit operations to mark an attributed character
-as bold. Just make the boolean member bold of the record
+as bold. Just make the boolean member bold of the record
true. The binding also hides the structures like WINDOW, PANEL, MENU, FORM
etc. ! It's a pure functional API.
- I try to do as much error checking as possible and feasible
@@ -60,8 +74,7 @@ error checking style of C.
- Support for wide characters is currently not in the binding, as it
is not really in ncurses at this point in time.
-
-
+
Limitations
- I provide no SCREEN datatype and functions to set a new screen.
@@ -81,7 +94,7 @@ which the various fieldtypes are derived.
forms subsystem.
- The *_IO packages are currently output only.
-
+
Hierarchy of packages
Forms
+
+
Text_IO
-
+
If you want to navigate through the html pages of the package specs, click here.
Implementation Details
Behind the abstraction
All the new types like Window, Panel,
Menu, Form etc. are just
-opaque representations of the pointers to the corresponding
-low level (n)curses structures like
+opaque representations of the pointers to the corresponding
+low level (n)curses structures like
WINDOW *, PANEL *,
MENU * or FORM *.
So you can safely pass them to C routines that expect a pointer
@@ -143,16 +156,14 @@ sign of the parameter is evaluated. ncurses has internally implemented
it in a way, that uses the line parameter also to control the amount of
lines to steal. This mechanism is used in the Rip_Off_Lines
routine of the binding.
-
-How user defined field types work
+
TBD
Enumeration fields handling
The (n)curses documentation says, that the String arrays to be passed to
an TYPE_ENUM fieldtype must not be automatic variables. This is not true
in this binding, because it is internally arranged to safely copy these
values.
-
-Using other Ada compilers
+
This should basically not be a problem.
Port to other curses implementations
Basically it should not be too hard to make all this run on a regular SVr4
@@ -167,6 +178,6 @@ have two choices to deal with this:
Most likely you will follow a mixed approach. Some features are easy to simulate,
others will be hard if not impossible.
-I'm quite sure I forgot something.
+I'm quite sure I forgot something.