[cairo] API Shakeup: cairo_begin_group, cairo_end_group, cairo_get_group

mental at rydia.net mental at rydia.net
Thu Feb 17 08:15:46 PST 2005


Quoting Owen Taylor <otaylor at redhat.com>:

> What we could do to get almost the same convenience is to add:
>
>   void cairo_end_group_to_source (cairo_t *cr)
>   {
>      cairo_pattern_t *pattern = cairo_end_group (cr);
>      cairo_set_source (cr, pattern);
>      cairo_pattern_destroy (cr);
>   }
>
> [ No, that isn't missing error checking ... we decided to
>    consistently return a magic singleton pattern on out of memory
> ]

HMM.  What about refcounting?

I have a feeling that has potential to require some odd special
cases in some language bindings...

-mental



More information about the cairo mailing list