質問

私は私のPDFファイルのフッターにレンダリングするためのいくつかの静的なテキストの文字を強調しようとしていますが、私のXSL内のタグの適切な組み合わせを把握することはできません。どのように私はこれを実現することができますか?

例:

<!-- Footer content -->
<xsl:template name="footer.content">  
  <xsl:param name="pageclass" select="''"/>
  <xsl:param name="sequence" select="''"/>
  <xsl:param name="position" select="''"/>
  <xsl:param name="gentext-key" select="''"/>

<fo:block>
<xsl:choose>

...
<xsl:when test="$sequence = 'odd' and $position = 'left'">
        <xsl:text>&#x00A9;<emphasis>My</emphasis>Company</xsl:text>
</xsl:when>
...
</xsl:choose>
</fo:block>
</xsl:template>

この例では、xsltprocの中でエラーが発生します。ヘルプ!

役に立ちましたか?

解決

fo:inlineを使用してみてください。

私はあなたが達成しようとしたり、あなたが取得しているエラーの種類何が、このような何かをしようとしている種類強調のものではありませんよ。

<!-- Footer content -->
<xsl:template name="footer.content">  
  <xsl:param name="pageclass" select="''"/>
  <xsl:param name="sequence" select="''"/>
  <xsl:param name="position" select="''"/>
  <xsl:param name="gentext-key" select="''"/>

<fo:block>
<xsl:choose>

...
<xsl:when test="$sequence = 'odd' and $position = 'left'">
        <xsl:text>&#x00A9;</xsl:text><fo:inline text-decoration="underline">My</fo:inline><xsl:text>Company</xsl:text>
</xsl:when>
...
</xsl:choose>
</fo:block>

希望このことができます。

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top