[Zope] Reports and barcodes.

chas panda@skinnyhippo.com
Tue, 28 Sep 1999 13:24:28 +0800


At 10:05 PM 9/27/99 -0500, Evan Simpson wrote:
>Ping Lau wrote:
>
>> I like to first thank all of you for your suggestions.  But I still can't
>> quite figure out how PDF can solve my problem.  The first problem I am
>> facing is printing reports to pre printed forms loaded in dot matrix
>> printers.  The program has to drive the printer to print the info at the
>> right spot on the form. The second problem is how to print barcode(Code39
>> symbology) on some documents.  The barcode encodes the document number.  I
>> have found a barcode class written in Java.  Is there a way to use Java
>> class within Zope?
>
>The reason we've been talking about PDF is that PDF files are explicitly
>designed to reproduce pages exactly as you specify, with everything
positioned
>just so. 

Perhaps I'm missing the point but, for the barcodes, why not 
just generate GIFs ? Then you could link them into webpages or
wherever. Faster, no plugins, leaves you open to choose another
format for the actual reports.

PIL is at www.pythonware.com (or go get Boutell's gd-lib if
you're that way inclined)


> Unless you use Acrobat Reader or some similar technology, you are
>going to find it very difficult to get your data to line up right on your
>pre-printed forms. HTML (the format your browser understands, and which Zope
>usually supplies) was never meant for precise positioning of page elements --
>quite the opposite, in fact.  This is a much larger problem than
generating the
>barcodes, which will depend on the document format you choose for printing.


As for reports, PDF is good for all of the reasons outlined by Evan.
However, with MSIE 4+ and absolute positioning, you CAN generate
a report with layout as precise and as good as any PDF document - 
easier and quicker to do too (I'm assuming your html and css are ok).
Stylesheets and the MSIE Client SDK are your friends.
For the reports, I'm assuming you control the end browser and this is
not for public access where some mong will be using Netscape 1.x

chas