react-pdf-viewer icon indicating copy to clipboard operation
react-pdf-viewer copied to clipboard

Print quality can be pixelated

Open mmacleodt opened this issue 2 years ago • 2 comments

Hi,

We are using react-pdf-viewer as a component to render documents in our application. We are also making use of the print button in the component.

Some users are noticing that the quality of the printed out document is poor compared to the original. I see that there is a call in the print functionality to canvas.toBlob(), which returns a image object of what is contained in the canvas (see https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob).

Is there a way of ensuring that the document that is printed via the component will be higher quality, as the image produced by canvas.toBlob (which the documentation states is 96 dpi) is not good enough for some of the users? We would like a print quality of at least 300 dpi (with 1200 dpi being the ideal quality).

Many thanks

mmacleodt avatar Oct 31 '22 12:10 mmacleodt

Hi,

Just wondering if you have considered a fix for this issue as I have not seen any update since posting the issue.

Many thanks

mmacleodt avatar Jun 06 '23 08:06 mmacleodt

Having these issues as well @phuocng, any thoughts?

viktorlarsson avatar Nov 17 '23 07:11 viktorlarsson