Details
Description
Hello,
Can you please help me on the issue as below?
[Issue]
print PDF file witch has font embedded subset.
I am trying to use PDFBOX 1.8.2 to print PDF file.
When I use printJob.print() to print PDF file, I got the error like this:
<2013/11/08 11:14:53 org.apache.pdfbox.filter.FlateFilter decode
fatal: FlateFilter: stop reading corrupt stream due to a DataFormatException>
And I checked the property of the PDF file and it's like below:
[Font]
SimSun(embedded subset)
type: TrueType(CID)
enconding: Identity-H
Here is my java Code:
[Code]
PDDocument document = PDDocument.load( pdfFileName );
PrinterJob printJob = PrinterJob.getPrinterJob();
printJob.setJobName(new File(pdfFileName).getName());
if(printerName != null )
{
PrintService[] printService = PrinterJob.lookupPrintServices();
boolean printerFound = false;
for(int i = 0; !printerFound && i < printService.length; i++)
{
if(printService[i].getName().indexOf(printerName) != -1)
}
}
printJob.setPageable(new PDPageable(document, printJob));
if( silentPrint || printJob.printDialog())
I'm sorry, i can't find the way to attatch the pdf file.
Is it possible for PDFBOX 1.8.2 to print pdf properly?
what about PDFBOX 2.0?
Thanks in advance.
Regards