Does line spacing depend on font name?. I am converting HTML string to PDF
using Itext but line spacing is not consistent from one font to other font
in column text. I am using setLeading to set the line space but it is
working for only some fonts. Basically for the same fontsize some fonts are
giving large line space, but PDF taking same line space for all fonts. Hoe
to fix this?. Thanks in advance.



porcupine wrote:
> 
> leading (line spacing) comes in two forms, Fixed and Multiplied. 
> Multiplied basically means, the larger the font, the larger the leading. 
> Fixed means the same leading for any font size. 
> 
> Usually (eg MS Word) Multiplied leading is 1.2f and fixed leading would be
> 0f, that would be eg (C#):- 
> paragraph.SetLeading(0f, 1.2f); 
> 
> if you want fixed leading, then you want eg:- 
> paragraph.SetLeading(5.0f, 1.0f); 
> 
> 
> magesh rathnam wrote:
>> 
>> Hi all,
>> 
>>   We are trying to replace a printer application with PDF created from
>> IText. We used to feed an html string to the printer software and it
>> generates the PDF. When we compare the PDF with the one generated via
>> IText,
>> we find mismatches in line spacing. We dont have any line spacing in
>> IText.
>> But the PDF from printnet had line spacing dependent on font size (not a
>> fixed line spacing). Is it possible to generate linespacing based on font
>> size in IText? We will have a fixed font size for a particular PDF.
>> 
>> Ex: Nothing special is being set in PrintNet related to line spacing. 
>> The
>> font size inside the <p> tag dictates line spacing.
>> 
>> <p alignment="center">  </p> <p alignment="center">  </p> <p
>> alignment="center">  </p> <p alignment="center">From ABC co</p>
>> 
>> Let me know if you have any questions. Appreciate your help.
>> 
>> -- 
>> Thanks & Regards,
>> Magesh
>> 
>> -------------------------------------------------------------------------
>> 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/
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Does-line-spacing-depend-on-font-size--tp9010557p20973714.html
Sent from the iText - General mailing list archive at Nabble.com.


------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.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