RE: Possible to avoid page breaks between table rows with keep-together?
Alexander, It's hard to tell, but I'm assuming that the row that contains the text There should not be a page break now is supposed to stay on the same page as the rows containing the texts With this line and And this line? If so, you could accomplish this a couple of different ways. You could either use keep-with-next.within-page=always or (keep-with-previous) on the rows that you want to keep together, or you could wrap all related rows inside a nested table with keep-together.within-page=always on that table. Realize that you're currently specifying keep-together.within-page on the individual rows, and as you can see, those rows are keeping together and not allowing a page break in the middle. If you want a series of rows to keep-together than you have to wrap those rows inside a parent block where keep-together is specified on that block. Or...use keep-with-next/previous. The approach that works the best will likely be determined by the algorithm you use to create this FO. Sean From: Marx, Alexander [mailto:[EMAIL PROTECTED] Sent: Monday, August 11, 2008 4:50 AM To: fop-users@xmlgraphics.apache.org Subject: Possible to avoid page breaks between table rows with keep-together? Hello FOP-Users, I need some help with using keep-together correctly. I am using the latest 0.95 release. I have attached a sample purchase order document which has a number of order lines with different kinds of additional information. The requirement is: One order line should be kept together on one page including all additional information. If the order line does not fit on the same page it is supposed to trigger a page break. I have tried to set keep-together accordingly but if you look at the output of the sample xml you'll find that there still is a page break within the same order line Can you point me in the right direction how it is possible to achieve the intended behaviour? Regards, Alexander -- CONFIDENTIALITY NOTICE This message and any included attachments are from Cerner Corporation and are intended only for the addressee. The information contained in this message is confidential and may constitute inside or non-public information under international, federal, or state securities laws. Unauthorized forwarding, printing, copying, distribution, or use of such information is strictly prohibited and may be unlawful. If you are not the addressee, please promptly delete this message and notify the sender of the delivery error by e-mail or you may call Cerner's corporate offices in Kansas City, Missouri, U.S.A at (+1) (816)221-1024.
Re: Possible to avoid page breaks between table rows with keep-together?
So you want to keep multiple table-rows together. You can do that by using keep-with-next.within-page=always if you have already specified keep-together on the row. Essentially, with the keep-together on the rows you make sure they can't be split and with the keep-with next, you can glue individual table-rows together. HTH On 11.08.2008 11:49:51 Marx, Alexander wrote: Hello FOP-Users, I need some help with using keep-together correctly. I am using the latest 0.95 release. I have attached a sample purchase order document which has a number of order lines with different kinds of additional information. The requirement is: One order line should be kept together on one page including all additional information. If the order line does not fit on the same page it is supposed to trigger a page break. I have tried to set keep-together accordingly but if you look at the output of the sample xml you'll find that there still is a page break within the same order line Can you point me in the right direction how it is possible to achieve the intended behaviour? Regards, Alexander Jeremias Maerki - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Java heap overflow error - unknown reason
I have been trying to troubleshoot a java heap error for a good while, and I have researched the error messages on this site without luck. I have a 6000+ page document with numerous tables - the largest tables being at the front of the document, where they run fine. In dividing the document, I find that it gets to slightly over 3000 pages before it dies. Because the tables are simple two-column tables, I tried setting them up as lists in list-blocks, but I still get a similar error. Following are the errors from both the table and list versions: TABLE: --- Nested Exception --- java.lang.OutOfMemoryError: Java heap space at java.util.Arrays.copyOf(Arrays.java:2882) at java.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:100) at java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:390) at java.lang.StringBuffer.append(StringBuffer.java:224) at org.apache.fop.layoutmgr.AbstractLayoutManager.addChildLM(AbstractLayoutManager.java:275) at org.apache.fop.layoutmgr.AbstractLayoutManager.addChildLMs(AbstractLayoutManager.java:289) at org.apache.fop.layoutmgr.BlockLayoutManager.createLineManager(BlockLayoutManager.java:205) at org.apache.fop.layoutmgr.BlockLayoutManager.createNextChildLMs(BlockLayoutManager.java:173) at org.apache.fop.layoutmgr.LMiter.hasNext(LMiter.java:40) at org.apache.fop.layoutmgr.AbstractLayoutManager.getChildLM(AbstractLayoutManager.java:116) at org.apache.fop.layoutmgr.BlockStackingLayoutManager.getBreakBefore(BlockStackingLayoutManager.java:978) at org.apache.fop.layoutmgr.BlockStackingLayoutManager.addKnuthElementsForBreakBefore(BlockStackingLayoutManager.java:954) at org.apache.fop.layoutmgr.BlockStackingLayoutManager.getNextKnuthElements(BlockStackingLayoutManager.java:253) at org.apache.fop.layoutmgr.BlockLayoutManager.getNextKnuthElements(BlockLayoutManager.java:116) at org.apache.fop.layoutmgr.table.TableCellLayoutManager.getNextKnuthElements(TableCellLayoutManager.java:170) at org.apache.fop.layoutmgr.table.RowGroupLayoutManager.createElementsForRowGroup(RowGroupLayoutManager.java:120) at org.apache.fop.layoutmgr.table.RowGroupLayoutManager.getNextKnuthElements(RowGroupLayoutManager.java:60) at org.apache.fop.layoutmgr.table.TableContentLayoutManager.getKnuthElementsForRowIterator(TableContentLayoutManager.java:220) at org.apache.fop.layoutmgr.table.TableContentLayoutManager.getNextKnuthElements(TableContentLayoutManager.java:172) at org.apache.fop.layoutmgr.table.TableLayoutManager.getNextKnuthElements(TableLayoutManager.java:247) at org.apache.fop.layoutmgr.BlockStackingLayoutManager.getNextKnuthElements(BlockStackingLayoutManager.java:294) at org.apache.fop.layoutmgr.BlockLayoutManager.getNextKnuthElements(BlockLayoutManager.java:116) at org.apache.fop.layoutmgr.BlockStackingLayoutManager.getNextKnuthElements(BlockStackingLayoutManager.java:294) at org.apache.fop.layoutmgr.BlockLayoutManager.getNextKnuthElements(BlockLayoutManager.java:116) at org.apache.fop.layoutmgr.StaticContentLayoutManager$StaticContentBreaker.getNextKnuthElements(StaticContentLayoutManager.java:318) at org.apache.fop.layoutmgr.AbstractBreaker.getNextBlockList(AbstractBreaker.java:552) at org.apache.fop.layoutmgr.AbstractBreaker.doLayout(AbstractBreaker.java:302) at org.apache.fop.layoutmgr.StaticContentLayoutManager.doLayout(StaticContentLayoutManager.java:240) at org.apache.fop.layoutmgr.PageSequenceLayoutManager.layoutSideRegion(PageSequenceLayoutManager.java:156) at org.apache.fop.layoutmgr.PageSequenceLayoutManager.finishPage(PageSequenceLayoutManager.java:163) at org.apache.fop.layoutmgr.AbstractPageSequenceLayoutManager.makeNewPage(AbstractPageSequenceLayoutManager.java:284) at org.apache.fop.layoutmgr.PageBreaker.handleBreakTrait(PageBreaker.java:494) LIST: --- Nested Exception --- java.lang.OutOfMemoryError: Java heap space at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2427) at java.lang.Class.getMethod0(Class.java:2670) at java.lang.Class.getMethod(Class.java:1603) at org.apache.commons.logging.LogFactory.getContextClassLoader(LogFactory.java:438) at org.apache.commons.logging.LogFactory$1.run(LogFactory.java:222) at java.security.AccessController.doPrivileged(Native Method) at org.apache.commons.logging.LogFactory.getFactory(LogFactory.java:218) at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:351) at org.apache.fop.layoutmgr.inline.BasicScaledBaselineTable.init(BasicScaledBaselineTable.java:37) at org.apache.fop.layoutmgr.inline.ScaledBaselineTableFactory.makeFontScaledBaselineTable(ScaledBaselineTableFactory.java:44) at
Re: Java heap overflow error - unknown reason
On Aug 11, 2008, at 18:43, DavidJKelly wrote: Hi I have been trying to troubleshoot a java heap error for a good while, and I have researched the error messages on this site without luck. I have a 6000+ page document with numerous tables - the largest tables being at the front of the document, where they run fine. In dividing the document, I find that it gets to slightly over 3000 pages before it dies. Because the tables are simple two-column tables, I tried setting them up as lists in list-blocks, but I still get a similar error. Following are the errors from both the table and list versions: It depends on how large the individual page-sequences are. If you cram all 6000 pages into one page-sequence, and do not use forced breaks anywhere, you're going to need what looks like an unreasonable amount of heap to render the document (because the current implementation of the layout algorithm does not consider any page- break final, unless in case of a forced break, or the end of the page- sequence). If possible, try to break up the document into multiple page- sequences, and the issue should disappear. Other hint: if the document contains a lot of fo:inlines, try simply replacing those with fo:wrapper. Cheers Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Repeating table/group headers on subsequent pages
The XML: ?xml version=1.0 encoding=utf-8? PIPELINEREPORT ROW ROWNUM=1 FocusEducation/Focus OrganizationORG1/Organization ProjectPRJ1/Project StatusSTAT1/Status Primary_Sector/Primary_Sector Amount$1.00/Amount Funding_TypeFT1/Funding_Type /ROW ROW ROWNUM=2 Focus/Focus OrganizationORG2/Organization ProjectPRJ2/Project StatusSTAT2/Status Primary_Sector/Primary_Sector Amount$1.00/Amount Funding_TypeFT2/Funding_Type /ROW ROW ROWNUM=3 Focus/Focus OrganizationORG3/Organization ProjectPRJ3/Project StatusSTAT3/Status Primary_Sector/Primary_Sector Amount$1.00/Amount Funding_TypeFT3/Funding_Type /ROW ROW ROWNUM=4 FocusInventor Support/Focus OrganizationORG4/Organization ProjectPRJ4/Project StatusSTAT4/Status Primary_Sector/Primary_Sector Amount$1.00/Amount Funding_TypeFT4/Funding_Type /ROW ROW ROWNUM=5 Focus/Focus OrganizationORG5/Organization ProjectPRJ5/Project StatusSTAT5/Status Primary_Sector/Primary_Sector Amount$1.00/Amount Funding_TypeFT5/Funding_Type /ROW The output I want: Education -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | -- ORG1 PRJ1STAT1 $1.00 FT1 -- ORG2 PRJ2STAT2 $1.00 FT2 -- ORG3 PRJ3STAT3 $1.00 FT3 -- Inventor Support -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | -- ORG4 PRJ4STAT4 $1.00 FT4 -- ORG5 PRJ5STAT5 $1.00 FT5 -- I have everything in place. The last, crucial missing piece is, if, say, the report breaks between the ORG4 and ORG5 rows, how do I get the rows: Inventor Support -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | To appear at the top of the next page? I know table-header-markers aren't supported yet. Is page markers the way to go? If so, I am struggling with how to use them to get these results. Thank you for any help you can give me. ~Paige - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Repeating table/group headers on subsequent pages
On Aug 11, 2008, at 22:51, Paige Balter wrote: Hi snip/ I have everything in place. The last, crucial missing piece is, if, say, the report breaks between the ORG4 and ORG5 rows, how do I get the rows: Inventor Support -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | To appear at the top of the next page? I know table-header-markers aren't supported yet. Is page markers the way to go? If so, I am struggling with how to use them to get these results. Assuming that you can create a separate fo:table for the rows containing ORG1-ORG3, if necessary (?) I think you need a simple fo:table-header to contain the header rows. Default behavior is that the header is repeated on page-breaks, so that should lead to the result you seek. HTH! Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Repeating table/group headers on subsequent pages
Thanks for your reply, Andreas. Sorry if my question was unclear, it is so hard to explain everything in an email. I have many more rows than just 5, I was keeping the number brief for example purposes. By creating a table header, I can get -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | -- to show up on the top of the next page, but the crucial part is the group header, that part that is bold below: *Inventor Support * -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | -- The report may have as many as 100 rows with 10 or so groups in it, and I was hoping that any time a group got split across pages, that the group header could appear at the top of the next page along with the table header. Please let me know if this still doesn't make sense. Again, thank you so much for your help. ~Paige Andreas Delmelle wrote: On Aug 11, 2008, at 22:51, Paige Balter wrote: Hi snip/ I have everything in place. The last, crucial missing piece is, if, say, the report breaks between the ORG4 and ORG5 rows, how do I get the rows: Inventor Support -- | Organization | Project | Status | Primary Sector | Amount | Funding Type | To appear at the top of the next page? I know table-header-markers aren't supported yet. Is page markers the way to go? If so, I am struggling with how to use them to get these results. Assuming that you can create a separate fo:table for the rows containing ORG1-ORG3, if necessary (?) I think you need a simple fo:table-header to contain the header rows. Default behavior is that the header is repeated on page-breaks, so that should lead to the result you seek. HTH! Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]