document.setLinesRequired(n); //Add the elements to the page. I mean with this statement is the page break should happen before the elements are added in case the page doesn't have sufficient (in this case n) number of lines.
Ramana. -----Original Message----- From: Bruno Lowagie [mailto:[EMAIL PROTECTED] Sent: Thursday, March 06, 2003 1:28 PM To: Jaladurgam, Ramana Cc: '[EMAIL PROTECTED]' Subject: Re: [iText-questions] Line height in a chunk Jaladurgam, Ramana wrote: >My requirement actually is: > I will go on adding some paragraphs/chunks/phrases to the >document. > OK. I understand. >These elements are of different fonts and sizes. > OK, I still understand. > There is a requirement that I should break the page when the page >doesn't have sufficient number of lines for a text to fit in. > Why would YOU break the page? This happens automagically. > Something like this: > document.setLinesRequired(n); > ??? This I don't understand ??? You can use the constructor with a PageSize to decide the dimensions of your page. Then you add objects. If they don't fit, a newPage will be triggered. Bruno **************************************************************************** This email may contain confidential material. If you were not an intended recipient, Please notify the sender and delete all copies. We may monitor email to and from our network. **************************************************************************** ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger for complex code. Debugging C/C++ programs can leave you feeling lost and disoriented. TotalView can help you find your way. Available on major UNIX and Linux platforms. Try it free. www.etnus.com _______________________________________________ iText-questions mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/itext-questions
