Code

Mnemonics in "Fill and stroke", "Align and distribute", and "Transform" dialogs ...
[inkscape.git] / src / extension / internal / bitmap / imagemagick.cpp
index f86d0ec42feeccd2b844ac6635b1b98272084bb1..e907612fdaa093098e27d6f361e7976d7aa7a26e 100644 (file)
@@ -120,8 +120,16 @@ ImageMagickDocCache::readImage(const char *xlink, Magick::Image *image)
                image->read(blob);
        }
        else {
-               image->read(xlink);
+               const gchar *path = xlink;
+    if (strncmp (xlink,"file:", 5) == 0) {
+      path = g_filename_from_uri(xlink, NULL, NULL);
+               }
+
+               try {
+                       image->read(path);
+               } catch (...) {}
        }
+       g_free(search);
 }
 
 bool