How would I make a web page print exactly the same across all browsers/printers?

…衆ロ難τιáo~ 提交于 2020-04-30 07:44:17

问题


Ok, so I'm pretty sure this isn't even possible, but I have a friend whose client is basically begging him for an answer on this so I told him I'd get some input from the friendly folks here at SO.

His client is ULTRA-PICKY about pixel precise user interface design across all browsers (IE7+, FF, Chrome and Safari). They have TEAMS of people in other countries who do nothing but sit there and measure to make sure everything matches their UX style guide down to the pixel in all browsers/versions (fonts, spacings between EVERYTHING, margins, etc).

Having said that, their next request is that they want to print driving directions but their UX requirements are just as stringent for printing. They want margins to be exactly the same on all pages, spacing between elements to be the same, etc. In other words, the printout should be EXACTLY the same, down to the pixel, no matter which browser you print from or printer you print on (aren't you glad this isn't your client)? :)

No, they want nothing to do with PDF, lol.

My question is: is this even possible? If it IS possible, can you point to some online references we can check out? Wouldn't each printer render things a bit differently based on default settings? Aren't there things outside the developer's control here when it comes to printing? Neither I nor my colleague have ever been asked to create something so precise across different browsers/printers so I though I'd get some input here.


回答1:


Render everything to an image (since you said no PDF)?

In all reality, this is an unreasonable request. You can create styles for different mediums, and handle browser differences with CSS resets and javascript, but you will always have different screen resolutions or screen types (eInk kindles come to mind) and printers with different inks or different types of printers.



来源:https://stackoverflow.com/questions/10391645/how-would-i-make-a-web-page-print-exactly-the-same-across-all-browsers-printers

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!