Re: [xsl] Elegant way to create an empty line

Subject: Re: [xsl] Elegant way to create an empty line
From: Jan Hoeft <mail@xxxxxxxxxxx>
Date: Thu, 09 Jul 2009 22:13:38 +0200
Hi Alain,
thank you. Your idea was the final hint.

My solution looks like this:

<xsl:template match="p[not(node())]" priority="1">
<fo:block>
<fo:leader/>
</fo:block>
</xsl:template>
<xsl:template match="p">
<fo:block>
<xsl:apply-templates/>
</fo:block>
</xsl:template>


Ken, the <p> implementation of the Antenna House HTML2FO converter does not work like in HTML Empty paragraphs are converted to empty blocks which collapse.

Thanks for your help
Jan



COUTHURES Alain schrieb:
Hi Jan,

Don't you need a specific template with match="p[not(node())]" priority="1"

Cheers,

Alain Couthures
<agenceXML>
http://www.agencexml.com
Hi,
is there an elegant way to create empty lines using block elements?

My template is quite simple:

<xsl:template match="p">
  <fo:block>
     <xsl:apply-templates/>
  </fo:block>
</xsl:template>

How do I tell FO to create a new line for each <p/>?
Cheers
Jan

Current Thread