[cl-pdf-devel] [Fwd: Re: cl-pdf question]
Cyrus Harmon
ch-lisp at bobobeach.com
Tue Oct 16 20:50:55 UTC 2007
Can you give some more details about your SBCL setup? What version,
what platform, etc...?
Thanks,
Cyrus
On Oct 16, 2007, at 1:31 PM, Cunningham, Jeff wrote:
> I am posting this question to the list at Marc's suggestion.
> If anyone knows how to configure cl-pdf to run under SBCL I'd sure
> appreciate some advice.
>
> Thanks.
> --Jeff
>
>
> Hi Jeff,
>
> Cunningham, Jeff wrote:
>> Hi Marc,
>>
>> I'm no doubt doing something really dumb, but I can't get your first
>> example to work in cl-pdf.
>> I am working with the latest copy and have all the dependencies
>> (latest copies). I'm running SBCL. I'm hoping you can tell me how to
>> get past this.
>>
>> Thanks.
>> --Jeff Cunningham
>> Seattle, Washington, USA
>>
>> Here's what I get:
>>
>> (asdf:oos 'asdf:load-op :cl-pdf)
>> (use-package :pdf)
>>
>> ;;; cl-pdf copyright 2002-2005 Marc Battyani see license.txt for
>> details of the BSD style license
>> ;;; You can reach me at marc.battyani at fractalconcept.com or
>> marc at battyani.net
>> ;;; The homepage of cl-pdf is here:
>> http://www.fractalconcept.com/asp/html/cl-pdf.html
>>
>> (defun example1 (&optional (file #P"/tmp/ex1.pdf"))
>> (pdf:with-document ()
>> (pdf:with-page ()
>> (pdf:with-outline-level ("Example" (pdf:register-page-
>> reference))
>> (let ((helvetica (pdf:get-font "Helvetica")))
>> (pdf:in-text-mode
>> (pdf:set-font helvetica 36.0)
>> (pdf:move-text 100 800)
>> (pdf:draw-text "cl-pdf: Example 1"))
>> (pdf:translate 230 500)
>> (loop repeat 150
>> for i = 0.67 then (* i 1.045)
>> do (pdf:in-text-mode
>> (pdf:set-font helvetica i)
>> (pdf:set-rgb-fill (/ (random 255) 255.0)(/ (random 255)
>> 255.0)(/ (random 255) 255.0))
>> (pdf:move-text (* i 3) 0)
>> (pdf:show-text "cl-typesetting"))
>> (pdf:rotate 13)))))
>> (pdf:write-document file)))
>>
>> (example1)
>>
>> #<SB-SYS:FD-STREAM for "file /tmp/ex1.pdf" {C463F41}> is not a
>> binary
>> output stream.
>> [Condition of type SIMPLE-TYPE-ERROR]
>>
>> Restarts:
>> 0: [ABORT] Abort SLIME compilation.
>> 1: [ABORT] Return to SLIME's top level.
>> 2: [TERMINATE-THREAD] Terminate this thread (#<THREAD "worker"
>> {B7055F1}>)
>>
> It's a configuration problem to use binary/text or bivalent streams in
> SBCL. I don't use SBCL, so I can't help you much here, but several
> cl-pdf/cl-typesetting users use it. So you should post your
> question in
> the cl-pdf mailing list.
>
> Marc
>
> _______________________________________________
> cl-pdf-devel site list
> cl-pdf-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/cl-pdf-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cl-pdf-devel/attachments/20071016/c01519c8/attachment.html>
More information about the cl-pdf-devel
mailing list