You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Jasmin Mehta <jm...@mdnotes.com> on 2003/03/26 17:29:08 UTC
xsl-fo question for
Hi,
I want to create PDF output from xml document using xsl-fo. The required
format is, should get label-text, label-text, label-text, label-text all
4 pairs in single row. Also I want to keep this as a header of the page.
For example,
Patient: Gina Latta Age : 60
Sex: M Patient ID#: 7678678768
Also all labels must be bold and have different font/size than
respective text value.
I am trying with below code:
<fo:static-content flow-name="xsl-region-before">
<fo:list-block provisional-distance-between-starts="3cm"
provisional-label-separation="0.15cm" font-size="12pt">
<!-- list item for Patient Name -->
<fo:list-item>
<fo:list-item-label end-indent="label-end()">
<fo:block text-align="start"
font-size="12pt"
font-family="serif"
font-weight="bold"
line-height="14pt">
Patient:
</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent="1.5cm">
<fo:block text-align="left" space-after.optimum="14pt"
white-space-collapse="false">
<xsl:apply-templates select="Patient_LName"/>,
<xsl:apply-templates select="Patient_FName"/>
</fo:block>
</fo:list-item-body>
</fo:list-item>
<fo:list-item>
<fo:list-item-label end-indent="label-end()">
<fo:block text-align="start"
font-size="12pt"
font-family="serif"
font-weight="bold"
line-height="14pt">
Age:
</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent="1.5cm">
<fo:block text-align="left"
space-after.optimum="14pt" white-space-collapse="false">
<xsl:apply-templates select="Note_2"/>
</fo:block>
</fo:list-item-body>
</fo:list-item>
</fo:static-content>
But it is displaying the result in separate rows.
'Patient: name'
'Age : age'
Please help.
Thanks
Jasmin