The objcX library and its possible evolution to GNUStep

This is taken directly from Paul Kunz's notes.

The objcX library is an Objective-C class library that emulates the Appkit component of NeXTSTEP. It is currently implemented for X-Windows and uses the the Motif widget set. Not all of the Appkit has been implemented, but most of those parts which are most frequently used in GUI applications have been implemented.

One possible evolution of the library would address all of these points. Limited Display PostScript support could be added by using GhostScript. How this might be done has been discussed in a note by L. Peter Deutsch, the author of GhostScript. A possible replacement for the Motif widget set would be a widget set written with GhostScript.

Given Display PostScript support via GhostScript, a PostScript based widget set could be built. First, the drawing code would need to be written in PostScript. Second, event handling will need to be implemented. One could follow the FirstResponder mechanism of NeXTSTEP, thus most of the event handling would be in Objective-C and portable. The Responder class has already been contributed to the library by Keith Mason.

A PostScript based widget set is one way to avoid Motif. Another is use an Xt based widget set. A free widget set that emulates Motif is being worked on at University of Idaho. It is called Lesstif and the URL for further information is

  http://www.cs.uidaho.edu:8000/hungry/microshaft/lesstif.html

They have tried this library with objcX and things aren't quite ready yet. By the way, they are also building a C++ library on top of it that emulates SGI's tools.

Another free widget set with the look and feel of NeXTSTEP objects has been written at the Moscow Insitute of Physics and Technology. It is called libNeXT but is not freely available yet. Or if 2d widgets are good enough, then Athena widgets could be used.

To port the library and PostScript widget set to MS-Windows, one would need only to re-implement the event handling code for Windows, and to supply the code to create and manage windows.

As the library was being built, we come to realize that the bulk of the code makes no reference to Motif. Some classes contain no Motif or X-Window reference at all. Also, the references to Motif are mostly contained in a few methods of any class. Most of these methods are are defined in base classes and overridden in subclasses.

Thus, to enhance portablility of the core code of the library, all methods that reference X-Window or Motif are implemented as Objective-C categories in separate files...

Thus, all methods and functions that will need to be implemented with a different widget set are clearly identified. Also given a corresponding set of files which uses a different widget set, one could build the library either to Motif or that other set.