A Cairo context
An element's id within the SVG, starting with "#" (a single hash character), for example, #layer1. This notation corresponds to a URL's fragment ID. Alternatively, pass NULL to render the whole SVG.
TRUE if drawing succeeded; FALSE otherwise. This function will emit a g_warning() if a rendering error occurs.
Deprecated: Please use rsvg.handle.Handle.renderLayer instead; that function lets you pass a viewport and obtain a good error message.
Renders a single SVG element in the same place as for a whole SVG document (a "subset" of the document). Please try to use rsvg.handle.Handle.renderLayer instead, which allows you to pick the size at which the document with the layer will be rendered.
This is equivalent to rsvg.handle.Handle.renderCairo, but it renders only a single element and its children, as if they composed an individual layer in the SVG.
Historically this function has picked a size for the whole document by itself, based on the following rules:
Drawing will occur with respect to the cr's current transformation: for example, if the cr has a rotated current transformation matrix, the whole SVG will be rotated in the rendered version.
This function depends on the rsvg.handle.Handle's DPI to compute dimensions in pixels, so you should call rsvg.handle.Handle.setDpi beforehand.
Note that cr must be a Cairo context that is not in an error state, that is, [cairo.context.Context.status] must return cairo.types.Status.Success for it. Cairo can set a context to be in an error state in various situations, for example, if it was passed an invalid matrix or if it was created for an invalid surface.
Element IDs should look like an URL fragment identifier; for example, pass #foo (hash foo) to get the geometry of the element that has an id="foo" attribute.