summaryrefslogtreecommitdiffstats
path: root/src/object/sp-image.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/object/sp-image.cpp')
-rw-r--r--src/object/sp-image.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/object/sp-image.cpp b/src/object/sp-image.cpp
index 8d3a15f0b..6fd9e5c1e 100644
--- a/src/object/sp-image.cpp
+++ b/src/object/sp-image.cpp
@@ -509,6 +509,26 @@ gchar* SPImage::description() const {
this->pixbuf->width(),
this->pixbuf->height(),
href_desc) );
+
+ if (this->pixbuf == NULL &&
+ this->document)
+ {
+ Inkscape::Pixbuf * pb = NULL;
+ pb = sp_image_repr_read_image (
+ this->getRepr()->attribute("xlink:href"),
+ this->getRepr()->attribute("sodipodi:absref"),
+ this->document->getBase());
+
+ if (pb) {
+ ret = ( pb == NULL ? g_strdup_printf(_("[bad reference]: %s"), href_desc)
+ : g_strdup_printf(_("%d × %d: %s"),
+ pb->width(),
+ pb->height(),
+ href_desc));
+ delete pb;
+ }
+ }
+
g_free(href_desc);
return ret;
}