Constructor

RsvgHandlenew_from_gfile_sync

Declaration [src]

RsvgHandle*
rsvg_handle_new_from_gfile_sync (
  GFile* file,
  RsvgHandleFlags flags,
  GCancellable* cancellable,
  GError** error
)

Description [src]

Creates a new RsvgHandle for file.

This function sets the “base file” of the handle to be file itself, so SVG elements like <image> which reference external resources will be resolved relative to the location of file.

If cancellable is not NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation was cancelled, the error G_IO_ERROR_CANCELLED will be returned in error.

Available since:2.32

Parameters

file GFile
 

A GFile

 The data is owned by the caller of the function.
flags RsvgHandleFlags
 

Flags from RsvgHandleFlags

cancellable GCancellable
 

A GCancellable, or NULL

 The argument can be NULL.
 The data is owned by the caller of the function.
error GError **
  The return location for a GError*, or NULL.

Return value

Returns: RsvgHandle
 

A new RsvgHandle on success, or NULL with error filled in.

 The caller of the function takes ownership of the data, and is responsible for freeing it.
 The return value can be NULL.