3 ms·
HexaPDF: Versatile PDF creation and manipulation library in pure Ruby
- lol768 3y agoUnfortunately the PDF generation ecosystem seems to be full of libraries that aren't permissively licensed, but there are some alternatives: .NET: PDFsharp: MIT License, benefits from transitive dependency exception in ImageSharp (otherwise nonfree in many cases). Supports font subsetting. FossPDF.Net: fork of QuestPDF, MIT license. High level layout interface, some significant drawbacks (doesn't position text correctly, no support for font subsetting; even with manually subset embedded fonts, Skia tends to produce poorly optimised PDFs which I found to be larger than they should) Ruby: Prawn: GPL (not AGPL) license. Supports font subsetting. Java: PDFBox: Apache License. Supports font subsetting. OpenPDF: Fork of iText, before it was given a dual license to enable commercial licenses to be sold. Python: ReportLab Toolkit: BSD license. More advanced markup and layout features are nonfree, in a separate product.
- thunderbong 3y agoI've been using WkhtmlToPdf all this while, so this seems a better option to try since it's pure Ruby. https://wkhtmltopdf.org/ https://wkhtmltopdf.org/