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 MARTIN Franck <fr...@c-s.fr> on 2002/05/14 16:11:45 UTC

AWT renderer

Hi all,

I can't find any example that shows how to use the AWT renderer. I
assume it is different from the other renderers since the target is not
a file. If someone could provide me with a sample code, i would
appreciate that very much.

Thank you

Franck MARTIN


Re: AWT renderer

Posted by "J.Pietschmann" <j3...@yahoo.de>.
MARTIN Franck wrote:
> I did just that and it helped a bit. I executed the followind code :

I meant look how AWTStarter uses the FOP core classes. The class
itself is not exactly meant for reuse.


> But i get an exception during the AWTStarter constructor. Unfortunately
> there's no message (it's null).

Try to create a PDF. If the error persists, you have probably
a buggy FO source.

J.Pietschmann



Re: AWT renderer

Posted by MARTIN Franck <fr...@c-s.fr>.
>>Get the FOP source distribution and look into
org/apache/fop/apps/AWTStarter.java and whatever catches your eye in this
package.

I did just that and it helped a bit. I executed the followind code :

    String[] clo =
{"-d","-awt","-xml",this.nomFichierXML,"-xsl",this.nomFichierXSL};
    try {
      AWTStarter awts = new AWTStarter(new CommandLineOptions(clo));
      awts.run();
      return "Success";
    }catch(Exception e){System.out.println("Failure: "+e.getMessage());return
"Failure: "+e.getMessage();}

But i get an exception during the AWTStarter constructor. Unfortunately
there's no message (it's null).

The debug messages are the following :

[DEBUG]: Input mode:
[DEBUG]: xslt transformation
[DEBUG]: xml input file: N:\Echange\essai\IncapEntr.xml
[DEBUG]: xslt stylesheet: N:\Echange\essai\IncapEntr.xsl
[DEBUG]: Output mode:
[DEBUG]: awt on screen
[DEBUG]: OPTIONS
[DEBUG]: no user configuration file is used [default]
[DEBUG]: debug mode on
[DEBUG]: dump configuration
[DEBUG]: quiet mode on
[DEBUG]: base directory: file:/N:/Echange/essai/

I can't figure out what i did wrong. Any idea??

Thanks alot

Franck

"J.Pietschmann" a écrit :

> MARTIN Franck wrote:
> > I can't find any example that shows how to use the AWT renderer. I
> > assume it is different from the other renderers since the target is not
> > a file. If someone could provide me with a sample code, i would
> > appreciate that very much.
>
> Get the FOP source distribution and look into
>   org/apache/fop/apps/AWTStarter.java and whatever
> catches your eye in this package.
>
> J.Pietschmann


Re: AWT renderer

Posted by "J.Pietschmann" <j3...@yahoo.de>.
MARTIN Franck wrote:
> I can't find any example that shows how to use the AWT renderer. I
> assume it is different from the other renderers since the target is not
> a file. If someone could provide me with a sample code, i would
> appreciate that very much.

Get the FOP source distribution and look into
  org/apache/fop/apps/AWTStarter.java and whatever
catches your eye in this package.

J.Pietschmann