I wasn't precise enough in my first posting. Next try...

>> I wonder how I can procude legal empty pages (and then suppress
>> them)?
>
> Forced blank pages are mainly created by page count constraints, for
> example a break-before="odd-page" will insert a page break [..].

My empty page results from missing content in the source XML file if the user does not select at least one topic on the web page to be rendered as pdf.
The cover sheet with (an empty) TOC is generated OK by the stylesheet. Now the main content should be selected and put into the flow of a second page master:


<fo:page-sequence-master>
  ...
  <fo:page-sequence-master master-name="PageMasterTwo">
    <fo:repeatable-page-master-alternatives>
      <fo:conditional-page-master-reference
          master-reference="PageMasterTwoOne"
          blank-or-not-blank="not-blank"/>
      <fo:conditional-page-master-reference
          master-reference="PageMasterTwoTwo"
          blank-or-not-blank="blank"/>
  </fo:repeatable-page-master-alternatives>
  ...
</fo:page-sequence-master>

<fo:page-sequence master-reference="PageMasterTwo">
  ... static content ...
  <fo:flow flow-name="xsl-region-body">
    <xsl:apply-templates select="company_info"/>
    <xsl:apply-templates select="address_list"/>
    ... other templates ...
  </fo:flow>
</fo:page-sequence>


The problem arises if there are no nodes <company_info>, <address_list>, etc.: The FO produced is an empty flow.
<fo:flow flow-name="xsl-region-body"/>


I thought this would result in an empty page and my page master with condition "blank" would be selected.
Instead I get the error message from FOP (see my first posting). I played a bit with the fo and got the results stated in my first posting.



Thanks again! Ralf



Reply via email to