Ng2-pdf-viewer: Feature: PDFjs Controls

Created on 14 Jun 2018  路  10Comments  路  Source: VadimDez/ng2-pdf-viewer

Bug Report or Feature Request (mark with an x)
- [ ] Regression (a behavior that used to work and stopped working in a new release)
- [ ] Bug report -> please search issues before submitting
- [x] Feature request
- [ ] Documentation issue or request

PDFjs seems to be using ViewerJS (https://mozilla.github.io/pdf.js/web/viewer.html) to set controls at the top of the rendered PDF for zoom, paging, and hand tool (panning). It would be great if this component used the ViewerJS controls as these tools would complete this component making it even more valuable then it already is for PDF rendering.

enhancement help wanted

Most helpful comment

Yes, this would be valuable to me also. A standard toolbar would be useful. Without anything standard how does one implement "print" function, or "email" function?

All 10 comments

Yes, this would be valuable to me also. A standard toolbar would be useful. Without anything standard how does one implement "print" function, or "email" function?

+1

Has anyone figured this out yet? I am trying to print in Edge and the usual iframe trick doesn't work due to Blob url being blocked.

Basically, the toolbar and menus are not in ng2-pdf-viewer code. It only include the core to display PDF.

The standard toolbar and menu code is in viewer.html in original PDF.JS code.

@longjingjun That's apparent, I'm not arguing about that. I'm mostly wondering how to hook up the print service from PDFJS. I have a wrapper component for ng2-pdf-viewer that replicates the look and feel of viewer.html but the printing functionality eludes me since it's not part of pdfjs-dist.

When I run the PDF.JS example locally and access: http://localhost:8888/web/viewer.html, It shows the print button is there on the top right hand side. I tried to print and it shows me the web browser print dialog. From this information, I think the print function is in PDF.JS. The matter is about how to call the print function from Angular app.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Please reopen this issue.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Please reopen

Was this page helpful?
0 / 5 - 0 ratings

Related issues

RahmatAliMalik5 picture RahmatAliMalik5  路  5Comments

GarciaFreelancer picture GarciaFreelancer  路  6Comments

ShayShaked picture ShayShaked  路  5Comments

jgrant95 picture jgrant95  路  6Comments

fncamm picture fncamm  路  4Comments