-
Notifications
You must be signed in to change notification settings - Fork 610
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
Allow PdfCopy to be used for writing new pages #1166
Conversation
This change will have twofold results:
Leaving the PR open for the community to drop some 2 cents. |
You mentioned in review:
Not only have they not planned that, this feature has not been tested for years in use. I would not be surprised if there were numerous corner cases for which the feature will fail. Thus, a larger number of tests of different situations would be nice. We have first adding content, then merging; other tests could be first merging, then adding content, probably also a longer mix of mergers and content additions. Nonetheless, the feature of course is interesting, it also was missing in all pre-7 versions of iText and there were requests again and again. |
The single test I wrote already added/merged/added. I just added another test that interleaves two files and combines it with adding a page in front of each. |
Just for reference, none of the other |
Great, thanks!
Neither of those classes is a
Maybe one should give this feature in |
Quality Gate passedIssues Measures |
Description of the new Feature/Bugfix
Remove unnecessary overridden methods from PdfCopy thus allowing it to be used to write new pages as well as copy them.
Related Issue: This fixes #1165
Unit-Tests for the new Feature/Bugfix
Compatibilities Issues
The behavior of
PdfCopy
is of course changed, since it now actually adds new pages if requested. I would expect that anyone that does that, actually intended to do it.Your real name
Rasmus Faber-Espensen
Testing details
See unit test.