Important libglade changes ...



As some of you may know, I have recently been adding GNOME support to
libglade, to go with the GNOME support Damon has been adding to glade.
Rather than having a library that is optionally compiled with GNOME
support, I have split the GNOME code off into a separate library called
libglade-gnome (it is still distributed with the libglade package).

For future versions of libglade, if you want to use the GNOME support,
here are the changes that must be made to your code:
  1) change the initialisation call to glade_init() to a call to
     glade_gnome_init().  This will initialise both the gtk and gnome
     widget building routines.
  2) In your make files, link the executables with the arguments returned
     by `libglade-config --cflags --libs gnome` rather than just
     `libglade-config --cflags --libs`.

For people using autoconf, I also provide a macro AM_PATH_LIBGLADE that
can be used to extract the cflags and libs for libglade.  It is called as:
  AM_PATH_LIBGLADE([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]])

Currently the only allowed module is "gnome".  If libglade is not found,
or the desired module is not found, the ACTION-IF-NOT-FOUND command is
executed.  Otherwise the ACTION-IF-FOUND command is executed.  The macro
will also AC_SUBST the LIBGLADE_CFLAGS and LIBGLADE_LIBS macros.  For the
typical GNOME program wanting to use libglade, you would probably call it
as:
  AM_PATH_LIBGLADE(,[AC_MSG_ERROR(libglade not found)],gnome)

For GTK only programs and GNOME programs that do not wish to take
advantage of libglade's GNOME features, you should not have to change
anything.  These programs will also not have any of the GNOME specific
libglade code linked in, which may be a plus.

James

--
Email: james@daa.com.au
WWW:   http://www.daa.com.au/~james/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]