CLX
CLX is to Common Lisp as Xlib is to C - it provides low-level X calls
on top of which a Graphics Toolkit can be based. See McCLIM for
the de-facto higher-level toolkit, also see Garnet, CLUE and CLIO
for alternatives.
The CLX package as found in the X Consortium contrib archive is considerably
out of date as various Lisp implementors have independently ported CLX to their
own platforms, fixing bugs and, in some cases, adding features in the
process.
- "telent CLX" (working title, also known as portable-clx) is used in SBCL and also forms
the basis of the OpenMCL and ECL CLX packages. As of 0.7.3 it
additionally supports Allegro CL. It
includes Unix-domain socket support, SHAPE, XRENDER, XFREE86-VIDMODE
extensions, authorization fixes for ssh-forwarded connections, and
many other bugfixes and performance improvements. Usually tested
against the latest released SBCL.
darcs get http://common-lisp.net/~crhodes/clx # patches merged by Christophe
http://verisons.telent.net/clx # version from which releases are made -- this seems to be a broken link
http://monday-monkey.com/repos/clx/ # OpenMCL tree by bryan o'connor?
Download ASDF package from http://ftp.linux.org.uk/pub/lisp/sbcl/clx_0.7.3.tar.gz
(link fixed)
- CLX for CMUCL is available from CMUCL download sites in the
extra package: see the Download instructions
- CLISP comes with two implementations of CLX - the original MIT-CLX
and NEW-CLX which is faster and has some extensions.
Remark: now telent-clx from Christophe Rhodes experimental tree (darcs get http://common-lisp.net/~crhodes/clx) also works with CLISP. But these patches aren't maintained by Christophe!
- LispWorks - Barry Wilkes ported the MIT R5.02 sources to
LispWorks for Linux - http://www.bew.org.uk/Lisp/index.html. Other UNIX ports of
LispWorks have a version of CLX supported by Xanalys.
- OpenMCL (based on telent CLX) at ftp://clozure.com/pub/CLX/
- CLX has been part of Allegro Common Lisp since it was called
Extended Common Lisp. You can browse the version distributed with
Allegro CL here;
it appears to be the same as the MIT sources, featurewise.
- In clocc (at
sourceforge) there is a CLX implementation for CLISP, ACL,
LWL?, CMUCL, SBCL using clocc-port, but (as of 2003.08.28)
this is stale at least as compared to the telent tree: if there's a
telent-derived CLX for your Lisp, you're better off using that.
The CLX Manual is available in HTML and texinfo.
Supported X11 extensions
- XRENDER by Gilbert Baumann (basically done in the telent tree)
- XSHAPE and XFREE86-VIDMODE in the telent tree
- GLX (experimental) and DPMS (also in the telent tree)
- BIG-REQUESTS (work begun in Christophe's darcs repository)
- Some XSM work has been done in Eclipse; e.g.: eclipse/lib/sm/ common-lisp.net CVSWeb entry
Opportunities to contribute
- Adding more effective declarations
- Update the CLX Manual.
- Adding documentation strings to functions (mostly just converting existing good comments to strings).
- Better i18n
- Support for the MITSHM extension
- Use XmlXcb (XML description of the X protocol as used by XCB) as basis.
ssh-forwarded connections
The standard CLX function OPEN-DISPLAY doesn't correctly extract the
display number from the DISPLAY environment variable. This is a
problem when using CLX on an ssh-forwarded X11 session, as ssh
typically uses display number 10+n. Additionally, CLX in its MIT
guise doesn't handle xauth very well, requiring the xhost
blunt instrument before it'll put up a window on such a display. This
is handled correctly in CMUCL CLX (use EXT:OPEN-CLX-DISPLAY) and in
telent CLX (XLIB:OPEN-DEFAULT-DISPLAY). See CMUCL Hints for more
information.
Perhaps you want to have a look at the source code of Acclaim as it directly uses CLX without any layer in between to display the rendered slides on screen.
Pages in this topic: clfswm CLIO CLUE CLX Manual Eclipse Garnet portable-clx portable-clx-devel SLIK xlyb
Also linked from: Acclaim Alan Crowe clisp clSET CLX Grapher CMUCL Hints Current recommended libraries ECL Fractal hacks ftp.linux.org.uk Graphics Toolkit Hemlock Less Recent Changes Logo-to-lisp McCLIM MorphiCL OpenGL Bindings OpenMCL Picasso Planet of the Feebs Simple 3D viewing Steeldump Suggested Programming Projects win32 X11 XIT
CLiki pages can be edited by anyone at any time. Imagine a fearsomely comprehensive disclaimer of liability. Now fear, comprehensively