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 bonekrusher <dj...@yahoo.com> on 2008/06/23 19:43:38 UTC
FOP 0.20.5 Preserve Whitespace
Hi,
I am using FOP 0.20.5 - I am trying to preserve whitespace but it's not
working. I tried both examples below with no luck.
<fo:block xsl:use-attribute-sets="text-10" linefeed-treatment="preserve"
white-space-collapse="false" wrap-option="wrap" white-space="pre">
<xsl:apply-templates/>
</fo:block>
<fo:block xsl:use-attribute-sets="text-10" linefeed-treatment="preserve"
white-space-collapse="false" wrap-option="wrap"
white-space-treatment="preserve">
<xsl:apply-templates/>
</fo:block>
Thanks
--
View this message in context: http://www.nabble.com/FOP-0.20.5-Preserve-Whitespace-tp18074357p18074357.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: FOP 0.20.5 Preserve Whitespace
Posted by bonekrusher <dj...@yahoo.com>.
Andreas,
I got it working.
<xsl:when test="@space = 'preserve'">
<fo:block xsl:use-attribute-sets="text-10" white-space-collapse="false"
wrap-option="wrap" white-space-treatment="preserve">
<xsl:value-of select="."/>
</fo:block>
</xsl:when>
Thanks,
Andreas Delmelle-2 wrote:
>
> On Jun 23, 2008, at 19:43, bonekrusher wrote:
>
>> I am using FOP 0.20.5 - I am trying to preserve whitespace but it's
>> not
>> working. I tried both examples below with no luck.
>
> Ouch! Is there a chance of upgrading to 0.95? 0.95 is much more
> compliant when it comes to those particular properties...
>
>> <fo:block xsl:use-attribute-sets="text-10" linefeed-
>> treatment="preserve"
>> white-space-collapse="false" wrap-option="wrap" white-space="pre">
>> <xsl:apply-templates/>
>> </fo:block>
>
> Note: 'white-space' is a shorthand property retained in XSL-FO for
> compatibility reasons with CSS.
> As such, white-space="pre" means the exact same thing as the other
> three specified property-values /plus/ white-space-treatment="preserve".
>
> see: http://www.w3.org/TR/xsl/#white-space
>
> As a matter of best practice, either use the shorthand or use the
> native properties, but specifying both is a (tiny bit) wasteful.
>
> I'm not sure if there's a workaround for you if you're stuck with
> 0.20.5... :/
>
>
> Cheers
>
> Andreas
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/FOP-0.20.5-Preserve-Whitespace-tp18074357p18089016.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: FOP 0.20.5 Preserve Whitespace
Posted by bonekrusher <dj...@yahoo.com>.
Andreas,
Having a "crack" at it is a good way of saying it. Its still on the the "to
do" list. As for my white space... I will keep working on it. :)
Regards,
Andreas Delmelle-2 wrote:
>
> On Jun 23, 2008, at 20:04, bonekrusher wrote:
>
>> As always, thank you for your help. I am stuck with 0.20.5 due to
>> the fact
>> that 0.94 or 0.95 do not support either fo:table-continued or fox
>> extension
>> "Continued-label".
>
> Right! Sorry, stupid question. :-/
> Now I remember... You were thinking about having a crack at
> implementing fo:table-retrieve-marker, no?
>
> As far as I remember, 0.20.5's behavior is non-compliant to such an
> extent that to preserve linefeeds, white-space-collapse should be set
> to false, and white-space-treatment has no effect... Bad news if you
> need white-space preservation around linefeeds, IIRC. :(
>
>
> Andreas
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/FOP-0.20.5-Preserve-Whitespace-tp18074357p18088589.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: FOP 0.20.5 Preserve Whitespace
Posted by Andreas Delmelle <an...@telenet.be>.
On Jun 23, 2008, at 20:04, bonekrusher wrote:
> As always, thank you for your help. I am stuck with 0.20.5 due to
> the fact
> that 0.94 or 0.95 do not support either fo:table-continued or fox
> extension
> "Continued-label".
Right! Sorry, stupid question. :-/
Now I remember... You were thinking about having a crack at
implementing fo:table-retrieve-marker, no?
As far as I remember, 0.20.5's behavior is non-compliant to such an
extent that to preserve linefeeds, white-space-collapse should be set
to false, and white-space-treatment has no effect... Bad news if you
need white-space preservation around linefeeds, IIRC. :(
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: FOP 0.20.5 Preserve Whitespace
Posted by bonekrusher <dj...@yahoo.com>.
Hi Andreas,
As always, thank you for your help. I am stuck with 0.20.5 due to the fact
that 0.94 or 0.95 do not support either fo:table-continued or fox extension
"Continued-label".
Bones
Andreas Delmelle-2 wrote:
>
> On Jun 23, 2008, at 19:43, bonekrusher wrote:
>
>> I am using FOP 0.20.5 - I am trying to preserve whitespace but it's
>> not
>> working. I tried both examples below with no luck.
>
> Ouch! Is there a chance of upgrading to 0.95? 0.95 is much more
> compliant when it comes to those particular properties...
>
>> <fo:block xsl:use-attribute-sets="text-10" linefeed-
>> treatment="preserve"
>> white-space-collapse="false" wrap-option="wrap" white-space="pre">
>> <xsl:apply-templates/>
>> </fo:block>
>
> Note: 'white-space' is a shorthand property retained in XSL-FO for
> compatibility reasons with CSS.
> As such, white-space="pre" means the exact same thing as the other
> three specified property-values /plus/ white-space-treatment="preserve".
>
> see: http://www.w3.org/TR/xsl/#white-space
>
> As a matter of best practice, either use the shorthand or use the
> native properties, but specifying both is a (tiny bit) wasteful.
>
> I'm not sure if there's a workaround for you if you're stuck with
> 0.20.5... :/
>
>
> Cheers
>
> Andreas
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/FOP-0.20.5-Preserve-Whitespace-tp18074357p18074808.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: FOP 0.20.5 Preserve Whitespace
Posted by Andreas Delmelle <an...@telenet.be>.
On Jun 23, 2008, at 19:43, bonekrusher wrote:
> I am using FOP 0.20.5 - I am trying to preserve whitespace but it's
> not
> working. I tried both examples below with no luck.
Ouch! Is there a chance of upgrading to 0.95? 0.95 is much more
compliant when it comes to those particular properties...
> <fo:block xsl:use-attribute-sets="text-10" linefeed-
> treatment="preserve"
> white-space-collapse="false" wrap-option="wrap" white-space="pre">
> <xsl:apply-templates/>
> </fo:block>
Note: 'white-space' is a shorthand property retained in XSL-FO for
compatibility reasons with CSS.
As such, white-space="pre" means the exact same thing as the other
three specified property-values /plus/ white-space-treatment="preserve".
see: http://www.w3.org/TR/xsl/#white-space
As a matter of best practice, either use the shorthand or use the
native properties, but specifying both is a (tiny bit) wasteful.
I'm not sure if there's a workaround for you if you're stuck with
0.20.5... :/
Cheers
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org