> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On
> Behalf Of Sebastian Koch
> Sent: Wednesday, August 27, 2008 11:07 AM
> To: [email protected]
> Subject: [iText-questions] problem adding overlay text
>
>
> Hi,
>
> I have some problems adding an overlay-text to an existing pdf-file.
>
> My first approach was to get the OverContent from the
> stamper, using it to
> create a Graphics2D to write a string to it. For writing the
> string I used a
> transparent black as Color.
>
> The output-pdf looks and prints just fine.
iText did correctly what it had to do.
> Converting the pdf to ps is
> problematic though.
You should complain to whoever does the conversion, iText has nothing to do
with it.
> Converting using xpdf's pdftops results in a 100% opaque overlay-text.
No transparency support, maybe.
> Converting using gs's pdf2ps results in a ps which prints ok, but the
> filesize is not acceptable. (like 5-6 mb for one page)
Transparency causes the page to be rasterized. That's a ps limitation.
>
> So my second approach was to use the UnderContent instead of
> the OverContent
> and use a 'normal' gray (no transparency) to write the string.
> Both, pdf2ps and pdftops create ps-files with a small size
> and both print
> correctly...
>
No transparency and all is well.
> ... however, now comes the problem I just could not solve:
> some of the PDFs already have a backgroundimage with solid
> white, writing in
> solid gray to the UnderContent doesn't help much ...
> Is there any way to write text just over the backgroundimage
> but under the
> rest of the pdf-content ?
No, unless you are ready to have a lot of work analyzing the content stream.
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.
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.1t3xt.com/docs/book.php