Using PDFBox

2010-12-02 Thread Steffanina, Jeff

I saw some references to Apache PDFBox and took a look at it.   I
currently use FOP / XSLT, etc to generate printed documents.  

Is there some specific feature(s) of PDFBox that I should take a closer
look at???   


Jeff 



RE: Using PDFBox

2010-12-02 Thread Eric Douglas
FOP has options to create PDF files and to send output directly to the
printer.  If those are working for you, I'm not sure why you might need
PDFBox.
I use the PDFBox project because FOP sending output directly to the
printer didn't work for me.  In one case it went to the wrong printer.
In another case it went to the wrong tray.
I used the FOP option to send the output to a ByteArrayOutputStream
instead, read the data from that stream into a ByteArrayInputStream
which works as input for PDFBox which creates a Pageable object, which I
was able to pass in to the Java print methods which gave me more control
over the output.
The PDFBox object can be saved as a PDF file, but the FOP
ByteArrayOutputStream can also be redirected to a FileOutputStream to
save directly.  I'm not sure what advantage PDFBox might have there.
One possible advantage would be to have the output saved in a Pageable
reuseable object if perhaps you want to send the same report to 2
different printers.



From: Steffanina, Jeff [mailto:jeff.steffan...@marriott.com] 
Sent: Thursday, December 02, 2010 9:19 AM
To: fop-users@xmlgraphics.apache.org
Subject: Using PDFBox




I saw some references to Apache PDFBox and took a look at it.   I
currently use FOP / XSLT, etc to generate printed documents.  

Is there some specific feature(s) of PDFBox that I should take a closer
look at???   


Jeff 



Bug 49837 - Soft Hyphen

2010-12-02 Thread Klearchos Klearchou
Hello to All,

 

I have Fop version 0.95 and I am trying to upgrade to 1.0 but I have
problems with the following regression bug (49837
https://issues.apache.org/bugzilla/show_bug.cgi?id=49837 ).

Is there any workaround for this?

 

I found that if I retype some specific hyphens (that used to look like boxes
from my TOAD) it worked.

 

Regards



fop 1.0 and svg error:

2010-12-02 Thread Tom Browder
I'm running fop 1.0 on Linux Ubuntu 10.04 LTS.

I'm trying to use an svg image via docbook source.  When I run the fo
file through fop to get pdf I get the following error as it encounters
my svg in the fo file:

Dec 2, 2010 2:05:08 PM org.apache.fop.events.LoggingEventListener processEvent
SEVERE: Image not available. URI: ./images/era-1.svg. Reason:
org.apache.xmlgraphics.image.loader.ImageException: The file format is
not supported. No ImagePreloader found for ./images/era-1.svg (See
position 25375:172)
Dec 2, 2010 2:05:08 PM org.apache.fop.events.LoggingEventListener processEvent
SEVERE: Image not found. URI: ./images/era-1.svg. (No context info available)

I have looked at the fop info on svg and see nothing that helps.  I'm
running with the xml graphics commons via Ubuntu installation.  I'm
using Sun Java.  Folks on the docbook list seem to have no problem
with using svg.

Note that I use svg successfully in my xsl customization layer so I
must be doing something wrong.

Thanks for any pointers.

Regards,

-Tom

Thomas M. Browder, Jr.
Niceville, Florida
USA

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



RE: fop 1.0 and svg error:

2010-12-02 Thread Eric Douglas
Is this your first attempt or was this working with any version of FOP
previously?
Are you able to reference any other type of images?
Of course SVG works.  I'm using SVG with FOP 1.0, though mine is
embedded in the XSL.  I'd think it has more to do with the file path.
Possible reasons:
File is not there.
Reference path ./ is not referring to what you think it is.
Bad or missing URIResolver?

It could just have to do with docbook.  I haven't used docbook myself
and I have seen others on this list complain of problems connecting
docbook to FOP.

-Original Message-
From: Tom Browder [mailto:tom.brow...@gmail.com] 
Sent: Thursday, December 02, 2010 3:10 PM
To: fop-users@xmlgraphics.apache.org
Subject: fop 1.0 and svg error:

I'm running fop 1.0 on Linux Ubuntu 10.04 LTS.

I'm trying to use an svg image via docbook source.  When I run the fo
file through fop to get pdf I get the following error as it encounters
my svg in the fo file:

Dec 2, 2010 2:05:08 PM org.apache.fop.events.LoggingEventListener
processEvent
SEVERE: Image not available. URI: ./images/era-1.svg. Reason:
org.apache.xmlgraphics.image.loader.ImageException: The file format is
not supported. No ImagePreloader found for ./images/era-1.svg (See
position 25375:172) Dec 2, 2010 2:05:08 PM
org.apache.fop.events.LoggingEventListener processEvent
SEVERE: Image not found. URI: ./images/era-1.svg. (No context info
available)

I have looked at the fop info on svg and see nothing that helps.  I'm
running with the xml graphics commons via Ubuntu installation.  I'm
using Sun Java.  Folks on the docbook list seem to have no problem with
using svg.

Note that I use svg successfully in my xsl customization layer so I must
be doing something wrong.

Thanks for any pointers.

Regards,

-Tom

Thomas M. Browder, Jr.
Niceville, Florida
USA

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


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



Re: fop 1.0 and svg error:

2010-12-02 Thread Tom Browder
On Thu, Dec 2, 2010 at 14:18, Eric Douglas edoug...@blockhouse.com wrote:
 Is this your first attempt or was this working with any version of FOP
 previously?

First attempt at using svg as a normal figure.

 Are you able to reference any other type of images?

Yes, png files work fine.

 Of course SVG works.  I'm using SVG with FOP 1.0, though mine is
 embedded in the XSL.  I'd think it has more to do with the file path.

That may be, but I've tried absolute file paths as well.

 Possible reasons:
 File is not there.
 Reference path ./ is not referring to what you think it is.
 Bad or missing URIResolver?

Could be.  Isn't that part of fop?

 It could just have to do with docbook.  I haven't used docbook myself
 and I have seen others on this list complain of problems connecting
 docbook to FOP.

That could well be, although when I raised this problem there they
said they weren't having problems.

Thanks, Eric.

-Tom

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



Re: fop 1.0 and svg error:

2010-12-02 Thread Tom Browder
My bad!  I found I had a bad svg file.  Fop works great!

Sorry for the false alarm.

Regards,

-Tom

Thomas M. Browder, Jr.
Niceville, Florida
USA

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



RE: Add-ons for Apache FOP

2010-12-02 Thread Lucian Opris
Thank you again for the answer. Considering I'll use fo:external-graphic, is
there easy way to determine page size in style? For large attachments (100
pages) having many fo:page-sequence will not slow down the rendering
process?
Thanks,

Lucian Opris

-Original Message-
From: Jeremias Maerki [mailto:d...@jeremias-maerki.ch] 
Sent: Thursday, December 02, 2010 2:07 AM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Add-ons for Apache FOP

fox:external-document doesn't allow any additional content besides the
full-page images. You'll have to determine the page sizes yourself and
use normal fo:page-sequence elements to set up the image for full-page
display.

The PDF size increases that much because there is currently no easy way
to cache the already transferred PDF objects so they are not transferred
again for each page. I've experimented with that some time ago but had
to disable that feature because of massive problems. I may revisit this
at some point (no current plans). If you have to add larger PDFs to a
document I suggest you do that as a post-processing step using Apache
PDFBox.

On 01.12.2010 21:45:05 Lucian Opris wrote:
 Also, I've noticed that without using fox:external-document the pdf size
is
 about 17K  then using fox:external-document to call a 608K PDF I've got a
 resulting 2.104K PDF. Do you know what could cause such a dramatic file
 increase?
 
 Lucian Opris
 
 -Original Message-
 From: Lucian Opris [mailto:lucian.op...@bluematrix.com] 
 Sent: Wednesday, December 01, 2010 3:12 PM
 To: fop-users@xmlgraphics.apache.org
 Subject: RE: Add-ons for Apache FOP
 
 Thank you Jeremias,
 I've added the fox:external-document
 src=C:/FOP1/fop-1.0/attachments/my.pdf/ to work in conjunction with new
 namespace
 xmlns:fox=http://xmlgraphics.apache.org/fop/extensions; and it worked
fine.
 Now the question is can we stamp header and footers on external pdf called
 with fox since fox:external-document is peer with fo:page-sequence?
 
 
 Lucian Opris
 
 -Original Message-
 From: Jeremias Maerki [mailto:d...@jeremias-maerki.ch] 
 Sent: Wednesday, December 01, 2010 2:13 AM
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: Add-ons for Apache FOP
 
 Hi Lucian
 
 On 30.11.2010 20:35:48 Lucian Opris wrote:
  Hi Jeremias,
  I'm using your FOP add-ons to call PDF attachments as images using
  fo:external-graphic src=my-doc.pdf#page=1/.
  Is there a way to preserve pdf page size for landscape pages or should I
 use
  fox:external-document src=my-doc.pdf/?
 
 Support for landscape pages is available in the latest release (2.0.0)
 of the plug-in.
 
  Are PDFs with mixed pagesizes work with fox:external-document and have
 the
  footer stamping start at the same point from left?
 
 Not sure what you mean by that. With fox:external-document the target
 page will have the exact size of the respective input page. This should
 work for each page independently.



Jeremias Maerki


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




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