Skip to content
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

Reusing/refilling or modifying PDF causes size to grow exponentially #14

Open
flooie opened this issue Jul 10, 2018 · 3 comments
Open

Comments

@flooie
Copy link

flooie commented Jul 10, 2018

Some bug causes the size of the Pdf used ( if repeatedly used to fill out) to grow exponentially large.
Any idea what is causing this?

@phihag
Copy link
Owner

phihag commented Jul 10, 2018

At the moment, pdfform amends the PDF file. It has to repeat some, but not all values in the extra data (what exactly depends on the structure of the form and is current values). Can you provide an example file and example code (i.e. with a loop that goes to 20 or so and produces a 1GB file)?

@flooie
Copy link
Author

flooie commented Jul 10, 2018

@phihag
screen shot 2018-07-10 at 9 31 50 am

Yeah - Its possible to replicate it with your demo. I ran it this morning and have attached a screen shot of the PDFs generated. I noticed it was an error I could manage by removing some of the non -utf8 characters in the tool tip TU (?) of an acroform on a PDF of mine yesterday.

þÿ. <-- this

I found some complaints of jsPDF appending this character and wonder if its somewhat related

parallax/jsPDF#1464

@damiantech
Copy link

I have been running into a lot of issues in which þÿ comes up for no apparent cause. In fact, in one of my applications it happened at the very beginning of a line of pdf.text().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants