[cairo] Exact placement of a multiline pango layout
behdad at behdad.org
Fri Oct 22 12:13:46 PDT 2010
On 10/22/10 14:51, Stefan Salewski wrote:
> I am drawing a multiline pango layout to a cairo surface, and I want do
> draw a rectangle around that text, giving something
> |Line 1 |
> |Line two |
> |A longer Line|
> Propose is something like drawing labels in a graphical layout tool. So
> I need exact control over layout, the frame in the example should exact
> enclose the logical(or ink) layout.
> Indeed, I have already a few working solutions, but I think they work
> only by fortune, and may fail with other types of text.
> I was not able to find a good exapmle like this one for cairo's toy
> I have found this thread from a mailing list, a similar problem,
> but I am still not convinced that I understand the correct solution. I
> think there should exists really some more simple examples for pango.
> Best regards
> Stefan Salewski
> cairo mailing list
> cairo at cairographics.org
More information about the cairo