On 05/01/2011 10:52, gen1986 wrote:

Hello,
Stepan and Eric thanks for the suggestions but the whole thing must be done
in java (the charting is only a part of the app).
Jeremias solution is close to what I must do.

After following the explanations of Jeremias and reading the sources of
Barcode4J, etc. I manage to get something out, but it still doesn't work and
I'm not sure about some points.

1) I don't have to call imageManager.convertImage(image, flavors) right ?
It's the fop framework who will do that. However if it's true, something is
going wrong because my converters are not executed.

Right, the Image Loader framework takes care of that. Did you add the file named "org.apache.xmlgraphics.image.loader.spi.ImageConverter" to the JAR containing your code in META-INF\services sub directory as suggested by Jeremias? This is needed in order for the Image Loader Framework to be made aware of your converter.
2) When I'm running the transformation I've got an error
GRAVE: Image not available. URI: (instream-object). Reason:
org.apache.xmlgraphics.image.loader.ImageException: The file format is not
supported. No ImagePreloader found for null (No context info available).

After googling a bit I've found that we have to add the following line to
the fop conf :<prefer-renderer>true</prefer-renderer>
That is not the correct solution. The prefer-renderer option forces use of the older renderers. The old Renderers don't benefit from the latest bug fixes and improvements that have been made to the painters.

If I'm doing so I've got another error : No handler defined for my
namespace...

So instead asking a lot of questions I've uploaded a basic test project so
you can see what I'm doing wrong.
http://old.nabble.com/file/p30594894/Fop-ChartExtension.rar
Fop-ChartExtension.rar

Thanks for your help!

Thanks,

Chris

Eugen



<snip/>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Reply via email to