pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tilman Hausherr <THaush...@t-online.de>
Subject Re: Printing PDF only shows a few letters in 1.8.7+, works in 1.8.6
Date Mon, 01 Dec 2014 07:11:24 GMT

Could you try doing the same from the command line, and what happens?

java -jar pdfbox-app-1.8.7.jar PrintPDF "PDF That Prints in PDFBox 
java -jar pdfbox-app-1.8.7.jar PDFReader "PDF That Prints in PDFBox 

because I did this and all the glyphs are there... So only difference is 
that I didn't test with a scratch file like you did.


Am 01.12.2014 um 05:53 schrieb Will Herrmann:
> I have a PDF (downloadable at http://bit.ly/1w96YVz) that prints fine in PDFBox 1.8.6
(using the pdfbox-app distribution, if it matters). The text is properly spaced and prints
without issue, matching how it appears in Adobe Reader and OS X Preview.
> But in both PDFBox 1.8.7 and the latest 1.8.8 snapshot, PDFBox only prints the letters
"F u c r", with a great deal of spacing in between. Oddly, theses are the 1st, 3rd, 5th, and
7th letters of the text in the PDF. Nothing else appears on any other line.
> The code that I am using with both versions of the library is as follows:
> ------------
> String fileLocation = //File Location
> File scratchFile = new File(System.getProperty("java.io.tmpdir"), "TempFile.tmp");
> if (!scratchFile.exists())
> 	scratchFile.createNewFile();
> scratchFile.deleteOnExit();
> PDDocument doc = PDDocument.load(fileLocation, new RandomAccessFile(scratchFile, "rw"));
> doc.print();
> ------------
> I tried searching the issue tracker to see if this is a known issue, but I wasn't entirely
sure what sort of words to search for. I'd appreciate it if community could tell me if this
is a known issue or, if not, whether or not a bug report might be created for the behavior.
> Thanks in Advance,
> -Will Herrmann

View raw message