Hi,
Is it possible to change line spacing within one document?
I've tried the following code:
Paragraph mainParagraph = new Paragraph();
mainParagraph.setLeading(11.5f);
Paragraph subParagraph = new Paragraph();
subParagraph.setLeading(14f);
// ...
// add some text to subParagraph
for (...) {
subParagraph.add(new Chunk(tokenizer.sval, fonts[0]));
// ...
subParagraph.add(new Chunk(Chunk.NEWLINE));
// ...
}
mainParagraph.add(subParagraph);
document.add(mainParagraph);
The space between the lines of subParagraph is always 11.5 from mainParagraph.
This is only an example - I have to change the leading often within the
document.
My intention was keeping all lines with the same distance together in one
paragraph.
But this doesn't work. It looks like that the top paragraph determinies the
leading.
What I'm doing wrong?
Holger
____________
Virus checked by G DATA AntiVirusKit
begin:vcard
fn;quoted-printable:Holger Rie=C3=9F
n;quoted-printable:Rie=C3=9F;Holger
org:CBS GmbH
adr;quoted-printable:;;Curiestra=C3=9Fe 3a;Chemnitz;Sachsen;09117;Deutschland
email;internet:[EMAIL PROTECTED]
tel;work:+49 (371) 8102574
tel;fax:+49 (371) 8102576
x-mozilla-html:FALSE
url:http://www.cbs.ag
version:2.1
end:vcard
-------------------------------------------------------------------------
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