[cairo] global clip for a cairo context

Enrico Weigelt, metux IT consult enrico.weigelt at gr13.net
Sat Jan 2 08:48:42 PST 2016


On 02.01.2016 15:25, Uli Schlachter wrote:
> P.S.: Actually, I'd do something like this:
> 
>   cairo_save(cr);
>   cairo_translate(cr, widget->x, widget->y);
>   cairo_rectangle(cr, 0, 0, widget->width, widget->height);
>   cairo_clip(cr);
>   widget->paint_callback(cr, widget->width, widget->height);
>   cairo_restore(cr);

Does that also work when the widget uses these operations itself ?

--mtx

--
Enrico Weigelt,
metux IT consulting
+49-151-27565287


More information about the cairo mailing list