experiment with print style css


Permalink 03:05:26 pm, by sarneil, 172 words, 287 views   English (CA)
Categories: Activity log; Mins. worked: 240

experiment with print style css

LD asked about print output of all the Franklin pages in one big (PDF) file.

To do a real job of this, I guess I could write some kind of translation using Apache FOP, but I can't justify the time and effort.

Did some experimenting with a @media print block of selectors for outputting plain black text on white background for printing. Added the selectors to the FranklinLayoutDev.css file. By and large it works, but images for some reason cause page breaks to appear unexpectedly in the PDF (for example Voyage/introduction). If I remove the "@media print" selector, then the rules apply to the screen output as well, and the images don't force a page break, but all the other behaviour works as it does for the PDF output. In principle, with a few more hours work I could probably get pretty clean output one web-page at a time, and then someone would have to generate a PDF of each page and then and assemble them into one big PDF.


No Pingbacks for this post yet...

Canadian Mysteries

The Canadian Mysteries site consists of a production site containing 12 mysteries, a containing shell and 30 mysteryquests; and a database-driven development site. HCMC took over tech support in summer 08. This blog documents work done on the site from Sept 08. Earlier work is documented in the depts blog in posts prepended with CanMys


XML Feeds