Re: difference between inkRect and logRect



On 13-06-12 12:10 PM, Parth Kanungo wrote:
Can you tell me the difference between inkRect and logRect ?

ink_rect is exactly what it says: tight bounding box of glyph images.
logical_rect is the conceptual size of the text.  Say, you have a line of text
that has one period only: "."  The ink rect of that line has a very narrow
height, but for line spacing purposes we want it to have a full line's height.
 Same for width: even if the glyph spills way out on the sides, conceptually
the glyph has an advance width narrower than the ink width.  Those values are
what logical_rect returns.


-- 
behdad
http://behdad.org/


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]