[cl-typesetting-devel] peculiar behaviour
Marc Battyani
marc.battyani at fractalconcept.com
Thu Sep 30 10:48:25 UTC 2004
"Bob Hutchison" <hutch at recursive.ca> wrote:
> I emailed this a couple of days ago and have not seen it come up yet on
> the mailing list, so trying again.
I got it but have not found the time to look at it until now.
> I'm starting to look into the cl-typesetting package and am
> encountering some very strange behaviour.
>
> I tried this bit of lisp:
>
> (iter (for i from 1 to 30)
> (tt::pprint-lisp-file
> (pathname "/Users/hutch/cl/cl-typesetting/pprint.lisp")
> (pathname (format nil "/tmp/pprint~A.pdf" i))
> "pprint of pprint"))
>
> Which runs without reporting any problems.
>
> A quick look at the pdf files shows that varying amounts of content is
> missing from the beginning of the document.
>
> Is this something unique to my setup (LW for mac) or are other people
> seeing this too? I first saw this when I was playing with the
> kw-extensions.
A binding of pdf:*page* was missing so a fresh page was not enforced at the
beginning of a with-document.
Try with this in pdf.lisp of cl-pdf:
(defmacro with-document ((&rest args) &body body)
`(let* ((*document* (make-instance 'document , at args))
(*outlines-stack* (list (outline-root *document*)))
(*root-page* (root-page *document*))
(*page* nil)
(*page-number* 0))
, at body))
This should fix it. Tell me if it's OK.
Marc
More information about the cl-typesetting-devel
mailing list