-
Notifications
You must be signed in to change notification settings - Fork 352
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
Webkit performance problem #19
Comments
I can confirm these problems. They are especially visible with longer documents. Our approach might be to convert the document to an html per page but that's not as elegant. |
jeroenjeremy: I believe that problem consist only in CSS or JS (something triggers repaint). If it is working fine in other browsers (even IE11!) I do not see a reason why change anything else. And from.my experience even 10 pages is enough to see problems |
For long, or technically complex PDF's converting to individual pages and writing a custom viewer that handles dynamically loading and unloading pages as they come in and out of the viewport will probably be your best bet. Depending on the size of the PDF you are trying to convert, you could also try adjusting the conversion settings (--heps, --veps) to reduce the number of elements that are created. |
I forgot to mention one important information. I use pdf2htmlex with So performance problem is not related to the length of original PDF (I tried 400 pages and 10 pages = same result). Problem must be somewhere in JS and CSS because when trying to load If I use element inspector in browser and uncheck CSS rule Even original demo "Full Circle Magazine" suffers from the same issue. |
@tomas-net I'm a little new to pdf2htmlex.. Could you point me to the "pdf2tmlex viewer" you are referring to? |
@amit777 By "pdf2tmlex viewer" I mean mainly Javascript code in index.html (or in separate file) used for dynamically loading pages, scrolling to specific page, zooming in/out, etc. and related CSS styles in index.html (or in separate file) used for styling common things like Even original demo propably converted by older version "Full Circle Magazine" (https://pdf2htmlex.github.io/pdf2htmlEX/demo/issue65_en.html) suffers from the same issue. Can anyone confirm this issue? |
Update to poppler-0.86.1 findDest now returns stg::unique_ptr and getURI no longer returns GooString but simply std::string
pdf2htmlEX faces to performance issues in Webkit-based browsers (mainly Safari macOS and iOS + Epiphany on Linux). Epiphany is good browser for testing because not everybody can access Apple devices. Whole page is slowly rendered, sometimes browser just crashes and if loaded then scrolling is too slow and browser keeps repainting whole page (instead of neccessary parts).
Blink engine (Chrome, Edge) is working fine.
If you use element inspector in browser and uncheck CSS rule
position: absolute
on#page-container
, everything will be OK (but this breaks other things like AJAX loading - it loads all pages, etc.).I tried to get rid of
position: absolute
and rewrite CSS styles forsidebar
andpage-container
todisplay: flex
(visual look was the same and performance issues remained). After that I tried to rewrite CSS styles todisplay: inline-block
- visual look was the same and performance issues remained and different issues occured in other browsers.The text was updated successfully, but these errors were encountered: