You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xalan.apache.org by David Marston/Cambridge/IBM <da...@us.ibm.com> on 2002/02/07 19:36:20 UTC

Re: call-template question (actually, xsl:number)

Bug: xsl:number assumes grouping-size="3" grouping-separator="," by
default, instead of no grouping. Morten Primdahl later wrote:

>Anyway, the solution seems to be to either translate($val,',','') or
> <xsl:number level="any" grouping-separator="," grouping-size="10"/>

The latter looks like the preferable workaround, since it will cause
less work for the processor. Set grouping-size even bigger, like 20.
.................David Marston



Re: call-template question (actually, xsl:number)

Posted by "Frank E. Weiss" <fr...@well.com>.
A grouping-size of 0 also works and seems more natural and less arbitrary. However I've been searching the
specifications (XSLT, Xalan, Java) for what a zero value should do but hit a dead end. Xalan's
org.apache.xalan.templates.ElemNumber depends on java.text.DecimalFormat, but the Java1.2 spec seems silent on the
matter. Just wondering if you'd still prefer a large number over zero.

David Marston/Cambridge/IBM wrote:

> Bug: xsl:number assumes grouping-size="3" grouping-separator="," by
> default, instead of no grouping. Morten Primdahl later wrote:
>
> >Anyway, the solution seems to be to either translate($val,',','') or
> > <xsl:number level="any" grouping-separator="," grouping-size="10"/>
>
> The latter looks like the preferable workaround, since it will cause
> less work for the processor. Set grouping-size even bigger, like 20.
> .................David Marston