cairo_surface_t

Main Gtk struct. A cairo_surface_t represents an image, either as the destination of a drawing operation or as source when drawing onto another surface. To draw to a cairo_surface_t, create a cairo context with the surface as the target, using cairo_create(). There are different subtypes of cairo_surface_t for different drawing backends; for example, cairo_image_surface_create() creates a bitmap image in memory. The type of a surface can be queried with cairo_surface_get_type(). The initial contents of a surface after creation depend upon the manner of its creation. If cairo creates the surface and backing storage for the user, it will be initially cleared; for example, cairo_image_surface_create() and cairo_surface_create_similar(). Alternatively, if the user passes in a reference to some backing storage and asks cairo to wrap that in a cairo_surface_t, then the contents are not modified; for example, cairo_image_surface_create_for_data() and cairo_xlib_surface_create(). Memory management of cairo_surface_t is done with cairo_surface_reference() and cairo_surface_destroy().

struct cairo_surface_t

Meta