Menu

Tree [e5ef75] master /
 History

HTTPS access


File Date Author Commit
 atk 2008-01-02 espen espen [bdc6c9] Using EXPORT-FROM-SYSTEM to autoexport symbols
 cairo 2022-04-10 Arseny Arseny [e5ef75] State the double-type constant explicitly since...
 examples 2016-02-28 Arseny Slobodyuk Arseny Slobodyuk [1314f9] One more fix to examples
 gdk 2008-12-10 espen espen [eb2096] API changes
 gffi 2022-04-09 Arseniy Slobodyuk Arseniy Slobodyuk [dd7106] Problem with ALIEN-CALLBACKS emerged in +INTERN...
 gio 2012-02-29 Rupert Swarbrick Rupert Swarbrick [381d1d] Explicitly name GProxy as network-proxy
 glade-xml 2008-10-09 espen espen [93ae85] Bug fix
 glib 2019-04-01 Arseny Arseny [da8ecd] Fixed clg on an Ubuntu 18.10
 gtk 2016-03-04 Arseny Slobodyuk Arseny Slobodyuk [704e5f] Fixed typecheck in gtktree functions returning ...
 pango 2008-01-02 espen espen [bdc6c9] Using EXPORT-FROM-SYSTEM to autoexport symbols
 rsvg 2008-10-08 espen espen [bcf029] Added macro WITH-HANDLE and function IMAGE-SURF...
 tools 2019-04-01 Arseny Arseny [da8ecd] Fixed clg on an Ubuntu 18.10
 .gitignore 2010-06-05 Rupert Swarbrick Rupert Swarbrick [fad6d6] Ignore fasls.
 CHANGELOG 2019-04-01 Arseny Arseny [da8ecd] Fixed clg on an Ubuntu 18.10
 COPYING 2005-04-23 espen espen [112ac1] Changed to MIT license
 README 2018-09-03 Arseny Slobodyuk Arseny Slobodyuk [6ba678] Oops
 STATUS 2005-09-26 espen espen [142c1c] Updated to reflect current state
 TODO 2006-09-08 espen espen [17502b] CLISP port marked as done
 hello-world.lisp 2007-06-19 espen espen [dc3dda] Added proper protection for multi threaded even...

Read Me

This package contains fork to the Common Lisp bindings to GTK+ v2.x. The
goal of the fork is to make the package working with current (stable) Debian
versions of the libraries and SBCL. It currently works with SBCL 1.3.14.
Ports to other CL implementations may be added later.


New versions
------------

The most recent version of this fork can be downloaded from
http://sourceforge.net/projects/clgfireproof.



Build instructions
------------------

1. For the old version of the instructions see original clg package.

   The clg bindings require recent SBCL with asdf installed, the system
   must have pkgconfig and libgtk2.0-dev, obviously.

2. Set up paths to match your system:

   - Set the correct pkg-config search path if your Gtk+ installation
     is in an unusual place, by adding it to the PKG_CONFIG_PATH
     environment variable before starting lisp.

   - Make sure ASDF finds the system definition files:

     have a directory where those files reside. If you don't have one -
     create it: mkdir /path/to/my/systems/.

     Add this in the .sbclrc:

     (require :asdf)
     (push "/path/to/my/systems/" asdf:*central-registry*)

     Link the system definition files from the clg subdirectories
     to this directory. For example:

     $ cd <clg toplevel>
     $ find .. -name '*.asd' -exec ln -s {} /path/to/my/systems/ \;

3. Compile and load the system:

     (require :gtk) ; for the cairo, pango, rsvg use the appropriate symbols

   If you are running SBCL with Slime you need to put the following
   in ~/.swank.lisp to prevent Slime from spawning multiple
   threads, since GTK+ is not really thread safe:

     #+sbcl(setq swank:*communication-style* :fd-handler)

   CLISP needs to be started with the option '-ansi' for clg to
   compile and load.


4. If everything worked, try (load "hello-world") to see a small
   window pop up, and then run testgtk.lisp in the example directory.



Guidelines for using the GTK+ API documentation 
-----------------------------------------------

Here are some brief guidelines for using the GTK+ API documentation.
A lot of (both intentional and unintentional) inconsistencies exists,
so it is also wise to check the source code, use the #'apropos and
#'describe.

- library prefixes are stripped from all symbols

- object properties should be available as virtual slots. A lot of 
  "missing" properties are manually defined as slots. Slots may be read
  only or write only, but there later type are generally only
  defined automatically through introspection

- the get/set part are removed from regular accessors, but retained
  in functions which set or retrieve multiple values

- predicate functions follow the normal convention of ending
  with '-P'

- if there are multiple similar named functions which only differ in
  the type of argument they accept, only one function accepting any
  kind of valid argument types is provided

- there are no gtk_*_new functions, use MAKE-INSTANCE to create widgets

- use CHILD-PROPERTY-VALUE or automatically defined accessors to
  access child properties

- use STYLE-PROPERTY-VALUE to access style properties

- the only function used to connect signals is SIGNAL-CONNECT

- some additional initargs to make-instance:

  - gtk:container

    child -- adds a child to a container widget. This argument could
    be a widget or a list who's first element is a widget and the rest
    child properties. Multiple :child initargs may be specified

    children -- list of children to be added

    child-args -- default child properties used when adding children (during
    construction only)

    show-children -- automatically make children (and grandchildren)
    visible. May be overridden in a child by explicit specifying :visible or
    another :show-children


  - gtk:button

    stock -- equivalent to ":label stock :use-stock t :use-underline t"


  - gtk:dialog

    button -- button specification applied to dialog-add-button. Multiple
    :button initargs may be specified

    buttons -- list of button specifications



Send comments and patches to clg-devel@lists.sourceforge.net or
ampy@users.sourceforge.net.
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.