Loading ...
Sorry, an error occurred while loading the content.

Newbie orphan related question

Expand Messages
  • Steve Osbourne
    HelloI am a newbie, working with the orphans attribute.I have produced a table which displays a series of rows. Each row has a type attribute. The types
    Message 1 of 1 , Dec 5, 2001
    • 0 Attachment
      Hello

      I am a newbie, working with the orphans attribute.

      I have produced a table which displays a series of rows. Each row has a type attribute. The types are:
      A = Author
      B = Book

      The author name and books are displayed as follows

      Author A

      Book 1 ... .... ... ...
      Book 2 ... .... ... ...
      Book 3 ... ... ... ...

      Author B

      Book 1 ... ... ...
      Book 2 ... .. ...
      etc...

      The problem is where to define an orphan on the Book types. The rule is if there are < 4 Books displayed at the end of the page then the Author and associated books must move to the next page.

      My general code

      <xsl:template>
      <xsl:flow ...>

      <fo:table
      text-align="center">
      ...

      <fo:table-body>
      <xsl:for-each select="./table/table-row">
      <fo:table-row>
      <fo:table-cell>
      <fo:block text-align="start" font-weight="bold">
      <xsl:for-each select="./row-title">
      <xsl:call-template name="replace-with-FArea"/> <!--call a template which displays the author, book -->
      </xsl:for-each>
      </fo:block>
      </fo:table-cell>
      <xsl:for-each select="./row-value">
      <fo:table-cell>
      <fo:block text-align="end" font-weight="bold" space-after.optimum="0.5pt">
      <xsl:value-of select="."/>
      <xsl:choose>
      <xsl:when test="string(following-sibling::row-symb)">
      <xsl:value-of select="following-sibling::row-symb"/>
      </xsl:when>
      <xsl:otherwise>
      <xsl:text> </xsl:text>
      </xsl:otherwise>
      </xsl:choose>
      </fo:block>
      </fo:table-cell>
      </xsl:for-each>
      </fo:table-row>

      <!-- If statements follow to give spaces between A and B, as well as B and D types -->

      </xsl:for-each>
      </fo:table-body>
      </fo:table>
      </fo:flow>
      </xsl:template>




      --

      _______________________________________________
      1 cent a minute calls anywhere in the U.S.!

      http://www.getpennytalk.com/cgi-bin/adforward.cgi?p_key=RG9853KJ&url=http://www.getpennytalk.com
    Your message has been successfully submitted and would be delivered to recipients shortly.