Re: Keeping tables together with FOP 0.92b
The XSL-FO style approach would be not to use always for the keep property but an integer number. But this hasn't been implemented, yet. On 13.09.2006 21:15:13 cknell wrote: I' recently back to working with FOP. I have a document that consists of a number of tables with widely-varying numbers of rows. Sometimes several tables will fit entirely onto a single page, with others will span several pages. The problem I'm having involves those cases where a table almost fits onto a page, but one or two rows flow over onto the next page. I'd like to start a new page if the table won't fit onto the current one. I've tried some keep-with-previous tacks, but when a very long table won't fit onto a single page FOP errors out. Does anyone have a sure-fire method for causing a table to start on a new page if all the rows won't fit on the current page? Jeremias Maerki - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Keeping tables together with FOP 0.92b
Hi I'm not an experienced user, but have you tried keep-with-next? It did work for me, although with other undesired side-effects (see my post with the superlong title keep-with-next causes last row of previous table to come along. regards - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Keeping tables together with FOP 0.92b
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 9:15 PM I' recently back to working with FOP. I have a document that consists of a number of tables with widely-varying numbers of rows. Sometimes several tables will fit entirely onto a single page, with others will span several pages. The problem I'm having involves those cases where a table almost fits onto a page, but one or two rows flow over onto the next page. I'd like to start a new page if the table won't fit onto the current one. I've tried some keep-with-previous tacks, but when a very long table won't fit onto a single page FOP errors out. Hi, keep-with-previous property doesn't work for table list (see [1]) And this is not yet done in FOP_TRUNK (see [2]) Does anyone have a sure-fire method for causing a table to start on a new page if all the rows won't fit on the current page? If you know rows height, you can add an explicit page break when needed, for example using the XPATH sequence position() mod XXX, where XXX is the number of rows per page. Thanks. Charles Knell [1] http://xmlgraphics.apache.org/fop/knownissues.html [2] http://xmlgraphics.apache.org/fop/changes.html HTH, Pascal - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Keeping tables together with FOP 0.92b
Pascal Sancho [EMAIL PROTECTED] wrote on 09/14/2006 07:47:09 AM: -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 9:15 PM I' recently back to working with FOP. I have a document that consists of a number of tables with widely-varying numbers of rows. Sometimes several tables will fit entirely onto a single page, with others will span several pages. The problem I'm having involves those cases where a table almost fits onto a page, but one or two rows flow over onto the next page. I'd like to start a new page if the table won't fit onto the current one. I've tried some keep-with-previous tacks, but when a very long table won't fit onto a single page FOP errors out. Hi, keep-with-previous property doesn't work for table list (see [1]) And this is not yet done in FOP_TRUNK (see [2]) Does anyone have a sure-fire method for causing a table to start on a new page if all the rows won't fit on the current page? If you know rows height, you can add an explicit page break when needed, for example using the XPATH sequence position() mod XXX, where XXX is the number of rows per page. We use the position() mod XXX technique to break page sequences and release memory, but there is one major issue we always run in to: when a cell wraps and the row height increases, your row counts are now off and the breaks no longer occur at predicted intervals. This can be minimized if you have _very_ predictable data in your cells. -Lou Thanks. Charles Knell [1] http://xmlgraphics.apache.org/fop/knownissues.html [2] http://xmlgraphics.apache.org/fop/changes.html HTH, Pascal - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Keeping tables together with FOP 0.92b
I know that if a table has 20 or more rows, it won't fit on a single page. I deal with such large tables in my XSLT like this: xsl:template match=table xsl:variable name=page-break-flag xsl:choose xsl:when test=count(child::column) gt; 19page/xsl:when xsl:otherwiseauto/xsl:otherwise /xsl:choose /xsl:variable ... fo:table-row keep-with-next=always break-before={$page-break-flag} fo:table-cellfo:block/fo:block/fo:table-cell ... /xsl:template Here I am dealing with a situation where the number of rows on a particular table may not be very large, but because other tables appear on the page before it, the page breaks in the middle of the table, like this.: Page Break Table 1 row row row row Table 2 row row row row row row row row Table 3 row row row row Page Break row row row row Table 4 row row row row In my case, the row heights are always the same, so Louis' warning is not applicable. In order to know if I should start a new page before beginning to print Table 3, I would have to know the number of rows that already appear on the page (or some other more clever work-around), but I can't think of a way to get that information. Does this suggest a solution to anyone? Thanks. -- Charles Knell [EMAIL PROTECTED] - email ÿþ <