diagram = svgtiny_create();
if (!diagram) {
g_set_error_literal(error,
- GDK_PIXBUF_ERROR,
- GDK_PIXBUF_ERROR_FAILED,
- "svgtiny_create() failed");
+ G_FILE_ERROR,
+ G_FILE_ERROR_NOMEM,
+ "out of memory in svgtiny_create()");
return NULL;
}
g_set_error_literal(error,
GDK_PIXBUF_ERROR,
GDK_PIXBUF_ERROR_CORRUPT_IMAGE,
- "libdom error in svgtiny_parse()");
+ "invalid XML DOM in svgtiny_parse()");
break;
case svgtiny_NOT_SVG:
g_set_error_literal(error,
GDK_PIXBUF_ERROR,
GDK_PIXBUF_ERROR_CORRUPT_IMAGE,
- "encountered svgtiny_NOT_SVG in svgtiny_parse()");
+ "missing <svg> element in svgtiny_parse()");
break;
case svgtiny_SVG_ERROR:
g_set_error(error,
GDK_PIXBUF_ERROR,
GDK_PIXBUF_ERROR_CORRUPT_IMAGE,
- "SVG error in svgtiny_parse() on line %i: %s",
+ "SVG format error in svgtiny_parse() on line %i: %s",
diagram->error_line,
diagram->error_message);
break;