Re: Memory and page-sequences

2016-01-05 Thread Andreas Delmelle
> On 05 Jan 2016, at 22:09, robrez <resendez.j...@gmail.com> wrote:
> 
> I was delighted to learn that fop 2.0 has been released (I live under a
> rock).
> 
> For some time now we've been manually breaking up our content into multiple
> page-sequences -- many more than we would like to use.
> 
> I saw that one long page-sequence still eats memory:
> https://xmlgraphics.apache.org/fop/2.0/running.html#memory
> 
> For years now, I've been using a less-than-ideal strategy to break my
> content up into multiple page-sequences. I'm wondering if there is any hope
> that we will be able to stop doing this at some point and let the pages
> break naturally.

Not in the near future, I'm afraid... It would require a very thorough rework 
of the line- and page-breaking interaction. 

At any rate, barring forced page-breaks, what happens is that first ALL line 
breaks for the entire page-sequence are determined, and only then is control 
handed over to the page-breaking algorithm, which in turn computes the 
page-breaks based on the line-boxes. 
There have been lots of theories/ideas on improving that, but one thing is 
certain: it should start with making the basic line-breaking process 
interruptible. As long as that is not the case, it is virtually impossible to 
improve this.
Roughly: if it is more or less a certainty that there are enough line-boxes to 
fill the current page, return control to the page-breaking algorithm, so that 
there is at least an opportunity to flush, and e.g. detect page-width changes 
much earlier. Right now, such changes are only detected after all the 
line-breaks have been computed once... If they occur, the line-breaking process 
is restarted as of the point where the page-break to a new page with different 
inline-progression-dimension occurred. In the end, that could very well mean 
that a set of hundreds of line-breaks are computed for nothing, just wasting 
memory and CPU cycles.

Definitely not a trivial matter to resolve.


KR

Andreas
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: RTF - Only simple-page-masters are supported on page-sequences

2013-06-26 Thread Chris Bowditch

Hi,

Thanks for the sample FO File. Since it appears to be a bug can you log 
a bug in JIRA and attach the test FO File there. Otherwise this issue 
may get forgotten.


Thank you!

Chris

On 23/06/2013 00:27, Bonekrusher wrote:

Hi Robert,

Below is a small repo. Thanks for looking into this.

?xml version=1.0 encoding=UTF-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#;
fo:layout-master-set xmlns:xs=http://www.w3.org/2001/XMLSchema;
xmlns:fn=http://www.w3.org/2005/xpath-functions;
fo:page-sequence-master master-name=page-sequence
fo:repeatable-page-master-alternatives
fo:conditional-page-master-reference 
odd-or-even=even
master-reference=seq-page-first blank-or-not-blank=not-blank
page-position=first/
fo:conditional-page-master-reference 
odd-or-even=odd
master-reference=seq-page-odd blank-or-not-blank=not-blank/
/fo:repeatable-page-master-alternatives
/fo:page-sequence-master
fo:simple-page-master master-name=seq-page-first 
page-height=11in
page-width=8.5in margin-top=0.5in margin-left=1.0in
margin-right=0.5in
fo:region-body region-name=xsl-region-body 
margin-top=0.80in
margin-bottom=.5in overflow=auto/
fo:region-before region-name=xsl-region-before 
extent=0.5in/
fo:region-after region-name=xsl-region-after 
extent=0.5in/
/fo:simple-page-master
fo:simple-page-master master-name=seq-page-odd 
page-height=11in
page-width=8.5in margin-top=0.5in margin-left=1.0in
margin-right=0.5in
fo:region-body region-name=xsl-region-body 
margin-top=0.35in
margin-bottom=.5in overflow=auto/
fo:region-before region-name=xsl-region-before 
extent=0.5in/
fo:region-after region-name=xsl-region-after 
extent=0.5in/
/fo:simple-page-master
fo:simple-page-master master-name=alternate-blank 
page-height=11in
page-width=8.5in margin-left=1.0in margin-right=1.0in
fo:region-body/
fo:region-before region-name=header-blank 
extent=11in/
/fo:simple-page-master
/fo:layout-master-set
fo:page-sequence initial-page-number=1 force-page-count=end-on-even
format=1 master-reference=page-sequence id=ps-0006
fo:static-content flow-name=xsl-region-before
fo:blockdata/fo:block
/fo:static-content
fo:static-content flow-name=header-blank
fo:block line-height=12pt font-family=Arial 
font-size=10pt
font-weight=bold text-align=center

/fo:block
/fo:static-content
fo:static-content flow-name=xsl-region-after
fo:blockdata/fo:block
/fo:static-content
fo:flow flow-name=xsl-region-body
fo:blockdata/fo:block
/fo:flow
/fo:page-sequence
/fo:root




--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734p38793.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org






-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: RTF - Only simple-page-masters are supported on page-sequences

2013-06-26 Thread Robert Meyer
Hi,

Sorry, I have been meaning to have a look at this but I am a bit busy at the 
moment.

As Chris has said, if you log a bug I'll take a look the next chance I get.

Thanks,

Robert Meyer

 Date: Wed, 26 Jun 2013 15:52:03 +0100
 From: bowditch_ch...@hotmail.com
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: RTF - Only simple-page-masters are supported on page-sequences
 
 Hi,
 
 Thanks for the sample FO File. Since it appears to be a bug can you log 
 a bug in JIRA and attach the test FO File there. Otherwise this issue 
 may get forgotten.
 
 Thank you!
 
 Chris
 
 On 23/06/2013 00:27, Bonekrusher wrote:
  Hi Robert,
 
  Below is a small repo. Thanks for looking into this.
 
  ?xml version=1.0 encoding=UTF-8?
  fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#;
  fo:layout-master-set xmlns:xs=http://www.w3.org/2001/XMLSchema;
  xmlns:fn=http://www.w3.org/2005/xpath-functions;
  fo:page-sequence-master master-name=page-sequence
  fo:repeatable-page-master-alternatives
  fo:conditional-page-master-reference 
  odd-or-even=even
  master-reference=seq-page-first blank-or-not-blank=not-blank
  page-position=first/
  fo:conditional-page-master-reference 
  odd-or-even=odd
  master-reference=seq-page-odd blank-or-not-blank=not-blank/
  /fo:repeatable-page-master-alternatives
  /fo:page-sequence-master
  fo:simple-page-master master-name=seq-page-first 
  page-height=11in
  page-width=8.5in margin-top=0.5in margin-left=1.0in
  margin-right=0.5in
  fo:region-body region-name=xsl-region-body 
  margin-top=0.80in
  margin-bottom=.5in overflow=auto/
  fo:region-before region-name=xsl-region-before 
  extent=0.5in/
  fo:region-after region-name=xsl-region-after 
  extent=0.5in/
  /fo:simple-page-master
  fo:simple-page-master master-name=seq-page-odd 
  page-height=11in
  page-width=8.5in margin-top=0.5in margin-left=1.0in
  margin-right=0.5in
  fo:region-body region-name=xsl-region-body 
  margin-top=0.35in
  margin-bottom=.5in overflow=auto/
  fo:region-before region-name=xsl-region-before 
  extent=0.5in/
  fo:region-after region-name=xsl-region-after 
  extent=0.5in/
  /fo:simple-page-master
  fo:simple-page-master master-name=alternate-blank 
  page-height=11in
  page-width=8.5in margin-left=1.0in margin-right=1.0in
  fo:region-body/
  fo:region-before region-name=header-blank 
  extent=11in/
  /fo:simple-page-master
  /fo:layout-master-set
  fo:page-sequence initial-page-number=1 force-page-count=end-on-even
  format=1 master-reference=page-sequence id=ps-0006
  fo:static-content flow-name=xsl-region-before
  fo:blockdata/fo:block
  /fo:static-content
  fo:static-content flow-name=header-blank
  fo:block line-height=12pt font-family=Arial 
  font-size=10pt
  font-weight=bold text-align=center
  
  /fo:block
  /fo:static-content
  fo:static-content flow-name=xsl-region-after
  fo:blockdata/fo:block
  /fo:static-content
  fo:flow flow-name=xsl-region-body
  fo:blockdata/fo:block
  /fo:flow
  /fo:page-sequence
  /fo:root
 
 
 
 
  --
  View this message in context: 
  http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734p38793.html
  Sent from the FOP - Users mailing list archive at Nabble.com.
 
  -
  To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
  For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 
 
 
 
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 
  

RE: RTF - Only simple-page-masters are supported on page-sequences

2013-06-26 Thread Bonekrusher
Thanks. Logged:

https://issues.apache.org/jira/browse/FOP-2270
https://issues.apache.org/jira/browse/FOP-2270  



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734p38808.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: RTF - Only simple-page-masters are supported on page-sequences

2013-06-22 Thread Bonekrusher
Hi Robert,

Below is a small repo. Thanks for looking into this.

?xml version=1.0 encoding=UTF-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#;
fo:layout-master-set xmlns:xs=http://www.w3.org/2001/XMLSchema;
xmlns:fn=http://www.w3.org/2005/xpath-functions;
fo:page-sequence-master master-name=page-sequence
fo:repeatable-page-master-alternatives
fo:conditional-page-master-reference 
odd-or-even=even
master-reference=seq-page-first blank-or-not-blank=not-blank
page-position=first/
fo:conditional-page-master-reference 
odd-or-even=odd
master-reference=seq-page-odd blank-or-not-blank=not-blank/
/fo:repeatable-page-master-alternatives
/fo:page-sequence-master
fo:simple-page-master master-name=seq-page-first 
page-height=11in
page-width=8.5in margin-top=0.5in margin-left=1.0in
margin-right=0.5in
fo:region-body region-name=xsl-region-body 
margin-top=0.80in
margin-bottom=.5in overflow=auto/
fo:region-before region-name=xsl-region-before 
extent=0.5in/
fo:region-after region-name=xsl-region-after 
extent=0.5in/
/fo:simple-page-master
fo:simple-page-master master-name=seq-page-odd 
page-height=11in
page-width=8.5in margin-top=0.5in margin-left=1.0in
margin-right=0.5in
fo:region-body region-name=xsl-region-body 
margin-top=0.35in
margin-bottom=.5in overflow=auto/
fo:region-before region-name=xsl-region-before 
extent=0.5in/
fo:region-after region-name=xsl-region-after 
extent=0.5in/
/fo:simple-page-master
fo:simple-page-master master-name=alternate-blank 
page-height=11in
page-width=8.5in margin-left=1.0in margin-right=1.0in
fo:region-body/
fo:region-before region-name=header-blank 
extent=11in/
/fo:simple-page-master
/fo:layout-master-set
fo:page-sequence initial-page-number=1 force-page-count=end-on-even
format=1 master-reference=page-sequence id=ps-0006
fo:static-content flow-name=xsl-region-before
fo:blockdata/fo:block
/fo:static-content
fo:static-content flow-name=header-blank
fo:block line-height=12pt font-family=Arial 
font-size=10pt
font-weight=bold text-align=center

/fo:block
/fo:static-content
fo:static-content flow-name=xsl-region-after
fo:blockdata/fo:block
/fo:static-content
fo:flow flow-name=xsl-region-body
fo:blockdata/fo:block
/fo:flow
/fo:page-sequence
/fo:root




--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734p38793.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: RTF - Only simple-page-masters are supported on page-sequences

2013-06-21 Thread Robert Meyer
Hi,

The line causing the error dates back from 2008 according to git blame. It can 
be seen in the RTFHandler.java class on line 217:

this.pagemaster
= 
pageSeq.getRoot().getLayoutMasterSet().getSimplePageMaster(reference);
if (this.pagemaster == null) {
RTFEventProducer eventProducer = 
RTFEventProducer.Provider.get(
getUserAgent().getEventBroadcaster());
eventProducer.onlySPMSupported(this, reference, 
pageSeq.getLocator());
...
}

It looks as though for some reason it's not reading the simple-page-master 
correctly and is therefore null.

Would it be possible for you to provide us with a shortened example to 
reproduce the issue? You can blank out any sensitive data in the FO if there is 
any.

Thanks,

Robert Meyer

 Date: Wed, 19 Jun 2013 03:15:44 -0700
 From: djs...@yahoo.com
 To: fop-users@xmlgraphics.apache.org
 Subject: RTF - Only simple-page-masters are supported on page-sequences
 
 Hi,
 
 I had a customer yesterday request a RTF version of a document rather than a
 PDF. When I ran my FO through the Latest nightly trunk snapshot, I received
 this error. 
 
 Only simple-page-masters are supported on page-sequences. Using default
 simple-page-master from page-sequence-master warning-recto-verso-document.
 (See position 1402:42)
 Exception
 org.apache.fop.apps.FOPException
 java.lang.NullPointerException
 
 I know this use to work in older version of FOP. Is this a bug or was this
 disabled?
 
 Thanks
 
 Phil
 
 
 
 
 --
 View this message in context: 
 http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734.html
 Sent from the FOP - Users mailing list archive at Nabble.com.
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 
  

RTF - Only simple-page-masters are supported on page-sequences

2013-06-19 Thread Bonekrusher
Hi,

I had a customer yesterday request a RTF version of a document rather than a
PDF. When I ran my FO through the Latest nightly trunk snapshot, I received
this error. 

Only simple-page-masters are supported on page-sequences. Using default
simple-page-master from page-sequence-master warning-recto-verso-document.
(See position 1402:42)
Exception
org.apache.fop.apps.FOPException
java.lang.NullPointerException

I know this use to work in older version of FOP. Is this a bug or was this
disabled?

Thanks

Phil




--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/RTF-Only-simple-page-masters-are-supported-on-page-sequences-tp38734.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread aemitic
Thanks Luis Bernardo, your explanation is really helpful.

So, it is a Fop limitation. 
I shall find the good balance between fo:page-sequence blocks number and
the number of pages contained in them.

I guess this info might save a lot of time to someone else in the future.
Especially to business users who are elaborating big big data. Maybe it
should be added to the Fop website under the memory consumption notes? Just
a suggestion.

Thanks again to everyone!



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38368.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Paul Womack

aemitic wrote:

Thanks for the suggestion.

This /workaround/ (it's not a solution) cannot be applied. Why:
  - internal pdf links would not work
  - pdf bookmarks would not work
  - page numbering would not be correct
  - creating over 15 PDFs and then merging them with an external tool is
unacceptable from a performance point of view


I cannot imagine a (useful) PDF with 150,000 pages.

This may well be a limitation of my imagination :-)

Can you tell me a little about this?

 BugBear


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Kerry, Richard


Surely that's 100k documents, each with one page (or a small number of pages) ?





Uncertainly,

Richard.











Richard Kerry
BNCS Engineer
T: +44 (0)20 82259063
M: +44 (0)7812 325518
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
richard.ke...@atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=mailto%3arichard.kerry%40atos.net
uk.atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=http%3a%2f%2fuk.atos.net%2fen-uk%2f
This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos group liability cannot be triggered for the 
message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable

From: Maruan Sahyoun [sahy...@fileaffairs.de]
Sent: 19 April 2013 11:56
To: fop-users@xmlgraphics.apache.org
Subject: Re: FOP memory growing with a lot of page-sequences

Hi

e.g. we have a banking customer where account statements are produced and sent 
for printing. A single PDF has around 100k pages.

Maruan

Am 19.04.2013 um 11:04 schrieb Paul Womack 
supp...@papermule.co.ukmailto:supp...@papermule.co.uk:

aemitic wrote:
Thanks for the suggestion.

This /workaround/ (it's not a solution) cannot be applied. Why:
 - internal pdf links would not work
 - pdf bookmarks would not work
 - page numbering would not be correct
 - creating over 15 PDFs and then merging them with an external tool is
unacceptable from a performance point of view

I cannot imagine a (useful) PDF with 150,000 pages.

This may well be a limitation of my imagination :-)

Can you tell me a little about this?

BugBear


-
To unsubscribe, e-mail: 
fop-users-unsubscr...@xmlgraphics.apache.orgmailto:fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: 
fop-users-h...@xmlgraphics.apache.orgmailto:fop-users-h...@xmlgraphics.apache.org




Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Maruan Sahyoun
no - that's one document with 100k pages

Maruan Sahyoun

Am 19.04.2013 um 13:04 schrieb Kerry, Richard richard.ke...@atos.net:

  
 Surely that's 100k documents, each with one page (or a small number of pages) 
 ?
  
  
 Uncertainly,
 Richard.
  
  
  
  
  
  
 Richard Kerry
 BNCS Engineer
 T: +44 (0)20 82259063
 M: +44 (0)7812 325518
 Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
 richard.ke...@atos.net
 uk.atos.net
 
 
 
 
 
 This e-mail and the documents attached are confidential and intended solely 
 for the addressee; it may also be privileged. If you receive this e-mail in 
 error, please notify the sender immediately and destroy it. As its integrity 
 cannot be secured on the Internet, the Atos group liability cannot be 
 triggered for the message content. Although the sender endeavours to maintain 
 a computer virus-free network, the sender does not warrant that this 
 transmission is virus-free and will not be liable
 
 From: Maruan Sahyoun [sahy...@fileaffairs.de]
 Sent: 19 April 2013 11:56
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: FOP memory growing with a lot of page-sequences
 
 Hi 
 
 e.g. we have a banking customer where account statements are produced and 
 sent for printing. A single PDF has around 100k pages.
 
 Maruan
 
 Am 19.04.2013 um 11:04 schrieb Paul Womack supp...@papermule.co.uk:
 
 aemitic wrote:
 Thanks for the suggestion.
 
 This /workaround/ (it's not a solution) cannot be applied. Why:
  - internal pdf links would not work
  - pdf bookmarks would not work
  - page numbering would not be correct
  - creating over 15 PDFs and then merging them with an external tool is
 unacceptable from a performance point of view
 
 I cannot imagine a (useful) PDF with 150,000 pages.
 
 This may well be a limitation of my imagination :-)
 
 Can you tell me a little about this?
 
 BugBear
 
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 
 
 



RE: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Kerry, Richard


Yes I did understand what you wrote, and the earlier correspondent.



I was attempting to ask why.

It seems illogical to treat many small documents as one large one.  Especially 
if the large one is so large that it is hard to process.





Regards,

Richard.










[Blue line]
Richard Kerry
BNCS Engineer
T: +44 (0)20 
82259063[cid:8CFF92A-DBC6-4E1DD-83CD-7AC227DEC5@MimeCtl]about:blank#
M: +44 (0)7812 
325518[cid:8CFF92A-DBC6-4E1DD-83CD-7AC227DEC5@MimeCtl]about:blank#
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
richard.ke...@atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=mailto%3arichard.kerry%40atos.net
uk.atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=http%3a%2f%2fuk.atos.net%2fen-uk%2f
[Atos logo]
This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos group liability cannot be triggered for the 
message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable

From: Maruan Sahyoun [sahy...@fileaffairs.de]
Sent: 19 April 2013 12:04
To: fop-users@xmlgraphics.apache.org
Subject: Re: FOP memory growing with a lot of page-sequences

no - that's one document with 100k pages

Maruan Sahyoun

Am 19.04.2013 um 13:04 schrieb Kerry, Richard 
richard.ke...@atos.netmailto:richard.ke...@atos.net:




Surely that's 100k documents, each with one page (or a small number of pages) ?





Uncertainly,
Richard.











Richard Kerry
BNCS Engineer
T: +44 (0)20 82259063
M: +44 (0)7812 325518
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
richard.ke...@atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=mailto%3arichard.kerry%40atos.net
uk.atos.nethttps://webmail.siemens-it-solutions.com/owa/redir.aspx?C=9fb20d019e3e4cb99344d708709a3177URL=http%3a%2f%2fuk.atos.net%2fen-uk%2f





This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos group liability cannot be triggered for the 
message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable

From: Maruan Sahyoun [sahy...@fileaffairs.demailto:sahy...@fileaffairs.de]
Sent: 19 April 2013 11:56
To: fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org
Subject: Re: FOP memory growing with a lot of page-sequences

Hi

e.g. we have a banking customer where account statements are produced and sent 
for printing. A single PDF has around 100k pages.

Maruan

Am 19.04.2013 um 11:04 schrieb Paul Womack 
supp...@papermule.co.ukmailto:supp...@papermule.co.uk:

aemitic wrote:
Thanks for the suggestion.

This /workaround/ (it's not a solution) cannot be applied. Why:
 - internal pdf links would not work
 - pdf bookmarks would not work
 - page numbering would not be correct
 - creating over 15 PDFs and then merging them with an external tool is
unacceptable from a performance point of view

I cannot imagine a (useful) PDF with 150,000 pages.

This may well be a limitation of my imagination :-)

Can you tell me a little about this?

BugBear


-
To unsubscribe, e-mail: 
fop-users-unsubscr...@xmlgraphics.apache.orgmailto:fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: 
fop-users-h...@xmlgraphics.apache.orgmailto:fop-users-h...@xmlgraphics.apache.org






blank
Description: blank

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread paul womack

Kerry, Richard wrote:

Yes I did understand what you wrote, and the earlier correspondent.

I was attempting to ask why.

It seems illogical to treat many small documents as one large one.  Especially 
if the large one is so large that it is hard to process.


That case sounds (to me) like many documents in one large print job.

I suppose one might consider turning a whole wiki (they can get big, I'm told)
into a single hyperlinked PDF. That would be a legitimate, and fairly useful
massive PDF.

 BugBear


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Maruan Sahyoun
well - it is one print job, has paperhandling marks, goes to an envelope 
stuffing machine 

Maruan Sahyoun

Am 19.04.2013 um 14:56 schrieb Kerry, Richard richard.ke...@atos.net:

  
 Yes I did understand what you wrote, and the earlier correspondent.
  
 I was attempting to ask why.
 It seems illogical to treat many small documents as one large one.  
 Especially if the large one is so large that it is hard to process. 
  
  
 Regards,
 Richard.
  
  
  
  
  
 Richard Kerry
 BNCS Engineer
 T: +44 (0)20 82259063
 M: +44 (0)7812 325518
 Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
 richard.ke...@atos.net
 uk.atos.net
 
 
 
 
 
 This e-mail and the documents attached are confidential and intended solely 
 for the addressee; it may also be privileged. If you receive this e-mail in 
 error, please notify the sender immediately and destroy it. As its integrity 
 cannot be secured on the Internet, the Atos group liability cannot be 
 triggered for the message content. Although the sender endeavours to maintain 
 a computer virus-free network, the sender does not warrant that this 
 transmission is virus-free and will not be liable
 From: Maruan Sahyoun [sahy...@fileaffairs.de]
 Sent: 19 April 2013 12:04
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: FOP memory growing with a lot of page-sequences
 
 no - that's one document with 100k pages
 
 Maruan Sahyoun
 
 Am 19.04.2013 um 13:04 schrieb Kerry, Richard richard.ke...@atos.net:
 
  
 Surely that's 100k documents, each with one page (or a small number of 
 pages) ?
  
  
 Uncertainly,
 Richard.
  
  
  
  
  
  
 Richard Kerry
 BNCS Engineer
 T: +44 (0)20 82259063
 M: +44 (0)7812 325518
 Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
 richard.ke...@atos.net
 uk.atos.net
 
 
 
 
 
 This e-mail and the documents attached are confidential and intended solely 
 for the addressee; it may also be privileged. If you receive this e-mail in 
 error, please notify the sender immediately and destroy it. As its integrity 
 cannot be secured on the Internet, the Atos group liability cannot be 
 triggered for the message content. Although the sender endeavours to 
 maintain a computer virus-free network, the sender does not warrant that 
 this transmission is virus-free and will not be liable
 From: Maruan Sahyoun [sahy...@fileaffairs.de]
 Sent: 19 April 2013 11:56
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: FOP memory growing with a lot of page-sequences
 
 Hi 
 
 e.g. we have a banking customer where account statements are produced and 
 sent for printing. A single PDF has around 100k pages.
 
 Maruan
 
 Am 19.04.2013 um 11:04 schrieb Paul Womack supp...@papermule.co.uk:
 
 aemitic wrote:
 Thanks for the suggestion.
 
 This /workaround/ (it's not a solution) cannot be applied. Why:
  - internal pdf links would not work
  - pdf bookmarks would not work
  - page numbering would not be correct
  - creating over 15 PDFs and then merging them with an external tool is
 unacceptable from a performance point of view
 
 I cannot imagine a (useful) PDF with 150,000 pages.
 
 This may well be a limitation of my imagination :-)
 
 Can you tell me a little about this?
 
 BugBear
 
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 
 blank
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org


RE : Re: FOP memory growing with a lot of page-sequences

2013-04-19 Thread Imad Bougataya
Hi,

I am attempting to do the same kind of processing.  How did you implement 
paperhandling marks (OMR?) ? 

Regards,
Imad Bougataya
06.74.58.85.96



 Message d'origine 
De : Maruan Sahyoun sahy...@fileaffairs.de 
Date : 19/04/2013  14:36  (GMT+00:00) 
A : fop-users@xmlgraphics.apache.org 
Objet : Re: FOP memory growing with a lot of page-sequences 
 
well - it is one print job, has paperhandling marks, goes to an envelope 
stuffing machine 

Maruan Sahyoun

Am 19.04.2013 um 14:56 schrieb Kerry, Richard richard.ke...@atos.net:

 
Yes I did understand what you wrote, and the earlier correspondent.
 
I was attempting to ask why.
It seems illogical to treat many small documents as one large one.  Especially 
if the large one is so large that it is hard to process. 
 
 
Regards,
Richard.
 
 
 
 
 
Richard Kerry
BNCS Engineer
T: +44 (0)20 82259063
M: +44 (0)7812 325518
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
richard.ke...@atos.net
uk.atos.net





This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos group liability cannot be triggered for the 
message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable

From: Maruan Sahyoun [sahy...@fileaffairs.de]
Sent: 19 April 2013 12:04
To: fop-users@xmlgraphics.apache.org
Subject: Re: FOP memory growing with a lot of page-sequences

no - that's one document with 100k pages

Maruan Sahyoun

Am 19.04.2013 um 13:04 schrieb Kerry, Richard richard.ke...@atos.net:

 
Surely that's 100k documents, each with one page (or a small number of pages) ?
 
 
Uncertainly,
Richard.
 
 
 
 
 
 
Richard Kerry
BNCS Engineer
T: +44 (0)20 82259063
M: +44 (0)7812 325518
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
richard.ke...@atos.net
uk.atos.net





This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos group liability cannot be triggered for the 
message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable

From: Maruan Sahyoun [sahy...@fileaffairs.de]
Sent: 19 April 2013 11:56
To: fop-users@xmlgraphics.apache.org
Subject: Re: FOP memory growing with a lot of page-sequences

Hi 

e.g. we have a banking customer where account statements are produced and sent 
for printing. A single PDF has around 100k pages.

Maruan

Am 19.04.2013 um 11:04 schrieb Paul Womack supp...@papermule.co.uk:

aemitic wrote:
Thanks for the suggestion.

This /workaround/ (it's not a solution) cannot be applied. Why:
 - internal pdf links would not work
 - pdf bookmarks would not work
 - page numbering would not be correct
 - creating over 15 PDFs and then merging them with an external tool is
unacceptable from a performance point of view

I cannot imagine a (useful) PDF with 150,000 pages.

This may well be a limitation of my imagination :-)

Can you tell me a little about this?

BugBear


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org




blank

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread Glenn Adams
Put each page-sequence in a separate XSL-FO file.


On Thu, Apr 18, 2013 at 5:09 AM, aemitic aemi...@hotmail.it wrote:

 Hi,

 I noticed that FOP (any version) uses a constantly growing amount of memory
 when creating PDFs. Even if using very small page-sequence blocks and no
 forward references.

 Please refer to this stackoverflow question which contains a small java
 program that replicates the issue.

 How can I limit the amount of used memory when transforming to PDF an FO
 file with a huge number of page-sequence blocks? ( 25)

 Thanks for any help



 --
 View this message in context:
 http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequences-tp38355.html
 Sent from the FOP - Users mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org




Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread aemitic
@Glenn Adams-2
Could you please elaborate more?

Transforming multiple XSL-FO files with FOP would mean to produce multiple
XSL-FO files, wouldn't it?
I need to produce a single PDF.



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38360.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread Glenn Adams
use a separate tool to combine the PDFs


On Thu, Apr 18, 2013 at 8:31 AM, aemitic aemi...@hotmail.it wrote:

 @Glenn Adams-2
 Could you please elaborate more?

 Transforming multiple XSL-FO files with FOP would mean to produce multiple
 XSL-FO files, wouldn't it?
 I need to produce a single PDF.



 --
 View this message in context:
 http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38360.html
 Sent from the FOP - Users mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org




Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread aemitic
Thanks for the suggestion.

This /workaround/ (it's not a solution) cannot be applied. Why:
 - internal pdf links would not work
 - pdf bookmarks would not work
 - page numbering would not be correct
 - creating over 15 PDFs and then merging them with an external tool is
unacceptable from a performance point of view




--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38362.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread Glenn Adams
It depends on what tool you use to combine them. In any case, I don't think
you will find an alternative any time soon. Just a heads up. If you care to
create a patch that solves this problem, then please post it and I'll make
sure it is applied ASAP.


On Thu, Apr 18, 2013 at 9:01 AM, aemitic aemi...@hotmail.it wrote:

 Thanks for the suggestion.

 This /workaround/ (it's not a solution) cannot be applied. Why:
  - internal pdf links would not work
  - pdf bookmarks would not work
  - page numbering would not be correct
  - creating over 15 PDFs and then merging them with an external tool is
 unacceptable from a performance point of view




 --
 View this message in context:
 http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38362.html
 Sent from the FOP - Users mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org




Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread Maruan Sahyoun
I'm not a fop expert but

o could you render individual page-sequences to the intermediate format
o stitch the intermediate results together
o do the final rendering based on the intermediate format

Just an idea. Don't know if that would work. I also think that merging 15 
PDF's is not ideal (although I have done that for a banking customer)

Maruan Sahyoun

Am 18.04.2013 um 17:01 schrieb aemitic aemi...@hotmail.it:

 Thanks for the suggestion.
 
 This /workaround/ (it's not a solution) cannot be applied. Why:
 - internal pdf links would not work
 - pdf bookmarks would not work
 - page numbering would not be correct
 - creating over 15 PDFs and then merging them with an external tool is
 unacceptable from a performance point of view
 
 
 
 
 --
 View this message in context: 
 http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequence-blocks-25-tp38355p38362.html
 Sent from the FOP - Users mailing list archive at Nabble.com.
 
 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 



Re: FOP memory growing with a lot of page-sequences

2013-04-18 Thread Luis Bernardo


You can't. Although it is true that memory is regained when a page is 
output, there is information that needs to be kept till the end, and 
that information keeps growing as you add pages. For instance, byte 
offsets for the objects need to be stored till the end to build the xref 
table, and right now all that is kept in memory.


You can get somewhat better results if you allow your page sequences to 
have more than one page (say, 100 or 1000). Putting all the pages in one 
page-sequence will not work either because you will run out of memory 
during the initial phase of building the FO tree.


On the other hand you can always increase the memory your jvm uses.

On 4/18/13 12:09 PM, aemitic wrote:

Hi,

I noticed that FOP (any version) uses a constantly growing amount of memory
when creating PDFs. Even if using very small page-sequence blocks and no
forward references.

Please refer to this stackoverflow question which contains a small java
program that replicates the issue.

How can I limit the amount of used memory when transforming to PDF an FO
file with a huge number of page-sequence blocks? ( 25)

Thanks for any help



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/FOP-memory-growing-with-a-lot-of-page-sequences-tp38355.html
Sent from the FOP - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org




-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Multiple Page Sequences

2011-11-07 Thread KAMOHELO MOFOKENG
Hi All,
 
I'm trying to create multiple page sequences during XSL-FO to PDF 
transformation so that I don't run out of memory (in case of large xml data).
 
Using the example - http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, 
I modified my XSL-FO as follows: 
 xsl:template 
match=/fo:rootxmlns:fo=http://www.w3.org/1999/XSL/Format;xsl:call-template
 
name=LAYOUT/xsl:choosefo:declarationsxsl:if
 test=count(ROOT/MEM-STMT/ACC/PROV) lt; 
20xsl:call-template 
name=MEM-TOTALS/xsl:call-template 
name=F-OTHER/xsl:call-template 
name=DUE/xsl:call-template 
name=REASON/ fo:page-sequencemaster-reference=pre-printfo:static-content fo:blockxsl:call-template
 
name=HEADER/ /fo:static-contentfo:static-content fo:blocktext-align=centerxsl:call-template
 name=FOOT/ 
/fo:static-contentfo:flowflow-name=xsl-region-body
 fo:blockxsl:choosexsl:when 
test=ROOT/MEM-STMT/FIN-BAL/FIN-BAMT 
!='0'fo:blockxsl:call-template 
name=FIN-BAL//fo:block/xsl:when/xsl:choosexsl:call-template
 name=PROVIDER/xsl:call-template 
name=MEM-TOTALS/xsl:call-template 
name=F-OTHER/xsl:call-template 
name=DUE/xsl:call-template 
name=REASON/ /fo:flow/fo:page-sequence/xsl:whenxsl:otherwisefo:page-sequencemaster-reference=globalfo:static-contentflow-name=xsl-region-before-firstfo:blockxsl:call-template
 
name=HEADER//fo:block/fo:static-contentfo:static-contentflow-name=xsl-region-afterfo:blocktext-align=centerxsl:call-template
 
name=FOOT//fo:block/fo:static-contentfo:flowflow-name=xsl-region-bodyfo:blockxsl:choosexsl:when
 test=ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'fo:blockxsl:call-template 
name=FIN-BAL//fo:block/xsl:when/xsl:choosexsl:if 
test=count(ROOT/MEM-STMT/ACC/PROV)=20xsl:call-template 
name=PROVIDER/xsl:call-template name=MEM-TOTALS/xsl:call-template 
name=F-OTHER/xsl:call-template name=DUE/xsl:call-template 
name=REASON//xsl:if/fo:block/fo:flow/fo:page-sequence/xsl:otherwise//xsl:choose/fo:rootxsl:template
 
The transformation works but FOP doesn't print all the pages of the resultant 
pdf file (prints 94 instead of 307).
 
How should I change my XSL-FO to make FOP print all pages?
 
Any help is appreciated.
 
Regards,
Kamo /fo:block /fo:blockflow-name=xsl-region-after /fo:blockflow-name=xsl-region-before-first/xsl:if/fo:declarationsxsl:call-template
 name=PROVIDER/xsl:when test=ROOT/MEM-STMT/COUNTRY ='MU'


Re: Multiple Page Sequences

2011-11-07 Thread Glenn Adams
   - specify a larger JVM heap size when running FOP
   - increase VM paging area allocation
   - buy more memory
   - divide your FOP file into multiple files, processed separately (rather
   than multiple page sequences in one document)


On Mon, Nov 7, 2011 at 1:07 AM, KAMOHELO MOFOKENG kamohelo2...@yahoo.comwrote:


 The transformation works but FOP doesn't print all the pages of the
 resultant pdf file (prints 94 instead of 307).

 How should I change my XSL-FO to make FOP print all pages?



Re: Multiple Page Sequences

2011-11-07 Thread KAMOHELO MOFOKENG
Hi Glenn,
 
Thanks for the prompt response.
  specify a larger JVM heap size when running FOP
I have done this - no change
 
 increase VM paging area allocation
I have done this - no change
 
 buy more memory
I have sufficient memory to run FOP transformation as evidenced when I run the 
transformation through XMLSpy  test_print_pdf. This problem occurs when I run 
the transformation through a Java code.
 
 divide your FOP file into multiple files, processed separately (rather than 
 multiple page sequences in one document)
Unfortunately for me, users want one file for each xml data transformation. I 
don't understand, why is not good idea to create multiple page sequences in one 
document?
 
Regards,
Kamo
 


From: Glenn Adams gl...@skynav.com
To: fop-users@xmlgraphics.apache.org; KAMOHELO MOFOKENG kamohelo2...@yahoo.com
Sent: Monday, November 7, 2011 10:20 AM
Subject: Re: Multiple Page Sequences


* specify a larger JVM heap size when running FOP
* increase VM paging area allocation
* buy more memory
* divide your FOP file into multiple files, processed separately 
(rather than multiple page sequences in one document)


On Mon, Nov 7, 2011 at 1:07 AM, KAMOHELO MOFOKENG kamohelo2...@yahoo.com 
wrote:



The transformation works but FOP doesn't print all the pages of the resultant 
pdf file (prints 94 instead of 307).

How should I change my XSL-FO to make FOP print all pages?

Re: Multiple Page Sequences

2011-11-07 Thread Glenn Adams
On Mon, Nov 7, 2011 at 1:33 AM, KAMOHELO MOFOKENG kamohelo2...@yahoo.comwrote:

 Hi Glenn,

 Thanks for the prompt response.

  specify a larger JVM heap size when running FOP
 I have done this - no change



You may need to verify that the larger JVM heap size is really in effect.
For example, by using memory monitoring utilities according to your OS to
see if your change is allowing FOP to use a larger VM space.


   increase VM paging area allocation
 I have done this - no change

  buy more memory
 I have sufficient memory to run FOP transformation as evidenced when I run
 the transformation through XMLSpy  test_print_pdf. This problem occurs
 when I run the transformation through a Java code.

  divide your FOP file into multiple files, processed separately (rather
 than multiple page sequences in one document)
 Unfortunately for me, users want one file for each xml data
 transformation. I don't understand, why is not good idea to create multiple
 page sequences in one document?



You asked for ideas about how to make it succeed. This is one idea. If it
works, then you may try it and find a way to combine the resultant multiple
page sequences into a single document using another tool.


 Regards,
 Kamo

   *From:* Glenn Adams gl...@skynav.com
 *To:* fop-users@xmlgraphics.apache.org; KAMOHELO MOFOKENG 
 kamohelo2...@yahoo.com
 *Sent:* Monday, November 7, 2011 10:20 AM
 *Subject:* Re: Multiple Page Sequences


- specify a larger JVM heap size when running FOP
- increase VM paging area allocation
- buy more memory
- divide your FOP file into multiple files, processed separately
(rather than multiple page sequences in one document)


 On Mon, Nov 7, 2011 at 1:07 AM, KAMOHELO MOFOKENG 
 kamohelo2...@yahoo.comwrote:


 The transformation works but FOP doesn't print all the pages of the
 resultant pdf file (prints 94 instead of 307).

 How should I change my XSL-FO to make FOP print all pages?






Re: Multiple Page Sequences

2011-11-07 Thread Rob Sargent
How large is the final pdf? That you do get a viewable pdf suggests that 
the process finished with out error.  Is that the case?


Is the document simply truncated or does it miss particular pieces of 
content?


How you looked at the resultant fo file (output of xsl transformation)?


KAMOHELO MOFOKENG wrote:

Hi All,
 
I'm trying to create multiple page sequences during XSL-FO to PDF 
transformation so that I don't run out of memory (in case of large xml 
data).
 
Using the 
example - http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, 
I modified my XSL-FO as follows: 
 
**

*xsl:template match*=///**
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
*xsl:call-template name*=/LAYOUT/*/*
*xsl:choose*
*xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
fo:declarations
*xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV) 
lt; 20/**

*xsl:call-template name*=/PROVIDER/*/*
***xsl:call-template name*=/MEM-TOTALS/*/*
*xsl:call-template name=/F-OTHER/**/*
*xsl:call-template name=/DUE/**/*
*xsl:call-template name=/REASON/**/*
***/xsl:if*
/fo:declarations
 
fo:page-sequence master-reference=pre-print

fo:static-content
flow-name=xsl-region-before-first
 
fo:block

*xsl:call-template name*=/HEADER/*/*
/fo:block
 
/fo:static-content
 
fo:static-content

flow-name=xsl-region-after
 
fo:block text-align=center

*xsl:call-template name*=/FOOT/*/*
/fo:block
 
/fo:static-content
 
fo:flow flow-name=xsl-region-body
 
fo:block

*xsl:choose*
*xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
fo:block
*xsl:call-template name*=/FIN-BAL/*/*
/fo:block
*/xsl:when*
*/xsl:choose*
*xsl:call-template name*=/PROVIDER/*/*
*xsl:call-template name*=/MEM-TOTALS/*/*
*xsl:call-template name*=/F-OTHER/*/*
*xsl:call-template name*=/DUE/*/*
*xsl:call-template name*=/REASON/*/*
/fo:block
 
/fo:flow

/fo:page-sequence
*/xsl:when*
 
*xsl:otherwise*

fo:page-sequence master-reference=global
fo:static-content
flow-name=xsl-region-before-first
 
fo:block

*xsl:call-template name*=/HEADER/*/*
/fo:block
 
/fo:static-content
 
fo:static-content

flow-name=xsl-region-after
 
fo:block text-align=center

*xsl:call-template name*=/FOOT/*/*
/fo:block
/fo:static-content
fo:flow flow-name=xsl-region-body
fo:block
*xsl:choose*
*xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
fo:block
*xsl:call-template name*=/FIN-BAL/*/*
/fo:block
*/xsl:when*
*/xsl:choose*
*xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/**
*xsl:call-template name*=/PROVIDER/*/*
*xsl:call-template name*=/MEM-TOTALS/*/*
*xsl:call-template name*=/F-OTHER/*/*
*xsl:call-template name*=/DUE/*/*
*xsl:call-template name*=/REASON/*/*
*/xsl:if*
/fo:block
/fo:flow
/fo:page-sequence
*/xsl:otherwise*
*/xsl:choose*
/fo:root
**
*/**xsl:template*
 
The transformation works but FOP doesn't print all the pages of the 
resultant pdf file (prints 94 instead of 307).
 
How should I change my XSL-FO to make FOP print all pages?
 
Any help is appreciated.
 
Regards,

Kamo


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: Multiple Page Sequences

2011-11-07 Thread KAMOHELO MOFOKENG
Hi Rob,
 
Much appreciation for the response.
 
 How large is the final pdf? That you do get a viewable pdf suggests that 
 the process finished with out error.  Is that the case?
1.6MB (this is when I use either XMLSpy or test_print_pdf). Yes, the process 
completes without an error.
 
 Is the document simply truncated or does it miss particular pieces of 
 content?
It misses pieces of content, specifically PROVIDER list.
 
 How you looked at the resultant fo file (output of xsl transformation)?
I don't quite understand your question. The resultant file is a pdf so I'm 
using acrobat reader to view it.

Regards,
Kamohelo
 


From: Rob Sargent rsarg...@xmission.com
To: fop-users@xmlgraphics.apache.org
Sent: Monday, November 7, 2011 3:25 PM
Subject: Re: Multiple Page Sequences

How large is the final pdf? That you do get a viewable pdf suggests that the 
process finished with out error.  Is that the case?

Is the document simply truncated or does it miss particular pieces of content?

How you looked at the resultant fo file (output of xsl transformation)?


KAMOHELO MOFOKENG wrote:
 Hi All,
  I'm trying to create multiple page sequences during XSL-FO to PDF 
transformation so that I don't run out of memory (in case of large xml data).
  Using the example - 
http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, I modified my 
XSL-FO as follows:  **
 *xsl:template match*=///**
        fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
 *        xsl:call-template name*=/LAYOUT/*/*
 *        xsl:choose*
 *            xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
                fo:declarations
 *                    xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV) lt; 
 20/**
 *                        xsl:call-template name*=/PROVIDER/*/*
 *                        **xsl:call-template name*=/MEM-TOTALS/*/*
 *                        xsl:call-template name=/F-OTHER/**/*
 *                        xsl:call-template name=/DUE/**/*
 *                        xsl:call-template name=/REASON/**/*
 *                    **/xsl:if*
                /fo:declarations
      fo:page-sequence master-reference=pre-print
        fo:static-content
            flow-name=xsl-region-before-first
          fo:block
 *            xsl:call-template name*=/HEADER/*/*
        /fo:block
      /fo:static-content
      fo:static-content
        flow-name=xsl-region-after
      fo:block text-align=center
 *        xsl:call-template name*=/FOOT/*/*
    /fo:block
      /fo:static-content
      fo:flow flow-name=xsl-region-body
      fo:block
 *        xsl:choose*
 *            xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
                fo:block
 *                    xsl:call-template name*=/FIN-BAL/*/*
                /fo:block
 *            /xsl:when*
 *        /xsl:choose*
 *        xsl:call-template name*=/PROVIDER/*/*
 *        xsl:call-template name*=/MEM-TOTALS/*/*
 *        xsl:call-template name*=/F-OTHER/*/*
 *        xsl:call-template name*=/DUE/*/*
 *        xsl:call-template name*=/REASON/*/*
 /fo:block
  /fo:flow
 /fo:page-sequence
 */xsl:when*
  *xsl:otherwise*
 fo:page-sequence master-reference=global
 fo:static-content
 flow-name=xsl-region-before-first
  fo:block
 *    xsl:call-template name*=/HEADER/*/*
 /fo:block
  /fo:static-content
  fo:static-content
 flow-name=xsl-region-after
  fo:block text-align=center
 *xsl:call-template name*=/FOOT/*/*
 /fo:block
 /fo:static-content
 fo:flow flow-name=xsl-region-body
 fo:block
 *xsl:choose*
 *xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
 fo:block
 *xsl:call-template name*=/FIN-BAL/*/*
 /fo:block
 */xsl:when*
 */xsl:choose*
 *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/**
 *xsl:call-template name*=/PROVIDER/*/*
 *xsl:call-template name*=/MEM-TOTALS/*/*
 *xsl:call-template name*=/F-OTHER/*/*
 *xsl:call-template name*=/DUE/*/*
 *xsl:call-template name*=/REASON/*/*
 */xsl:if*
 /fo:block
 /fo:flow
 /fo:page-sequence
 */xsl:otherwise*
 */xsl:choose*
 /fo:root
 **
 */**xsl:template*
  The transformation works but FOP doesn't print all the pages of the 
resultant pdf file (prints 94 instead of 307).
  How should I change my XSL-FO to make FOP print all pages?
  Any help is appreciated.
  Regards,
 Kamo

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

AW: Multiple Page Sequences

2011-11-07 Thread Georg Datterl
Hi Kamohelo,

Are you sure your transformation is correct? Did you check whether the missing 
data is still there after transforming your XML, before you generate a PDF?

Mit freundlichen Grüßen

Georg Datterl

-- Kontakt --

Georg Datterl

Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg

HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20

www.geneon.dehttp://www.geneon.de

Weitere Mitglieder der Willmy MediaGroup:

IRS Integrated Realization Services GmbH:
www.irs-nbg.dehttp://www.irs-nbg.de
Willmy PrintMedia GmbH:  www.willmy.dehttp://www.willmy.de
Willmy Consult  Content GmbH:   
www.willmycc.dehttp://www.willmycc.de

Von: KAMOHELO MOFOKENG [mailto:kamohelo2...@yahoo.com]
Gesendet: Montag, 7. November 2011 15:19
An: fop-users@xmlgraphics.apache.org
Betreff: Re: Multiple Page Sequences

Hi Rob,

Much appreciation for the response.

 How large is the final pdf? That you do get a viewable pdf suggests that 
 the process finished with out error.  Is that the case?
1.6MB (this is when I use either XMLSpy or test_print_pdf). Yes, the process 
completes without an error.

 Is the document simply truncated or does it miss particular pieces of 
 content?
It misses pieces of content, specifically PROVIDER list.

 How you looked at the resultant fo file (output of xsl transformation)?
I don't quite understand your question. The resultant file is a pdf so I'm 
using acrobat reader to view it.

Regards,
Kamohelo

From: Rob Sargent rsarg...@xmission.commailto:rsarg...@xmission.com
To: fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org
Sent: Monday, November 7, 2011 3:25 PM
Subject: Re: Multiple Page Sequences

How large is the final pdf? That you do get a viewable pdf suggests that the 
process finished with out error.  Is that the case?

Is the document simply truncated or does it miss particular pieces of content?

How you looked at the resultant fo file (output of xsl transformation)?


KAMOHELO MOFOKENG wrote:
 Hi All,
  I'm trying to create multiple page sequences during XSL-FO to PDF 
 transformation so that I don't run out of memory (in case of large xml data).
  Using the example - 
 http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, I modified my 
 XSL-FO as follows:  **
 *xsl:template match*=///**
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
 *xsl:call-template name*=/LAYOUT/*/*
 *xsl:choose*
 *xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
fo:declarations
 *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV) lt; 
 20/**
 *xsl:call-template name*=/PROVIDER/*/*
 ***xsl:call-template name*=/MEM-TOTALS/*/*
 *xsl:call-template name=/F-OTHER/**/*
 *xsl:call-template name=/DUE/**/*
 *xsl:call-template name=/REASON/**/*
 ***/xsl:if*
/fo:declarations
  fo:page-sequence master-reference=pre-print
fo:static-content
flow-name=xsl-region-before-first
  fo:block
 *xsl:call-template name*=/HEADER/*/*
/fo:block
  /fo:static-content
  fo:static-content
flow-name=xsl-region-after
  fo:block text-align=center
 *xsl:call-template name*=/FOOT/*/*
/fo:block
  /fo:static-content
  fo:flow flow-name=xsl-region-body
  fo:block
 *xsl:choose*
 *xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
fo:block
 *xsl:call-template name*=/FIN-BAL/*/*
/fo:block
 */xsl:when*
 */xsl:choose*
 *xsl:call-template name*=/PROVIDER/*/*
 *xsl:call-template name*=/MEM-TOTALS/*/*
 *xsl:call-template name*=/F-OTHER/*/*
 *xsl:call-template name*=/DUE/*/*
 *xsl:call-template name*=/REASON/*/*
 /fo:block
  /fo:flow
 /fo:page-sequence
 */xsl:when*
  *xsl:otherwise*
 fo:page-sequence master-reference=global
 fo:static-content
 flow-name=xsl-region-before-first
  fo:block
 *xsl:call-template name*=/HEADER/*/*
 /fo:block
  /fo:static-content
  fo:static-content
 flow-name=xsl-region-after
  fo:block text-align=center
 *xsl:call-template name*=/FOOT/*/*
 /fo:block
 /fo:static-content
 fo:flow flow-name=xsl-region-body
 fo:block
 *xsl:choose*
 *xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
 fo:block
 *xsl:call-template name*=/FIN-BAL/*/*
 /fo:block
 */xsl:when*
 */xsl:choose*
 *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/**
 *xsl:call-template name*=/PROVIDER/*/*
 *xsl:call-template name*=/MEM-TOTALS/*/*
 *xsl:call-template name*=/F-OTHER/*/*
 *xsl:call-template name*=/DUE/*/*
 *xsl:call-template name*=/REASON/*/*
 */xsl:if*
 /fo:block
 /fo:flow
 /fo:page-sequence
 */xsl:otherwise*
 */xsl:choose*
 /fo:root
 **
 */**xsl:template*
  The transformation

Re: Multiple Page Sequences

2011-11-07 Thread KAMOHELO MOFOKENG
Hi Glenn,
 
I really appreciate the ideas that you are contributing towards the solution of 
this problem.
 
I'm just limited by user's requirements+costs in terms of how I'm expected 
to deliver this solution.
 
The fact is that my piece of code already works for smaller sized files  since 
this has already been accepted because it fits the requirements. I'm looking to 
extend it to cater for bigger files as well.
 
Regards,
Kamo



From: Glenn Adams gl...@skynav.com
To: fop-users@xmlgraphics.apache.org; KAMOHELO MOFOKENG kamohelo2...@yahoo.com
Sent: Monday, November 7, 2011 3:18 PM
Subject: Re: Multiple Page Sequences





On Mon, Nov 7, 2011 at 1:33 AM, KAMOHELO MOFOKENG kamohelo2...@yahoo.com 
wrote:

Hi Glenn,
 
Thanks for the prompt response.
  specify a larger JVM heap size when running FOP
I have done this - no change


You may need to verify that the larger JVM heap size is really in effect. For 
example, by using memory monitoring utilities according to your OS to see if 
your change is allowing FOP to use a larger VM space.

 increase VM paging area allocation
I have done this - no change

 buy more memory
I have sufficient memory to run FOP transformation as evidenced when I run the 
transformation through XMLSpy  test_print_pdf. This problem occurs when I run 
the transformation through a Java code.

 divide your FOP file into multiple files, processed separately (rather 
 than multiple page sequences in one document)
Unfortunately for me, users want one file for each xml data transformation. I 
don't understand, why is not good idea to create multiple page sequences in 
one document?


You asked for ideas about how to make it succeed. This is one idea. If it 
works, then you may try it and find a way to combine the resultant multiple 
page sequences into a single document using another tool.

Regards,
Kamo
 
From: Glenn Adams gl...@skynav.com
To: fop-users@xmlgraphics.apache.org; KAMOHELO MOFOKENG 
kamohelo2...@yahoo.com
Sent: Monday, November 7, 2011 10:20 AM
Subject: Re: Multiple Page Sequences


   * specify a larger JVM heap size when running FOP
   * increase VM paging area allocation
   * buy more memory
   * divide your FOP file into multiple files, processed separately 
 (rather than multiple page sequences in one document)


On Mon, Nov 7, 2011 at 1:07 AM, KAMOHELO MOFOKENG kamohelo2...@yahoo.com 
wrote:



The transformation works but FOP doesn't print all the pages of the resultant 
pdf file (prints 94 instead of 307).

How should I change my XSL-FO to make FOP print all pages?



Re: AW: Multiple Page Sequences

2011-11-07 Thread KAMOHELO MOFOKENG
Hi Georg,
 
Thanks for the response.
 
 Are you sure your transformation is correct?
Yes, it works well for smaller files.
 
 Did you check whether the missing data is still there after transforming 
 your XML, before you generate a PDF?
The missing data is still there. On closer look, I think that my xsl file is 
not executing the if-statement: xsl:if 
test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/, which could only mean that the 
if-condition is always false.
 
Regards,
Kamo
 




From: Georg Datterl georg.datt...@geneon.de
To: fop-users@xmlgraphics.apache.org fop-users@xmlgraphics.apache.org; 
KAMOHELO MOFOKENG kamohelo2...@yahoo.com
Sent: Monday, November 7, 2011 4:22 PM
Subject: AW: Multiple Page Sequences

Hi Kamohelo,
 
Are you sure your transformation is correct? Did you check whether the missing 
data is still there after transforming your XML, before you generate a PDF?
 
Mit freundlichen Grüßen
 
Georg Datterl
 
-- Kontakt --
 
Georg Datterl
 
Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg
 
HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert 
 
Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20
 
www.geneon.de
 
Weitere Mitglieder der Willmy MediaGroup:
 
IRS Integrated Realization Services GmbH:    www.irs-nbg.de
Willmy PrintMedia GmbH:  www.willmy.de
Willmy Consult  Content GmbH:   www.willmycc.de
 
Von:KAMOHELO MOFOKENG [mailto:kamohelo2...@yahoo.com] 
Gesendet: Montag, 7. November 2011 15:19
An: fop-users@xmlgraphics.apache.org
Betreff: Re: Multiple Page Sequences
 
Hi Rob,
 
Much appreciation for the response.
 
 How large is the final pdf? That you do get a viewable pdf suggests that 
 the process finished with out error.  Is that the case?
1.6MB (this is when I use either XMLSpy or test_print_pdf). Yes, the process 
completes without an error.
 
 Is the document simply truncated or does it miss particular pieces of 
 content?
It misses pieces of content, specifically PROVIDER list.
 
 How you looked at the resultant fo file (output of xsl transformation)?
I don't quite understand your question. The resultant file is a pdf so I'm 
using acrobat reader to view it.

Regards,
Kamohelo
 
From:Rob Sargent rsarg...@xmission.com
To: fop-users@xmlgraphics.apache.org
Sent: Monday, November 7, 2011 3:25 PM
Subject: Re: Multiple Page Sequences

How large is the final pdf? That you do get a viewable pdf suggests that the 
process finished with out error.  Is that the case?

Is the document simply truncated or does it miss particular pieces of content?

How you looked at the resultant fo file (output of xsl transformation)?


KAMOHELO MOFOKENG wrote:
 Hi All,
  I'm trying to create multiple page sequences during XSL-FO to PDF 
transformation so that I don't run out of memory (in case of large xml data).
  Using the example - 
http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, I modified my 
XSL-FO as follows:  **
 *xsl:template match*=///**
        fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
 *        xsl:call-template name*=/LAYOUT/*/*
 *        xsl:choose*
 *            xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
                fo:declarations
 *                    xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV) lt; 
 20/**
 *                        xsl:call-template name*=/PROVIDER/*/*
 *                        **xsl:call-template name*=/MEM-TOTALS/*/*
 *                        xsl:call-template name=/F-OTHER/**/*
 *                        xsl:call-template name=/DUE/**/*
 *                        xsl:call-template name=/REASON/**/*
 *                    **/xsl:if*
                /fo:declarations
      fo:page-sequence master-reference=pre-print
        fo:static-content
            flow-name=xsl-region-before-first
          fo:block
 *            xsl:call-template name*=/HEADER/*/*
        /fo:block
      /fo:static-content
      fo:static-content
        flow-name=xsl-region-after
      fo:block text-align=center
 *        xsl:call-template name*=/FOOT/*/*
    /fo:block
      /fo:static-content
      fo:flow flow-name=xsl-region-body
      fo:block
 *        xsl:choose*
 *            xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
                fo:block
 *                    xsl:call-template name*=/FIN-BAL/*/*
                /fo:block
 *            /xsl:when*
 *        /xsl:choose*
 *        xsl:call-template name*=/PROVIDER/*/*
 *        xsl:call-template name*=/MEM-TOTALS/*/*
 *        xsl:call-template name*=/F-OTHER/*/*
 *        xsl:call-template name*=/DUE/*/*
 *        xsl:call-template name*=/REASON/*/*
 /fo:block
  /fo:flow
 /fo:page-sequence
 */xsl:when*
  *xsl:otherwise*
 fo:page-sequence master-reference=global
 fo:static-content
 flow-name=xsl-region-before-first
  fo:block
 *    xsl:call-template name*=/HEADER/*/*
 /fo:block
  /fo:static-content
  fo:static-content
 flow-name=xsl-region-after
  fo:block text-align=center
 *xsl:call-template name*=/FOOT/*/*
 /fo:block

AW: AW: Multiple Page Sequences

2011-11-07 Thread Georg Datterl
Hi Kamohelo,

Maybe we are talking about different things. Your xsl-file transforms your xml 
file into a fo-file. This fo file ist then transformed to pdf by FOP. IF your 
data survived the first transformation (which I highly doubt), then it would be 
a FOP problem. If the data is already gone after the first transformation, your 
transformation is incorrect. For example, because something is always false.

Regards,

Georg Datterl

-- Kontakt --

Georg Datterl

Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg

HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20

www.geneon.dehttp://www.geneon.de

Weitere Mitglieder der Willmy MediaGroup:

IRS Integrated Realization Services GmbH:
www.irs-nbg.dehttp://www.irs-nbg.de
Willmy PrintMedia GmbH:  www.willmy.dehttp://www.willmy.de
Willmy Consult  Content GmbH:   
www.willmycc.dehttp://www.willmycc.de

Von: KAMOHELO MOFOKENG [mailto:kamohelo2...@yahoo.com]
Gesendet: Montag, 7. November 2011 15:29
An: Georg Datterl; fop-users@xmlgraphics.apache.org
Betreff: Re: AW: Multiple Page Sequences

Hi Georg,

Thanks for the response.

 Are you sure your transformation is correct?
Yes, it works well for smaller files.

 Did you check whether the missing data is still there after transforming 
 your XML, before you generate a PDF?
The missing data is still there. On closer look, I think that my xsl file is 
not executing the if-statement: xsl:if 
test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/, which could only mean that the 
if-condition is always false.

Regards,
Kamo

From: Georg Datterl georg.datt...@geneon.demailto:georg.datt...@geneon.de
To: fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org 
fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org; 
KAMOHELO MOFOKENG kamohelo2...@yahoo.commailto:kamohelo2...@yahoo.com
Sent: Monday, November 7, 2011 4:22 PM
Subject: AW: Multiple Page Sequences
Hi Kamohelo,

Are you sure your transformation is correct? Did you check whether the missing 
data is still there after transforming your XML, before you generate a PDF?

Mit freundlichen Grüßen

Georg Datterl

-- Kontakt --

Georg Datterl

Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg

HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20

www.geneon.dehttp://www.geneon.de/

Weitere Mitglieder der Willmy MediaGroup:

IRS Integrated Realization Services GmbH:
www.irs-nbg.dehttp://www.irs-nbg.de/
Willmy PrintMedia GmbH:  
www.willmy.dehttp://www.willmy.de/
Willmy Consult  Content GmbH:   
www.willmycc.dehttp://www.willmycc.de/

Von: KAMOHELO MOFOKENG [mailto:kamohelo2...@yahoo.com]
Gesendet: Montag, 7. November 2011 15:19
An: fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org
Betreff: Re: Multiple Page Sequences

Hi Rob,

Much appreciation for the response.

 How large is the final pdf? That you do get a viewable pdf suggests that 
 the process finished with out error.  Is that the case?
1.6MB (this is when I use either XMLSpy or test_print_pdf). Yes, the process 
completes without an error.

 Is the document simply truncated or does it miss particular pieces of 
 content?
It misses pieces of content, specifically PROVIDER list.

 How you looked at the resultant fo file (output of xsl transformation)?
I don't quite understand your question. The resultant file is a pdf so I'm 
using acrobat reader to view it.

Regards,
Kamohelo

From: Rob Sargent rsarg...@xmission.commailto:rsarg...@xmission.com
To: fop-users@xmlgraphics.apache.orgmailto:fop-users@xmlgraphics.apache.org
Sent: Monday, November 7, 2011 3:25 PM
Subject: Re: Multiple Page Sequences

How large is the final pdf? That you do get a viewable pdf suggests that the 
process finished with out error.  Is that the case?

Is the document simply truncated or does it miss particular pieces of content?

How you looked at the resultant fo file (output of xsl transformation)?


KAMOHELO MOFOKENG wrote:
 Hi All,
  I'm trying to create multiple page sequences during XSL-FO to PDF 
 transformation so that I don't run out of memory (in case of large xml data).
  Using the example - 
 http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, I modified my 
 XSL-FO as follows:  **
 *xsl:template match*=///**
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
 *xsl:call-template name*=/LAYOUT/*/*
 *xsl:choose*
 *xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
fo:declarations
 *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV) lt; 
 20/**
 *xsl:call-template name*=/PROVIDER/*/*
 ***xsl:call-template name*=/MEM-TOTALS/*/*
 *xsl:call-template name=/F-OTHER/**/*
 *xsl:call-template name=/DUE

Re: Multiple Page Sequences

2011-11-07 Thread Rob Sargent


On 11/07/2011 07:18 AM, KAMOHELO MOFOKENG wrote:
 Hi Rob,
  
 Much appreciation for the response.
  
  How large is the final pdf? That you do get a viewable pdf suggests
 that the process finished with out error.  Is that the case?
 1.6MB (this is when I use either XMLSpy or test_print_pdf). Yes, the
 process completes without an error.
  
  Is the document simply truncated or does it miss particular pieces
 of content?
 It misses pieces of content, specifically PROVIDER list.
Then you xsl is not transforming that data (not copying the content from
the source to the fo file) which is then renderered as pdf.  The fo
file is an xml file with you content wrapped in fo directives.  The
renderer then uses that to make a pdf (or richtext or...)

  
  How you looked at the resultant fo file (output of xsl
 transformation)?
 I don't quite understand your question. The resultant file is a pdf so
 I'm using acrobat reader to view it.

 Regards,
 Kamohelo
  
 *From:* Rob Sargent rsarg...@xmission.com
 *To:* fop-users@xmlgraphics.apache.org
 *Sent:* Monday, November 7, 2011 3:25 PM
 *Subject:* Re: Multiple Page Sequences

 How large is the final pdf? That you do get a viewable pdf suggests
 that the process finished with out error.  Is that the case?

 Is the document simply truncated or does it miss particular pieces of
 content?

 How you looked at the resultant fo file (output of xsl transformation)?


 KAMOHELO MOFOKENG wrote:
  Hi All,
   I'm trying to create multiple page sequences during XSL-FO to PDF
 transformation so that I don't run out of memory (in case of large xml
 data).
   Using the example -
 http://www.scriptorium.com/whitepapers/xslfo/xslfo_4.html, I modified
 my XSL-FO as follows:  **
  *xsl:template match*=///**
 fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  *xsl:call-template name*=/LAYOUT/*/*
  *xsl:choose*
  *xsl:when test*=/ROOT/MEM-STMT/COUNTRY ='MU'/**
 fo:declarations
  *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV)
 lt; 20/**
  *xsl:call-template name*=/PROVIDER/*/*
  ***xsl:call-template name*=/MEM-TOTALS/*/*
  *xsl:call-template name=/F-OTHER/**/*
  *xsl:call-template name=/DUE/**/*
  *xsl:call-template name=/REASON/**/*
  ***/xsl:if*
 /fo:declarations
   fo:page-sequence master-reference=pre-print
 fo:static-content
 flow-name=xsl-region-before-first
   fo:block
  *xsl:call-template name*=/HEADER/*/*
 /fo:block
   /fo:static-content
   fo:static-content
 flow-name=xsl-region-after
   fo:block text-align=center
  *xsl:call-template name*=/FOOT/*/*
 /fo:block
   /fo:static-content
   fo:flow flow-name=xsl-region-body
   fo:block
  *xsl:choose*
  *xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
 fo:block
  *xsl:call-template name*=/FIN-BAL/*/*
 /fo:block
  */xsl:when*
  */xsl:choose*
  *xsl:call-template name*=/PROVIDER/*/*
  *xsl:call-template name*=/MEM-TOTALS/*/*
  *xsl:call-template name*=/F-OTHER/*/*
  *xsl:call-template name*=/DUE/*/*
  *xsl:call-template name*=/REASON/*/*
  /fo:block
   /fo:flow
  /fo:page-sequence
  */xsl:when*
   *xsl:otherwise*
  fo:page-sequence master-reference=global
  fo:static-content
  flow-name=xsl-region-before-first
   fo:block
  *xsl:call-template name*=/HEADER/*/*
  /fo:block
   /fo:static-content
   fo:static-content
  flow-name=xsl-region-after
   fo:block text-align=center
  *xsl:call-template name*=/FOOT/*/*
  /fo:block
  /fo:static-content
  fo:flow flow-name=xsl-region-body
  fo:block
  *xsl:choose*
  *xsl:when test*=/ROOT/MEM-STMT/FIN-BAL/FIN-BAMT !='0'/**
  fo:block
  *xsl:call-template name*=/FIN-BAL/*/*
  /fo:block
  */xsl:when*
  */xsl:choose*
  *xsl:if test*=/count(ROOT/MEM-STMT/ACC/PROV)=20/**
  *xsl:call-template name*=/PROVIDER/*/*
  *xsl:call-template name*=/MEM-TOTALS/*/*
  *xsl:call-template name*=/F-OTHER/*/*
  *xsl:call-template name*=/DUE/*/*
  *xsl:call-template name*=/REASON/*/*
  */xsl:if*
  /fo:block
  /fo:flow
  /fo:page-sequence
  */xsl:otherwise*
  */xsl:choose*
  /fo:root
  **
  */**xsl:template*
   The transformation works but FOP doesn't print all the pages of the
 resultant pdf file (prints 94 instead of 307).
   How should I change my XSL-FO to make FOP print all pages?
   Any help is appreciated.
   Regards,
  Kamo

 -
 To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
 mailto:fop-users-unsubscr...@xmlgraphics.apache.org
 For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
 mailto:fop-users-h...@xmlgraphics.apache.org





AW: multiple page sequences help

2010-02-24 Thread Georg Datterl
Hi Ismail,

difficult, since a new page sequence means a page break. For trunk there's a 
feature which should save finished pages in long page sequences, but for 0.20 I 
guess you are out of luck.

Can you indentify lines which would be ok to start a new page with?

Regards,

Georg Datterl

-- Kontakt --

Georg Datterl

Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg

HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20

www.geneon.de

Weitere Mitglieder der Willmy MediaGroup:

IRS Integrated Realization Services GmbH:www.irs-nbg.de
Willmy PrintMedia GmbH:www.willmy.de
Willmy Consult  Content GmbH: www.willmycc.de


-Ursprüngliche Nachricht-
Von: ismail.k...@polaris.co.in [mailto:ismail.k...@polaris.co.in]
Gesendet: Mittwoch, 24. Februar 2010 15:50
An: fop-users@xmlgraphics.apache.org
Betreff: multiple page sequences help


Hi,

I am using FOP 0.20 with JDK 1.4. I am getting outofmemory issue while
converting XML+XSL to PDF when there is huge data.
The are file which requires more than 800mb memory while conversion. There
are 8 threads processing simultaneously. Setting the heap size to 2 gb will
also not help.

I searched on net for multiple page sequences but did not got to know how
to do that.

Currently I am creating XML file with one table containing entire data.
Please help me on how to implementing multiple page sequences for the same.


| Thanks  Regards
| Ismail Khan




This e-Mail may contain proprietary and confidential information and is sent 
for the intended recipient(s) only.  If by an addressing or transmission error 
this mail has been misdirected to you, you are requested to delete this mail 
immediately. You are also hereby notified that any use, any form of 
reproduction, dissemination, copying, disclosure, modification, distribution 
and/or publication of this e-mail message, contents or its attachment other 
than by its intended recipient/s is strictly prohibited.

Visit us at http://www.polaris.co.in


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



multiple page sequences help

2010-02-24 Thread ismail . khan

Hi,

I am using FOP 0.20 with JDK 1.4. I am getting outofmemory issue while
converting XML+XSL to PDF when there is huge data.
The are file which requires more than 800mb memory while conversion. There
are 8 threads processing simultaneously. Setting the heap size to 2 gb will
also not help.

I searched on net for multiple page sequences but did not got to know how
to do that.

Currently I am creating XML file with one table containing entire data.
Please help me on how to implementing multiple page sequences for the same.


| Thanks  Regards
| Ismail Khan




This e-Mail may contain proprietary and confidential information and is sent 
for the intended recipient(s) only.  If by an addressing or transmission error 
this mail has been misdirected to you, you are requested to delete this mail 
immediately. You are also hereby notified that any use, any form of 
reproduction, dissemination, copying, disclosure, modification, distribution 
and/or publication of this e-mail message, contents or its attachment other 
than by its intended recipient/s is strictly prohibited.

Visit us at http://www.polaris.co.in


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



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: Unwanted extra page between page-sequences

2008-05-21 Thread Talken, Patrick (GE Infra, Aviation)
I am running 0.20.5 but it might not make a difference. I tried your .fo
file  after removing the  initial-page-number=1 on the second page
sequence and I didn't get the blank page, so that maybe the issue.
 
Patrick

  _  

From: David Gerdt [mailto:[EMAIL PROTECTED] 
Sent: Monday, May 19, 2008 12:48 PM
To: fop-users@xmlgraphics.apache.org
Subject: Unwanted extra page between page-sequences


Hello all-
 
Can someone help me understand why I'm getting an extra blank page with
the attached fo file? If I remove either one of the page sequences, it
renders correctly as a single page pdf. If both are together, I keep
getting a blank page between the two.
 
I'm sure it's probably a simple error that I've just overlooked, but
I've hit a wall and would love another pair of eyes to help me see what
I'm not seeing.
 
I'm running 0.95beta.
 
Thanks in advance!
 
Dave

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



Unwanted extra page between page-sequences

2008-05-19 Thread David Gerdt
Hello all-
 
Can someone help me understand why I'm getting an extra blank page with the 
attached fo file? If I remove either one of the page sequences, it renders 
correctly as a single page pdf. If both are together, I keep getting a blank 
page between the two.
 
I'm sure it's probably a simple error that I've just overlooked, but I've hit a 
wall and would love another pair of eyes to help me see what I'm not seeing.
 
I'm running 0.95beta.
 
Thanks in advance!
 
Dave


test.fo
Description: Binary data
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

RE: Unwanted extra page between page-sequences

2008-05-19 Thread Amick, Eric
Your second page sequence has an initial-page-number of 1. Since the
first page sequence generated only one page, and the starting page
number of the second sequence is odd, FO is required to generate a blank
page by default. The solution depends on what you're after. If the
second sequence is supposed to have a starting number of 1 and you don't
want the blank page, add the 
 
force-page-count=no-force 
 
property to the first page sequence. If you just want the page numbering
to continue from one sequence to the next, the simplest solution is to
remove the initial-page-number from the second page sequence.
 
Eric Amick
Legislative Computer Systems
Office of the Clerk
 



From: David Gerdt [mailto:[EMAIL PROTECTED] 
Sent: Monday, May 19, 2008 12:48
To: fop-users@xmlgraphics.apache.org
Subject: Unwanted extra page between page-sequences


Hello all-
 
Can someone help me understand why I'm getting an extra blank page with
the attached fo file? If I remove either one of the page sequences, it
renders correctly as a single page pdf. If both are together, I keep
getting a blank page between the two.
 
I'm sure it's probably a simple error that I've just overlooked, but
I've hit a wall and would love another pair of eyes to help me see what
I'm not seeing.
 
I'm running 0.95beta.
 
Thanks in advance!
 
Dave


RE: Unwanted extra page between page-sequences

2008-05-19 Thread David Gerdt
Bingo! Makes perfect sense and fixes the problem. 
 
I do actually need to reset the page numbers with each page sequence as there 
are page numbers in header sections on some of the pages that need to start 
over with each sequence. I had stripped them out in the sample file, trying to 
get to the root of the problem.
 
Thanks!

 Amick, Eric [EMAIL PROTECTED] 5/19/2008 1:38 PM 
Your second page sequence has an initial-page-number of 1. Since the first page 
sequence generated only one page, and the starting page number of the second 
sequence is odd, FO is required to generate a blank page by default. The 
solution depends on what you're after. If the second sequence is supposed to 
have a starting number of 1 and you don't want the blank page, add the 
 
force-page-count=no-force 
 
property to the first page sequence. If you just want the page numbering to 
continue from one sequence to the next, the simplest solution is to remove the 
initial-page-number from the second page sequence.
 
Eric Amick
Legislative Computer Systems
Office of the Clerk
 

From: David Gerdt [mailto:[EMAIL PROTECTED] 
Sent: Monday, May 19, 2008 12:48
To: fop-users@xmlgraphics.apache.org 
Subject: Unwanted extra page between page-sequences

Hello all-
 
Can someone help me understand why I'm getting an extra blank page with the 
attached fo file? If I remove either one of the page sequences, it renders 
correctly as a single page pdf. If both are together, I keep getting a blank 
page between the two.
 
I'm sure it's probably a simple error that I've just overlooked, but I've hit a 
wall and would love another pair of eyes to help me see what I'm not seeing.
 
I'm running 0.95beta.
 
Thanks in advance!
 
Dave


Re: How to keep pagenumber over several page-sequences

2007-11-14 Thread Chris Bowditch

Michael Niemann wrote:


hello,
I've split up my document into several page-sequences for better 
performance.


xsl:for-each select=documentContent/chapter
fo:page-sequence master-reference=ContentPageMaster 
initial-page-number=1 force-page-count=no-force

  fo:static-content flow-name=xsl-region-after
fo:blockfo:page-number //fo:block
  /fo:static-content
  fo:flow flow-name=xsl-region-body
fo:block font-size=24 font-weight=bold 
border-bottom=solid black 1px id={generate-id()} 
margin-bottom=20pxxsl:value-of select=@page //fo:block

fo:blockxsl:apply-templates //fo:block
  /fo:flow 
/fo:page-sequence

  /xsl:for-each
/fo:root
  /xsl:template

As you can easily see each chapter now starts with page 1. Is it 
possible to pass the pagenumber between those sequences without losing 
all the performance gain I got from spolitting up the chapter into 
sequences?


Don't set initial-page-number=1 on any page-sequence except the first. 
To do this you will need to introduce an xsl:if. Try something like the 
following (caveat: completely untested and provided with no warranty!)


xsl:for-each select=documentContent/chapter
fo:page-sequence master-reference=ContentPageMaster 
force-page-count=no-force

xsl:if test=position()==1
xsl:attribute 
name=initial-page-number1/xsl:attribute
/xsl:if
   fo:static-content flow-name=xsl-region-after
 fo:blockfo:page-number //fo:block

etc

Chris



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



RE: How to keep pagenumber over several page-sequences

2007-11-14 Thread Michael Niemann
That makes sense. By removing the initial pagenumber for the chapter block the 
count starts with the index page though. How can I make it start with 1 without 
setting it in the block?

Puppala, Kumar (LNG-CON) [EMAIL PROTECTED] wrote:v\:* 
{behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* 
{behavior:url(#default#VML);} .shape {behavior:url(#default#VML);}   
Having just the force-page-count property on the subsequent page sequences 
should do the trick.
   
  fo:page-sequence master-reference=ContentPageMaster 
force-page-count=no-force
   
  The page number on subsequent page sequences is a continuation from the 
previous page sequence in this case.
   
  
-
  



   
-
Be a better pen pal. Text or chat with friends inside Yahoo! Mail. See how.

RE: How to keep pagenumber over several page-sequences

2007-11-14 Thread Puppala, Kumar (LNG-CON)
Let me try to understand your requirement. You have the following
page-sequences in your document

 

Page sequence for Index

Page sequence for Chapter1

Page sequence for Chapter2

...

 

And you want the page number to start off from 1 on Chapter 1 instead of
Index.

 

If this is what you want, you can set initial-page-number on the page
sequence for Chapter1 to 1 and then not mention this attribute on the
remaining page-sequences. Regarding page sequence for Index, you mention
the initial-page-number to 1 as well. The page number gets reset
whenever you mention the initial-page-number property on a particular
sequence.

 

Hope this helps.

 

 



From: Michael Niemann [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, November 14, 2007 4:09 AM
To: fop-users@xmlgraphics.apache.org
Subject: RE: How to keep pagenumber over several page-sequences

 

That makes sense. By removing the initial pagenumber for the chapter
block the count starts with the index page though. How can I make it
start with 1 without setting it in the block?

Puppala, Kumar (LNG-CON) [EMAIL PROTECTED] wrote:

Having just the force-page-count property on the subsequent page
sequences should do the trick.

 

fo:page-sequence master-reference=ContentPageMaster
force-page-count=no-force

 

The page number on subsequent page sequences is a continuation from the
previous page sequence in this case.

 



  



Be a better pen pal. Text or chat with friends inside Yahoo! Mail. See
how. http://us.rd.yahoo.com/evt=51732/*http:/overview.mail.yahoo.com/ 



RE: How to keep pagenumber over several page-sequences

2007-11-14 Thread MichaelNie

thanks. chris already posted the solution to my noobish problem. the chapters
are generated through the same sequence template so I just had to insert the
initial value during the first iteration.


Puppala, Kumar (LNG-CON) wrote:
 
 Let me try to understand your requirement. You have the following
 page-sequences in your document
 
  
 
 Page sequence for Index
 
 Page sequence for Chapter1
 
 Page sequence for Chapter2
 
 ...
 
  
 
 And you want the page number to start off from 1 on Chapter 1 instead of
 Index.
 
  
 
 If this is what you want, you can set initial-page-number on the page
 sequence for Chapter1 to 1 and then not mention this attribute on the
 remaining page-sequences. Regarding page sequence for Index, you mention
 the initial-page-number to 1 as well. The page number gets reset
 whenever you mention the initial-page-number property on a particular
 sequence.
 
  
 
 Hope this helps.
 
  
 
  
 
 
 
 From: Michael Niemann [mailto:[EMAIL PROTECTED] 
 Sent: Wednesday, November 14, 2007 4:09 AM
 To: fop-users@xmlgraphics.apache.org
 Subject: RE: How to keep pagenumber over several page-sequences
 
  
 
 That makes sense. By removing the initial pagenumber for the chapter
 block the count starts with the index page though. How can I make it
 start with 1 without setting it in the block?
 
 Puppala, Kumar (LNG-CON) [EMAIL PROTECTED] wrote:
 
 Having just the force-page-count property on the subsequent page
 sequences should do the trick.
 
  
 
 fo:page-sequence master-reference=ContentPageMaster
 force-page-count=no-force
 
  
 
 The page number on subsequent page sequences is a continuation from the
 previous page sequence in this case.
 
  
 
 
 
   
 
 
 
 Be a better pen pal. Text or chat with friends inside Yahoo! Mail. See
 how. http://us.rd.yahoo.com/evt=51732/*http:/overview.mail.yahoo.com/ 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/How-to-keep-pagenumber-over-several-page-sequences-tf4799039.html#a13748535
Sent from the FOP - Users mailing list archive at Nabble.com.


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



How to keep pagenumber over several page-sequences

2007-11-13 Thread Michael Niemann
hello,
I've split up my document into several page-sequences for better performance.

xsl:for-each select=documentContent/chapter
fo:page-sequence master-reference=ContentPageMaster 
initial-page-number=1 force-page-count=no-force
  fo:static-content flow-name=xsl-region-after
fo:blockfo:page-number //fo:block 
  /fo:static-content
  fo:flow flow-name=xsl-region-body 
fo:block font-size=24 font-weight=bold border-bottom=solid 
black 1px id={generate-id()} margin-bottom=20pxxsl:value-of 
select=@page //fo:block
fo:blockxsl:apply-templates //fo:block
  /fo:flow  
/fo:page-sequence
  /xsl:for-each
/fo:root
  /xsl:template

As you can easily see each chapter now starts with page 1. Is it possible to 
pass the pagenumber between those sequences without losing all the performance 
gain I got from spolitting up the chapter into sequences?

best regards
michael

   
-
Get easy, one-click access to your favorites.  Make Yahoo! your homepage.

RE: How to keep pagenumber over several page-sequences

2007-11-13 Thread Puppala, Kumar (LNG-CON)
Having just the force-page-count property on the subsequent page
sequences should do the trick.

 

fo:page-sequence master-reference=ContentPageMaster
force-page-count=no-force

 

The page number on subsequent page sequences is a continuation from the
previous page sequence in this case.

 



From: Michael Niemann [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 13, 2007 10:45 AM
To: fop-users@xmlgraphics.apache.org
Subject: How to keep pagenumber over several page-sequences

 

hello,
I've split up my document into several page-sequences for better
performance.

xsl:for-each select=documentContent/chapter
fo:page-sequence master-reference=ContentPageMaster
initial-page-number=1 force-page-count=no-force
  fo:static-content flow-name=xsl-region-after
fo:blockfo:page-number //fo:block 
  /fo:static-content
  fo:flow flow-name=xsl-region-body 
fo:block font-size=24 font-weight=bold
border-bottom=solid black 1px id={generate-id()}
margin-bottom=20pxxsl:value-of select=@page //fo:block
fo:blockxsl:apply-templates //fo:block
  /fo:flow  
/fo:page-sequence
  /xsl:for-each
/fo:root
  /xsl:template

As you can easily see each chapter now starts with page 1. Is it
possible to pass the pagenumber between those sequences without losing
all the performance gain I got from spolitting up the chapter into
sequences?

best regards
michael

  



Get easy, one-click access to your favorites. Make Yahoo! your homepage.
http://us.rd.yahoo.com/evt=51443/*http:/www.yahoo.com/r/hs  



Alternate page sequences independently on odd or even page number

2007-10-24 Thread ahaddad
Hello FOP experts!

I have the following problem: inside a big edition, some page-sequences
do use recto-verso pre-printed formulars.

So, I am using the following fo:repeatable-page-master-alternatives
structure:

fo:page-sequence-master master-name=releve_quit
  fo:repeatable-page-master-alternatives
fo:conditional-page-master-reference
   master-reference=releve_quit_verso
   odd-or-even=any
   page-position=first/
fo:conditional-page-master-reference
   master-reference=releve_quit_verso
   odd-or-even=even
   page-position=any/
fo:conditional-page-master-reference
   master-reference=releve_quit_recto
   odd-or-even=odd
   page-position=any/
  /fo:repeatable-page-master-alternatives
/fo:page-sequence-master

But, of-course, it doesn't work when the first page has an odd
page-number. In this case, the master-reference releve_quit_verso is
printed two times (the first time because-off the page-position=first
attribute, the second because-of the odd-or-even=even)...

So the question is: how to direct the fo:flow in such a way that the
first page always uses the releve_quit_verso template, and then alternate
recto/verso sides independently of the global page number (odd or even)?

The aim is to avoid generating blank pages or force page numbers because
the edition is using other page sequences which can be printed in any
order (so I can't reinitialize the page number when releve_quit
page-sequence-master begins) !!

Thanks for any help.

Ahmed HADDAD.




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



Re: Adding same header and footer for multiple page sequences in XSLFO

2007-10-15 Thread Murali Krishna
Hi Phyllis,
Thanks for the reply.I am aware of  including the fo:static-content 
inside the page sequence .Actually  my requirement is something else.Here 
whatever fo:block  we have inserted into the page sequence at some flow 
region ,the same fo:block has to be inserted  across, say five pages ,without 
redundant repetition of the same fo:block in the xslfo code .So i want some 
declarative template  fo:block   kind of thing which will be repeated in all 
the pages without actually writing explicitly evertime in the page sequence.

regards,
Murali Krishna
  Hi,

  You should be able to put the fo:static-content in the fo:page-sequence.

  fo:page-sequence master-reference=detail
  fo:static-content flow-name=xsl-region-after
  fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
space-before=5mm space-after=5mm font-weight=bold
   This Text belongs to the footer part of the FO page
  /fo:block
  /fo:static-content
  fo:flow 
   
  /fo:flow
  /fo:page-sequence
  
-Original Message-
From: Murali Krishna [mailto:[EMAIL PROTECTED]
Sent: Friday, October 12, 2007 6:07 AM
To: FOP users
Subject: Adding same header and footer for multiple page sequences in XSLFO


Hi,
I have a requirement to have same header and footer on every page of the 
pdf output of xslfo .
Without using following redundant code in every page sequence how could i 
achieve the same effect by declaring the footer once and just refer somehow to 
that on every page sequence.

The footer is as follows:-

fo:static-content flow-name=xsl-region-after
 fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
space-before=5mm space-after=5mm font-weight=bold
  This Text belongs to the footer part of the FO page
/fo:block
/fo:static-content

Thanking in anticipation,

Murali Krishna

Re: Adding same header and footer for multiple page sequences in XSLFO

2007-10-15 Thread Jeremias Maerki
You can only do that at XSLT level. In the FO file, the static-content
has to be repeated for every page-sequence. That's how XSL-FO works, I'm
afraid.

Jeremias Maerki



On 15.10.2007 08:17:48 Murali Krishna wrote:
 Hi Phyllis,
 Thanks for the reply.I am aware of  including the fo:static-content 
 inside the page sequence .Actually  my requirement is something else.Here 
 whatever fo:block  we have inserted into the page sequence at some flow 
 region ,the same fo:block has to be inserted  across, say five pages 
 ,without redundant repetition of the same fo:block in the xslfo code .So i 
 want some declarative template  fo:block   kind of thing which will be 
 repeated in all the pages without actually writing explicitly evertime in the 
 page sequence.
 
 regards,
 Murali Krishna
   Hi,
 
   You should be able to put the fo:static-content in the fo:page-sequence.
 
   fo:page-sequence master-reference=detail
   fo:static-content flow-name=xsl-region-after
   fo:block  text-indent=5mm  font-family=verdana 
 font-size=12pt  space-before=5mm space-after=5mm font-weight=bold
This Text belongs to the footer part of the FO page
   /fo:block
   /fo:static-content
   fo:flow 

   /fo:flow
   /fo:page-sequence
   
 -Original Message-
 From: Murali Krishna [mailto:[EMAIL PROTECTED]
 Sent: Friday, October 12, 2007 6:07 AM
 To: FOP users
 Subject: Adding same header and footer for multiple page sequences in 
 XSLFO
 
 
 Hi,
 I have a requirement to have same header and footer on every page of the 
 pdf output of xslfo .
 Without using following redundant code in every page sequence how could i 
 achieve the same effect by declaring the footer once and just refer somehow 
 to that on every page sequence.
 
 The footer is as follows:-
 
 fo:static-content flow-name=xsl-region-after
  fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
 space-before=5mm space-after=5mm font-weight=bold
   This Text belongs to the footer part of the FO page
 /fo:block
 /fo:static-content
 
 Thanking in anticipation,
 
 Murali Krishna


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



RE: Adding same header and footer for multiple page sequences in XSLFO

2007-10-12 Thread Brown, Phyllis (NIH/NIEHS) [C]
Hi,
 
You should be able to put the fo:static-content in the fo:page-sequence.
 
fo:page-sequence master-reference=detail
fo:static-content flow-name=xsl-region-after
fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
space-before=5mm space-after=5mm font-weight=bold
 This Text belongs to the footer part of the FO page
/fo:block
/fo:static-content
fo:flow 
 
/fo:flow
/fo:page-sequence


-Original Message-
From: Murali Krishna [mailto:[EMAIL PROTECTED]
Sent: Friday, October 12, 2007 6:07 AM
To: FOP users
Subject: Adding same header and footer for multiple page sequences in XSLFO


Hi,
I have a requirement to have same header and footer on every page of the pdf 
output of xslfo .
Without using following redundant code in every page sequence how could i 
achieve the same effect by declaring the footer once and just refer somehow to 
that on every page sequence.
 
The footer is as follows:-
 
fo:static-content flow-name=xsl-region-after
 fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
space-before=5mm space-after=5mm font-weight=bold
  This Text belongs to the footer part of the FO page
/fo:block
/fo:static-content
 
Thanking in anticipation,
 
Murali Krishna



Adding same header and footer for multiple page sequences in XSLFO

2007-10-12 Thread Murali Krishna
Hi,
I have a requirement to have same header and footer on every page of the pdf 
output of xslfo .
Without using following redundant code in every page sequence how could i 
achieve the same effect by declaring the footer once and just refer somehow to 
that on every page sequence.

The footer is as follows:-

fo:static-content flow-name=xsl-region-after
 fo:block  text-indent=5mm  font-family=verdana font-size=12pt  
space-before=5mm space-after=5mm font-weight=bold
  This Text belongs to the footer part of the FO page
/fo:block
/fo:static-content

Thanking in anticipation,

Murali Krishna

Re: About page sequences

2007-07-31 Thread Andreas L Delmelle

On Jul 30, 2007, at 18:13, Richard FARAND wrote:

Hi


I am new to FOP.


In that case: Welcome!

I have to print a set of clients' invoices. For each client I have  
to print a letter first, and then print all his invoices.

So I have an XML File with structure like this:
snip /
letter and invoice do not use the same page-master. I defined two  
page-masters with master-name = letter and invoice.


Which page-sequence (conditional or not), should I use to print for  
each client, his letter in the right page-master and then all his  
invoices in the second one.


That depends a bit, I think, on whether the letter itself can be more  
than one page. If not, then it would be conditional-page-master- 
alternatives you want to look at:
- one for the first page (page-position=first - refer to the  
letter page-master)
- and one for the others (page-position=rest - refer to the  
invoice page-master)


I can't immediately think of a straightforward solution in case the  
letter can be more than one page, but perhaps I'm simply missing  
something... Anyone?



Cheers

Andreas


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



About page sequences

2007-07-30 Thread Richard FARAND

Hi FOP experts!

I am new to FOP.
I have to print a set of clients' invoices. For each client I have to 
print a letter first, and then print all his invoices.

So I have an XML File with structure like this:

all_invoices
   client name=client1
   letter
   /letter
   invoices
   invoice/invoice
   invoice/invoice
   /invoices
/client
   client name=client2
   letter
   /letter
   invoices
   invoice/invoice
   invoice/invoice
   /invoices
/client
/all_invoices

letter and invoice do not use the same page-master. I defined two 
page-masters with master-name = letter and invoice.


Which page-sequence (conditional or not), should I use to print for each 
client, his letter in the right page-master and then all his invoices in 
the second one.


B.R.
Richard.




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



Re: About page sequences

2007-07-30 Thread Richard FARAND

Hi experts!

I really need help because we have to decide soon wether we will use FOP 
or not.


The question is how to write in xsl-fo:

for-each client:
   1- print letter using simple-master-page=letter
   2- for-each invoice of client: print invoice 
using simple-master-page=invoice


Remark:

   * simple-master-page=letter does use only a region-body.
   * simple-master-page=invoice uses a region-before and a region-body.

Thanks for any help.

Richard FARAND a écrit:


Hi FOP experts!

I am new to FOP.
I have to print a set of clients' invoices. For each client I have to 
print a letter first, and then print all his invoices.

So I have an XML File with structure like this:

all_invoices
   client name=client1
   letter
   /letter
   invoices
   invoice/invoice
   invoice/invoice
   /invoices
/client
   client name=client2
   letter
   /letter
   invoices
   invoice/invoice
   invoice/invoice
   /invoices
/client
/all_invoices

letter and invoice do not use the same page-master. I defined two 
page-masters with master-name = letter and invoice.


Which page-sequence (conditional or not), should I use to print for 
each client, his letter in the right page-master and then all his 
invoices in the second one.


B.R.
Richard.





Re: About page sequences

2007-07-30 Thread J.Pietschmann

Richard FARAND wrote:
I have to print a set of clients' invoices. For each client I have to 
print a letter first, and then print all his invoices.

So I have an XML File with structure like this:

[snip]
Which page-sequence (conditional or not), should I use to print for each 
client, his letter in the right page-master and then all his invoices in 
the second one.


Please clarify whether you need help writing the FO or whether you
need help writing the transformation from your XML source to the FO.
In the latter case, you'll get help more easily on the XSL list:
 http://www.mulberrytech.com/xsl/xsl-list/

There are several examples for FO documents using multiple page masters
in the FOP distribution, for example
 examples/fo/pagination/franklin_2pageseqs.fo
You can find more on the internet, in particular in Dave Pawson's XSL
FAQ.

J.Pietschmann

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



Re: Page Sequences

2005-12-09 Thread Clifton Craig
You know what? Is the patch already in the new Alpha release? Cause if it is 
then it's not worth my time applying it to FOP-0.20.2. I've already tried my 
stylesheet with the alpha version and I still have the memory issue.

On Thursday 08 December 2005 10:17 pm, Andreas L Delmelle wrote:
 On Dec 8, 2005, at 23:01, Clifton Craig wrote:
  I'm banging my head on this so maybe I'll look into the quick fix
  since this
  is the 2nd or 3rd time someone has brought it up. Is it a jar or
  something
  that would be easy to install?

 Not exactly... although not too much effort either.

 Check out the source via SVN:
http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/
 fop-0_20_2-maintain

 ... and build-it-yourself.


 HTH!

 Cheers,

 Andreas


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

-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

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



Re: Page Sequences

2005-12-09 Thread Jeremias Maerki
The layout engine of 0.90alpha1 works differently. It's a bit difficult
to compare the two versions. But I'd have to say the same optimization
is currently not possible in 0.90/Trunk unless we extend the breaking
algorithm to support a first/best fit strategy so the objects can be
released early (i.e. as soon as their areas have been generated). Also
remember that 0.90 is not yet optimized in any way. In many situations
it uses a little more memory than the old, optimized 0.20.5 release.
That's also part of why the current version is called alpha. So, if
you have memory problems, better stick to 0.20.5 for the moment.

On 09.12.2005 14:41:28 Clifton Craig wrote:
 You know what? Is the patch already in the new Alpha release? Cause if it is 
 then it's not worth my time applying it to FOP-0.20.2. I've already tried my 
 stylesheet with the alpha version and I still have the memory issue.
 
 On Thursday 08 December 2005 10:17 pm, Andreas L Delmelle wrote:
  On Dec 8, 2005, at 23:01, Clifton Craig wrote:
   I'm banging my head on this so maybe I'll look into the quick fix
   since this
   is the 2nd or 3rd time someone has brought it up. Is it a jar or
   something
   that would be easy to install?
 
  Not exactly... although not too much effort either.
 
  Check out the source via SVN:
 http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/
  fop-0_20_2-maintain
 
  ... and build-it-yourself.


Jeremias Maerki


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



Re: Page Sequences

2005-12-09 Thread Clifton Craig
Thank you all so much. I have another question though. Why is it that I would 
get the same OutOfMemoryError on the XEP personal edition? That's what has me 
wondering if it's really something wrong with my FO syntax or my stylesheet. 
It has me wondering about one section in my stylesheet that matches elements 
towards the bottom of the document. While that alone doesn't cause 
OutOfMemory running only through Xalan for transforming I wonder if that 
along with the pagesequence thing is just over the top? This is so 
frustrating! I'm willing to try anything now. Let me try applying the patch 
and we'll see.
-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

On Friday 09 December 2005 9:19 am, Jeremias Maerki wrote:
 The layout engine of 0.90alpha1 works differently. It's a bit difficult
 to compare the two versions. But I'd have to say the same optimization
 is currently not possible in 0.90/Trunk unless we extend the breaking
 algorithm to support a first/best fit strategy so the objects can be
 released early (i.e. as soon as their areas have been generated). Also
 remember that 0.90 is not yet optimized in any way. In many situations
 it uses a little more memory than the old, optimized 0.20.5 release.
 That's also part of why the current version is called alpha. So, if
 you have memory problems, better stick to 0.20.5 for the moment.


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



Re: Page Sequences

2005-12-09 Thread Andreas L Delmelle

On Dec 9, 2005, at 15:33, Clifton Craig wrote:

Why is it that I would get the same OutOfMemoryError on the XEP  
personal edition?
That's what has me wondering if it's really something wrong with my  
FO syntax or

my stylesheet.
It has me wondering about one section in my stylesheet that matches  
elements

towards the bottom of the document.


Hmm, I suppose in extreme cases it could be that FOP and Xalan  
*together* cause the OOMError... You mention having performed the  
XSLT step separately. Did you also run the resulting FO through FOP?  
Did it also run out of memory?
(If not, then you could try using Saxon instead of Xalan, although  
from what I've gathered so far about the structure of your FO  
document, it could turn out that FOP chokes on it anyway...)



Andreas



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



Re: Page Sequences

2005-12-09 Thread Clifton Craig
Ok, I've been toiling over this for far too long and I'm 'bout to be fired as 
a result. I really need some help. My report works as follows. Depending on 
what option the report runs with there will be nested group/ elements 
representing the layout of the data respective to the UI selection. each 
group can have one or more nested groups followed by an aggregate/ element. 
Then the inner most group will have row/ elements containing the data which 
is to be laid out in tabular form on the resulting PDF. I process the group 
elements recursively in my stylesheet and evalutate them to a bunch of flat 
fo:table/s for the PDF There's no nesting of tables, I just list them 
outright. The entire recursive process is called from an xsl:call-template/ 
from the fo:flow/ element in a single fo:page-sequence/ element letting 
the processor figuring out the page breaks. The resulting output can be huge 
so this is where the memory is bogged down. 

My problems are two-fold. For one, I can't get my hands around an algorithm 
that allows me to manage my own page breaks. The best I could do is come up 
with a process that iterates an arbitrary number of group/ elements (which 
I call a section-count) at each nesting level (as well as off the root). This 
algorithm wrap a page sequence around each section-count group elements. It 
doesn't work because I end up with nested fo:page-sequence/ elements. I 
need a way to do either something similar without ending up with nested 
page-sequences or something radically different that doesn't render the 
output looking all crazy with one or two lines of data on each page. 

My next problem is my inability to get the patch from the svn repo. I'm afraid 
I'm not smart enough to use it. I have three different svn clients, none of 
which work. I tried kdesvn, rapidsvn, and the svnup plugin for Idea. I 
believe the problem here is with our authenticating HTTP proxy. I don't see a 
way to config proxy settings on any of them yet the URL I'm using for the FOP 
repository is an http URL. What gives here? I'm using, from the FOP dev page, 
this here: 
http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/fop-0_20_2-maintain/
Is that right? Do I have to set proxy settings somewhere to get out to it? How 
does it work? I've checked out apache projects from CVS before and that seems 
to work fine. I need some serious help. Please, I'm open to any suggestions. 
Thanx in advance!
-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

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



Re: Page Sequences

2005-12-09 Thread Clifton Craig
I finally got the danged thing to download from the svn repo. Took me all day 
to figure out how to get around our doggone proxy. I'm going to try building 
it and see if that will fix my problem. In the interim if somebody could help 
me with an algorithm I'd be ever so grateful. I'm an ameture at 
declarative/functional programming.
-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

On Friday 09 December 2005 3:26 pm, Clifton Craig wrote:
 Ok, I've been toiling over this for far too long and I'm 'bout to be fired
 as a result. I really need some help. My report works as follows. Depending
 on what option the report runs with there will be nested group/ elements
 representing the layout of the data respective to the UI selection. each
 group can have one or more nested groups followed by an aggregate/
 element. Then the inner most group will have row/ elements containing the
 data which is to be laid out in tabular form on the resulting PDF. I
 process the group elements recursively in my stylesheet and evalutate them
 to a bunch of flat fo:table/s for the PDF There's no nesting of tables, I
 just list them outright. The entire recursive process is called from an
 xsl:call-template/ from the fo:flow/ element in a single
 fo:page-sequence/ element letting the processor figuring out the page
 breaks. The resulting output can be huge so this is where the memory is
 bogged down.

 My problems are two-fold. For one, I can't get my hands around an algorithm
 that allows me to manage my own page breaks. The best I could do is come up
 with a process that iterates an arbitrary number of group/ elements
 (which I call a section-count) at each nesting level (as well as off the
 root). This algorithm wrap a page sequence around each section-count group
 elements. It doesn't work because I end up with nested fo:page-sequence/
 elements. I need a way to do either something similar without ending up
 with nested page-sequences or something radically different that doesn't
 render the output looking all crazy with one or two lines of data on each
 page.

 My next problem is my inability to get the patch from the svn repo. I'm
 afraid I'm not smart enough to use it. I have three different svn clients,
 none of which work. I tried kdesvn, rapidsvn, and the svnup plugin for
 Idea. I believe the problem here is with our authenticating HTTP proxy. I
 don't see a way to config proxy settings on any of them yet the URL I'm
 using for the FOP repository is an http URL. What gives here? I'm using,
 from the FOP dev page, this here:
 http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/fop-0_20_2-maintai
n/ Is that right? Do I have to set proxy settings somewhere to get out to
 it? How does it work? I've checked out apache projects from CVS before and
 that seems to work fine. I need some serious help. Please, I'm open to any
 suggestions. Thanx in advance!

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



Re: Page Sequences

2005-12-08 Thread Chris Bowditch

Clifton Craig wrote:

snip/


J,
So the only time tables are realeased are at the end of a page sequence? That 
would explain my dilemma. Even though I use multiple smaller tables per row 
instead of one big table all of the smaller tables are held until the page 
sequence ends? That sux.


Non constructive comments are *not* welcome. You must realise that the 
possibility of back tracking makes the task of knowing when to release 
objects very tricky. If you think you are up to the challenge of writing 
algorithms to do layout more efficiently then please share them. 
Otherwise refrain from making such negative comments.


Chris



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



Re: Page Sequences

2005-12-08 Thread Clifton Craig
Chris,

My apologies as I didn't mean those comments to sting. What I should have said 
was, that sux for me. Or even better, it sux to be me. I was only venting 
from my current situation and I wasn't attempting to trash talk the product 
at all. FOP is the perfect fit for our project and there are few (if any) 
alternatives that work as well. No I am not up to writing more efficient 
algorithms as I am but a peon developer who is barely able to keep up with 
the algorithms required to effectively interface with such a product. Thanx 
for keeping me in line. No hard feelings.

-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

On Thursday 08 December 2005 3:56 am, Chris Bowditch wrote:
 Clifton Craig wrote:

 snip/

  J,
  So the only time tables are realeased are at the end of a page sequence?
  That would explain my dilemma. Even though I use multiple smaller tables
  per row instead of one big table all of the smaller tables are held until
  the page sequence ends? That sux.

 Non constructive comments are *not* welcome. You must realise that the
 possibility of back tracking makes the task of knowing when to release
 objects very tricky. If you think you are up to the challenge of writing
 algorithms to do layout more efficiently then please share them.
 Otherwise refrain from making such negative comments.

 Chris



 -
 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: Page Sequences

2005-12-08 Thread Chris Bowditch

Clifton Craig wrote:


Chris,

My apologies as I didn't mean those comments to sting. What I should have said 
was, that sux for me. Or even better, it sux to be me. I was only venting 
from my current situation and I wasn't attempting to trash talk the product 
at all. FOP is the perfect fit for our project and there are few (if any) 
alternatives that work as well. No I am not up to writing more efficient 
algorithms as I am but a peon developer who is barely able to keep up with 
the algorithms required to effectively interface with such a product. Thanx 
for keeping me in line. No hard feelings.




Thanks for clearing that up Craig. All is forgiven. It is so easy to 
misunderstand on e-mail sometimes...


Chris



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



Re: Page Sequences

2005-12-08 Thread J.Pietschmann

Clifton Craig wrote:

So the only time tables are realeased are at the end of a page sequence?


Yes. The problem is actually all the stuff used during content
layout, which is otherwise released after a page has been rendered.
There is a quick fix in the source repository for this.

J.Pietschmann


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



Re: Page Sequences

2005-12-08 Thread Andreas L Delmelle

On Dec 8, 2005, at 23:01, Clifton Craig wrote:

I'm banging my head on this so maybe I'll look into the quick fix  
since this
is the 2nd or 3rd time someone has brought it up. Is it a jar or  
something

that would be easy to install?


Not exactly... although not too much effort either.

Check out the source via SVN:
  http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/ 
fop-0_20_2-maintain


... and build-it-yourself.


HTH!

Cheers,

Andreas


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



Re: Page Sequences

2005-12-07 Thread Clifton Craig
Andreas,

Thanx for your reply. Yes I do want to ultimately make it look like it did 
when I just dumped the entire report body under one page sequence, however I 
cannot use one page sequence due to memory overflow issues. I'm still a 
little concerned as to why I'm having memory overflow if it is the norm to 
use one page sequence for the report body as I've done. As for my stylesheet, 
I'm not offended at all from your comments rather I'm just not as concerned 
on that part of it. The end result would be the same no matter what technique 
I used in XSLT and the performance of the stylesheet is acceptible when I use 
Xalan directly to produce FO. The only big question here is, Can I get away 
with using one page sequence or do I have to use multiple page sequences? 
Another equally big question is, How do I go about using multiple page 
sequences effectively if I have no other option?
On Tuesday 06 December 2005 4:07 pm, Andreas L Delmelle wrote:

  Here's a brief synopsis of how things work. A group of Java classes
  run
  multiple queries to pull data from the db and into a result set.
  Some more
  Java code transforms the data into XML (sort of an intermediate
  form for the
  report). my stylesheet then takes the resultset tranformed into XML
  and
  transforms it again into FO for the FOP engine. The data can be
  voluminous
  and we are looking into streamlining the process. My major
  bottleneck now has
  been the stylesheet creating FO that appears to be choking the FO
  engine. In
  a perfect world I'd love to just dump the report in one page
  sequence element
  and have the engine sort it out but it doesn't appear to work well
  that way.

 So IIC, you need to make it look like it had all been placed under
 one page-sequence. (more or less: only the very last page in the
 document can be filled partly, but the rest needs to appear as if it
 were one fo:flow in one fo:page-sequence). Is that a correct assessment?


 Cheers,

 Andreas

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

-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

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



Re: Page Sequences

2005-12-07 Thread Andreas L Delmelle

On Dec 7, 2005, at 16:12, Clifton Craig wrote:

Hi,

Thanx for your reply. Yes I do want to ultimately make it look like  
it did
when I just dumped the entire report body under one page sequence,  
however I

cannot use one page sequence due to memory overflow issues.
I'm still a little concerned as to why I'm having memory overflow  
if it is the norm to

use one page sequence for the report body as I've done.


The explanation for the excessive memory use, AFAIU, is that the  
Table object holds a list with references to its childNodes, and  
every childNode again has such a list, etc.


As long as the Table is referenced, *all* of its descendant nodes  
will remain referenced, so if you have a large table with about 20  
columns and 1000 rows, and the contents of the cells are plain simple  
blocks, then keeping this table together in one page-sequence,  
possibly means 2 cells in memory plus *all* nodes for their  
content (so, a minimum of 2 blocks and *all* their character data)
Given that FOs by definition are compound objects (and not all their  
members are primitive types), you can try to do the math... and that  
is only the FO-tree side.


Since the handles to the FOs are released only at the end of each  
page-sequence, splitting the table over multiple page-sequences is  
currently the only way to keep it manageable. (in both versions of FOP)


(Side-note: somehow it should be possible to release the objects for  
the cells and their content once we're absolutely certain that they  
will no longer be needed. Determining that, however, doesn't seem to  
be as simple as it sounds, since layout may involve backtracking  
several rows...)


As for my stylesheet, I'm not offended at all from your comments  
rather I'm just not as concerned
on that part of it. The end result would be the same no matter what  
technique
I used in XSLT and the performance of the stylesheet is acceptible  
when I use

Xalan directly to produce FO.


OK, my remarks were related more to style than efficiency. In your  
case, I'm guessing there is no noticeable performance benefit to my  
suggestions... It just 'rhymes' better with the XSLT way of doing  
things (apply templates to node-sets).


The only big question here is, Can I get away with using one page  
sequence or do I have to use multiple page sequences?


Oh, you *can* get away with using one page-sequence, but only if you  
have a massive heap at your disposal...


Another equally big question is, How do I go about using multiple  
page

sequences effectively if I have no other option?


Well, you mentioned line-counting. How do you go about that exactly?  
Does this number of lines correspond to a number of elements in your  
source XML? In that case, you're probably best off using XSLT  
grouping techniques[*].
If you know in advance how many rows will fit on a page, you could  
even create one page-sequence per page (one table per page), which  
should reduce the memory consumption drastically.


[*] see: http://www.jenitennison.com/xslt/grouping/index.xml

HTH!

Cheers,

Andreas



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



Re: Page Sequences

2005-12-07 Thread Clifton Craig
On Wednesday 07 December 2005 3:46 pm, J.Pietschmann wrote:
 Clifton Craig wrote:
  I'm still a
  little concerned as to why I'm having memory overflow if it is the norm
  to use one page sequence for the report body as I've done.

 Tables lock up objects used for content formatting for too long,
 they are released (together with objects representing the FO)
 at the end of a page sequence only. Using multiple page sequences
 releases memory earlier.

 J.Pietschmann

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

J,
So the only time tables are realeased are at the end of a page sequence? That 
would explain my dilemma. Even though I use multiple smaller tables per row 
instead of one big table all of the smaller tables are held until the page 
sequence ends? That sux.
-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

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



Re: Page Sequences

2005-12-06 Thread Chris Bowditch

Glen Mazza wrote:

No doubt.  But 0.90alpha1 will be getting better.  Very few if any 
committers really understand 0.20.5 anymore, the committers who worked 
on it are mostly gone today.


I reckon Joerg is a bit of an expert at 0.20.5 ;)

Chris



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



Re: Page Sequences

2005-12-06 Thread Clifton Craig
Dave that's exactly what my issue is, you hit the nail right on the head. I'm 
having trouble with the memory issues not only in FOP 20.5.1 but in XEP and 
0.9alpha as well. It was suggested, and it seems to have worked out well, 
that I use multiple page sequences to fix the problem. While I feel this is 
mostly a hack I was inquiring on how to implement it in my report which is 
modestly complex. To recap from my original post, I had memory issues with 
transforming an XML document about 1.2M in size. the same exact transform 
worked well (showing no slowdown at all) with an XML doc sized at about 800K 
which lead me thinking that there was some threshold I crossed or something. 
Someone suggested I manage page-sequencing myself and I tried it. I hacked my 
stylesheet and basically put each line on a separate page as a rough 
experiment. The hack worked llike a charm only leaving me to wonder how to 
manage my own page sequences effectively. In my report we allow the user the 
option of grouping on 1-6 levels and also allow control over page breaks so 
this would be a particular challenge.

-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]

On Monday 05 December 2005 6:11 pm, David Frankson wrote:
  I may be misunderstanding your question, but it seems like you just

 need

  one fo:page-sequence, with predefined fo:static-contents for the

 header

  and footer (fo:static-contents will get automatically printed on each
  page.)  Next, put all the content that will be placed on each page in
  the one fo:flow for the fo:page-sequence.

 He is probably using the multiple page sequences to work around the
 memory issues in tables.  I would say that most all of us who use 20.5
 do this.  I've written lots of xsl:fo that does its own page sequencing
 by counting lines of data, and we tend to design our reports differently
 to overcome the limitations in fop.

 I've seen mention of memory fixes on this list, but most of us are
 hesitant to do our own pulls from CVS.  If the developers don't feel
 like this code is worthy or stable enough for a release of any kind,
 then we are not putting it into production.  However, if you were to
 take the latest source and put it into a 20.5.1, we'd probably
 enthusiastically take it, and it might solve a lot of the
 performance/memory issues that are posted to the list.

 Dave

 -Original Message-
 From: Glen Mazza [mailto:[EMAIL PROTECTED]
 Sent: Monday, December 05, 2005 4:42 PM
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: Page Sequences

 Clifton Craig wrote:
  I'm writing a report transform usinf XSLT for XSL-FO and I have some

 basic

  questions. What's the best way to code for multiple page sequences.

 For

  example I have some static content that I like to keep in the header

 and

  footers and I guess it doesn't matter but I'd like to reuse chunks of

 XML-FO

  for that purpose rather than replicating it to the result tree.

 I may be misunderstanding your question, but it seems like you just need

 one fo:page-sequence, with predefined fo:static-contents for the header
 and footer (fo:static-contents will get automatically printed on each
 page.)  Next, put all the content that will be placed on each page in
 the one fo:flow for the fo:page-sequence.

  Now from within that template I want to start new page sequences and

 spit out

  the following using a new-page XSLT-template:

 The page handling is done by FOP -- you won't know the number of pages
 needed, that is done by FOP's layout process.

  What bothers me even more is since I'm
  programmatically controlling new pages is there a better way to handle

 this

  type of processing? Right now it looks like I'll have to keep a line

 count in

  my stylesheet to detect when I should programmatically start new

 pages. Is

  there a better way? How do most people do multipage reports with

 variable

  data? Iss everybody line counting in there stylesheets?

 I don't think anybody does that.  Place all your content (except for the

 header and footer) in the single fo:flow of the fo:page-sequence, and
 that should work.

 Glen

 -
 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]

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



Re: Page Sequences

2005-12-06 Thread Clifton Craig
Andreas,

I understand my stylesheet snippets are amature because that's just what I was 
when I started the project, an XSL amature. I am open to any and all 
suggestions for improvement but understand that I am most interested in 
fixing the pressing memory problem at hand. See my answer to Dave who was 
dead on. I'm a little hesitant to post my nasty XSL stylesheet in entirety as 
it may require explaining that is not directly related to my problem and 
sidetrack the issue. On the other hand I'm guessing there are experts here 
that could probably look through the unrelated fluff and find out where I'm 
going wrong. I'd probably have to work out an XML schema or something to go 
along with the stylesheet too. I had a tool that could generate that for me 
but it expired. (See I'm sidetracked already!) Anyway, thank you all for 
showing interest in my dilemma. I really need some good adivce on how to 
control page breaks programmatically since it seems I'm stuck doing it this 
way.

Here's a brief synopsis of how things work. A group of Java classes run 
multiple queries to pull data from the db and into a result set. Some more 
Java code transforms the data into XML (sort of an intermediate form for the 
report). my stylesheet then takes the resultset tranformed into XML and 
transforms it again into FO for the FOP engine. The data can be voluminous 
and we are looking into streamlining the process. My major bottleneck now has 
been the stylesheet creating FO that appears to be choking the FO engine. In 
a perfect world I'd love to just dump the report in one page sequence element 
and have the engine sort it out but it doesn't appear to work well that way. 
Thanx for all suggestions.

-- 
Clifton C. Craig, Software Engineer
[EMAIL PROTECTED]
On Monday 05 December 2005 5:47 pm, Andreas L Delmelle wrote:
 On Dec 5, 2005, at 21:43, Clifton Craig wrote:


 Hi,

  I'm writing a report transform usinf XSLT for XSL-FO and I have
  some basic
  questions. What's the best way to code for multiple page sequences.
  For
  example I have some static content that I like to keep in the
  header and
  footers and I guess it doesn't matter but I'd like to reuse chunks
  of XML-FO
  for that purpose rather than replicating it to the result tree.
  What I mean
  is I have some XSL for a page sequence that looks like this:

 I'm unsure what exactly you mean, but I guess you could define parts
 of the static-content (the ones you're going to reuse) as
 xsl:variables --some maybe even in another, included/imported
 stylesheet to keep them separated for maintainability--, and insert
 them into the result tree using xsl:copy-of.

 Say,

 xsl:variable name=static-one
fo:block font-family={$FONT-DEFAULT}
  fo:block text-align=center font-size=12pt font-weight=bold
!-- Be very careful about the below XPath expression, as it
 will not
 necessarily be evaluated in the same context it currently
 is...
 If the expression actually evaluates differently for
 different
 page-sequences, this can't be put in a global variable,
 IIC --
xsl:value-of select=snapshot/title /
  /fo:block
...
 /xsl:variable

 Then further on you can go:

 fo:page-sequence master-reference=snapshot-pages
fo:static-content flow-name=header
  !-- some dynamic static content, specific to *this* page-
 sequence --
  xsl:copy-of select=$static-one /
/fo:static-content
 ...

 Also, the following seems a little fishy, although I have way too
 little context here to form an accurate idea of why you're using
 named templates instead of matching ones.

  xsl:call-template name=group-headings
xsl:with-param name=group select=snapshot/data/group[1]/
  /xsl:call-template
  xsl:call-template name=column-headers
xsl:with-param name=meta select=/snapshot/data/meta/
  /xsl:call-template

 I don't know exactly what happens to these parameters, but if I see
 this, it makes me think: Why not use

 xsl:apply-templates select=snapshot/data/group[1] /
 xsl:apply-templates select=/snapshot/data/meta /

 ?

 If the column-headers template actually needs to applied to several
 different types of nodes (other than meta), you could redefine it from

 xsl:template name=column-headers

 to

 xsl:template match=meta | ... | ...

 snip /

  What bothers me even more is since I'm programmatically controlling
  new pages
  is there a better way to handle this type of processing?

 Can you explain a bit further what you mean by 'programmatically
 controlling new pages'? If we get to see a bit more, maybe we can
 offer you a better way...

  Right now it looks like I'll have to keep a line count in my
  stylesheet to
  detect when I should programmatically start new pages.

 Why? Is the processor's page-breaking algorithm insufficient for some
 reason? Can't you use XSL-FO's break-* properties to control this?


 HTH!

 Cheers,

 Andreas

Re: Page Sequences

2005-12-06 Thread Andreas L Delmelle

On Dec 6, 2005, at 15:16, Clifton Craig wrote:

Hi,

I understand my stylesheet snippets are amature because that's just  
what I was

when I started the project, an XSL amature.


Whoops, I hope I didn't give the impression that I was mocking your  
current level of understanding XSLT... Besides that, strictly  
speaking I'm an amateur myself, so don't worry. I just tried to raise  
some valid questions, based on the parts of the stylesheet you've  
shown us, and what I learned about XSLT over the years. Sometimes,  
you help people more by putting it as a question, so they will have  
to make the effort to answer it for themselves... Once you do, the  
logic behind it will remain apparent longer than if you get a fully  
worked-out solution on a platter. You will be able to profit from the  
gained knowledge in other scenarios as well.


No need to post the full stylesheet. I'd rather see *you* take a look  
at it, at the XSLT Rec and at some of the answers you already  
received, and try to make out whether any comments that were offered  
can be of use to you.


Now that that's out of the way:

snip /
Here's a brief synopsis of how things work. A group of Java classes  
run
multiple queries to pull data from the db and into a result set.  
Some more
Java code transforms the data into XML (sort of an intermediate  
form for the
report). my stylesheet then takes the resultset tranformed into XML  
and
transforms it again into FO for the FOP engine. The data can be  
voluminous
and we are looking into streamlining the process. My major  
bottleneck now has
been the stylesheet creating FO that appears to be choking the FO  
engine. In
a perfect world I'd love to just dump the report in one page  
sequence element
and have the engine sort it out but it doesn't appear to work well  
that way.


So IIC, you need to make it look like it had all been placed under  
one page-sequence. (more or less: only the very last page in the  
document can be filled partly, but the rest needs to appear as if it  
were one fo:flow in one fo:page-sequence). Is that a correct assessment?



Cheers,

Andreas

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



Page Sequences

2005-12-05 Thread Clifton Craig
I'm writing a report transform usinf XSLT for XSL-FO and I have some basic 
questions. What's the best way to code for multiple page sequences. For 
example I have some static content that I like to keep in the header and 
footers and I guess it doesn't matter but I'd like to reuse chunks of XML-FO 
for that purpose rather than replicating it to the result tree. What I mean 
is I have some XSL for a page sequence that looks like this:

fo:page-sequence master-reference=snapshot-pages
fo:static-content flow-name=header
fo:block
xsl:attribute name=font-familyxsl:value-of 
select=$FONT-DEFAULT//xsl:attribute
fo:block text-align=center font-size=12pt 
font-weight=bold
xsl:value-of select=snapshot/title/
/fo:block
fo:block text-align=center space-before=.50in 
font-size=10pt
  white-space-collapse=false 
white-space-treatment=preserve
xsl:value-of select=snapshot/header/
/fo:block
xsl:call-template name=group-headings
xsl:with-param name=group 
select=snapshot/data/group[1]/
/xsl:call-template
xsl:call-template name=column-headers
xsl:with-param name=meta 
select=/snapshot/data/meta/
/xsl:call-template
/fo:block
/fo:static-content
fo:static-content flow-name=footer
fo:block
xsl:attribute name=font-familyxsl:value-of 
select=$FONT-DEFAULT//xsl:attribute
fo:block text-align=right font-size=9pt
xsl:value-of select=snapshot/footer/
/fo:block
fo:block text-align=right font-size=9ptPage
fo:page-number/
/fo:block
/fo:block
/fo:static-content
fo:flow flow-name=body

!-- Report data goes here, a bunch of tables get dumped from the called 
recursive template. --
xsl:call-template name=GroupDescend
xsl:with-param name=groupVar 
select=snapshot/data/
xsl:with-param name=groupLvl0/xsl:with-param
xsl:with-param name=groupRoot 
select=snapshot/data/
/xsl:call-template
/fo:flow
/fo:page-sequence

Now from within that template I want to start new page sequences and spit out 
the following using a new-page XSLT-template:

/fo:flow
/fo:page-sequence
fo:page-sequence master-reference=snapshot-pages
fo:static-content flow-name=header
fo:block
xsl:attribute name=font-familyxsl:value-of 
select=$FONT-DEFAULT//xsl:attribute
fo:block text-align=center font-size=12pt 
font-weight=bold
xsl:value-of select=snapshot/title/
/fo:block
fo:block text-align=center space-before=.50in 
font-size=10pt
  white-space-collapse=false 
white-space-treatment=preserve
xsl:value-of select=snapshot/header/
/fo:block
xsl:call-template name=group-headings
xsl:with-param name=group 
select=snapshot/data/group[1]/
/xsl:call-template
xsl:call-template name=column-headers
xsl:with-param name=meta 
select=/snapshot/data/meta/
/xsl:call-template
/fo:block
/fo:static-content
fo:static-content flow-name=footer
fo:block
xsl:attribute name=font-familyxsl:value-of 
select=$FONT-DEFAULT//xsl:attribute
fo:block text-align=right font-size=9pt
xsl:value-of select=snapshot/footer/
/fo:block
fo:block text-align=right font-size=9ptPage
fo:page-number/
/fo:block
/fo:block
/fo:static-content
fo:flow flow-name=body

Since the new page stuff is essentially the same as the external wrapping XML 
fragments is there a way I can re-use it? Could I use an id/ref-id thing or 
something like that? The more I think about it the less important it sounds 
since it's all piping into the FOP engine anyway and never needing to 
materialize to disk or anything. What bothers me even more is since I'm 
programmatically controlling new pages

Re: Page Sequences

2005-12-05 Thread Glen Mazza


Clifton Craig wrote:

I'm writing a report transform usinf XSLT for XSL-FO and I have some basic 
questions. What's the best way to code for multiple page sequences. For 
example I have some static content that I like to keep in the header and 
footers and I guess it doesn't matter but I'd like to reuse chunks of XML-FO 
for that purpose rather than replicating it to the result tree. 


I may be misunderstanding your question, but it seems like you just need 
one fo:page-sequence, with predefined fo:static-contents for the header 
and footer (fo:static-contents will get automatically printed on each 
page.)  Next, put all the content that will be placed on each page in 
the one fo:flow for the fo:page-sequence.




Now from within that template I want to start new page sequences and spit out 
the following using a new-page XSLT-template:




The page handling is done by FOP -- you won't know the number of pages 
needed, that is done by FOP's layout process.




What bothers me even more is since I'm 
programmatically controlling new pages is there a better way to handle this 
type of processing? Right now it looks like I'll have to keep a line count in 
my stylesheet to detect when I should programmatically start new pages. Is 
there a better way? How do most people do multipage reports with variable 
data? Iss everybody line counting in there stylesheets? 


I don't think anybody does that.  Place all your content (except for the 
header and footer) in the single fo:flow of the fo:page-sequence, and 
that should work.


Glen

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



Re: Page Sequences

2005-12-05 Thread Andreas L Delmelle

On Dec 5, 2005, at 21:43, Clifton Craig wrote:


Hi,

I'm writing a report transform usinf XSLT for XSL-FO and I have  
some basic
questions. What's the best way to code for multiple page sequences.  
For
example I have some static content that I like to keep in the  
header and
footers and I guess it doesn't matter but I'd like to reuse chunks  
of XML-FO
for that purpose rather than replicating it to the result tree.  
What I mean

is I have some XSL for a page sequence that looks like this:


I'm unsure what exactly you mean, but I guess you could define parts  
of the static-content (the ones you're going to reuse) as  
xsl:variables --some maybe even in another, included/imported  
stylesheet to keep them separated for maintainability--, and insert  
them into the result tree using xsl:copy-of.


Say,

xsl:variable name=static-one
  fo:block font-family={$FONT-DEFAULT}
fo:block text-align=center font-size=12pt font-weight=bold
  !-- Be very careful about the below XPath expression, as it  
will not
   necessarily be evaluated in the same context it currently  
is...
   If the expression actually evaluates differently for  
different
   page-sequences, this can't be put in a global variable,  
IIC --

  xsl:value-of select=snapshot/title /
/fo:block
  ...
/xsl:variable

Then further on you can go:

fo:page-sequence master-reference=snapshot-pages
  fo:static-content flow-name=header
!-- some dynamic static content, specific to *this* page- 
sequence --

xsl:copy-of select=$static-one /
  /fo:static-content
...

Also, the following seems a little fishy, although I have way too  
little context here to form an accurate idea of why you're using  
named templates instead of matching ones.



xsl:call-template name=group-headings
  xsl:with-param name=group select=snapshot/data/group[1]/
/xsl:call-template
xsl:call-template name=column-headers
  xsl:with-param name=meta select=/snapshot/data/meta/
/xsl:call-template


I don't know exactly what happens to these parameters, but if I see  
this, it makes me think: Why not use


xsl:apply-templates select=snapshot/data/group[1] /
xsl:apply-templates select=/snapshot/data/meta /

?

If the column-headers template actually needs to applied to several  
different types of nodes (other than meta), you could redefine it from


xsl:template name=column-headers

to

xsl:template match=meta | ... | ...

snip /
What bothers me even more is since I'm programmatically controlling  
new pages

is there a better way to handle this type of processing?


Can you explain a bit further what you mean by 'programmatically  
controlling new pages'? If we get to see a bit more, maybe we can  
offer you a better way...


Right now it looks like I'll have to keep a line count in my  
stylesheet to

detect when I should programmatically start new pages.


Why? Is the processor's page-breaking algorithm insufficient for some  
reason? Can't you use XSL-FO's break-* properties to control this?



HTH!

Cheers,

Andreas

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



RE: Page Sequences

2005-12-05 Thread David Frankson
 I may be misunderstanding your question, but it seems like you just
need 
 one fo:page-sequence, with predefined fo:static-contents for the
header 
 and footer (fo:static-contents will get automatically printed on each 
 page.)  Next, put all the content that will be placed on each page in 
 the one fo:flow for the fo:page-sequence.

He is probably using the multiple page sequences to work around the
memory issues in tables.  I would say that most all of us who use 20.5
do this.  I've written lots of xsl:fo that does its own page sequencing
by counting lines of data, and we tend to design our reports differently
to overcome the limitations in fop.

I've seen mention of memory fixes on this list, but most of us are
hesitant to do our own pulls from CVS.  If the developers don't feel
like this code is worthy or stable enough for a release of any kind,
then we are not putting it into production.  However, if you were to
take the latest source and put it into a 20.5.1, we'd probably
enthusiastically take it, and it might solve a lot of the
performance/memory issues that are posted to the list.

Dave

-Original Message-
From: Glen Mazza [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 05, 2005 4:42 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Page Sequences


Clifton Craig wrote:

 I'm writing a report transform usinf XSLT for XSL-FO and I have some
basic 
 questions. What's the best way to code for multiple page sequences.
For 
 example I have some static content that I like to keep in the header
and 
 footers and I guess it doesn't matter but I'd like to reuse chunks of
XML-FO 
 for that purpose rather than replicating it to the result tree. 

I may be misunderstanding your question, but it seems like you just need

one fo:page-sequence, with predefined fo:static-contents for the header 
and footer (fo:static-contents will get automatically printed on each 
page.)  Next, put all the content that will be placed on each page in 
the one fo:flow for the fo:page-sequence.

 
 Now from within that template I want to start new page sequences and
spit out 
 the following using a new-page XSLT-template:
 

The page handling is done by FOP -- you won't know the number of pages 
needed, that is done by FOP's layout process.

 
 What bothers me even more is since I'm 
 programmatically controlling new pages is there a better way to handle
this 
 type of processing? Right now it looks like I'll have to keep a line
count in 
 my stylesheet to detect when I should programmatically start new
pages. Is 
 there a better way? How do most people do multipage reports with
variable 
 data? Iss everybody line counting in there stylesheets? 

I don't think anybody does that.  Place all your content (except for the

header and footer) in the single fo:flow of the fo:page-sequence, and 
that should work.

Glen

-
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: Page Sequences

2005-12-05 Thread Andreas L Delmelle

On Dec 6, 2005, at 00:11, David Frankson wrote:



He is probably using the multiple page sequences to work around the
memory issues in tables.  I would say that most all of us who use 20.5
do this.  I've written lots of xsl:fo that does its own page  
sequencing
by counting lines of data, and we tend to design our reports  
differently

to overcome the limitations in fop.


Ahem, I feel compelled to add: not only FOP. Didn't the OP mention  
running into trouble with XEP as well?



I've seen mention of memory fixes on this list, but most of us are
hesitant to do our own pulls from CVS.  If the developers don't feel
like this code is worthy or stable enough for a release of any kind,
then we are not putting it into production.


That's got absolutely nothing to do with not thinking that the code  
is worthy or stable enough. If not, it wouldn't be recommended on the  
list, no?
Development for the 0.20 branch was discontinued long ago. Some  
changes have been committed to the repository after the last release,  
which unfortunately never got included in the packages, but doing  
another release off that branch would have sent the wrong signals,  
IMO. You cannot on the one hand claim to terminate that branch, and  
then still pull releases off it. Makes no sense at all.


If you want it, it's there. If you're hesitant to check it out, then  
you don't really want it.

It is as simple as that.


Cheers,

Andreas

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



Re: Page Sequences

2005-12-05 Thread Glen Mazza

David Frankson wrote:


However, if you were to
take the latest source and put it into a 20.5.1, we'd probably
enthusiastically take it, and it might solve a lot of the
performance/memory issues that are posted to the list.



No doubt.  But 0.90alpha1 will be getting better.  Very few if any 
committers really understand 0.20.5 anymore, the committers who worked 
on it are mostly gone today.


Glen

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