Bruno Lowagie (iText <bruno <at> lowagie.com> writes: Create a ColumnText object with the PdfTemplate. Add the Paragraph to a ColumnText object. Set the boundaries of the ColumnText so that they correspond with the PdfTemplate. Invoke go(). br, Bruno --------------------
How can I use your idea for the following case? Codeexample: PdfTemplate template = p_Writer.getDirectContent().createTemplate(10, 10); BaseFont bf = p_FontTypeHelper.convertFont(iFormatElement.GetFontName(), iFormatElement.GetFontSize(), iFormatElement.GetFontColor(), iFormatElement.GetFormat(), p_ContextConnector).getBaseFont(); String text = "Test"; // Here I only got the paragraph object float fontSize = (float) iFormatElement.GetFontSize(); float textSize = bf.getWidthPoint(text, fontSize); template.beginText(); template.setColorFill(iFormatElement.GetFontColor()); template.setFontAndSize(bf, fontSize); template.setTextMatrix(0, 0); template.showText(text); template.endText(); template.setWidth(textSize); template.setHeight(fontSize); Image img = Image.getInstance(template); img.setRotationDegrees(90); cell = new PdfPCell(img); ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
