Forum Bugs

Printing Wikipedia with "wiki2.css" formatting fau

someonenew
Hello,

trying to print the following page does not work properly as code samples are printed over "normal" text in the other column or are cropped.

http://en.wikipedia.org/wiki/Recursion_(computer_science)

The command line used:

prince --no-author-style -s http://www.princexml.com/howcome/2008/wikipedia/wiki2.css "http://en.wikipedia.org/wiki/Recursion_(computer_science)" -o out.pdf


Any suggestions appreciated
Regards
mikeday
Using "white-space: pre-wrap" for the code samples would allow them to wrap to the next line instead of overflowing, but the result would still be quite unreadable as the code samples are long and the columns are narrow.

Perhaps a better solution would be to avoid using columns for this article, or use columns for the body text and place the code samples on a named page of their own that does not use columns.
howcome
someonenew wrote:
Hello,

trying to print the following page does not work properly as code samples are printed over "normal" text in the other column or are cropped.

http://en.wikipedia.org/wiki/Recursion_(computer_science)


Trying to print an article about recursion seems irresponsible :-)

As Michael points out, the content may not be suitable for printing in a two-column layout.

You could try reducing the font size of the code samples.

There is no way in CSS to say "scale the font size of this text to ensure that it fits within the content box of the element. Even if that option was available, it may not be optimal as thext would (perhaps) be too small to read. Also, the font size would vary between samples.