Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


Tip of the Day
Language: Java
Expertise: Intermediate
Mar 5, 2007

Using the FOP-to-AWT Viewer

When you want to use the FOP-to-AWT Viewer from a Java application, you can use the ExampleAWTViewer.java. This application is available in the \fop-0.20.5\examples\embedding\java\embedding directory. Using this class, you don't have to develop the application from scratch.

Just copy the application, rename it, and make the following replacements:


//code to be replaced
...
//Setup directories
File baseDir = new File(".");
...
//Setup input and output files
File fofile=new File(baseDir, "xml/fo/helloworld.fo");
...


//code for replacement
...
//Setup directories
File baseDir = new File("YOUR_DIRECTORY");
...
//Setup input and output files
File fofile=new File(baseDir, "YOUR FO FILE");
...

Leonard Anghel
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap