coolwanglu / pdf2htmlEX

Convert PDF to HTML without losing text or format.
http://coolwanglu.github.com/pdf2htmlEX/
Other
10.35k stars 1.84k forks source link

Error: Cannot save font to #754

Open joseluisct opened 6 years ago

joseluisct commented 6 years ago

I have an error converting some pdf files, it is: Internal Error: File Offset wrong for ttf table (name-data), -1 expected 174 Save Failed Cannot save font to C:\Users\test\AppData\Local\Temp//pdf2htmlEX-a14136/__tmp_font1.ttf

I'm using Windows last executable:

pdf2htmlEX version 0.14.6 Libraries: poppler 0.33.0 libfontforge 20150621 cairo 1.12.18 Supported image format: png jpg svg

Thank you.

joseluisct commented 6 years ago

I'm testing it and fails at page 76 but if I change pages order, it still fails at page 76, even if I remove it from file.

It's fails even with command: pdf2htmlEx test.pdf

And testing to split it into files of 10 pages for example, it works OK... but I can't use it, I need to convert all pages in one file.

hkajcy commented 6 years ago

Some font in pdf can NOT convert. You must change the origin code to skip it. Most time there is no problem if you do it.