Not quite. The line gaps are typically 0 so scaling them in any way will not help.
So *instead* of scaling the ascent and descent values (ie. leave them alone) and just change the lineGap values as follows:
new_line_gap = int(0.5 * (ascent + descent)) (assuming of course descent is positive).
The 0.5 comes from (1.5 line spacing - 1).
That sets the leading value in the font metrics to be half the font original height.
Either way I will try it tomorrow when I get back home.
Thanks!
|