pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alain <alain...@yahoo.com>
Subject Re: Printing a PDF doc with images
Date Tue, 05 Feb 2013 20:51:41 GMT
Eliot, thanks for the reply!

I am currently running 1.7.1, where did you find release 1.8?

Alain




________________________________
 From: Eliot Kimber <ekimber@rsicms.com>
To: "users@pdfbox.apache.org" <users@pdfbox.apache.org>; Alain <alaineec@yahoo.com>

Sent: Tuesday, February 5, 2013 3:46 PM
Subject: Re: Printing a PDF doc with images
 
Not sure if it's the same issue, but I ran into a problem with scanned
images that used an overlay mask. Those images are not handled correctly by
PDFBox 1.7.1 but the handling is corrected in 1.8 as of last November some
time. So you might try using the latest 1.8 build and see if it resolves
your issue.

Cheers,

E.

On 2/5/13 2:39 PM, "Alain" <alaineec@yahoo.com> wrote:

> 
> 
> 
> Using the following code in an applet to print a PDF directly to a printer
> defined on the client machine.
> 
> 
> DocFlavor flavor = DocFlavor.SERVICE_FORMATTED.PAGEABLE;
> PrintRequestAttributeSet patts = new HashPrintRequestAttributeSet();
> PrintService[] ps = PrintServiceLookup.lookupPrintServices(flavor, patts);
> if (ps.length == 0) {
>     throw new IllegalStateException("No Printer found");
> }  
> PrinterJob job = PrinterJob.getPrinterJob();
> job.setPrintService(ps[7]);
> PDFParser parser = new PDFParser(new ByteArrayInputStream(pdfDoc));
> parser.parse();
> job.setPageable(parser.getPDDocument());
> job.print();
> 
> 
> 
> My problem is that scanned page's in the document do not print correctly.
> 
> First was experiencing a page printed in a gray shade. Removed the compression
> from the scanner
> and now the pages are completely blank.
> 
> All other pages generated with itext print fine, the pages that are generated
> via a scanner do not.
> 
> Can anyone shed some light on what i am doing wrong?
> 
> Just started using PDFBox and trying to move forward.
> 
> Thanks
> Alain

-- 
Eliot Kimber
Senior Solutions Architect, RSI Content Solutions
"Bringing Strategy, Content, and Technology Together"
Main: 512.554.9368
www.rsicms.com
www.rsuitecms.com
Book: DITA For Practitioners, from XML Press,
http://xmlpress.net/publications/dita/practitioners-1/
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message