[cairo] pango.Context from a cairo.ImageSurface ?
Behdad Esfahbod
behdad at behdad.org
Mon Feb 26 12:02:49 PST 2007
On Mon, 2007-02-26 at 14:29 -0500, Tobias Ceglarek wrote:
>
> When I call cairo.Context(surface) I get a cairo.Context.
Then do a pangocairo.CairoContext(cairo_context) to get a
pango_cairo_context:
cr = cairo.Context (surface)
pcr = pangocairo.CairoContext (cr)
layout = pcr.create_layout ()
...
pcr.show_layout (layout, ...)
The confusing point here is that pangocairo.CairoContext is a subclass
of a cairo.Context that adds support for rendering to it using Pango.
It's not a subclass of pango.Context.
--
behdad
http://behdad.org/
"Those who would give up Essential Liberty to purchase a little
Temporary Safety, deserve neither Liberty nor Safety."
-- Benjamin Franklin, 1759
More information about the cairo
mailing list