Title: RE: Change page size

    Forest, Sebastien wrote:
    > Hi
    > I need to produce a pdf with fop 0.20.5rc3a with a combinaison of two
    > differents page size. The document is in 8.5 X 11 inch but when I
    > encounter a special tag in the xml file I need to switch to 11 X 17
    > inch. Is there a way to switch page-master depending on the tag in the xml.

    Create a new page-sequence when you encounter the tag thats orders a
    change in page dimensions. Of course, this will cause text after the tag
    to be moved to a new page.

When I encounter the tag I create a new page-sequence but FOP give me an error because the page-sequence must be in the fo:root and not in a fo:block. I'am able to change page-sequence, but only if the tag I'm looking for is at the root. If this tag ("graphic" in my example) is a child of another tag I didn't find a way to control it.

Exemple:
<?xml version="1.0" encoding="UTF-8"?>
<wp>
  <para>para 1
    <para>para 1.1</para>
  </para>
  <para>para 2</para>
  <para>para 3</para>
  <graphic>graphic 1</graphic>
  <para>para 4</para>
  <graphic>graphic 2</graphic>
  <graphic>graphic 3</graphic>
  <para>para 5
    <para>para 5.1
      <graphic>graphic 4</graphic>
    </para>
  </para>
</wp>

Can anyone help me?

Reply via email to