[cl-typesetting-devel] Reusing bits of code

Marc Battyani marc.battyani at fractalconcept.com
Fri Jul 8 16:58:20 UTC 2005


Peter Seibel wrote:
> On Jul 8, 2005, at 9:10 AM, Marc Battyani wrote:
> >
> > Otherwise for trial and error it's useful to draw the block border to
> > speed-up the convergence process.
>
> Okay, so that seems a bit kludgy. Let me step back and ask this: is
> there any (easy) way to define a new kind of box? Since cl-
> typesetting seems to all be done in terms of boxes It'd be sort of
> cool if I could define a logo-box which I can then place in any
> content (perhaps scaling it at the same time) and then let cl-
> typesetting take care of laying it out relative to everything else.
> Does that make sense?

More or less... ;-)
Making a special kind of box is very easy, just have a look at the simple
boxes like image or colored-box for instance. But in your case you don't
need to make a new kind of box, just use an user-drawn-box and provide the
drawing function. Now it's using this for a logo that seems strange to me.
Generally you place the logo at some fixed places on the page, not in the
text. Anyway once you have a draw-logo function you can use it in a
user-drawn-box as well as using it directly.

> -Peter
>
> P.S. I was taking a look at the internals of cl-pdf and cl-
> typesetting the other day and I noticed that cl-pdf contains two
> variables *font* and *font-size* which, as far as I can tell, are
> write-only. (Took me a while to figure that out since cl-typesetting
> also has *font* and *font-size* variables that it does use. But the
> cl-pdf symbols aren't exported so those are different vars. I assume
> the cl-pdf ones are vestigial and perhaps should be deleted.)

OK I will have a look at that.

Marc





More information about the cl-typesetting-devel mailing list