xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joseph Wright <...@otnb.com>
Subject Re: Migrating 0.95 to 1.1 - Issue forcing text to even pages in PDF. Always have last line on odd page dropped.
Date Mon, 04 Mar 2013 18:11:28 GMT
Simon the fake region approach worked perfect. We have switched our
code to use this with 1.1 and are running full test.

Thank You.

On Fri, Mar 1, 2013 at 3:14 AM, Simon Steiner
<simonsteiner1984@gmail.com> wrote:
> Hi,
>
> What about using fake region: region-name="blank"
>
>   <fo:layout-master-set>
>   <fo:simple-page-master master-name="body">
>     <fo:region-body />
>   </fo:simple-page-master>
>
>     <fo:simple-page-master master-name="blank">
>     <fo:region-body region-name="blank"/>
>   </fo:simple-page-master>
>
>     <fo:page-sequence-master master-name="LetterPages">
>       <fo:repeatable-page-master-alternatives>
>
>         <fo:conditional-page-master-reference odd-or-even="odd"
> master-reference="body"/>
>         <fo:conditional-page-master-reference odd-or-even="even"
> master-reference="blank"/>
>
>       </fo:repeatable-page-master-alternatives>
>     </fo:page-sequence-master>
>   </fo:layout-master-set>
>
> Thanks
>
> -----Original Message-----
> From: Joseph Wright [mailto:joe@otnb.com]
> Sent: Friday, March 01, 2013 12:02 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: Migrating 0.95 to 1.1 - Issue forcing text to even pages in PDF.
> Always have last line on odd page dropped.
>
> We currently use 0.95 for creating PDFs and are migrating to 1.1 as we need
> some of the new features. We noticed one of our existing features has an
> issue with 1.1.
>
> We want to have text flow on odd pages and skip even pages as we create the
> PDF. We perform this in 0.95 by having the region body margin on the even
> page consume all available space. In 0.95 this worked as you can see in the
> attached Test3_095.pdf file. When we run this in 1.1 the feature appears to
> work, but we always have 1 line of data missing at the page break. It is
> like the odd page always consumes 1 line of text even when the margin of the
> page has no room.
> In the attached example Test3_11.pdf you will notice the PDF jumps from Line
> 075 to Line 077.
>
> This is probably not a bug. It is most likely we used a trick to make this
> work in 0.95 and there is a better way to handle it.
>
> We created a simple FO file to test this scenario in 0.95 and 11. This is
> the file:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <fo:root xmlns:pcl="http://xmlgraphics.apache.org/fop/extensions/pcl"
>          xmlns:fo="http://www.w3.org/1999/XSL/Format"
>          xmlns:exslt="http://exslt.org/common"
>          xmlns:ps="http://xmlgraphics.apache.org/fop/postscript">
>
>     <fo:layout-master-set>
>         <fo:page-sequence-master master-name="simple">
>             <fo:repeatable-page-master-alternatives>
>                 <fo:conditional-page-master-reference
> master-reference="PageMaster-Body" odd-or-even="odd"/>
>                 <fo:conditional-page-master-reference
> master-reference="PageMaster-Even" odd-or-even="even"/>
>             </fo:repeatable-page-master-alternatives>
>         </fo:page-sequence-master>
>
>         <fo:simple-page-master margin="12mm 12mm 12mm 25mm"
> master-name="PageMaster-Body" page-height="279mm" page-width="216mm">
>             <fo:region-body margin="44mm 0mm 20mm 0mm"/>
>             <fo:region-before region-name="header" extent="30mm"
> display-align="after"/>
>             <fo:region-after region-name="footer" extent="2mm"
> display-align="before"/>
>         </fo:simple-page-master>
>         <fo:simple-page-master master-name="PageMaster-Even"
> page-height="279mm" page-width="216mm" margin-left="12mm"
> margin-top="0mm" margin-bottom="0mm">
>             <fo:region-body margin-top="279mm" margin-bottom="0mm"/>
>             <fo:region-after region-name="footer" extent="5mm"
> display-align="before"/>
>         </fo:simple-page-master>
>     </fo:layout-master-set>
>     <fo:page-sequence master-reference="simple"
> force-page-count="even" initial-page-number="auto-odd">
>
>         <fo:flow flow-name="xsl-region-body">
>             <fo:block>Line 001</fo:block>
>             <fo:block>Line 002</fo:block>
>             <fo:block>Line 003</fo:block>
>             <fo:block>Line 004</fo:block>
>             <fo:block>Line 005</fo:block>
>             <fo:block>Line 006</fo:block>
>             <fo:block>Line 007</fo:block>
>             <fo:block>Line 008</fo:block>
>             <fo:block>Line 009</fo:block>
>             <fo:block>Line 010</fo:block>
>             <fo:block>Line 011</fo:block>
>             <fo:block>Line 012</fo:block>
>             <fo:block>Line 013</fo:block>
>             <fo:block>Line 014</fo:block>
>             <fo:block>Line 015</fo:block>
>             <fo:block>Line 016</fo:block>
>             <fo:block>Line 017</fo:block>
>             <fo:block>Line 018</fo:block>
>             <fo:block>Line 019</fo:block>
>             <fo:block>Line 020</fo:block>
>             <fo:block>Line 021</fo:block>
>             <fo:block>Line 022</fo:block>
>             <fo:block>Line 023</fo:block>
>             <fo:block>Line 024</fo:block>
>             <fo:block>Line 025</fo:block>
>             <fo:block>Line 026</fo:block>
>             <fo:block>Line 027</fo:block>
>             <fo:block>Line 028</fo:block>
>             <fo:block>Line 029</fo:block>
>             <fo:block>Line 030</fo:block>
>             <fo:block>Line 031</fo:block>
>             <fo:block>Line 032</fo:block>
>             <fo:block>Line 033</fo:block>
>             <fo:block>Line 034</fo:block>
>             <fo:block>Line 035</fo:block>
>             <fo:block>Line 036</fo:block>
>             <fo:block>Line 037</fo:block>
>             <fo:block>Line 038</fo:block>
>             <fo:block>Line 039</fo:block>
>             <fo:block>Line 040</fo:block>
>             <fo:block>Line 041</fo:block>
>             <fo:block>Line 042</fo:block>
>             <fo:block>Line 043</fo:block>
>             <fo:block>Line 044</fo:block>
>             <fo:block>Line 045</fo:block>
>             <fo:block>Line 046</fo:block>
>             <fo:block>Line 047</fo:block>
>             <fo:block>Line 048</fo:block>
>             <fo:block>Line 049</fo:block>
>             <fo:block>Line 050</fo:block>
>             <fo:block>Line 051</fo:block>
>             <fo:block>Line 052</fo:block>
>             <fo:block>Line 053</fo:block>
>             <fo:block>Line 054</fo:block>
>             <fo:block>Line 055</fo:block>
>             <fo:block>Line 056</fo:block>
>             <fo:block>Line 057</fo:block>
>             <fo:block>Line 058</fo:block>
>             <fo:block>Line 059</fo:block>
>             <fo:block>Line 060</fo:block>
>             <fo:block>Line 061</fo:block>
>             <fo:block>Line 062</fo:block>
>             <fo:block>Line 063</fo:block>
>             <fo:block>Line 064</fo:block>
>             <fo:block>Line 065</fo:block>
>             <fo:block>Line 066</fo:block>
>             <fo:block>Line 067</fo:block>
>             <fo:block>Line 068</fo:block>
>             <fo:block>Line 069</fo:block>
>             <fo:block>Line 070</fo:block>
>             <fo:block>Line 071</fo:block>
>             <fo:block>Line 072</fo:block>
>             <fo:block>Line 073</fo:block>
>             <fo:block>Line 074</fo:block>
>             <fo:block>Line 075</fo:block>
>             <fo:block>Line 076</fo:block>
>             <fo:block>Line 077</fo:block>
>             <fo:block>Line 078</fo:block>
>             <fo:block>Line 079</fo:block>
>             <fo:block>Line 080</fo:block>
>             <fo:block>Line 081</fo:block>
>             <fo:block>Line 082</fo:block>
>             <fo:block>Line 083</fo:block>
>             <fo:block>Line 084</fo:block>
>             <fo:block>Line 085</fo:block>
>             <fo:block>Line 086</fo:block>
>             <fo:block>Line 087</fo:block>
>             <fo:block>Line 088</fo:block>
>             <fo:block>Line 089</fo:block>
>             <fo:block>Line 090</fo:block>
>             <fo:block>Line 091</fo:block>
>             <fo:block>Line 092</fo:block>
>             <fo:block>Line 093</fo:block>
>             <fo:block>Line 094</fo:block>
>             <fo:block>Line 095</fo:block>
>             <fo:block>Line 096</fo:block>
>             <fo:block>Line 097</fo:block>
>             <fo:block>Line 098</fo:block>
>             <fo:block>Line 099</fo:block>
>             <fo:block>Line 100</fo:block>
>             <fo:block>Line 101</fo:block>
>             <fo:block>Line 102</fo:block>
>             <fo:block>Line 103</fo:block>
>             <fo:block>Line 104</fo:block>
>             <fo:block>Line 105</fo:block>
>             <fo:block>Line 106</fo:block>
>             <fo:block>Line 107</fo:block>
>             <fo:block>Line 108</fo:block>
>             <fo:block>Line 109</fo:block>
>             <fo:block>Line 110</fo:block>
>             <fo:block>Line 111</fo:block>
>             <fo:block>Line 112</fo:block>
>             <fo:block>Line 113</fo:block>
>             <fo:block>Line 114</fo:block>
>             <fo:block>Line 115</fo:block>
>             <fo:block>Line 116</fo:block>
>             <fo:block>Line 117</fo:block>
>             <fo:block>Line 118</fo:block>
>             <fo:block>Line 119</fo:block>
>             <fo:block>Line 120</fo:block>
>             <fo:block>Line 121</fo:block>
>             <fo:block>Line 122</fo:block>
>             <fo:block>Line 123</fo:block>
>             <fo:block>Line 124</fo:block>
>             <fo:block>Line 125</fo:block>
>             <fo:block>Line 126</fo:block>
>         </fo:flow>
>     </fo:page-sequence>
> </fo:root>
>
> Thank you for you help.
>
> Jo
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>

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


Mime
View raw message