[cl-gtk2-devel] cl-gtk2 w/ cl-cairo2

Kalyanov Dmitry kalyanov.dmitry at gmail.com
Wed Mar 31 19:26:16 UTC 2010


On Wednesday 31 March 2010 19:52:33, Tamas Papp wrote:
> Hi cl-gtk2 developers,
> 
> I am the author of the cl-cairo2 library (with significant
> contributions from others), and I was very happy to see it mentioned
> on the cl-gtk2 page.
> 
> cl-cairo2 has some basic functionality for displaying graphics using
> X11.  It basically creates an xlib image surface in cairo, draws on
> that, and copies that to a window whenever there is a change or X asks
> for redrawing.
> 
> This code was written by my in plain vanilla X (manually implemented
> event loop etc) with a few Lisp wrappers, and it is not very robust.
> I was wondering if it would be possible to do a better job with
> cl-gtk2.  Since cl-cairo2 is mentioned on the project page, maybe
> someone here could point me to code that does something related so
> that I could learn how to do this.  I have to admit that I am pretty
> clueless about X and Gtk programming in general.

cl-gtk2 integrates with cl-cairo2 by providing a couple of wrappers that 
create cairo surfaces and contexts and then all drawing is done by calling cl-
cairo2 functions.

There is a demo that uses cl-cairo2 (http://github.com/dmitryvk/cl-
gtk2/blob/master/cairo/cairo.demo.lisp). This demo creates a window which 
includes widget painted with cl-cairo2.

PS. Thanks for a good binding to Cairo!

----
Кальянов Дмитрий
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <https://mailman.common-lisp.net/pipermail/cl-gtk2-devel/attachments/20100331/42c9b41f/attachment.sig>


More information about the cl-gtk2-devel mailing list