Cogitas Blog:
Google Android, machine learning,
natural language processing
and Java programming.


For Devs Info
Tips and code for app, website and server developers.

GUI tools for Lisp

Filed under: programming languages — Tags: , , , — January 4, 2011

Having recently understood the power of Lisp thanks to reading The Nature Of Lisp and then working my way through the early chapters of Practical Common Lisp (by Peter Seibel, also author of the excellent Coders at Work: Reflections on the Craft of Programming), I decided to find out more about GUI tools for Lisp.

A quick Google search brought out the following results:

Cello – the website is “under construction” with a 2004 date at the bottom… not encouraging. The link where “prerelease bundles and screenshots” can be found shows an empty directory. The mailing list for devs is still active but has got a very low activity – only one thread for 2010. So I’m thinking it’s a dead project?

McClim – the most recent release dates back to 2008 and is release 0.9.6 so my guess is either they are working on v1.0 but taking more time than planned, or they have stopped development? The devs mailing list is more active than for Cello so I’m hoping this means the devs haven’t given up. The website offers many screenshots of apps using McClim. While the GUI looks remind me of the early 90s, it does seem that it can do the job for an in-house/very specialist app but not for a “general public” app.

Garnet – the project page on sourceforge shows that most recent commit was in late 2009 and only one bug was submitted in 2010 (which suggests a low usage of the GUI). This tool kit dates back to the 90s and support from Carnegie Mellon University was dropped in 1995. The toolkit is described as “quite complete and mature” and the screenshots confirm a mid-90s GUI look. From the screenshots, it seems that you can develop fairly complex GUI, but it is another one the “general public” would probably consider dated.

cl gtk2 – this is a Common Lisp GUI library based on gtk+. The last release was in December 2009, and the dev mailing list has got a few threads for 2010 but isn’t very active. It seems that the main dev has been focusing on “adding native threads support for SBCL on Windows that are necessary for developing cross-platform GUI applications with SBCL and cl-gtk2″, so cl gtk2 is certainly still an active project, it seems to only be a case that something had to be done elsewhere to then get back to work on cl gtk2. Because it is a binding for gtk+, the look is very modern and would be suitable for general development – however, the library for gtk2 isn’t yet complete, according to the dev, but this is most definitively one to follow.

Cells – a Lisp binding for Gtk+. The last update of this one was in 2007 so no support for modern gtk+ 2.14 and beyond is to be expected, however it does look like a fairly mature library.

Common Qt – as the name suggests, this is a Common Lisp binding for Qt. This is in active development (last commit today actually!). Well worth keeping an eye on.

EQL – another Common Lisp binding for Qt. This one is also in active development (last release in December 2010), with an active user mailing list. Also well worth keeping an eye on.

Unsurprisingly, it seems that the most currently active GUI toolkit projects for Lisp are bindings for Qt, a very potent and versatile GUI library. At this present moment in time, and with the information on Common Qt and EQL, I cannot really work out the differences between them, so I guess the next step is to check them both out.

What is your experience with Lisp GUI libraries? Which one do you use and would you recommend it?

Android programming tips ebook cooming soon - fill in this quick form to be notified when the ebook comes out

5 Comments »

  1. [...] Lisp (by Peter Seibel, also author of the excellent Coders at Work: Reflections on the Craft of… [full post] Nat Cogitas Blog programming languagesgtk+guilisp 0 0 0 0 [...]

    Pingback by GUI tools for Lisp — January 4, 2011 @ 11:23 am

  2. cl-gtk2, in my opinion, is the best of the lot.
    Why?
    For numerous reasons. Most obvious being that Dmitry Kalyanov has really done an admirable job.
    Ease of use, from installation, comprehensive and very informative documentation, tutorial/example, it also means it is lispy, i.e., no need to drag a residual abstract concepts from other languages in your software, is there?
    And then, there is the best reason for using cl-gtk2, you actually do not have to. There is a support for glade, therefore, all your GUI programming is nothing but a plumbing self-understandable parts together. Checking is there anything new with the cl-gtk2 is part of my routine now :) .

    From today perspective, it seems that Cells, Cello and Garnet were nothing but exercises in concept. A real shame, because all of them could offer so much, not just to Lisp world.

    I do not know what to add about McClim, you put it perfectly. I hope we will all see v1.

    I have insufficient experience considering CommonQt and Eql. As I see, they both have a support for GUI designers tool, a big plus. With great pleasure I notice that EQL is promoting a ECL, an excellent CL implementation, though, I feel, often overlooked and neglected.

    Speaking of often overlooked, neglected but excellent software, take a look at the Gtk-Server wrapper by Leonardo Cecchi, which it does exactly what it states in its name. Therefore, if you need the latest capabilities in your GUI, but do not want to bother yourself with it, and taking too much time from your software logic, maybe you should also take a look at the GTK-server, as well as its lispy wrapper.

    Comment by Tomislav Tomsic — January 9, 2011 @ 9:25 pm

  3. If I want to us cl-gtk2, what do I have to install if I have emacs-slime-sbcl? If installed all required how to use the tools?

    Comment by arm — February 17, 2011 @ 1:08 am

  4. @arm
    That is all you need.
    You should all-ready be set.
    Understandably, one more thing you need is a cl-gtk2 source, which asdf-capable, as is a large majority of new or newish Common Lisp software.

    Explanation, what you need to do then:

    For a while now, sbcl comes with pre-packaged asdf, which has become a standard way of “packaging” CL code. If you are not familiar with it, don’t be alarmed, asdf is nothing but lisp program/utility for easier cl software system loading.
    It differs from the rest of cl software, besides its use, only that it has support for .asd types of files.
    I do not know which OS, etc you use, in the end it doesn’t matter, work-flow for asdf packaged software is the following:
    1. Download the Common Lisp code you are interestred in.
    2. Put it where you are supposed to, in the so-called *central-registry*. You can find details on cliki ( http://www.cliki.net/asdf ), among other places.
    3. Start emacs, write M-x slime (meaning, pressing Alt key in ,approximately 99.9762% cases, holding it and pressing x key, then writing slime), pressing enter, after educational string of letters, you will get to the slime emacs mode, where you can develop in CL, more easily, then in terminal.
    4. Once there, write (asdf:oos ‘asdf:load-op :foo-bar) , where foo-bar is the name of the software you intend to work with.
    If you have a more recent version of asdf, and you probably have, if you have a newer version of sbcl, you can write in a more succinct way just: (asdf:load-system ‘foo-bar), or something like that ;) .

    In any case, I would suggest to you to always check respective .asdf files. Not only that you will get a general overview of software architecture, you will also see what “foo-bar-baz” you should/can use, in order to operate software adequately. But, I digress, that is for some other thread entirely.

    Like I said, I do not know details about platform you use, therefore here is example what I should do. I am using the same combo as you are, but on Ubuntu/GTK. Which means, after I download cl-gtk2, I should de-archive it (unrar it, unzip it), in a folder /usr/share/common-lisp/source. Then I should go to the new child folder cl-gtk2-0.1.1/gtk where cl-gtk2-gtk.asd file is waiting for me. You can repeat the same procedure for any asdf file you find in the software you downloaded. Then, I should select that file, click and hold middle mouse button and drag it to the /usr/share/common-lisp/systems, in order to create a file “shortcut”, i.e. a symlink. After that, I can use cl software in the previously described manner.
    Note, on Ubuntu one can find asdf files there, because of common lisp controller, which, for simplicity sake, we can say is nothing but a “distro-friendly” wrapper around asdf utility.

    I hope I helped you somewhat, and shorten you some time, when you read documentation applicable for your respective case. If my reply is to verbose, I apologize.
    For some time now, I intend to write a series of blogs about various “first time cl user” issues, with lots of friendly pictures and step by step explanations. Well, you see at what length I tend to go ;) , I hope I’ll soon find some time to do it.
    Bye

    Comment by TomislavTomsic — February 19, 2011 @ 7:53 pm

  5. You don’t mention LTK. I thought it’d look awful, but actually it can be made to look not too bad. And it has the virtue of being really simple to use.

    Comment by Peredur ab Efrog — January 9, 2014 @ 12:35 am

RSS feed for comments on this post. TrackBack URL

Leave a comment