danfickle/neoflyingsaucer

Q: A new PDF output library.

danfickle opened this issue · 2 comments

The issue is that the old IText library is no longer maintained and the author is hostile to open-source projects using it (judging from comments on StackOverflow). He also claims it has unfixed technical problems.

Therefore, I've been looking for an open source project to replace it and came across the open-source version of the PDFJet library. I've uploaded it at pdfstream. It's licensed under a BSD style license.

It doesn't have many of the features that Itext has, such as form components and encryption, but it is mature and looks well written. Have a look and comment if you have an opinion on whether we should switch.

EDIT: I'm working on this in the pdfstream branch.

Progress Report

The pdfstream is mostly integrated and I'm moving it to the master branch as it is sufficiently advanced. The iText library will eventually be deleted. The following items still need to be done:

  • checkbox
  • select (partially implemented)
  • select multiple
  • radio button
  • text input
  • textarea
  • draw linear-gradient
  • draw oval
  • debug image positioning
  • debug dashed line dash array
  • embedded fonts(code available from the PDFClown library)
  • reenable compressiong of PDF streams
  • support for fonts other than latin scripts
  • support for indexed color png images (at the moment it just converts to rgb color space)
  • pdf bookmarks
  • right to left text

The pdfstream library is now used by the browser example. If anyone wants to switch back see the code in /flying-saucer-examples/com/github/neoflyingsaucer/other/PDFRenderer::renderToPDF(String, String, Character, UserAgentCallback)

UPDATE: Now it is rendering using both pdf engines to enable debugging. As file for our new PDF output renderer and file.old.pdf for IText. To change this behaviour see above code location and you can choose pdf renderer.

I've created separate items (#44 #43 #41) for the remaining issues, so will now close this one.