Be aware that changing the glyph widths of the characters of a font is NOT a 
great practice and should ONLY be used as a last resort...

Leonard

-----Original Message-----
From: 1T3XT info [mailto:[email protected]] 
Sent: Wednesday, April 08, 2009 11:00 AM
To: Post all your questions about iText here
Subject: Re: [iText-questions] itext: every letter in its cell

mitroiasi wrote:
> 
> I forgot to say that I want to insert this text in an already created pdf.
> I have found this example:
> 
> PdfReader reader = new PdfReader("tax_initial.pdf");
> PdfStamper stamp = new PdfStamper(reader, new
> FileOutputStream("tax_result.pdf"));
> PdfContentByte over;
> BaseFont bf = BaseFont.createFont(BaseFont.HELVETICA, BaseFont.WINANSI,
> BaseFont.EMBEDDED);
> over = stamp.getOverContent(1);
> over.beginText();
> over.setFontAndSize(bf, 14);
> over.showTextAligned(Element.ALIGN_LEFT, "Name", 58, 780, 0);
> over.setFontAndSize(bf, 12);
> over.showTextAligned(Element.ALIGN_LEFT, "Addresse", 58, 765, 0);
> over.showTextAligned(Element.ALIGN_LEFT, "[email protected]", 58, 750, 0);
> 
> Is there another possibility to insert some text in an already created pdf?

Either use a monospaced font, or change the glyph widths of the font.
http://1t3xt.be/?X0001c3
http://1t3xt.be/?X00026f
-- 
This answer is provided by 1T3XT BVBA
http://www.1t3xt.com/ - http://www.1t3xt.info

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
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

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
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

Reply via email to