The Gnome Development Framework
Gnome’s application development framework centers around a suite of libraries, all written in portable ANSI C and intended to be used on UNIX-like systems. Libraries which involve graphics realy on the X Window System. Wrappers are available which export the Gnome API to nearly any language you can think of, including Ada, Scheme, Python, Perl, Tom, Eiffel, Dylan, and Objective C. There are at least three different C++ wrappers as well.
Taking full advantage of the free software tradition, Gnome didn’t start from scratch. It uses several libraries which are maintained separately from the Gnome project. These are a part of the Gnome application development framework, and you can count on their presence in a Gnome environment.
glib is the base of the Gnome infrastructure. It’s a C utility library, providing routines to create and manipulate common data structures. It also addresses portability issues; for example, many systems lack the snprintf() function, but glib contains an im- plementation called g_snprintf() which is both guaranteed to exist on all platforms and slightly safer than snprintf() (it always NULL-terminates the target buffer).
Gnome 1.0 uses glib version 1.2 and works with any glib in the 1.2 series (1.2.1, 1.2.2, etc.). All glib versions beginning with 1.2 are compatible bug-fix releases.
GTK+, or the Gimp Tool Kit, is the GUI toolkit used in Gnome applications. GTK+
was originally written for the Gimp (GNU Image Manipulation Program — http://www.gimp.org), but has become a general-purpose library. GTK+ depends on glib.
The GTK+ package includes GDK, the Gimp Drawing Kit, which is a simplification and abstraction of the low-level X Window System libraries. Since GTK+ uses GDK rather than calling X directly, a port of GDK permits GTK+ to run on windowing systems other than X with relatively few modifications. GTK+ and the Gimp have already been ported to the Win32 platform in this way.
GTK+ provides several features for Gnome applications:
• A dynamic type system.
• An object system written in C, complete with inheritance, type checking, and a signal/callback infrastructure. The type and object systems are not GUI-specific.
• A GtkWidget object written using the object system, which defines the interface
GTK+’s graphical components implement.
• A large collection of useful GtkWidget subclasses (widgets); this collection forms the bulk of GTK+’s code.
Gnome adds a number of additional widgets to the basic GTK+ collection.
Gnome 1.0 is based on GTK+ version 1.2. All GTK+ versions beginning with 1.2 are compatible bug-fix releases; 1.2.1, for example.
ORBit is a CORBA 2.2 ORB written in C. It was designed to be small and fast com- pared to other ORBs, and supports the C language mapping. ORBit is implemented as a suite of libraries.
CORBA, or Common Object Request Broker Architecture, is a specification for Object Request Brokers, or ORBs. An ORB is much like a dynamic linker, but it works with objects, rather than subroutines. At runtime, a program can request the services of a particular object; the ORB locates the object and creates a connection between it and the program. For example, an email program might request an “addressbook” object, and use it to look up a person’s name. Unlike dynamic linking, CORBA works fine across a network, and even allows different programming languages and operating systems to interact with one another. If you’re familiar with DCOM on the Windows operating system, CORBA is analagous.
Imlib (“Image Library”) provides routines for loading, saving, displaying, and scal- ing images in a variety of popular formats (including GIF, JPEG, PNG, and TIFF). It comes in two versions; an Xlib-only version, and a GDK-based version. Gnome uses the GDK version.
Read the next: The Gnome Development Framework: Gnome Libraries