On 10/05/2012 21:48, cats wrote:
> The purchase of a licence for itext has been authorised so either way, I
> suppose we might as well get on and buy it (and get the complementary itext
> book), but it would be good to have a plan of how its going to work first
Wait, wait!

First let us see if we understand your requirement.

I can interpret your question in two different ways:

1. you want to can create PDFs with interactive features (fields and 
annotations).

With FOP, you create pages with content. The content of a page is 
present in one (or more) content stream(s). You'll find these streams in 
the /Contents entry of the page dictionary as well as in the XObjects 
listed in the /Resources (that is: if the page content refers to 
eXternal Objects).

Reading your mail I could assume that you want to add interactive form 
fields. Form fields are listed in the /AcroForm entry of the root 
dictionary of a PDF. Form fields are represented using widget 
annotations. Annotations are objects that usually can be visualized on a 
page on top of the existing content.

  In many cases, one form field corresponds with one widget annotation, 
but that's not a must; one form field can be visualized using more than 
one annotation. If one form field corresponds with one annotation, we 
typically merge the field infrastructure with the annotation 
infrastructure (two "PDF dictionaries" are combined into one).

With iText you can add interactive fields and their widget annotations 
to an existing PDF, but ONLY if you can provide the coordinates on the 
page. I assume that you don't know these coordinates. Is that a correct 
assumption? If so: how are you going to find the coordinates you need?

2. You want to create a finished PDF and then change the content stream 
by replacing one specific word by another specific word.

Please download chapter 6 of the book (the chapter is available for free!):
http://www.manning.com/lowagie2/samplechapter6.pdf
Read the intro to understand why it's not a good idea to do this. PDF is 
NOT a format for editing.

That's why I would suggest to use another approach.
Please take a look at this video: http://www.parleys.com/d/3186
It shows how to use XML Worker to convert HTML + CSS to PDF.
Maybe that's more or less what you want to achieve.

However, it's hard to really understand the exact requirement without 
more info.

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to