lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Tue, Oct 27, 2009 at 9:02 PM, Luiz Henrique de Figueiredo
<> wrote:
>> On Oct 27, 2009, at 8:34 PM, Patrick wrote:
>> > Actually the only thing I am really suck with is FPDF. I want to
>> > generate PDF quotes for my small business.
>> Perhaps something like lpdf would help?
>> lpdf is a binding for PDFlib:
> FPDF explicitly avoids PDFlib.
> Looking at the code in FPDF, it seems to be easy to convert to pure Lua,
> but of course I know no PHP. If anyone knows PHP and can confirm that it'd
> be easy to convert to pure Lua, I could try it.

Hi Luiz,

FPDF is very popular in the PHP world because it is free and easy to
use. Its pseudo OO code is ugly though.
But TCPDF, which is even more useful is even uglier, probably the
ugliest code I have seen in PHP ever. But it does the job quite well
and has lots of features. I produce this kind of documents with it :

The best PHP PDF class in terms of "code beauty" is Zend_PDF.
Unfortunately it is incomplete as for example it doesn't support
cells. But its API is nice and powerful. You might want to have a look
at it before you start working on a pure Lua PDF module.

If you are more familiar with Python, there are at least two FPDF
ports in Python:

There are also some Ruby ports:

It would be nice to have such a thing in Lua, indeed :)

Bertrand Mansion