The
cairo-status-t enumeration is used to indicate errors that can
occur when using Cairo.
In some cases it is returned directly by functions. but when using a
cairo-t context, the last error, if any, is stored in the context and can be retrieved with the function
cairo-status.
New entries may be added in future versions. Use the function
cairo-status-to-string to get a human readable representation of an
error message.
(defcenum cairo-status-t
:success
:no-memory
:invalid-restore
:invalid-pop-group
:no-current-point
:invalid-matrix
:invalid-status
:null-pointer
:invalid-string
:invalid-path-data
:read-error
:write-error
:surface-finished
:surface-type-mismatch
:pattern-type-mismatch
:invalid-content
:invalid-format
:invalid-visual
:file-not-found
:invalid-dash
:invalid-dsc-comment
:invalid-index
:clip-not-representable
:temp-file-error
:invalide-stride
:font-type-mismatch
:user-font-immutable
:user-font-error
:negative-count
:invalid-clusters
:invalid-slant
:invalid-weight
:invalid-size
:user-font-not-implemented
:device-type-mismatch
:device-error
:invalid-mesh-construction
:device-finished
:jbig2-global-missing
:png-error
:freetype-error
:win32-gdk-error
:tag-error
:last-status)
- :success
- No error has occurred.
- :no-memory
- Out of memory.
- :invalid-store
- The function cairo-restore called without matching the function cairo-save.
- :invalid-pop-group
- No saved group to pop, i.e. the function cairo-pop-group without matching the function cairo-push-group.
- :no-current-point
- No current point defined.
- :invalid-matrix
- Invalid matrix (not invertible).
- :invalid-status
- Invalid cairo-status-t value for an input.
- :null-pointer
- NULL pointer.
- :invalid-string
- Input string not valid UTF-8.
- :path-data
- Input path data not valid.
- :read-error
- Error while reading from input stream.
- :write-error
- Error while writing to output stream.
- :surface-finished
- Target surface has been finished.
- :surface-type-mismatch
- The surface type is not appropriate for the operation.
- :pattern-type-mismatch
- The pattern type is not appropriate for the operation.
- :invalid-content
- Invalid cairo-content-t value for an input.
- :invalid-format
- Invalid cairo-format-t value for an input.
- :invalid-visual
- Invalid value for an input Visual.
- :file-not-found
- File not found.
- :invalid-dash
- Invalid value for a dash setting.
- :invalid-dsc-comment
- Invalid value for a DSC comment.
- :invalid-index
- Invalid index passed to getter.
- :clip-not-representable
- Clip region not representable in desired format.
- :temp-file-error
- Error creating or writing to a temporary file.
- :invalid-stride
- Invalid value for stride.
- :font-type-mismatch
- The font type is not appropriate for the operation.
- :user-font-immutable
- The user-font is immutable.
- :user-font-error
- Error occurred in a user-font callback function.
- :negative-count
- Negative number used where it is not allowed.
- :invalid-clusters
- Input clusters do not represent the accompanying text and glyph array.
- :invalid-slant
- Invalid cairo-font-slant-t value for an input.
- :invalid-weight
- Invalid cairo-font-weight-t value for an input.
- :invalid-size
- Invalid value (typically too big) for the size of the input (surface, pattern, etc.).
- :user-font-not-implemented
- User-font method not implemented.
- :device-type-mismatch
- The device type is not appropriate for the operation.
- :device-error
- An operation to the device caused an unspecified error.
- :invalid-mesh-construction
- A mesh pattern construction operation was used outside of a cairo-mesh-pattern-begin-patch and cairo-mesh-pattern-end-patch pair of functions.
- :device-finished
- Target device has been finished.
- :jbig2-global-missing
- CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID has
been used on at least one image but no image provided CAIRO_MIME_TYPE_JBIG2_GLOBAL.
- :png-error
- Error occurred in libpng while reading from or writing to a PNG file.
- :freetype-error
- Error occurred in libfreetype.
- :win32-gdi-error
- Error occurred in the Windows Graphics Device Interface.
- :tag-error
- Invalid tag name, attributes, or nesting.
- :last-status
- This is a special value indicating the number of status
values defined in this enumeration. When using this value, note that the
version of Cairo at run-time may have additional status values defined than the value of this symbol at compile-time.