Three-D Athena Widgets (Xaw3d) for Linux Joachim Schnitter josch@pc.chemie.th-darmstadt.de These are the sources of my port of the Xaw3d library, a true replacement for the Athena widget library Xaw which gives your Athena based applications 3D appearance similar to another well known commercial widget library. The package consists of the following files: -- This file: 15511 Oct 12 10:56 Xaw3d-0.6B-3.0.1-src-README -- GNU Public Licence: 17982 Jun 18 1991 COPYING -- A script to unpack the sources and apply the patches: 745 Oct 12 10:54 Unpack -- The original sources: 1294336 Mar 19 1993 Xaw3d-0.6B.tar -- Patches which allow to build libXaw3d in parallel to libXaw in the MIT source tree (only for Linux) 15096 Oct 12 10:19 Xaw3d.patch -- Jump table definitions for the dll library (only for Linux) 5837 Oct 12 10:39 jump_funcs 76 Oct 12 10:39 jump_ignore 6953 Oct 12 10:39 jump_vars -- C file generated from laylex.l by LEX (Linux / GNU FLEX fails!) 18092 Oct 12 10:39 laylex.c -- A bug fix to xterm 10118 Jul 30 16:11 xterm-linux.patch -- My enhancements/bug fixes 49594 Oct 12 10:21 Xaw3d.new.diff - HOWTO -------------------------------------------------------------- This package was designed so that Xaw3d is fully integrated into X11R5. There are additional definitions in the configuration files for imake which allow you to use Xaw3d or XAW3D in you Imakefiles whereever you would put Xaw or XAW. It is therefore a good idea to install the configuration files, too. 1) Unpack MIT's sources. 2) Unpack the sources of XFree86 (this brings in some bug fixes and the commands to build shared libraries). 3) cd to the directory wich contains the MIT source tree ./mit. 4) Copy Xaw3d-0.6B-3.0.1-src-tar.gz to the current directory (the one containing ./mit). 4) Unpack this package partially: gunzip -c Xaw3d-0.6B-3.0.1-src-tar.gz | tar xvf - 5) cd to ./Xaw3d. 6) Decide whether you want to try my enhancements. I you do not believe that they are ok comment out the marked line in ./Unpack. 7) Unpack this package completely: ./Unpack 8) cd to the MIT source tree: cd ../mit 9) Make the package. If you have already done a 'make World' do make all >& make.log & sit back and have a cup of coffee or two. If it is finished check the make log: more make.log there should not be any errors. Then (as the super user) cd lib/Xaw3d make install This will install the header files in /usr/include/X11 and the libraries (static, stubs and shared) in /usr/lib. You will have to move the shared library libXaw3d.so.3.0.1 to /lib and link it there to libXaw3d.so.3 (and to libXaw.so.3 if you want to replace the Xaw widgets by their 3D counterparts). If you want to install the changed configuration files for imake, too, cd to mit/config and do (as the super user) make install If you build the whole X11R5 from scratch follow the instructions in the XFree86 source package. Xaw3d will then be fully integrated in your X11R5 setup. - ADDITIONAL COMMENTS ------------------------------------------------ The package was built from the Xaw3d-0.6B sources and includes some modifications to enhance 3D appearance and fix some bugs. These changes have been submitted to the creator of Xaw3d for inclusion into his files, but they are not yet officially released. Since for me they work without problems I wish to make them available, too. The original package includes an additional widget named Layout which is a very powerful replacement of the Form widget. It offers a mechanism to place and resize sub-widgets in a manner similar to TeX using "boxes and glue". The Layout widget is in this package, too. (As far as I could see the Layout widget is not operational in older dll library versions of Xaw3d. Forgive me if I am wrong.) The dynamic library is fully compatible with libXaw.so.3.0.1. It is therefore possible to 'ln -s libXaw3d.so.3.0.1 libXaw.so.3' to make all your Xaw programs use the 3D features of Xaw3d. This has been accomplished by creating a jump table with entries of the same order and size like those found in libXaw. The additional entries necessary for the Layout widget have been moved to the end of the table to avoid interference with the Xaw compatible entries. You can nevertheless relink all you Xaw applications with Xaw3d but if they are linked dynamically this is not necessary. If you want to use libXaw3d (instead of libXaw) I suggest that the following lines be put into your ~/.Xdefaults (I have entered Gray80 into my .Xdefaults for most of the Form widgets - it is the default color of olwm's frames. Therefore Gray80 colored scrollbars look nice. You are of course invited to use your favourite colors): *beNiceToColormap: false *shapeStyle: Rectangle *topShadowContrast: 20 *bottomShadowContrast: 40 *Scrollbar*background: Gray80 Check the header files in /usr/include/X11/Xaw3d for the available resources. Since some programs use the Xaw widgets in a funny way application specific resources need to be set, too, for these programs. Especially the Scrollbar widget behaves unexpected if you do not set the resources on a per application base, i.e. the globally defined resource *Scrollbar*background is ignored by some programs. Please send bug reports, comments, suggestions concerning this package to - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Joachim Schnitter Tel.: +49 (61 51) 16-53 97 Technische Hochschule Darmstadt Fax : +49 (61 51) 16-42 98 Physikalische Chemie I Petersenstr. 20 64287 Darmstadt Germany E-Mail: josch@pc.chemie.th-darmstadt.de - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - I will try to help as much as my filled time table allows. Since this package contains some features not yet released officially you are asked to report anything to me instead of contacting the official creator/maintainer of Xaw3d. The official README file states some problems with xterm, xarchie and aXe. I have not found anything strange with xterm and the most recent version of xarchie when I replaced Xaw by Xaw3d. I picked the xterm executable found in the SLS distribution (I use a customized one) and it worked. If you have problems using one of these programs please apply the patches found in /contrib/Xaw3d on ftp.x.org or any mirroring site. ====================================================================== Here follows the README file of the official source distribution: ---------------------------------------------------------------------- Three-D Athena Widgets (Xaw3d) Kaleb S. Keithley kaleb@jpl-devvax.jpl.nasa.gov Features: This is Release 0.6B (17 Feb, 1993) of a set of 3-D widgets based on the R5 Athena Widget set. The Three-D Athena may be used as a general replacement for the Athena (Xaw) Widget set. In general, you may relink almost any Athena Widget based application with the Three-D Athena Widget set and obtain a three dimensional appearance. On systems with shared libraries, you can replace your shared libXaw with libXaw3d and obtain the three dimensional appearance without even relinking. In this release, I have tested all of the clients distributed on the R5 MIT source tape, plus xfig-2.1.5, xarchie-1.3, and aXe-3.1. All Xaw3d sources have been thoroughly delinted using Sun's /bin/lint and gcc using -traditional -pedantic -Wall and -ansi -pedantic -Wall. Top and bottom shadow colors, shadow width, top and bottom shadow contrast should be self explanatory, and may be set via the usual and customary methods, e.g. app-defaults, .Xdefaults, programmatically, with editres, etc. The user data resource may be used to "hang" application specific data on a widget, and is only settable programmatically. This release adds the following features: o The 0.6A release fixed a problem in the Imakefile and added comments to the README. No changes were made to the Xaw3d sources. o The 0.6B release added a comment to the README. No changes were make to the Xaw3d sources. o The Layout widget. If I may borrow the phrase, this is an insanely great widget written by Keith Packard, and introduced at the '93 X Technical Conference. I have included it in Xaw3d, with Keith's permission, because Xaw has been in need of a versatile manager widget. Subclassed from Constraint, the Layout widget uses TeX- like semantics to describe where to place children and how to do geometry management. o Scrollbar with arrows. This is an Athena-based arrowhead-style Scrollbar written by Mitch Trachtenberg that is 100% compatible with the normal Athena Scrollbar. Selection of the normal style or the arrow style Scrollbar is a compile-time option for Xaw3d. The arrow style scrollbar is available separately on export in the file: /contrib/Xaw.Scrollbar.mta.Z o Bug fixes. More bug fixes than you can shake a stick at. Known problems: o You won't be able to replace shared libXaw with libXaw3d on systems with SVR3 style shared libraries. o On SVR4/386, I've had reports that replacing shared libXaw with libXaw3d works, and I've had reports that it doesn't. Try it and see. o Xaw3d pixel allocation doesn't behave well when beNiceToColormap is False and the Default Colormap is full. o The samples in Layout.h are wrong and don't work. Example programs written by Keith Packard that use the Layout widget are available on export in /contrib/Layout.tar.Z aXe-3.1 and xarchie: aXe-3.1 and xarchie won't compile against Xaw3d because they subclass the Xaw widgets themselves. To solve this, I now have a pair of patches for these programs. See below for where to get these patches. Renaming/replacing shared libXaw with libXaw3d will definitely break unpatched aXe-3.1 and xarchie. aXe-4.0 includes optional support for Xaw3d. Consult the aXe README for more information. xterm: A comment that appears in the xterm source: * * ...There be serious and nasty dragons here. * xterm is, well, xterm. The auto-scroll in the arrow-style scrollbar doesn't work in xterm because it relies on XtTimeouts. xterm, perhaps in the name of speed, circumvents XtAppNextEvent() and goes direct to XNextEvent() to get it's XEvents, with the unfortunate side effect of completely ignoring "other sources" like timeouts. I have included a patch for xterm to support the arrow-style scrollbar. See below for where to get this patch. Getting: Xaw3d may be found on export.lcs.mit.edu (18.24.0.12) and possibly other sites; check archie. On export, it may be found in the file: ~ftp/contrib/Xaw3d/R5/Xaw3d-0.6B.tar.Z There is no patch file from 0.5 to 0.6 -- it's larger than the tar file. Patches for xarchie-1.3, aXe-3.1, and xterm may be found in the files: ~ftp/contrib/Xaw3d/R5/xarchie3d.patch ~ftp/contrib/Xaw3d/R5/aXe3d.patch ~ftp/contrib/Xaw3d/R5/xterm.patch Building: Untar the distribution from the base of your MIT source tree. This will create the directory .../mit/lib/Xaw3d. 'cd' there and: 'make Makefile; make includes; make depend; make; make install'. The Imakefile contains the line: # EXTRA_DEFINES = -DARROW_SCROLLBAR If you want the arrow-scrollbar, then uncomment the line by deleting the '#'. The Imakefile uses the Xaw symbols in .../mit/config, so if you have debugging, profiling, shared libs, etc. specified for Xaw, you'll get them in Xaw3d too. Using: Just relink your Xaw based application with -lXaw3d. To obtain an appearance similar to another well know widget set, use the following resources: *background: LightSkyBlue *shapeStyle: Rectangle *beNiceToColormap: False By default, Label widgets do not have shadows drawn for them. You can force shadows to be drawn for specifying: *shadowWidth: 2 If you'd like the default behavior (i.e. not 3-D) on pulldown menus, use: *SmeBSB*shadowWidth: 0 Credits (in chronological order of their contribution): All the people at the X Consortium Achille Hui (eillihca@drizzle.stanford.edu) Robert Withrow (witr@rwwa.com) Malcolm Strickland (chuck-strickland@orl.mmc.com David Flanagan (david@ora.com) Jamie Zawinski (jwz%thalidomide@lucid.com Frank Terhaar-Yonkers (fty@bizarre.trpnc.epa.gov) Mike Schulze (mike@cs.curtin.edu.au) Gustaf Neumann (neumann@dec4.wu-wien.ac.at) Jerry Whelan (guru@stasi.bradley.edu) Mark Rawling (mwr@mel.dit.csiro.au) Tim Theisen (tim@cs.wisc.edu) Mitch Trachtenberg (mitch@mta.com) Keith Packard (keithp@ncd.com) Comments, fixes, etc. to: kaleb@jpl-devvax.jpl.nasa.gov