Hi everyone :)
My first post and I'm a noob with xsl-fo so this is likely to be an
obvious answer I've just not been able to see :)
I'm trying to generate layout for labels and have setup an A4 page
with 2 columns and then a block-container for each label, expecting
the containers to flow down column one, then down column two of each
page before then moving onto a new page.
The xsl is here:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform
" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:rx="http://www.renderx.com/XSL/Extensions
">
<xsl:output method="xml" version="1.0" encoding="ISO-8859-1"/>
<xsl:template match="/labels">
<fo:root>
<fo:layout-master-set>
<fo:simple-page-master master-name="A4" page-width="210mm" page-
height="296mm" margin-left="2mm" margin-right="2mm" margin-top="8mm"
margin-bottom="8mm" >
<fo:region-body region-name="labelBody" margin-top="0mm" margin-
bottom="0mm" column-count="2" column-gap="0px"/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="A4" force-page-count="no-force">
<fo:flow flow-name="labelBody">
<xsl:apply-templates select="/labels/label" />
</fo:flow>
</fo:page-sequence>
</fo:root>
</xsl:template>
<xsl:template match="/labels/label">
<fo:block-container font-family="sans-serif" font-size="16pt"
height="50mm" text-align="center" padding="10mm" display-
align="center" margin="0pt" background-color="blue" keep-
together.within-column="always" break-after="auto">
<fo:block margin="1mm"><xsl:value-of select="./line1" /></fo:block>
<fo:block margin="1mm"><xsl:value-of select="./line2" /></fo:block>
<fo:block margin="1mm"><xsl:value-of select="./line3" /></fo:block>
<fo:block margin="1mm"><xsl:value-of select="./line4" /></fo:block>
</fo:block-container>
</xsl:template>
</xsl:stylesheet>
The blue background on the containers is just to help show what is
going on :)
And an example of the xml expected is:
<labels>
<label>
<line1>Birmingham</line1>
<line2>SS08 Kids Int</line2>
<line3>Pack 1/1</line3>
<line4>International</line4>
</label>
</labels>
Just repeat the <label> node to generate multiple labels.
The problem is that, while on the last page everything behaves as
expected, on every other proceeding page XEP only fills the first
column.
Can someone please tell me what I'm missing and why this is happening?
Thanks!
Robert
--- Robert Goldsmith Systems Integrator SP Group "Please consider the environment before printing this e-mail" *********************************************************************************** IMPORTANT - this email and the information that it contains may be confidential, legally privileged and/or protected by law. It is intended solely for the use of the individual or entity to whom it is addressed. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium (including by printing it out. Please also delete all copies of this email and any attachments from your system and shred any printed copies. We do not accept any liability for losses or damages that you may suffer as a result of your receipt of this email including but not limited to computer service or system failure, access delays or interruption, data non-delivery or mis-delivery, computer viruses or other harmful components. Any views expressed in this message are those of the individual sender except where the sender specifically states them to be the views of the SP Group. Copyright in this email and any attachments belongs to the SP Group the sender or its licensors. *********************************************************************************** ------------------- (*) To unsubscribe, send a message with words 'unsubscribe xep-support' in the body of the message to majordomo@renderx.com from the address you are subscribed from. (*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.htmlReceived on Fri Jan 11 04:44:09 2008
This archive was generated by hypermail 2.1.8 : Fri Jan 11 2008 - 04:44:15 PST