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 Michael König <Mi...@ms-koenig.de> on 2002/01/09 21:08:20 UTC
problems with unicode in a table
Hello,
I use a table where I find a strange behaviour.
Whenever I use a unicode-character like the Euro-Currency-Symbol \u20AC
the following columns a more or less shifted to the right.
Like this:
no unicode used 19,00
with unicode 19,00
no unicode 20,00
The table is formated like this:
<fo:table-row>
<fo:table-cell>
<fo:block><xsl:value-of select="summe/beschreibung"/></fo:block>
</fo:table-cell>
<fo:table-cell>
<fo:block text-align="end"><xsl:value-of
select="summe/betrag"/></fo:block>
</fo:table-cell>
</fo:table-row>
and the xml:
..
<summe><beschreibung>no unicode
used</beschreibung><betrag>19,00</betrag></summe>
<summe><beschreibung>with unicode
€</beschreibung><betrag>20,00</betrag></summe>
..
Any idea?
By the way, the DOM-Document has encoding="UTF-8"
Thanks, Michael
Re: problems with unicode in a table
Posted by Chuck Paussa <Ch...@systems.dhl.com>.
Michael,
I saw this discussed before. Apparently your fontname.xml file does not
have a character width defined for the euro symbol. So, FOP calculates
the starting position for printing the text assuming that the euro
symbol has no size. The fix was to alter the fontname.xml file pointed
to by your userconfig.xml file. If this is an embedded font, then you
have to actually hack the fontname.xml file that is being compiled into
FOP. I really have no idea how you would do any of these things but,
that was the thread of the discussion.
Chuck
Michael König wrote:
>Hello,
>I use a table where I find a strange behaviour.
>
>Whenever I use a unicode-character like the Euro-Currency-Symbol \u20AC
>the following columns a more or less shifted to the right.
>
>Like this:
>
>no unicode used 19,00
>with unicode 19,00
>no unicode 20,00
>
>
>The table is formated like this:
> <fo:table-row>
> <fo:table-cell>
> <fo:block><xsl:value-of select="summe/beschreibung"/></fo:block>
> </fo:table-cell>
> <fo:table-cell>
> <fo:block text-align="end"><xsl:value-of
>select="summe/betrag"/></fo:block>
> </fo:table-cell>
> </fo:table-row>
>
>and the xml:
>..
><summe><beschreibung>no unicode
>used</beschreibung><betrag>19,00</betrag></summe>
><summe><beschreibung>with unicode
>€</beschreibung><betrag>20,00</betrag></summe>
>..
>
>Any idea?
>By the way, the DOM-Document has encoding="UTF-8"
>
>Thanks, Michael
>
>