Re: How to create a PangoCairoFontMap?

On Tue, 2007-12-11 at 09:33 +0200, Cosmin Humeniuc wrote:
>         map = pango_cairo_font_map_get_default();
>         pango = pango_cairo_font_map_create_context((PangoCairoFontMap*)map);
>         pango_cairo_context_set_font_options(pango, options);

You are creating a PangoContext called pango, set font options on it,
and then not use it.  Change that for what
pango_layout_get_context(layout) returns.  Fix that and it works.

>         pango_layout_context_changed(layout);
>         pango_cairo_update_layout(cr, layout);


...very few phenomena can pull someone out of Deep Hack Mode, with two
noted exceptions: being struck by lightning, or worse, your *computer*
being struck by lightning.  -- Matt Welsh

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