[cl-typesetting-devel] Layout glitch
Peter Seibel
peter at gigamonkeys.com
Fri Feb 29 04:24:03 UTC 2008
When setting justified text, cl-typesetting tries to justify the last
line of a paragraph. That seems contrary to normal typographic style as
it results in extremely loose lines.
This code produces the attached output which shows the problem:
(in-package :tt)
(defun foo (&optional (output "/tmp/foo.pdf"))
(with-document ()
(draw-pages
(compile-text ()
(paragraph (:h-align :justify :top-margin 12)
"Short paragraph")
(paragraph (:h-align :justify :top-margin 12)
"Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Praesent
euismod malesuada enim. Pellentesque elementum dui eget leo. Duis
iaculis. Fusce malesuada, lorem quis congue pulvinar, purus mauris
commodo risus, a rhoncus ante ipsum bibendum velit. Quisque nisi quam,
mollis non, convallis nec, ornare sit amet, justo. Integer tincidunt,
dolor vitae lacinia pellentesque, diam magna volutpat dui, et rutrum
nisl tellus quis sem. Praesent suscipit tincidunt lacus. Mauris ut odio.
Pellentesque in neque a urna lobortis iaculis. Aliquam id metus et
ligula placerat cursus. Donec ut libero. Aliquam tempor ornare felis.
Aenean convallis. Ut non lacus id urna fermentum bibendum. Aenean
adipiscing bibendum pede. Nullam laoreet erat eu elit. Fusce interdum
cursus dolor. Fusce nisl. Suspendisse diam libero."))
:break :after
:size :Letter
:margins '(72 72 72 72)
:header-top 36
:footer-bottom 36)
(pdf:write-document output)))
-Peter
--
Peter Seibel : peter at gigamonkeys.com
A Billion Monkeys Can't be Wrong : http://www.gigamonkeys.com/blog/
Practical Common Lisp : http://www.gigamonkeys.com/book/
Coders at Work : http://www.codersatwork.com/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: foo.pdf
Type: application/pdf
Size: 4118 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/cl-typesetting-devel/attachments/20080228/7eb7090b/attachment.pdf>
More information about the cl-typesetting-devel
mailing list