TCPDF vs mPDF (quick overview) | |
Автор: utilmind |
TCPDF is the best tool to create booklet covers or non-template based PDFs. It’s excellently supports SVG, PNG and another graphic formats, however if you would like to generate PDF’s based on some HTML templates — it’s wrong tool :( If you want to use HTML templates and create PDFs with look and feel of pure HTML pages — forget about TCPDF and use mPDF instead. Unfortunately, development of mPDF has been suspended recently, but it’s still briliant in converting HTML to PDFwith full (or almost full) CSS3 support. However, unfortunately, mPDF doesn’t natively supports SVG format (I guess it uses GD-library for it), doesn’t allows to display SVGs with custom fonts, etc. Unfortunately both major features (native SVG and HTML support) is crucial for me, so I decided to use both these libraries. I’m creating TCPDF to create the covers for my booklet, or some single pages with custom vector graphic (which I can modify on fly), and mPDF to create text reports, based on my HTML templates. Actually, in some near future I could switch to mPDF completely, but it will happens if either, mPDF will have better support of custom graphic (including native support of SVG-format), or when Inkscape will allow to convert text-based SVGs to plain SVGs with outlined text. I guess this feature already implemented, but doesn’t released yet officially in stable release. So let’s wait for Inkscape 0.49... I hope to be able to modify text in SVG-files, export them to SVGs with outlined path using command-line Inkscape tool, then I will use outlined SVGs in mPDF. Summary:
You decide what to use. I’m using them both. |
Tweet |
Отправить на E-mail Версия для печати |