[gimp] file-svg: Remove obsolete code which was put in to handle librsvg API breakage
- From: Mukund Sivaraman <muks src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] file-svg: Remove obsolete code which was put in to handle librsvg API breakage
- Date: Thu, 1 Dec 2011 16:54:22 +0000 (UTC)
commit a174f5d44ab076aed99958c3ff901ae00dd8a406
Author: Mukund Sivaraman <muks banu com>
Date: Thu Dec 1 22:23:16 2011 +0530
file-svg: Remove obsolete code which was put in to handle librsvg API breakage
GIMP now depends on a more recent version of librsvg.
plug-ins/common/file-svg.c | 26 ++++----------------------
1 files changed, 4 insertions(+), 22 deletions(-)
---
diff --git a/plug-ins/common/file-svg.c b/plug-ins/common/file-svg.c
index 36f186d..0ae1e28 100644
--- a/plug-ins/common/file-svg.c
+++ b/plug-ins/common/file-svg.c
@@ -407,26 +407,6 @@ load_set_size_callback (gint *width,
}
}
-static RsvgHandle *
-load_rsvg_handle_new (gdouble xres,
- gdouble yres)
-{
- RsvgHandle *handle = rsvg_handle_new ();
-
-#if (((LIBRSVG_MAJOR_VERSION == 2) && (LIBRSVG_MINOR_VERSION == 13) && \
- ((LIBRSVG_MICRO_VERSION == 0) || \
- (LIBRSVG_MICRO_VERSION == 1) || \
- (LIBRSVG_MICRO_VERSION == 2))) || \
- ((LIBRSVG_MAJOR_VERSION == 2) && (LIBRSVG_MINOR_VERSION == 11) && \
- (LIBRSVG_MICRO_VERSION == 0)))
- rsvg_handle_set_dpi (handle, xres, yres);
-#else
- rsvg_handle_set_dpi_x_y (handle, xres, yres);
-#endif
-
- return handle;
-}
-
/* This function renders a pixbuf from an SVG file according to vals. */
static GdkPixbuf *
load_rsvg_pixbuf (const gchar *filename,
@@ -446,7 +426,8 @@ load_rsvg_pixbuf (const gchar *filename,
g_io_channel_set_encoding (io, NULL, NULL);
- handle = load_rsvg_handle_new (vals->resolution, vals->resolution);
+ handle = rsvg_handle_new ();
+ rsvg_handle_set_dpi (handle, vals->resolution);
/* set the base URI so that librsvg can resolve relative paths */
uri = g_filename_to_uri (filename, NULL, NULL);
@@ -521,7 +502,8 @@ load_rsvg_size (const gchar *filename,
g_io_channel_set_encoding (io, NULL, NULL);
- handle = load_rsvg_handle_new (vals->resolution, vals->resolution);
+ handle = rsvg_handle_new ();
+ rsvg_handle_set_dpi (handle, vals->resolution);
vals->width = SVG_DEFAULT_SIZE;
vals->height = SVG_DEFAULT_SIZE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]