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 Awadhoot Aphale <aw...@broadcom.com.INVALID> on 2019/01/24 15:08:32 UTC

Apache FOP 2.3

Hi,

I have upgraded the FOP library in the legacy application from 0.94 to 2.3.
I am using JDK 1.6.

I have made necessary changes in the source code to work with FOP 2.3.

After the upgrade, XML to PDF conversion has stopped working. I am using
xsl to convert to pdf.

Following is the section of xsl where error is reported,

<xsl:when test="@id = 'fourthForm'">
<fo:block background-image="{$imgPath}" border-style="solid"
border-width="0.2pt"
text-align="left" font-size="8pt"
font-weight="bold" color="white" padding-top="1pt"
padding-bottom="1pt">
<xsl:value-of select="tr/td/span" />
</fo:block>

imgPath is defined as shown below,

<xsl:variable name="imgPath1" select="html/body/input/@value" />
<xsl:variable name="imgPath2"
select="'/images/table_header_center.png'" />

<xsl:variable name="imgPath" select="concat($imgPath1,$imgPath2)" />

Error reported is,

SystemId Unknown; Line #106; Column #41; java.lang.NullPointerException

If I remove background-image="{$imgPath}" from fo:block, it works fine.

Not sure what is wrong here. Any help would be appreciated.

Thank you.
Thanks,
Awadhoot

Re: Apache FOP 2.3

Posted by Matt Kynaston <ma...@claritum.com>.
On Thursday, 24 January 2019, Awadhoot Aphale
<aw...@broadcom.com.invalid>
>
>
> SystemId Unknown; Line #106; Column #41; java.lang.NullPointerException
>
> If I remove background-image="{$imgPath}" from fo:block, it works fine.
>

I don’t use the XSLT side of it all, but if you can intercept the actual
FOP being generated it would almost certainly help.


-- 
Matt Kynaston
Lead Developer
www.claritum.com

Claritum Limited. Registered Office 30 Gay Street Bath BA1 2PA, registered
in England and Wales, No. 3878694.