View Single Post
Old 10-31-2011, 08:57 AM   #49
willus
Fuzzball, the purple cat
willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.
 
willus's Avatar
 
Posts: 1,272
Karma: 11087488
Join Date: Jun 2011
Location: California
Device: iPad
k2pdfopt gaps between rows (adjustment)

Quote:
Originally Posted by orpheus2011 View Post
Many thanks for this, I am now trying the settings recommended on your site and its giving some good results. However, I keep occasionally getting one or two fully justified lines which are much smaller than the rest. I have attached a sample page that shows this. The document was 8.5 inches wide, and I gave an odpi of 198, with right justification and RTL scanning also enabled. Could you please tell me why this happens? Many thanks again!
Yes. See the attached image. You have just enough characters crowding the gap between the lines that k2pdfopt doesn't consider it a clean enough gap. If your text doesn't have any figures, I recommend increasing the gap threshold for the rows--the -gtr option or "gt" in the interactive menu and then the "Gap threshold for rows" entry. Here is the text from the k2pdfopt usage info on -gtr: "Threshold for detecting gaps between rows (expert mode). This sets the maximum total black pixels, in inches, on average, that can be in each row of pixels before the gap is no longer considered a gap. A higher value makes it easier to detect gaps between rows of text. Too high of a value may inadvertently split figures and other graphics. Default = 0.006." At some point I'll do a help page on this.

Try increasing the row-gap threshold slowly until you get the result you want, e.g. .008, .01, .015, etc.
Attached Thumbnails
Click image for larger version

Name:	linegap.png
Views:	1210
Size:	30.7 KB
ID:	91950  

Last edited by willus; 09-06-2012 at 11:59 PM. Reason: Re-add attachment
willus is offline   Reply With Quote