#1268 Make the Docbook XSLs work with Apache FOP 1.1

closed-invalid
None
5
2012-11-28
2012-11-26
Radu Coravu
No

The Apache FOP 1.1 which was released about a month ago has a much stricter policy of checking if references (image references in particular) are made using the proper URI syntax.

For example a Docbook <note> generates an image reference in the XSL-FO file like this:

<fo:external-graphic width="auto" height="auto"
content-width="36pt"
src="url(D:\projects\eXml\frameworks/docbook/xsl/images/note.png)"
/>

which breaks Apache FOP because the path is a local file system path and not an URL-like path.

We added a bug on the Apache FOP list about this:

https://issues.apache.org/bugzilla/show_bug.cgi?id=54098

but they will not add configuration settings in order to have FOP more lax.

Regards,
Radu

Radu Coravu
http://www.oxygenxml.com

Discussion

  • Robert Stayton
    Robert Stayton
    2012-11-26

    I'm not able to duplicate this problem. Normally DocBook XSL does not generate full paths for images. In the case of a <note> element, the path is generated from the name of the element to get "note.png", and that is appended to the value of the stylesheet param 'admon.graphics.path', which by default is set to a relative path "images/". It is not clear to me how the rest of that path you show is being generated.

    It looks like perhaps the saxon:systemId() extension function is being invoked somewhere to generate the full path.

    Can you describe how Oxygen generates the .fo file?

     
  • Radu Coravu
    Radu Coravu
    2012-11-27

    Hi Bob,

    Sorry about this, indeed in the default Docbook PDF scenarios we bundle we have the parameter "admon.graphics.path" set to a file path and not to an URL path.

    Sorry about this, you can close this one.

    Regards,
    Radu

     
  • Robert Stayton
    Robert Stayton
    2012-11-28

    • assigned_to: nobody --> bobstayton
    • status: open --> closed-invalid