-
Notifications
You must be signed in to change notification settings - Fork 375
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
pdf2json interprets one word as 2 JSON objects #71
Comments
have you tried to parse with '-m' in cmd line? |
Thanks for your reply! |
could you remove Math.abs from line 197 of lib/pdf2json/pdffont.js, then run with -m again? |
After I removed the Math.abs function and ran it with the 'm' parameter, the strings in the columns next to each other were merged together. The affected words are still presented in separated JSON-objects. |
could you try it with v1.1.6? |
Hi,
I use pdf2json to parse some pdfs, which contain week-tables. However, after I parse the files, there’s a strange behavior - some of the words are separated in the JSON-file as different objects, while they’re actually one word inside of the pdf.
Example:
Files:
plan.pdf
plan.txt (sorry, can't upload JSON-Files)
The word:
„Champignons“ (column: „Mittwoch“, row: 2, line: 3) is interpreted as "Champig" and "nons" (2 JSON Objects)
JSON:
{"x":26.51,"y":16.388,"w":3.932,"sw":0.35678125,"clr":0,"A":"left","R":[{"T":"Champig","S":3,"TS":[0,12,0,0]}]},{"x":28.745,"y":16.388,"w":7.169,"sw":0.35678125,"clr":0,"A":"left","R":[{"T":"nons%20und%20Lauch%20","S":3,"TS":[0,12,0,0]}]}
This issue also occur in other rows. I suspect that it's caused by the specific pdf-structure.
Any ideas how I can fix that?
Thanks for your support!
The text was updated successfully, but these errors were encountered: