Convert Image to PDF with FOP

Q

How to convert an image file into a PDF file with FOP?

✍: FYIcenter.com

A

FOP allows you to convert a single image file into a PDF file without any XSL-FO format file. Here is how to do this:

fyicenter> cd \local\fop-2.x\fop

fyicenter> fop -imagein examples\fo\graphics\page.gif \temp\page.pdf
... org.apache.fop.events.LoggingEventListener processEvent
INFO: Rendered page #1.

The output PDF file is located at \temp\page.pdf. Open it with a PDF viewer, you will see something like this:
FOP Example - Convert GIF to PDF

 

"FOP -awt" - Generate Output on Screen

Run barcode.fo Example in FOP

FOP Commands and Examples

⇑⇑ FAQ for FOP (Formatting Object Processor)

2016-07-03, 3608🔥, 0💬