In this release, the X11 and Xt components are available directly
on the Web from two sites:
The copyright notices have been revised.
Online files
The "doc" directory contains online documentation files.
The "ada" directory contains source files for X11Ada.
The "c" directory contains the C header files from which the
Ada was derived. These could be needed because the tool we
used to translate the C headers to Ada left out the comments.
If you want to take a look at the original comments that were
in the C headers, the Ada files contain references like:
PointerMotionHintMask : constant := 128; -- X.h:108
which says that this Ada declaration corresponds to line 108 of the
C header file X.h.
The "test" directory contains a few small test programs.
Documentation
The documentation files in the "doc" directory are:
- x11ada.html
- this file
- roadmap
- a map of the correspondence between Ada package
names, Ada source files, and C header files
- xbind.*
- xbind.ps is the Postscript version of a technical
report and overview of X11Ada; xbind.doc is the
Microsoft Word version.
- interf4.*
- interf4.ps is the Postscript version of a paper
about a Windows NT binding that was recently completed.
The sections
of the paper about variable-length argument lists
and variable-length arrays are also relevant
to the X binding. (Also, the section on
treatment of C unions should be relevant,
except the support for pragma Unchecked_Union
is not yet implemented in GNAT 3.01 on Sparc.)
Interf4.doc is the Microsoft Word version.
This paper was published in the 1995 TriAda conference proceedings.
- stdarg.*
- stdarg.ps is the Postscript version of a paper
about the Stdarg package of X11Ada;
stdarg.doc is the Microsoft Word version.
Building X11Ada on other platforms
This release of X11Ada has been tested with GNAT 3.01 on Sun-4.
The Stdarg family of packages are known to be machine-dependent.
Versions are provided for the
- Sun-4 Sparc
- Intel 386-486-Pentium
- Hewlett-Packard HP-9000 series 700 and 800
- MIPS/Silicon Graphics
- PowerPC
- DEC Alpha
machine architectures. Here is how to build it for one of these
platforms:
- If you are building X11Ada on Sparc, do nothing special.
- If you are building X11Ada on Intel, HP, or SGI edit the file
stdarg-machine.ads and set the constant This_Arch to the correct
value for your machine.
- On Intel, there is a warning message about record alignment
in the file stdarg-machine.ads. This message can be ignored.
- If you are building on HP, the line
#define STACK_GROWS_UP
in the file var.c must be commented out.
Also the rep clause for ArgBlock in stdarg.ads must be un-commented.
- If you are building for the Alpha, the type Resource must be
commented out of x.ads and x.adb.
- If you are using another hardware platform, some rewriting of
the Stdarg packages will be needed. To get started, see the
stdarg.doc documentation file.
In the "test" directory, the "testvar" program tests that the Stdarg
mechanism is working, and has been built correctly for the current
machine platform.
As new releases of GNAT come out,
and other Ada 95 compilers become available,
small changes to X11Ada may be needed.
Test programs
Currently there are 5 small test programs:
- testvar tests the Stdarg mechanism, as mentioned above, and gives
examples of how to use this mechanism from an application program.
- testexten tests the extensible array mechanism , and gives
examples of how to use this mechanism from an application program.
- basicwin is a simple Xlib program
- xrowcolumn is a simple Xt program
- hello_motif is a simple Motif program
The last three are translated from examples in the O'Reilly X
programming manuals.
Here is what these three are supposed to look like when run:
basicwin,
xrowcolumn, and
hello_motif.
There may be slight differences on your system.
Sending test comments and programs
More test programs are needed. Please send them! It's OK if they
contain copyright notices, as long as the copyright text allows me
to re-distribute the programs along with the general release of the
binding.
Please send comments and test programs to:
Mitch Gart
Intermetrics
733 Concord Avenue
Cambridge, MA, 02138, USA
mg@inmet.com (email)
617-661-1840 (voice)
617-868-2843 (Fax)
X11Ada programming examples
For information on X11Ada programming see
The Free X11/Ada 95 Programmer's Home Page.
Some programs have been contributed by users of the binding,
see the
contributions directory.
Changes
Last updated March 8, 1996.
March 4, 1996: upgrade to GNAT 3.03.
Feb 29, 1996: various small bug fixes. Add null_widget and other
declarations for private types. Move Resource to package X.Tasking
so the binding can be used on machines where tasking is not supported.
Added contributions directory and Mandelbrot program. Fix AdaMagic
compilation errors.
Dec 19, 1995: release that changes access subprograms to all have
pragma Convention (C), and other small changes to make the binding
work with the OCS compiler.