Re: Supporting multiple languages, including CJK

2016-10-18 Thread John Hewson
> On 12 Oct 2016, at 05:24, Daniel King wrote: > > Hi, > > I'm attempting to write text to a PDF in situations where I need to support > multiple languages on a single PDF. This may include regular latin characters > as well as CJK characters. I've tried many attempts to do this and have it

Re: How to certify a PDF

2016-10-18 Thread Damien Butaye
Hello Tilman, Here follows two links explaining the difference : 1. http://www.investintech.com/resources/articles/certifyingsigningpdf/ 2. http://stackoverflow.com/questions/16710439/how-to-add-blank-page-in-digitally-signed-pdf-using-java/16711745#16711745 Damien. 2016-10-18 8:49

Re: How to certify a PDF

2016-10-18 Thread Diego Azevedo
From what I'm reading on ISO 32000, the certification Signature is a normal signature, but with a DocMDP transform method. So the ou should do something like this: PDSignature signature = new PDSignature; [..] //do your thing COSDictinary dictionary = signature.getCOSObject(); //Cr

Re: How to certify a PDF

2016-10-18 Thread Damien Butaye
Hello Diego, Thank you for your help. I just tried your code but it seems that it doesn't work. The result has nor signature nor certify element. I'll try again. If you have any idea, don't hesitate ;) Damien. 2016-10-18 13:04 GMT+02:00 Diego Azevedo : > From what I'm reading on ISO 32000, the

RE: Supporting multiple languages, including CJK

2016-10-18 Thread Daniel King
I'm curious why you shouldn't load fonts that are scanned in by PDFBox using org.apache.fontbox.util.autodetect.FontDirFinder and instead reference a hard coded system directory? -Original Message- From: John Hewson [mailto:j...@jahewson.com] Sent: Tuesday, October 18, 2016 3:09 AM To:

Re: How to certify a PDF

2016-10-18 Thread Diego Azevedo
Hello Damien, I made a typo: dictionary.setItem("Reference", reference_*s*_); // Add Array to Signature dictionary There is no point in creating the array, add the "SigRef" dictionary to it... and not use the array on the "Sig" dictionary. So... just add the 'S' to the variable and re-

Re: How to certify a PDF

2016-10-18 Thread Damien Butaye
Nice! Thank you very much! (Btw, it could be nice to integrate in a future release a method certify() in the PDSignature object). obrigado! 2016-10-18 15:42 GMT+02:00 Diego Azevedo : > Hello Damien, > > I made a typo: > > dictionary.setItem("Reference", reference*s*); // Add Array to Signature

Removing the Javascript from a PDF

2016-10-18 Thread email
Hi, I am fairly new to PDFBox and I am wondering if there is a way to find and remove all the Javascript in a PDF file. I have a script to do with with IText but the version I am using is fairly old and I would like to use PDFBox for all the PDF manipulation if possible. Thanks, Mike

Re: How to certify a PDF

2016-10-18 Thread Damien Butaye
One last question, have you got the "blue ribbon" on the top the pdf when you open it with Acrobat? In my case not, although it is well certified as shown in the Acrobat Signature Panel. 2016-10-18 15:58 GMT+02:00 Damien Butaye : > Nice! Thank you very much! > > (Btw, it could be nice to integr

Re: How to certify a PDF

2016-10-18 Thread Diego Azevedo
No, but in my case it would never happen, because my certificate is trusted for signing, but not certifying: Image: http://imgur.com/XYZCB8H []'s Diego Azevedo On 18/10/2016 13:30, Damien Butaye wrote: One last question, have you got the "blue ribbon" on the top the pdf when you open it with

Re: [PDFBox 2.0.3] PDFRenderer.renderImageWithDPI Text Upside-Down and Out of Position

2016-10-18 Thread Tilman Hausherr
Am 18.10.2016 um 08:39 schrieb Tilman Hausherr: Hello John, This works in the unreleased 2.0.4 https://repository.apache.org/content/groups/snapshots/org/apache/pdfbox/pdfbox-app/2.0.4-SNAPSHOT/ I suspect that this is related to the PDFBOX-3000 issue, although your file doesn't have transparen

Re: Removing the Javascript from a PDF

2016-10-18 Thread Tilman Hausherr
Am 18.10.2016 um 15:59 schrieb em...@michaelfesser.ca: Hi, I am fairly new to PDFBox and I am wondering if there is a way to find and remove all the Javascript in a PDF file. I have a script to do with with IText but the version I am using is fairly old and I would like to use PDFBox for all

Re: [PDFBox 2.0.3] PDFRenderer.renderImageWithDPI Text Upside-Down and Out of Position

2016-10-18 Thread John Planow
Thanks, Tilman! I appreciate you taking the time to look into this. I tried the latest 2.0.4 snapshot and unfortunately, it exhibits the same behavior. I'd appreciate any further advice you have, but it's looking like I may have to use a different approach. With gratitude, John -- *JOHN PLANOW

Re: [PDFBox 2.0.3] PDFRenderer.renderImageWithDPI Text Upside-Down and Out of Position

2016-10-18 Thread Tilman Hausherr
Am 18.10.2016 um 19:47 schrieb John Planow: Thanks, Tilman! I appreciate you taking the time to look into this. I tried the latest 2.0.4 snapshot and unfortunately, it exhibits the same behavior. I'd appreciate any further advice you have, but it's looking like I may have to use a different appr

Re: Supporting multiple languages, including CJK

2016-10-18 Thread Andreas Lehmkuehler
Am 18.10.2016 um 15:32 schrieb Daniel King: I'm curious why you shouldn't load fonts that are scanned in by PDFBox using org.apache.fontbox.util.autodetect.FontDirFinder and instead reference a hard coded system directory? As you don't know what you get when asking the FontMapper for "Arial" es

Re: [PDFBox 2.0.3] PDFRenderer.renderImageWithDPI Text Upside-Down and Out of Position

2016-10-18 Thread John Planow
That did the trick. :-) Thanks. At a quick glance, I didn't see a release timeline anywhere. Any ideas when 2.0.4 will be released officially? -- *JOHN PLANOW *| SOFTWARE DEVELOPER jpla...@parchment.com direct 916.367.6868 ext. 1623 3000 Lava Ridge Court, Suite 210, Roseville, CA 95661 *Parchmen

RE: Supporting multiple languages, including CJK

2016-10-18 Thread Daniel King
Okay, that makes sense. Back to my root problem. I have a string which I want to write to a PDF. This string contains both latin and Arabic characters. I can't use Arial Unicode MS since we are running on a linux system and I have been told we have some licensing concerns as well since PDFBox em

Re: Supporting multiple languages, including CJK

2016-10-18 Thread John Hewson
> On 18 Oct 2016, at 15:08, Daniel King wrote: > > Okay, that makes sense. Back to my root problem. I have a string which I want > to write to a PDF. This string contains both latin and Arabic characters. I > can't use Arial Unicode MS since we are running on a linux system and I have > been