[comp.sys.apollo] Common Lisp and graphics

nelson_r@apollo.UUCP.UUCP (10/02/87)

>>The ability to call DOMAIN Library functions from DOMAIN/CommonLISP is 
>>provided through the Foreign Function Interface ...

In addition to the information Leonard posted about Graphics and Lisp you 
might also want to make sure you are using Domain Common Lisp version 2.10 
which runs on software release 9.6.  This version includes a Window Toolkit 
which is built on top of Apollo's GPR package. Now there are three ways to 
use Lisp and Apollo graphics.

1) Use the foreign function interface to call pad_$ and gpr_$ calls directly
from Lisp.

2) If you already have a graphics window package written in some other language
(C, PAS, FTN) you can use the "load foreign file" interface to Lisp together
with the "define foreign function" interface to allow your own graphics
functions to be callable from Lisp.

3) Use the Common Lisp Window Toolkit, which is new at version 2.10. Since
the Window Toolkit is built on top of gpr_$ calls, you may not be able to make
your own gpr_$ calls directly from within the Window Toolkit.

Another source of examples is in the "/domain_examples/common_lisp_examples"
directory. In that directory there is a fairly complete mini-window manager 
with pop up menus.  It is written in Lisp and calls gpr_$ and pad_$ calls 
directly. To run it:

% lisp
> (cd "/domain_examples/common_lisp_examples/rect/")
> (load "rect.lbin")
> (main)

Then use the left mouse button to create a window, middle to move a window
and right mouse button to bring up a pop-up menu when inside an existing
window.

--  Rolf Nelson           UUCP: {mit-erl,yale,uw-beaver}!apollo!nelson_r 
    Apollo Computer       ARPA: apollo!nelson_r@EDDIE.MIT.EDU
-------