After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 648764 - Cannot use SVG background
Cannot use SVG background
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Background
3.0.x
Other Linux
: Normal normal
: ---
Assigned To: Control-Center Maintainers
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-04-27 14:06 UTC by Ross Burton
Modified: 2011-08-30 08:54 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ross Burton 2011-04-27 14:06:44 UTC
I have a lovely SVG image that I used to have as a wallpaper in GNOME 2, and now I've switched to GNOME 3 I can't select it in the Background preferences. :(
Comment 1 Bastien Nocera 2011-04-28 19:48:19 UTC
The patch is simple enough:

diff --git a/panels/background/bg-pictures-source.c b/panels/background/bg-pictures-source.c
index 5f2a02c..228803a 100644
--- a/panels/background/bg-pictures-source.c
+++ b/panels/background/bg-pictures-source.c
@@ -240,7 +240,8 @@ add_single_file (BgPicturesSource *bg_source,
     return FALSE;
 
   if (g_str_equal ("image/png", content_type) ||
-      g_str_equal ("image/jpeg", content_type))
+      g_str_equal ("image/jpeg", content_type) ||
+      g_str_equal ("image/svg+xml", content_type))
     {
       CcBackgroundItem *item;
       char *uri;

But, I would guess that the majority of svg images that one would use as backgrounds would be semi-transparent ones. I couldn't see either of the images I selected when using nautilus, see bug 648882.
Comment 2 Matthias Clasen 2011-04-29 03:20:44 UTC
diff --git a/panels/background/cc-background-panel.c b/panels/background/cc-back
index 2ba9c56..a8a9a9b 100644
--- a/panels/background/cc-background-panel.c
+++ b/panels/background/cc-background-panel.c
@@ -957,8 +957,7 @@ add_button_clicked (GtkButton         *button,
   priv = panel->priv;
 
   filter = gtk_file_filter_new ();
-  gtk_file_filter_add_mime_type (filter, "image/png");
-  gtk_file_filter_add_mime_type (filter, "image/jpeg");
+  gtk_file_filter_add_mime_type (filter, "image/*");
 
   chooser = gtk_file_chooser_dialog_new (_("Browse for more pictures"),
                                         GTK_WINDOW (gtk_widget_get_toplevel (WI


is also needed
Comment 3 Rodrigo Moya 2011-08-30 08:32:27 UTC
Fixed in master
Comment 4 Bastien Nocera 2011-08-30 08:54:05 UTC
It hasn't been pushed, and still has the same problem I mentioned in comment 1. Why did you commit (and not push) this?