Re: [iText-questions] remove watermark layer

2011-06-16 Thread 1T3XT BVBA
On 16/06/2011 13:25, jjalink wrote: I have stopped using this code, since it completely clears page 1 in some of the files. I don't remember the context of the problem. Is it about OCG? Note that two OCG bugs were fixed in iText 5.1.1: http://itextpdf.com/history/?branch=51&node=511 * Bugf

Re: [iText-questions] remove watermark layer

2011-06-16 Thread jjalink
I have stopped using this code, since it completely clears page 1 in some of the files. I could not consistently re-create the issue re-processing the same file in debug environment worked. Instead - system code changed to locate the "clean" file and add watermark to it. PS. We paid for the iText

Re: [iText-questions] remove watermark layer

2011-01-25 Thread 1T3XT BVBA
RBolotov wrote: > And sure thing, if PDF does not contain any optional content groups with > radio button behavior, field OCGRadioGroup becomes null. I added > if (OCGRadioGroup == null) > OCGRadioGroup = new PdfArray(); > after line 1606 in PdfStamperImp, rebuilt iText with a

Re: [iText-questions] remove watermark layer

2011-01-24 Thread RBolotov
I've got a similar problem. I want to add new layer to a PDF document, already containing several layers. The most obvious way would be something like this: PdfReader reader = new PdfReader(new RandomAccessFileOrArray("c:\\books\\new book.pdf"), null);

Re: [iText-questions] remove watermark layer

2011-01-06 Thread 1T3XT BVBA
Op 6/01/2011 20:43, Paul Cooper schreef: > Which version of iText generated these pdfs? I always use the version that is in the SVN repository. What I'd need, is not the code, but a PDF that allows me to reproduce the problem. I've tested with iText created PDFs and with PDFs created with Acrobat

Re: [iText-questions] remove watermark layer

2011-01-06 Thread Paul Cooper
1T3XT, I did not notice this post, as it isn't a reply to the original thread... Which version of iText generated these pdfs? I've tried both 2.1.4 (yes, I know, not the latest version of v2) and 5.0.5. Both generated errors; 2.1.4 threw a NullPointerException closing the PdfStamper, while 5.0.

Re: [iText-questions] remove watermark layer

2011-01-05 Thread 1T3XT
Op 5/01/2011 18:23, Paul Cooper schreef: Wow. How so, wow? So, shouldn’t this code be removed from your library, as it seems to be useless and bug-inducing? See the attached example. Are you saying the code is useless? If I have a file ocg.pdf, then I can use the code to get info about Pdf

Re: [iText-questions] remove watermark layer

2011-01-05 Thread Paul Cooper
y, January 05, 2011 4:35 AM To: itext-questions@lists.sourceforge.net Subject: Re: [iText-questions] remove watermark layer Op 5/01/2011 0:40, Paul Cooper schreef: Has this issue ever been resolved? Yes, we've received sample PDFs and we provided a custom solution for which we were paid. Cont

Re: [iText-questions] remove watermark layer

2011-01-05 Thread 1T3XT BVBA
Op 5/01/2011 0:40, Paul Cooper schreef: Has this issue ever been resolved? Yes, we've received sample PDFs and we provided a custom solution for which we were paid. Contact consultancy with sufficient samples and your specific requirements, and we'll make you an offer. http://itextpdf.com/supp

Re: [iText-questions] remove watermark layer

2011-01-04 Thread Paul Cooper
eron.com] Sent: Wednesday, June 23, 2010 8:34 AM To: Post all your questions about iText here Subject: Re: [iText-questions] remove watermark layer This code works perfectly for an adobe created layer, but always fails on an iText layered file. Attached are one of each. public static

Re: [iText-questions] remove watermark layer

2010-10-31 Thread 1T3XT info
On 31/10/2010 10:41, jjalink wrote: > > This is the latest OCG removal code from Bruno: > > http://itext-general.2136553.n4.nabble.com/file/n3020962/RemoveChanges1.java > RemoveChanges1.java That code makes some assumptions about the original PDF. For instance: it assumes that the page content is

Re: [iText-questions] remove watermark layer

2010-10-31 Thread jjalink
This is the latest OCG removal code from Bruno: http://itext-general.2136553.n4.nabble.com/file/n3020962/RemoveChanges1.java RemoveChanges1.java -- View this message in context: http://itext-general.2136553.n4.nabble.com/remove-watermark-layer-tp2264258p3020962.html Sent from the iText - Gener

Re: [iText-questions] remove watermark layer

2010-06-23 Thread Jaakov Jalink
There is something wrong with the way I created the iText layers - I'll resolve it. Thanks anyway. This footnote confirms that this email message has been scanned by PineApp Mail-SeCure for the presence of ma

Re: [iText-questions] remove watermark layer

2010-06-23 Thread Jaakov Jalink
PDF version 1.4 - file attached -Original Message- From: Paulo Soares [mailto:psoa...@glintt.com] Sent: Wednesday, June 23, 2010 12:35 PM To: Post all your questions about iText here Subject: Re: [iText-questions] remove watermark layer What PDF are you using? Paulo -Original

Re: [iText-questions] remove watermark layer

2010-06-23 Thread Paulo Soares
What PDF are you using? Paulo -Original Message- From: jjalink [mailto:jaak...@syneron.com] Sent: Wednesday, June 23, 2010 9:25 AM To: itext-questions@lists.sourceforge.net Subject: Re: [iText-questions] remove watermark layer I narrowed it down to 4 code lines, and it still throws a

Re: [iText-questions] remove watermark layer

2010-06-23 Thread jjalink
I narrowed it down to 4 code lines, and it still throws a NullPointerException on close line. if i remove the Map line, i just get a copy of the inFile. PdfReader reader = new PdfReader(inFile); PdfStamper stamper = new PdfStamper(reader, new FileOutputStream(outFile)); Ma

Re: [iText-questions] remove watermark layer

2010-06-22 Thread jjalink
here it is again - line separated: Exception in thread "main" java.lang.NullPointerException at com.itextpdf.text.pdf.PdfWriter.fillOCProperties(PdfWriter.java:2567) at com.itextpdf.text.pdf.PdfStamperImp.close(PdfStamperImp.java:189) at com.itextpdf.text.pdf.PdfStamper.cl

[iText-questions] remove watermark layer

2010-06-22 Thread jjalink
the code blow throws a an exception in the stamper.close line i see no reason for the exception - any idea?? exception: Exception in thread "main" java.lang.NullPointerException at com.itextpdf.text.pdf.PdfWriter.fillOCProperties(PdfWriter.java:2567) at com.itextpdf.text.pdf.PdfSta