-
Notifications
You must be signed in to change notification settings - Fork 10.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug 1302069 - Printing canvases at PDF document size. #7677
Conversation
Nice work! It turns out that when I printed to PDF before, the scale was set to 200% by Firefox (I'm not sure if that's a default or it's somehow set that way, but I didn't set that manually). Sorry for the noise. If I set that to 100% as it should be, it prints just fine. More testing is necessary, but so far this looks good. |
/botio-linux preview |
From: Bot.io (Linux)ReceivedCommand cmd_preview from @timvandermeij received. Current queue size: 0 Live output at: http://107.21.233.14:8877/d0bd116a1ccad76/output.txt |
From: Bot.io (Linux)SuccessFull output at http://107.21.233.14:8877/d0bd116a1ccad76/output.txt Total script time: 1.04 mins Published |
/botio-windows preview |
From: Bot.io (Windows)ReceivedCommand cmd_preview from @yurydelendik received. Current queue size: 0 Live output at: http://107.22.172.223:8877/acdc6d404bb2df2/output.txt |
From: Bot.io (Windows)SuccessFull output at http://107.22.172.223:8877/acdc6d404bb2df2/output.txt Total script time: 1.80 mins Published |
Testing on my local computers (Mac and Win) did not discover any regressions (on different browsers). @timvandermeij confirms it work fine on Linux as well (via IRC). We are good to merge. |
Awesome! |
Awesome, you guys are! The initial bug of IE only printing half a page seems to be fixed with this new update. Except, I do not believe this is fully off the table yet (frowns at IE). I am using pdf.js version 1.6.258 and have also tested the above 1.6.218 against a few documents I am trying to get this to work with, and I see the following 2 things happening...
I realize these are 2 separate issues, just noting them here since all the above issues are what I have been following. Unfortunately the documents in question contain sensitive information and I am unable to just post some links at this time, I will try and re-produce the above with links using a different document and open proper issue reports. I appreciate all the work you guys are doing to solve IE's unruly issues! |
There is nothing can be done about issues above -- browser does not inform about pages it prints. What we can do is detect if browser has top/bottom margins, truncate images from top/bottom or prescale it (Notice that you can scale it in IE during printing to avoid the problem). Safari for Mac OSX has the similar issue. |
For number 1 above, I believe I understand what the issue may be, though pdf.js in any browser but IE handles the page height without issues, I can even set it in the PDF to 350mm and it works in all browsers, but for IE it stops just short or defaults back to the A4 paper size height which is 297mm. I will research more before claiming it to be a pdf.js issue and will report back. For number 2 above, when the viewer is in an iframe, the printed result is a little larger then a quarter of the page (width and height). I have not been able to look further into this, but am able to show it happening even with your default pdf provided with the viewer. When I get a chance to look into this further, I will provide an issue report if its pdf.js' issue. Either way, thanks again for your hard work guys. |
When we try to load the .msg file with landscape from pdf.js using chrome browser the quality of the print is not fine and it becomes blur and unable to read the content is their any solution for this. Same pdf document if we print outside it is working fine is their any solution for this. Thanks |
Bug 1302069 - Printing canvases at PDF document size.
Trying to make printing code sane -- it attempts to print canvases with sizes that are specified in the PDF document. Problem only appear when automatic/non-100% scale is selected in the browser or paper is smaller than PDF page needs. Pros is scale of the print can be now controlled by the user (https://bugzilla.mozilla.org/show_bug.cgi?id=1302069).