Re: text extension problem



pango_layout_get_size() returns the logical (layout) size.  It sounds
like you want the ink size (which pixels will be touched when
rendered).  To get the exact ink bounds, call
pango_layout_get_extents(), passing in a non-null ink_rect and a null
logical_rect.  pango_layout_get_pixel_extents() is a convenience
function that expands the result to pixel boundaries.  Look at the
implementations in pango-layout.c and you'll see the relationship
between these functions.

  --deh!

-- 
"I've just found the silverware and I'm sticking a fork in that square!" - N.H.


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