[cl-typesetting-devel] Top-level layout, multi-page tables, and other contrib
Dmitri Ivanov
divanov at aha.ru
Sun Mar 7 07:10:14 UTC 2004
Hello Marc,
|> 3) AFAIR, code badly needs lots of restructuring and encapsulation.
|> For example, the pdf:page class should inherit from typeset:page,
| pdf:document -
|> from typeset:document, not vice versa.
|
| No. cl-pdf can be used without cl-typesetting. At least for now ;-)
At least symbols pdf:*document*, pdf:*page* and some others should be
imported into typeset and then reexported.
I assumed that finalize-page can perform custom operations like adding
outline via finalize-fn. Perhaps finalize-page should become a generic and
do this in :before or :after method for pdf::page argument (as well as
getting content).
BTW, I've run into the questionable method in stroke.lisp:
(defmethod stroke ((style text-style) x y)
(when (font style)
(setf *font* (font style)))
(when (font-size style)
(setf *font-size* (font-size style)))
(when (text-x-scale style)
(setf *text-x-scale* (text-x-scale style)))
(when (color style)
(setf *color* (color style))
(pdf::set-color-fill *color*)))
Though *color* holds a foreground, or stroking, color value, this value is
assigned as a non-stroking PDF color. Must we have the following:
(defmethod stroke ((style text-style) x y)
(when (font style)
(setf *font* (font style)))
(when (font-size style)
(setf *font-size* (font-size style)))
(when (text-x-scale style)
(setf *text-x-scale* (text-x-scale style)))
(when (color style)
(setf *color* (color style))
(pdf::set-color-stroke *color*))
(when (background-color style)
(setf *background-color* (background-color style))
(pdf::set-color-fill *background-color*)))
?
--
Sincerely,
Dmitri Ivanov
lisp.ystok.ru
More information about the cl-typesetting-devel
mailing list