Re: [iText-questions] Silently printing a PDF to a network printer

2006-07-06 Thread Matt Krevs
Leonard Rosenthol leonardr at pdfsages.com writes:

 
 At 07:30 PM 7/5/2006, Matt Krevs wrote:
 It seems the ability to send a PDF to a network printer from within 
 a java app is some sort of holy grail right now.
 
  Depends on the printer and OS involved.
 
  If the printer is an Adobe Postscript Level 3 printer - then 
 it's a no-brainer.
 
  If you are running on Mac OS X or any Unix with CUPS 
 installed - it's a no-brainer.
 
  If you want a truly platform and printer-neutral solution, 
 your looking at a variety of options - none of which are great for 
 one reason or another.
 
 Leonard
 

Sadly, the printer in question is on a Windows platform. Do you know of a 
Windows specific solution?

You mentioned 
If you want a truly platform and printer-neutral solution, 
your looking at a variety of options - none of which are great for 
one reason or another.

Can you maybe elaborate? Maybe I could investigate the least worst option.



Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] example tiff2pdf

2006-07-06 Thread carl lang
Hi Paulo,

Would you please be able to tell me where to find an example 
for using com.lowagie.tools.plugins.Tiff2Pdf, 
and how to create pdf from multiple page tiff?

Thanks,
Carl Lang
South Africa



Message: 1Date: Wed, 5 Jul 2006 15:02:25 +0100From: Paulo Soares [EMAIL PROTECTED]Subject: Re: [iText-questions] read multiple pages of a tiff
To: Post all your questions about iText here   itext-questions@lists.sourceforge.net
Message-ID:   [EMAIL PROTECTED]
Content-Type: text/plain;charset=us-asciicom.lowagie.tools.plugins.Tiff2PdfPaulo -Original Message- From: 
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
] On Behalf Of carl lang Sent: Wednesday, July 05, 2006 1:29 PM To: itext-questions@lists.sourceforge.net
 Subject: [iText-questions] read multiple pages of a tiff Hi, I have recently downloaded itext software to create PDF files, I am interested in creating a PDF file with tiff images,
 my question is how can I create a PDF from a tiff file that has multiple pages of images in it. So for example I would like to create a PDF from a tiff page number 2. Is this possible?
 Thanks in advance, Carl LangAviso Legal:Esta mensagem é destinada exclusivamente ao destinatário. Pode conter informação confidencial ou legalmente protegida. A incorrecta transmissão desta mensagem não significa a perca de confidencialidade. Se esta mensagem for recebida por engano, por favor envie-a de volta para o remetente e apague-a do seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de usar, revelar ou distribuir qualquer parte desta mensagem.
Disclaimer:This message is destined exclusively to the intended receiver. It may contain confidential or legally protected information. The incorrect transmission of this message does not mean the loss of its confidentiality. If this message is received by mistake, please send it back to the sender and delete it from your system immediately. It is forbidden to any person who is not the intended receiver to use, distribute or copy any part of this message.

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Andrew Thompson
Is this what is meant by userunits? Basically I am putting a map image as a jpg 
into a pdf document, but this is generated using 96dpi, when the pdf is created 
the scale is being altered as itext is creating at 72dpi, I have a requirement 
to maintain the accurancy of the map image, can someone point me to where to 
find the code or a description in the api to set userunits? I literally can 
find nothing googling

Cheers

Andy 

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Leonard Rosenthol
Sent: 05 July 2006 18:08
To: Post all your questions about iText here; 
itext-questions@lists.sourceforge.net
Subject: Re: [iText-questions] dpi userunits

At 12:43 PM 7/5/2006, Andrew Thompson wrote:
Hi, i am trying to set the default value for dpi in a itext pdf 
document from 72 to 96,

 You can't change dpi - but you can change the transformation of the 
units used in the PDF using the standard
SetTransform() methods...You will, however, need to be sure to get all your 
coordinates correct when doing this.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier 
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


This e-mail has been scanned for all viruses by Star. The service is powered by 
MessageLabs. For more information on a proactive anti-virus service working 
around the clock, around the globe, visit:
http://www.star.net.uk


--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 


This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] tiff2pdf can it create pdf from certain tiff page?

2006-07-06 Thread Paulo Soares
Those tools are not only useful as they are but are also there as an example of 
what can be done. Look at the source and change it according to your needs.

Paulo

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of carl lang
 Sent: Thursday, July 06, 2006 9:47 AM
 To: itext-questions@lists.sourceforge.net
 Subject: [iText-questions] tiff2pdf can it create pdf from 
 certain tiff page?
 
 Hi Paulo,
  
 I am able to run Tiff2Pdf , but it creates pdf from the 
 entire tiff file,
 I want to be able to specifiy which page of the tiff must be 
 used to create the pdf,
 is that possible?
 also when Tiff2Pdf creates pdf it adds file name to the top 
 of each page in the pdf ,
 is it possible to leave that out?
  
 I think it is great to have a free tool such as itext pdf !
  
 Thanks,
 Carl Lang
 South Africa 
 
 -- Forwarded message --
 From: carl lang [EMAIL PROTECTED]
 Date: Jul 6, 2006 10:28 AM 
 Subject: example tiff2pdf
 To: itext-questions@lists.sourceforge.net
 
  
 Hi Paulo,
  
 Would you please be able to tell me where to find an example 
 for using com.lowagie.tools.plugins.Tiff2Pdf, 
 and how to create pdf from multiple page tiff?
  
 Thanks,
 Carl Lang
 South Africa
  
  
  
 Message: 1
 Date: Wed, 5 Jul 2006 15:02:25 +0100
 From: Paulo Soares [EMAIL PROTECTED] 
 Subject: Re: [iText-questions] read multiple pages of a tiff 
 To: Post all your questions about iText here
 itext-questions@lists.sourceforge.net 
 mailto:itext-questions@lists.sourceforge.net 
 Message-ID:
 
 [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] 
 Content-Type: text/plain;   charset=us-ascii
 
 com.lowagie.tools.plugins.Tiff2Pdf
 
 Paulo
 
  -Original Message- 
  From: [EMAIL PROTECTED]
  [mailto: [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] ] On
  Behalf Of carl lang
  Sent: Wednesday, July 05, 2006 1:29 PM
  To: itext-questions@lists.sourceforge.net 
 mailto:itext-questions@lists.sourceforge.net 
  Subject: [iText-questions] read multiple pages of a tiff
 
  Hi,
 
  I have recently downloaded itext software to create PDF files,
  I am interested in creating a PDF file with tiff images, 
  my question is how can I create a PDF from a tiff file that has
  multiple pages of images in it.
  So for example I would like to create a PDF from a tiff 
 page number 2.
 
  Is this possible? 
 
  Thanks in advance,
  Carl Lang
 
 
 
 Aviso Legal:
 Esta mensagem é destinada exclusivamente ao destinatário. 
 Pode conter informação confidencial ou legalmente protegida. 
 A incorrecta transmissão desta mensagem não significa a perca 
 de confidencialidade. Se esta mensagem for recebida por 
 engano, por favor envie-a de volta para o remetente e 
 apague-a do seu sistema de imediato. É proibido a qualquer 
 pessoa que não o destinatário de usar, revelar ou distribuir 
 qualquer parte desta mensagem. 
 
 Disclaimer:
 This message is destined exclusively to the intended 
 receiver. It may contain confidential or legally protected 
 information. The incorrect transmission of this message does 
 not mean the loss of its confidentiality. If this message is 
 received by mistake, please send it back to the sender and 
 delete it from your system immediately. It is forbidden to 
 any person who is not the intended receiver to use, 
 distribute or copy any part of this message. 
  
 


Aviso Legal:
Esta mensagem é destinada exclusivamente ao destinatário. Pode conter 
informação confidencial ou legalmente protegida. A incorrecta transmissão desta 
mensagem não significa a perca de confidencialidade. Se esta mensagem for 
recebida por engano, por favor envie-a de volta para o remetente e apague-a do 
seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de 
usar, revelar ou distribuir qualquer parte desta mensagem. 

Disclaimer:
This message is destined exclusively to the intended receiver. It may contain 
confidential or legally protected information. The incorrect transmission of 
this message does not mean the loss of its confidentiality. If this message is 
received by mistake, please send it back to the sender and delete it from your 
system immediately. It is forbidden to any person who is not the intended 
receiver to use, distribute or copy any part of this message.

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] PdfPCell in a layer...

2006-07-06 Thread Paulo Soares
You can do it with a cell event and apply the layer to canvases.

Paulo

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Marco Schoolenberg
 Sent: Thursday, July 06, 2006 9:31 AM
 To: itext-questions@lists.sourceforge.net
 Subject: [iText-questions] PdfPCell in a layer...
 
 
 Dear Itext contributers,
 
 I am new to iText. First of I want to say very nice 
 package. Though I have
 a question. In my code I am in a for loop hitting the 
 elements of a Vector
 object with some db entries. I am wondering if there is a 
 good way to add a
 specific PdfPCell to a PdfLayer. The issue is I don't want to 
 add the whole
 table I am looping true to the layer because. I have tried to 
 make use of:
 
 TextField ff = new TextField(writer, new 
 Rectangle(200, 600,
 300, 620), field1);
 ff.setBorderColor(Color.blue);
// ff.setBorderStyle(PdfBorderDictionary.STYLE_SOLID);
 ff.setBorderWidth(TextField.BORDER_WIDTH_THIN);
 ff.setText(I'm a form field);
 PdfFormField form = ff.getTextField();
 form.setLayer(l2);
 writer.addAnnotation(form);
 
 Writing  it in this way presents me with positioning a issue. 
 I would like
 to use a setLayer(layer) on a PdfPCell. I know I can't can 
 anyone give me a
 good suggestion?
 
 Kind regards
 
 
 Marco Schoolenberg
 [EMAIL PROTECTED]
 
 
 
 Using Tomcat but need to do more? Need to support web 
 services, security?
 Get stuff done quickly with pre-integrated technology to make 
 your job easier
 Download IBM WebSphere Application Server v.1.0.1 based on 
 Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057;
 dat=121642
 ___
 iText-questions mailing list
 iText-questions@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/itext-questions
 


Aviso Legal:
Esta mensagem é destinada exclusivamente ao destinatário. Pode conter 
informação confidencial ou legalmente protegida. A incorrecta transmissão desta 
mensagem não significa a perca de confidencialidade. Se esta mensagem for 
recebida por engano, por favor envie-a de volta para o remetente e apague-a do 
seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de 
usar, revelar ou distribuir qualquer parte desta mensagem. 

Disclaimer:
This message is destined exclusively to the intended receiver. It may contain 
confidential or legally protected information. The incorrect transmission of 
this message does not mean the loss of its confidentiality. If this message is 
received by mistake, please send it back to the sender and delete it from your 
system immediately. It is forbidden to any person who is not the intended 
receiver to use, distribute or copy any part of this message.


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Getting the bytes of the digital signature ?

2006-07-06 Thread Paulo Soares
Probably easier this way:

AcroFields af = reader.getAcroFields();
PdfDictionary v = af.getSignatureDictionary(Signature1); 
PdfString ct = (PdfString)v.get(PdfName.CONTENTS);
byte[] b = ct.getBytes();

Paulo

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Luiz Kobayashi
 Sent: Tuesday, July 04, 2006 11:25 PM
 To: Post all your questions about iText here
 Subject: Re: [iText-questions] Getting the bytes of the 
 digital signature ?
 
 Paulo,
 
 first of all, many thanks for your reply.
 
 I have been trying to do as you suggested, but I am unable to 
 understand 
 how to get the dictionary.
 I have got a new PdfReader to read it, I got its AcroFields, 
 but while I 
 can get its fields using getFields(), I haven't figured out 
 how to use 
 the dictionary with it in order to get the ArrayList (or 
 similar) with 
 the DS content.
 
 If you could shed me some light on this, I'd be most grateful.
 
 Thanks again and sorry for the trouble,
 
 Luiz Kobayashi
 
 Paulo Soares escreveu:
  The easiest way is to sign the pdf and then read it with 
 PdfReader. From 
  there get AcroFields.Item.merged dictionary, then the key 
 /V and then 
  /Contents.
 
  Paulo
 
  - Original Message - 
  From: Luiz Kobayashi [EMAIL PROTECTED]
  To: Post all your questions about iText here 
  itext-questions@lists.sourceforge.net
  Sent: Friday, June 30, 2006 8:07 PM
  Subject: [iText-questions] Getting the bytes of the digital 
 signature ?
 
 

  Hi all,
 
  I am using iText to apply digital signatures to my PDFs. 
 It works really
  great (many thanks for the developers! :-) )
 
  I was wondering whether there is a way to retrieve the bytes
  corresponding to the digital signature itself.
 
  The code snippet provided in the website and in the 
 Javadoc allows me to
  sign and verify the signature, but I have no control about 
 the signature
  itself.
 
  I am thinking about signing the PDF first and then using 
 something along
  the lines of
 
  AcroFields af = reader.getAcroFields();
  ArrayList names = af.getSignatureNames();
  PdfPKCS7 pk = af.verifySignature(name);
  byte[]  digitalsignature = getEncodedPKCS7();
 
  to get the bytes.
 
  Is this approach correct? Or is there any smarter way?
 
  Any help would be greatly appreciated.
 
  Thanks in advance,
 
  -- 
  Luiz Kobayashi
  
 
 Using Tomcat but need to do more? Need to support web 
 services, security?
 Get stuff done quickly with pre-integrated technology to make 
 your job easier
 Download IBM WebSphere Application Server v.1.0.1 based on 
 Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057;
 dat=121642
 ___
 iText-questions mailing list
 iText-questions@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/itext-questions
 


Aviso Legal:
Esta mensagem é destinada exclusivamente ao destinatário. Pode conter 
informação confidencial ou legalmente protegida. A incorrecta transmissão desta 
mensagem não significa a perca de confidencialidade. Se esta mensagem for 
recebida por engano, por favor envie-a de volta para o remetente e apague-a do 
seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de 
usar, revelar ou distribuir qualquer parte desta mensagem. 

Disclaimer:
This message is destined exclusively to the intended receiver. It may contain 
confidential or legally protected information. The incorrect transmission of 
this message does not mean the loss of its confidentiality. If this message is 
received by mistake, please send it back to the sender and delete it from your 
system immediately. It is forbidden to any person who is not the intended 
receiver to use, distribute or copy any part of this message.


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Embedding external PKCS7 Signature - Debugging...

2006-07-06 Thread Paulo Soares
You need to calculate the hash only over the bytes that you get from
PdfSignatureAppearance.getRangeStream(). You may also need to use the
subfilter PdfName.ADBE_PKCS7_SHA1 but it all depends on what is inside
the generated PKCS#7. 

Paulo

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Oliver Welter
 Sent: Wednesday, July 05, 2006 7:22 AM
 To: itext-questions@lists.sourceforge.net
 Subject: [iText-questions] Embedding external PKCS7 Signature 
 - Debugging...
 
 Hi Folks,
 
 I have a problem with diigtal signed PDFs - here is what I want to do:
 
 I have a Java-App that calculates the hash of a PDF Document, 
 gives this
 Hash to an external Application and receives a PKCS7 
 container with the
 signature back. The container has not only the sigend Hash but another
 PKCS7 structure, containing a Timestamp and the hash. So I used PPKFS
 
 dic.put(PdfName.FILTER, new PdfName(SAFE.PPKSF));
 dic.put(PdfName.SUBFILTER, new PdfName(adbe.pkcs7.detached));
 
 
 And copied the external received structure to another dictornary
 dic.put(PdfName.CONTENTS, new PdfString(outc).setHexWriting(true));
 
 All seems runninf fine, the signatuer is embeded and I can 
 see it in the
 PDF Document but its invalid. Acrobat complains that the content was
 altered 1 misc modification.
 
 So - first question: Is this was correct ? Do I use the right
 implementation and thus is acrobat using the correct hash for 
 validation?
 If so, is there any way to extract the hash back from the PKCS7
 container - I tried hard and I am a bit familiar with openssl 
 tools, but
 didnt manage to get this out...
 
 TIA and regards
 
 Oliver
 -- 
 Diese Nachricht wurde digital unterschrieben
 oliwel's public key: http://www.oliwel.de/oliwel.crt
 Basiszertifikat: http://www.ldv.ei.tum.de/page72
 
 Using Tomcat but need to do more? Need to support web 
 services, security?
 Get stuff done quickly with pre-integrated technology to make 
 your job easier
 Download IBM WebSphere Application Server v.1.0.1 based on 
 Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057;
 dat=121642
 ___
 iText-questions mailing list
 iText-questions@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/itext-questions
 


Aviso Legal:
Esta mensagem é destinada exclusivamente ao destinatário. Pode conter 
informação confidencial ou legalmente protegida. A incorrecta transmissão desta 
mensagem não significa a perca de confidencialidade. Se esta mensagem for 
recebida por engano, por favor envie-a de volta para o remetente e apague-a do 
seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de 
usar, revelar ou distribuir qualquer parte desta mensagem. 

Disclaimer:
This message is destined exclusively to the intended receiver. It may contain 
confidential or legally protected information. The incorrect transmission of 
this message does not mean the loss of its confidentiality. If this message is 
received by mistake, please send it back to the sender and delete it from your 
system immediately. It is forbidden to any person who is not the intended 
receiver to use, distribute or copy any part of this message.


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Embedding external PKCS7 Signature - Debugging...

2006-07-06 Thread Oliver Welter

Hi Paulo,


You need to calculate the hash only over the bytes that you get from


In the meantime I found the error - my Application is not able to sign 
binary data :(



subfilter PdfName.ADBE_PKCS7_SHA1 but it all depends on what is inside
the generated PKCS#7. 


Is there somewhere a usable documentation on the options - I have 
searched adobe websites but didnt find anything valuable...


I am looking for the possibility to embed the SHA1 in a base64 encoded 
form - anybody knows if this is possible ?


Oliver

--
Diese Nachricht wurde digital unterschrieben
oliwel's public key: http://www.oliwel.de/oliwel.crt
Basiszertifikat: http://www.ldv.ei.tum.de/page72


smime.p7s
Description: S/MIME Cryptographic Signature
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Embedding external PKCS7 Signature- Debugging...

2006-07-06 Thread Paulo Soares
 

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Oliver Welter
 Sent: Thursday, July 06, 2006 12:42 PM
 To: Post all your questions about iText here
 Subject: Re: [iText-questions] Embedding external PKCS7 
 Signature- Debugging...
 
 Hi Paulo,
 
  You need to calculate the hash only over the bytes that you get from
 
 In the meantime I found the error - my Application is not 
 able to sign 
 binary data :(
 
  subfilter PdfName.ADBE_PKCS7_SHA1 but it all depends on 
 what is inside
  the generated PKCS#7. 
 
 Is there somewhere a usable documentation on the options - I have 
 searched adobe websites but didnt find anything valuable...


http://partners.adobe.com/public/developer/acrobat/index_advanced.html
 
 I am looking for the possibility to embed the SHA1 in a 
 base64 encoded 
 form - anybody knows if this is possible ?
 

Not possible. You must sign the binary data.

Paulo


Aviso Legal:
Esta mensagem é destinada exclusivamente ao destinatário. Pode conter 
informação confidencial ou legalmente protegida. A incorrecta transmissão desta 
mensagem não significa a perca de confidencialidade. Se esta mensagem for 
recebida por engano, por favor envie-a de volta para o remetente e apague-a do 
seu sistema de imediato. É proibido a qualquer pessoa que não o destinatário de 
usar, revelar ou distribuir qualquer parte desta mensagem. 

Disclaimer:
This message is destined exclusively to the intended receiver. It may contain 
confidential or legally protected information. The incorrect transmission of 
this message does not mean the loss of its confidentiality. If this message is 
received by mistake, please send it back to the sender and delete it from your 
system immediately. It is forbidden to any person who is not the intended 
receiver to use, distribute or copy any part of this message.


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Leonard Rosenthol
At 06:25 AM 7/6/2006, Andrew Thompson wrote:
Is this what is meant by userunits?

 If you are referring to the key on the /Page called 
/UserUnits - then no.


Basically I am putting a map image as a jpg into a pdf document, but 
this is generated using 96dpi, when the pdf is created the scale is 
being altered as itext is creating at 72dpi,

 Just do the math to create the appropriate scale transform 
when you place the image.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Silently printing a PDF to a network printer

2006-07-06 Thread Leonard Rosenthol
At 03:00 AM 7/6/2006, Matt Krevs wrote:
Sadly, the printer in question is on a Windows platform. Do you know of a
Windows specific solution?

 The best solutions for Windows involve calling out to a 
native component - be it Adobe Acrobat or some other 3rd party solution.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Andrew Thompson
But the problem is that depending on the resolution of the screen the image 
that is sent to the pdf is of different sizes, is there definetely no way in 
itext to alter the default dpi? 

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Leonard Rosenthol
Sent: 06 July 2006 13:23
To: Post all your questions about iText here; Post all your questions about 
iText here
Subject: Re: [iText-questions] dpi userunits

At 06:25 AM 7/6/2006, Andrew Thompson wrote:
Is this what is meant by userunits?

 If you are referring to the key on the /Page called /UserUnits - then 
no.


Basically I am putting a map image as a jpg into a pdf document, but 
this is generated using 96dpi, when the pdf is created the scale is 
being altered as itext is creating at 72dpi,

 Just do the math to create the appropriate scale transform 
when you place the image.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


-- 
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 


This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Leonard Rosenthol
At 09:09 AM 7/6/2006, Andrew Thompson wrote:
But the problem is that depending on the resolution of the screen 
the image that is sent to the pdf is of different sizes,

 You mean you are putting different images INTO the PDF document?

 Or you are talking about what Acrobat (or whatever PDF 
viewer) is doing when it displays the created PDF on the user's computer?


is there definetely no way in itext to alter the default dpi?

 A PDF document DOES NOT HAVE a dpi!   It is a 
resolution-independent collection of objects.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] cant get source code!

2006-07-06 Thread carl lang
Hi Paulo,

I Downloaded the itext-src-1.4.2.zip file but I am unable to open with winzip,
error is it does not appear to be a valid archive.

i also tried using wincvs to download src , but i'm having trouble using
wincvs , it gives an error when i try log in :
cvs -d :pserver:[EMAIL PROTECTED]:/cvsroot/itext login 
Unable to initialize the CVS process: The system cannot find the file specified.
The CVS used is : cvs.exe

I wonder if you could send me the itext source by email please?

Thanks for your time,
Carl Lang
South Africa

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Andrew Thompson
Well basically I have an image that has a scale bar of 2.91 but when it is 
inserted into the pdf document it is being displayed as 3.4cm, if the pdf does 
not have a dpi then where has this default of 72dpi arisen from? 

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Leonard Rosenthol
Sent: 06 July 2006 15:07
To: Post all your questions about iText here; Post all your questions about 
iText here
Subject: Re: [iText-questions] dpi userunits

At 09:09 AM 7/6/2006, Andrew Thompson wrote:
But the problem is that depending on the resolution of the screen the 
image that is sent to the pdf is of different sizes,

 You mean you are putting different images INTO the PDF document?

 Or you are talking about what Acrobat (or whatever PDF
viewer) is doing when it displays the created PDF on the user's computer?


is there definetely no way in itext to alter the default dpi?

 A PDF document DOES NOT HAVE a dpi!   It is a 
resolution-independent collection of objects.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


-- 
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.9.9/382 - Release Date: 04/07/2006
 


This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] cant get source code!

2006-07-06 Thread David Delbecq
Could it be you issued a 'save link as' from the itext Download 
Compile webpage? If yes, you save an html file instead of the source :)
The link direct you to a list of mirrors for downloading

carl lang wrote:
 Hi Paulo,
  
 I Downloaded the itext-src-1.4.2.zip file but I am unable to open with
 winzip,
 error is it does not appear to be a valid archive.
  
 i also tried using wincvs to download src , but i'm having trouble using
 wincvs , it gives an error when i try log in :

 cvs -d :pserver:[EMAIL PROTECTED]:/cvsroot/itext login

 Unable to initialize the CVS process: The system cannot find the file
 specified.

 The CVS used is : cvs.exe

  

 I wonder if you could send me the itext source by email please?

  

 Thanks for your time,

 Carl Lang

 South Africa

  
 

 Using Tomcat but need to do more? Need to support web services, security?
 Get stuff done quickly with pre-integrated technology to make your job easier
 Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
 

 ___
 iText-questions mailing list
 iText-questions@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/itext-questions
   


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Leonard Rosenthol
At 10:24 AM 7/6/2006, Andrew Thompson wrote:
Well basically I have an image that has a scale bar of 2.91

 At what resolution?   72dpi or 96dpi?


but when it is inserted into the pdf document it is being displayed as 3.4cm,

 Are you providing a transform when you place it into the PDF?


  if the pdf does not have a dpi then where has this default of 
 72dpi arisen from?

 Because the default transformation matrix in a PDF is 72 
USER UNITS to an inch, but that's not an actual dots per inch (dpi) 
since vector and textual data have no dots.

 When placing an image, unless you specify a transform, the 
pixels in the image are assumed to be in user units (so there would 
be 72 of them to an inch, which would be logically equivalent to 
72dpi).  If you wish to adjust the relationship of pixels to user 
units for this particular image, then you apply a transform when you 
place the image.

 OK?


Leonard


---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] Using AcroForm for form letter generation

2006-07-06 Thread Nick V
I am working on a web application that needs to create
form letters with data pulled from a database merged
into those letters. The form letters are to appear as
one long “page” in the user’s browser window. Then
when he/she goes to print from the browser, the
letters print out one after the other, one page per
letter. 

I want to create the PDF output in memory by sending
the output directly to the client via the servlet’s
output stream. I would rather not write files on the
server.

One way I am considering doing this is by using an
Acrobat form (AcroForm), filling it in once for each
record pulled from the database. However, I can only
generate one letter at a time when writing directly to
the servlet’s output stream. I want to fill in the
form multiple times, sending the output as one
continuous stream. 

I CAN open the Acrobat form, fill it in and save it to
a file for each letter and then copy all the files
into one file and send it to the user but that is not
what I WANT to do.

Does anybody know of a way to do what I have described
using Acrobat forms?

Thanks!

Nick


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Using AcroForm for form letter generation

2006-07-06 Thread Bruno Lowagie
Nick V wrote:

I want to create the PDF output in memory by sending
the output directly to the client via the servlet’s
output stream. I would rather not write files on the
server.

One way I am considering doing this is by using an
Acrobat form (AcroForm), filling it in once for each
record pulled from the database. However, I can only
generate one letter at a time when writing directly to
the servlet’s output stream. I want to fill in the
form multiple times, sending the output as one
continuous stream. 

I CAN open the Acrobat form, fill it in and save it to
a file for each letter and then copy all the files
into one file and send it to the user but that is not
what I WANT to do.

Does anybody know of a way to do what I have described
using Acrobat forms?
  

Today I gave a demo about a system that did just that, see:
http://itext.ugent.be/articles/ects-ict/index.php?page=4#start

What you need to do is read the empty AcroForm with PdfReader,
create a PdfStamper object that writes to a ByteArrayOutputStream,
then use the bytes returned by the toByteArray method of this outputstream
to create a new PdfReader, use this PdfReader with PdfCopy to create
the final PDF also in memory.
Iterate the reading and stamping for every record in your database.
Add every page to the PdfCopy object...

br,
Bruno

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] Fwd: iText

2006-07-06 Thread rakib islam
Note: forwarded message attached. 
		Do you Yahoo!? Next-gen email? Have it all with the  all-new Yahoo! Mail Beta.---BeginMessage---
Hi   I am RAKIB trying to use iText Library.To install iText library i follow the rules written by "Christoph Bartnick".But when i create the"CLASSPATH"variable with the value of iText Jar File's destination path I can compile every java program but fail to run any java program.When i run any program an exception is thrown each time that is "java.lang.NoClassDefFoundError". But if i delete the "CLASSPATH" varible i can able to compile and run all the Javaprogram which are not related to itext library. i am using J2SE 5.0,TextPad 4.5, windows 2000 professional. So What Should I Do Now? Please help me to solve the problem   

		Yahoo! Music Unlimited - Access over 1 million songs.
Try it free. ---End Message---
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] dpi userunits

2006-07-06 Thread Peter B. West
Andrew,

Leonard isn't just being pedantic. It's important to understand what's 
happening here.

Peter

Leonard Rosenthol wrote:
 At 10:24 AM 7/6/2006, Andrew Thompson wrote:
 
Well basically I have an image that has a scale bar of 2.91
 
 
  At what resolution?   72dpi or 96dpi?
 
 
 
but when it is inserted into the pdf document it is being displayed as 3.4cm,
 
 
  Are you providing a transform when you place it into the PDF?
 
 
 
 if the pdf does not have a dpi then where has this default of 
72dpi arisen from?
 
 
  Because the default transformation matrix in a PDF is 72 
 USER UNITS to an inch, but that's not an actual dots per inch (dpi) 
 since vector and textual data have no dots.
 
  When placing an image, unless you specify a transform, the 
 pixels in the image are assumed to be in user units (so there would 
 be 72 of them to an inch, which would be logically equivalent to 
 72dpi).  If you wish to adjust the relationship of pixels to user 
 units for this particular image, then you apply a transform when you 
 place the image.
 
  OK?
 
 
 Leonard


-- 
Peter B. West http://cv.pbw.id.au/
Folio http://defoe.sourceforge.net/folio/

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] Paragraph and PdfContentByte

2006-07-06 Thread Miguel Tablado
Hello.I have a problem writing into an existing pdf file. I want to write a Paragraph into a pdf bookmark, but I don't find what is the PdfContentByte's method to do add a Paragraph nor the funcionality to add a Paragraph at a specific position.
If it is not posible, It will be enough if I could justify a text of a bookmark.Could you help me?Thanks in advance!Miguel Tablado.
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] iText

2006-07-06 Thread rakib islam
Hi   I am RAKIB trying to use iText Library.To install iText library i follow the rules written by "Christoph Bartnick".But when i create the"CLASSPATH"variable with the value of iText Jar File's destination path I can compile every java program but fail to run any java program.When i run any program an exception is thrown each time that is "java.lang.NoClassDefFoundError". But if i delete the "CLASSPATH" varible i can able to compile and run all the Javaprogram which are not related to itext library. i am using J2SE 5.0,TextPad 4.5, windows 2000 professional. So What Should I Do Now? Please help me to solve the problem   

		Yahoo! Music Unlimited - Access over 1 million songs.
Try it free. Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] PdfPTable, thin rectangle(s) and half empty pages (fwd)

2006-07-06 Thread Cathrine Tan
Hello,
I have a document that contains 4 PdfPTable.
One of these PdfPTable contains 6 columns, and one of these 6 columns could 
potentially contain a very long cell that spans over more than 1 page.
The problem that I have notice is, whenever I have at least a cell that 
spans over more than 1 page, there will be mysterious, very thin (about 1 mm 
or so) rectangles on the top of the next page. Also, if the next row in the 
PdfPTable cannot fit into the remaining of the page, it will leave the 
remaining of the page blank (sometimes about half a page of empty spaces ) 
and start the next row on the next page. Is it possible to fill the empty 
spaces with some of the content for the next row, rather than having the 
empty half page ? 

Thanks 




Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Paragraph and PdfContentByte

2006-07-06 Thread Mark Storer



PdfContentByte is strictly for things that appear in pages. A 
bookmark's appearance is just a string... you can't even control the font or 
point size.

You can set 
the color, and have flags to control 'italic' and 'bold', but that's it. 
I'm not sure that iText exposes this ability, let me check... Yes, iText 
has a PdfOutline object that allows you to set its color (with a java.awt.Color) 
and style.

And there's 
an example of how to use it:
http://itextdocs.lowagie.com/examples/com/lowagie/examples/directcontent/pageevents/Bookmarks.java

It actually uses a PdfContentByte, but only as a way to access the root 
outline. I suspect that PdfWriter.getRootOutline() was added after this 
example was written... it would be less confusing to write 
Bookmarks.OnParagraph() like this:

public void onParagraph(PdfWriter writer, 
Document document, float position) 
{
n++; PdfDestination destination 
= new PdfDestination(PdfDestination.FITH, position); PdfOutline root = 
writer.getRootOutline();  PdfOutline outline = new PdfOutline(root, 
destination, "paragraph " + n);}

I believe you can safely ignore the 
"new PdfOutline" return value.  Outlines are in a doubly linked parent-child 
tree, so there's no danger of it being garbage collected... javac might complain however, though you'll still 
get a 'variable assigned but never used' 
warning.
--Mark Storer  Senior Software Engineer  
Cardiff Software 
#include disclaimer typedef std::DisclaimerCardiff DisCard; 

  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]On Behalf Of 
  Miguel TabladoSent: Thursday, July 06, 2006 9:04 
  AMTo: itext-questions@lists.sourceforge.netSubject: 
  [iText-questions] Paragraph and 
  PdfContentByteHello.I have a problem writing into 
  an existing pdf file. I want to write a Paragraph into a pdf bookmark, but I 
  don't find what is the PdfContentByte's method to do add a Paragraph nor the 
  funcionality to add a Paragraph at a specific position. If it is not 
  posible, It will be enough if I could justify a text of a 
  bookmark.Could you help me?Thanks in advance!Miguel 
  Tablado.
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] Getting the bytes of the digital signature ?

2006-07-06 Thread Luiz Kobayashi
Thanks a lot, Paulo!

Luiz Kobayashi

Paulo Soares escreveu:
 Probably easier this way:

 AcroFields af = reader.getAcroFields();
 PdfDictionary v = af.getSignatureDictionary(Signature1); 
 PdfString ct = (PdfString)v.get(PdfName.CONTENTS);
 byte[] b = ct.getBytes();

 Paulo
   



Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] How to edit the appearance of an existing digital signature?

2006-07-06 Thread Luiz Kobayashi
Hello all,

first of all, many thanks again to Paulo, who helped me a lot in my 
previous question.

My next question is: How to edit the appearance of an existing digital 
signature? Is this possible?

One thing that I want to do is to sign a pdf and display the digital 
signature in base64 in the n2 layer.

The way I thought to do was:
1) Sign the pdf as shown in the tutorial
2) Read the signed pdf file and retrieve the signature bytes (thanks to 
Paulo who showed me how to do it!)
3) Get the n2 layer of the signature and change it.

But when I try to do

PdfReader reader2 = new PdfReader(baos.toByteArray()); // baos is the 
byte array where the signed pdf is stored
PdfStamper stp2 = new PdfStamper(reader2, fout, '\0', true);
PdfSignatureAppearance sap2 = stp2.getSignatureAppearance();

I get a java.lang.NullPointerException whenever I try doing anything 
with sap2, like sap2.getLayer(2) or sap2.setLayer2Text().

So, I was wondering what would be the right way to do, if there is one.

Any help would be greatly appreciated.

Thanks in advance,

Luiz Kobayashi

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] How to edit the appearance of an existing digitalsignature?

2006-07-06 Thread Mark Storer

 My next question is: How to edit the appearance of an 
 existing digital signature? Is this possible?

Yes, it's possible... but in all likelyhood it would invalidate the signature.  
If iText is doing the initial signing, you could safely modify 
PdfSignatureAppearance.getAppearance() and still have valid signatures.

After poking around in iText a bit, it looks like your NPE is a result of not 
having called PdfStamper.createSignature() first... which makes perfect sense 
if you're trying to modify an existing sig.  At which point you've departed the 
land of convenient APIs and have to delve into the low level PDF objects, 
PdfDictionary and its ilk.

--Mark Storer
  Senior Software Engineer
  Cardiff Software

#include disclaimer
typedef std::DisclaimerCardiff DisCard;



 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] 
 Behalf Of Luiz
 Kobayashi
 Sent: Thursday, July 06, 2006 2:38 PM
 To: itext-questions@lists.sourceforge.net
 Subject: [iText-questions] How to edit the appearance of an existing
 digitalsignature?
 
 
 Hello all,
 
 first of all, many thanks again to Paulo, who helped me a lot in my 
 previous question.
 
 
 One thing that I want to do is to sign a pdf and display the digital 
 signature in base64 in the n2 layer.
 
 The way I thought to do was:
 1) Sign the pdf as shown in the tutorial
 2) Read the signed pdf file and retrieve the signature bytes 
 (thanks to 
 Paulo who showed me how to do it!)
 3) Get the n2 layer of the signature and change it.
 
 But when I try to do
 
 PdfReader reader2 = new PdfReader(baos.toByteArray()); // baos is the 
 byte array where the signed pdf is stored
 PdfStamper stp2 = new PdfStamper(reader2, fout, '\0', true);
 PdfSignatureAppearance sap2 = stp2.getSignatureAppearance();
 
 I get a java.lang.NullPointerException whenever I try doing anything 
 with sap2, like sap2.getLayer(2) or sap2.setLayer2Text().
 
 So, I was wondering what would be the right way to do, if 
 there is one.
 
 Any help would be greatly appreciated.
 
 Thanks in advance,
 
 Luiz Kobayashi
 
 Using Tomcat but need to do more? Need to support web 
 services, security?
 Get stuff done quickly with pre-integrated technology to make 
 your job easier
 Download IBM WebSphere Application Server v.1.0.1 based on 
 Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057;
dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] How to edit the appearance of an existing digitalsignature?

2006-07-06 Thread Leonard Rosenthol
At 05:54 PM 7/6/2006, Mark Storer wrote:
Yes, it's possible... but in all likelyhood it would invalidate the 
signature.

 It SHOULD invalidate the signature - though admittedly, if 
you do an update instead of a garbage collected save, then it 
won't.  It would achieve your goal.

 HOWEVER, I would NOT recommend doing this as it would cause 
Acrobat to flag your documents as modified after signing which 
could be taken by your users as problematic...HELL, I'd consider it a problem!


If iText is doing the initial signing, you could safely modify 
PdfSignatureAppearance.getAppearance() and still have valid signatures.

 Except they won't know the sig bits till after it's signed, 
which means that appearance has to be written out.  It's a Catch-22.


Leonard

---
Leonard Rosentholmailto:[EMAIL PROTECTED]
Chief Technical Officer  http://www.pdfsages.com
PDF Sages, Inc.  215-938-7080 (voice)
  215-938-0880 (fax)


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions


Re: [iText-questions] How to edit the appearance of an existing digitalsignature?

2006-07-06 Thread Paulo Soares
You're not the first to ask that and it's not possible without invalidating 
the signature. In effect, for that to work you would need to sign the 
signature itself a bit like an endless loop.

Paulo

- Original Message - 
From: Luiz Kobayashi [EMAIL PROTECTED]
To: itext-questions@lists.sourceforge.net
Sent: Thursday, July 06, 2006 10:38 PM
Subject: [iText-questions] How to edit the appearance of an existing 
digitalsignature?


 Hello all,

 first of all, many thanks again to Paulo, who helped me a lot in my
 previous question.

 My next question is: How to edit the appearance of an existing digital
 signature? Is this possible?

 One thing that I want to do is to sign a pdf and display the digital
 signature in base64 in the n2 layer.

 The way I thought to do was:
 1) Sign the pdf as shown in the tutorial
 2) Read the signed pdf file and retrieve the signature bytes (thanks to
 Paulo who showed me how to do it!)
 3) Get the n2 layer of the signature and change it.

 But when I try to do

 PdfReader reader2 = new PdfReader(baos.toByteArray()); // baos is the
 byte array where the signed pdf is stored
 PdfStamper stp2 = new PdfStamper(reader2, fout, '\0', true);
 PdfSignatureAppearance sap2 = stp2.getSignatureAppearance();

 I get a java.lang.NullPointerException whenever I try doing anything
 with sap2, like sap2.getLayer(2) or sap2.setLayer2Text().

 So, I was wondering what would be the right way to do, if there is one.

 Any help would be greatly appreciated.

 Thanks in advance,

 Luiz Kobayashi

 Using Tomcat but need to do more? Need to support web services, security?
 Get stuff done quickly with pre-integrated technology to make your job 
 easier
 Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
 ___
 iText-questions mailing list
 iText-questions@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/itext-questions 


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions