Help with page sequences to solve memroy problem

2008-07-12 Thread Marvin Wolfthal

Hi,
I am generating a PDF that consists of a header and a data sequence,
each having a Category name and one or more Items, each with a result 
set table:

Category name
Item(+)
Result set table

I'm now running out of memory because the result sets are too large. My 
understanding is that the solution is use multiple page sequences, so 
that rendering will be done after each sequence is processed and memory 
freed up. Is there a way I can define a page sequence so that each 
Category and its group of Items will be processed as a single page? 
Currently all of my Categories and their items are being processed as a 
single huge sequence.


fo:page-sequence master-reference=data
...
fo:flow flow-name=data-region-body
fo:block
xsl:call-template name=Category select=Category/
/fo:block
fo:block
xsl:call-template name=Item select=Category/Item/
/fo:block
/fo:flow
/fo:page-sequence


The processing involves an XSL transform of an XML file with more or 
less the following structure:


Report
Category name=category_name
Item
Row
/Row
Row
...
/Item
Item
...
/Category
Category
...
/Report

Many thanks for any assistance.

Marvin Wolfthal

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Help with page sequences to solve memroy problem

2008-07-12 Thread Andreas Delmelle

On Jul 12, 2008, at 21:16, Marvin Wolfthal wrote:

Hi


I am generating a PDF that consists of a header and a data sequence,
each having a Category name and one or more Items, each with a  
result set table:

Category name
Item(+)
Result set table

I'm now running out of memory because the result sets are too  
large. My understanding is that the solution is use multiple page  
sequences, so that rendering will be done after each sequence is  
processed and memory freed up. Is there a way I can define a page  
sequence so that each Category and its group of Items will be  
processed as a single page? Currently all of my Categories and  
their items are being processed as a single huge sequence.


fo:page-sequence master-reference=data
...
fo:flow flow-name=data-region-body
fo:block
xsl:call-template name=Category select=Category/


Just FYI: note that the 'select' attribute does nothing here. Either  
you 'call' templates by name, or you 'apply' matching templates to a  
set of nodes...




The processing involves an XSL transform of an XML file with more  
or less the following structure:


snip /

Very roughly:

xsl:template match=Report
  root xmlns=...
layout-master-set.../layout-master-set
xsl:apply-templates select=Category /
  /root
/xsl:template

xsl:template match=Category
  page-sequence master-reference=data
flow flow-name=data-region-body
  blockxsl:value-of select=@name //block
  blockxsl:apply-templates select=Item //block
/flow
  /page-sequence
/xsl:template

xsl:template match=Item
  table
...

etc.


HTH!

Andreas

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Barcode fonts not displaying correctly when generating PCL

2008-07-12 Thread Martin Edge
Hi Guys

Before I start looking into the Barcode4J implementation - some warning
output was transparent to me when I initially reported this problem.

I notice now when generating the PCL - I additionally get these errors:

13/07/2008 10:46:06 org.apache.fop.fonts.truetype.TTFFile determineAscDesc
WARNING: Ascender and descender together are larger than the em box. This
could
lead to a wrong baseline placement in Apache FOP.
13/07/2008 10:46:06 org.apache.fop.fonts.truetype.TTFFile determineAscDesc
WARNING: Ascender and descender together are larger than the em box. This
could
lead to a wrong baseline placement in Apache FOP.
13/07/2008 10:46:09 org.apache.fop.events.LoggingEventListener processEvent
INFO: Adjusting end-indent based on overconstrained geometry rules for
fo:table.
 (See position 30:92)

What do these mean?

Thanks
Martin.



-Original Message-
From: Jeremias Maerki [mailto:[EMAIL PROTECTED] 
Sent: Friday, 11 July 2008 11:47 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Barcode fonts not displaying correctly when generating PCL

Try GhostPCL as an alternative (to generate a TIFF from PCL):
http://www.artifex.com/downloads/

There's a Windows binary available in PCL Downloader 2006:
http://www.cyrtech.de/progs/dl2006/dl2006.htm

On 11.07.2008 15:24:42 Martin Edge wrote:
 OK - Just tried the test by changing the source and target DPI to 300. The
 filesize of course doubled, but unfortunately using my trial version of
 RedTitan EscapeE (I hope the viewer is behaving as well) shows the barcode
 fonts still weirdly rendered.
 
 I'm guessing I'm going to have to learn the Barcode4J thing. 
 
 Thanks for the help
 Martin.
 
snip/ 


Jeremias Maerki


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Barcode fonts not displaying correctly when generating PCL

2008-07-12 Thread Martin Edge


Just to concur with David – now I’m playing with the Barcode4J extension – with 
PCL the DPI does need to be greater. It looked “reasonable” at 144 dpi, but 
increasing to 300 didn’t have much additional impact on the file size (72dpi - 
144dpi near on doubled the filesize)
Thanks
Martin.


From: David Gerdt [mailto:[EMAIL PROTECTED] 
Sent: Friday, 11 July 2008 10:45 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Barcode fonts not displaying correctly when generating PCL

Just in case it could be this simple...
 
I've only played with barcodes and I used Barcode4J, not fonts, but I had 
similar trouble with how barcodes were rendered when I first started playing 
with FOP because I didn't specify the target resolution for the PCL renderer. 
When I set it to 300 my barcodes came out right.

 Martin Edge [EMAIL PROTECTED] 7/11/2008 5:26 AM 
Hey Guys,

Just wanted to check I’m doing everything correctly.

I am having some problems displaying barcodes in PCL. 

http://www.asmorphic.net.au/images/barcodes.jpg is an example of what I’m
seeing.

As I edit the intermediate file, I have performed two tests:

- Generate AT using application/pdf then run –atin –pdf etc – and the
barcodes are displayed properly and scannable.
- Generate AT using application/vnd…..pcl etc – and the barcodes appear very
different and cannot be scanned.

I figure given the PDF renders the fonts partially, the fonts are being
properly loaded into the FOP engine. 

My fop.xconf portions for PDF and PCL has:
  fonts
  directoryc:\pdfbin\fonts\/directory
  /fonts

.. and given you can see in the image the font partially works its
definitely loading OK .. Both fonts are True Type Fonts.

The FO content which displays the barcodes:

 fo:block-container reference-orientation=90
inline-progression-dimension=680pt
fo:block font-family=3 of 9 Barcode font-size=18pt
background-color=white text-align=start*1234567890MLQIS*/fo:block
 /fo:block-container
  /fo:static-content

And 

fo:block text-align=start margin-top=115pt
margin-bottom=8pt
fo:inline font-family=Barcode 4-state
font-size=12pt
width=65mm130101221102120022002230301003013/fo:inline
fo:inline font-family=Helvetica font-size=6pt
min-height=16pt
  
border-top-width=-20mm001/01/fo:inline
 /fo:block

Is there any thing I’m obviously doing wrong here – or is there a potential
problem? If as per the research below I have to create an image it’s
possible I guess – but a bit of a pain ..

Jeremias – I found some  of your emails from 2002/2003 – I hope it’s
possible now! 

http://osdir.com/ml/krysalis.devel/2003-12/msg00010.html
http://osdir.com/ml/text.xml.fop.devel/2002-11/msg00231.html

;)

Thanks
Martin


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]