Skip to content

Instantly share code, notes, and snippets.

@bpowers
Created June 28, 2013 18:27
Show Gist options
  • Save bpowers/5886884 to your computer and use it in GitHub Desktop.
Save bpowers/5886884 to your computer and use it in GitHub Desktop.
void draw(cairo_t* cr)
{
// ... do some vector drawing
cairo_surface_t* surface = cairo_get_target(cr);
cairo_surface_flush(surface);
CGContextRef cgctx = cairo_quartz_surface_get_cg_context(surface);
// use Apple's CoreText API
cairo_surface_mark_dirty(surface);
// do more vector drawing
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment