views:

32

answers:

1

I've recently been working on a print stylesheet for a website, and I realized that I was at a loss for effective ways to tweak it. It's one thing to have a reload cycle for working on the on-screen layout:

  • change code
  • command-tab
  • reload

but that whole process gets much more arduous when you're trying to print:

  • change code
  • command-tab
  • reload
  • print
  • squint at print-preview image
  • open PDF in Preview for further inspection

Are there tools I'm missing out on here? Does WebKit's inspector have a "pretend this is paged media" checkbox? Is there some magic that Firebug (shudder) can do?

+1  A: 

Just show the print stylesheet in your browser using media="screen" while debugging. The print preview view uses the same rendering engine as normal browsing mode so you can get accurate results using that.

Tatu Ulmanen
Except the normal browsing mode doesn't have pages, so I have no idea how content will flow. Normal browsing mode has a width of a certain number of pixels, while a page has a width of a certain number of inches or centimeters. There are fundamental implementation-independent differences between screen and print. Debugging between those is what I'm after.
Jim Puls