[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

dw:redisplay-helper-stream



   From: shirley@parc.xerox.com (Mark Shirley)
   Date: Thu, 3 Oct 1991 22:45:43 PDT


   I'm trying to write something similar to dw:format-graph-from-root
   but with a different layout algorithm.  The key element I need is a
   way to figure out the bounding box for some text and graphical
   output before actually writing those things to the output stream.
   For instance, I need a "helper" stream that produces no output, but
   records the motions of the cursor and the bounding boxes of
   graphics calls.

It sounds like what you need is DW:CONTINUATION-OUTPUT-SIZE.  It takes
a stream and a function and lets you know what the extent of the
output is.  As I recall, it was not in the printed docs for 7.2,
though it was in the on-line docs.  I have not checked to see if it is
in the 8.0 documentation.

You have to be careful when doing nested invocations because it is
really easy to get bad combinatorial behavior -- one of the big
advantages of using CLIM is that it is easy to cache the sizes of
subdisplays rather than recomputing them a zillion times.

--David Gadbois