#10 closed defect (fixed)
SVG support on windows (or lack thereof)
Reported by: | Antoine Martin | Owned by: | Antoine Martin |
---|---|---|---|
Priority: | major | Milestone: | 1.1 |
Component: | Client | Keywords: | win32 |
Cc: |
Description
Some apps only supply an SVG icon (ie: wine notepad).
Either we convert those on the fly to another format (how?) and cache this on disk.
Or we get Windows/gtk to play nice and load the svg pixbuf loader...
Change History (10)
comment:1 Changed 15 years ago by
comment:2 Changed 15 years ago by
With the current version of gtk we ship, this is what happens when we try to load an SVG on MS Windows:
GError: Unable to load image-loading module: D:\Windows-Shifter/lib/gtk-2.0/2.10.0/loaders/svg_loader.dll: The specified module could not be found.
There is some sample code for rendering SVGs on win32 using ctypes:
http://www.cairographics.org/cookbook/librsvgpython/
Problem is that we get into DLL-hell: we need to bring an unknown amount of dependencies with it, see:
http://www.nabble.com/wxSVG---an-SVG-solution--td19097413.html
,
http://www.mail-archive.com/[email protected]/msg11736.html
and
http://www.nabble.com/Nmap-4.85b1->>-zenmap.exe-:-librsvg-2-2.dll-not-found!-td21691797.html
comment:3 Changed 15 years ago by
In the meantime, we could just send the SVG icons to the clients that support it. Not hard, but tedious as we would need to carry a flag with the icon data to avoid sending it to the win32 clients.
comment:4 Changed 15 years ago by
Owner: | changed from Antoine Martin to Antoine Martin |
---|---|
Status: | new → accepted |
more info about svg for win32: http://www.cairographics.org/cairo_rsvg_and_python_in_windows/
comment:5 Changed 15 years ago by
Warning dialog fixed by upgrading the build environment to the latest GTK release.
Still need to check that the rsvg dll does its job, but at least it stopped moaning!
comment:6 Changed 15 years ago by
comment:7 Changed 15 years ago by
Resolution: | → fixed |
---|---|
Status: | accepted → closed |
Tested on brand new install of XP (with MSVCR90.DLL
but that's another matter... see #68)
comment:8 Changed 15 years ago by
For reference, here is the list of DLLs used:
freetype6.dll intl.dll libatk-1.0-0.dll libcairo-2.dll libcroco-0.6-3.dll libexpat-1.dll libfontconfig-1.dll libgailutil-18.dll libgdk-win32-2.0-0.dll libgdk_pixbuf-2.0-0.dll libgio-2.0-0.dll libglib-2.0-0.dll libgmodule-2.0-0.dll libgobject-2.0-0.dll libgsf-1-114.dll libgsf-gnome-1-114.dll libgsf-win32-1-114.dll libgthread-2.0-0.dll libgtk-win32-2.0-0.dll libjpeg-7.dll libjpeg-7_1.dll libpango-1.0-0.dll libpangocairo-1.0-0.dll libpangoft2-1.0-0.dll libpangowin32-1.0-0.dll libpng12-0.dll librsvg-2-2.dll libtiff-3.dll libtiffxx-3.dll libxml2-2.dll zlib1.dll libbz2.dll.a zdll.exp zdll.lib libpixmap.dll libsvg.dll libwimp.dll svg_loader.dll libgail.dll
comment:9 Changed 15 years ago by
And here is the gdk-pixbuf.loaders
that got generated (if you don't get SVG in there, it will not work...):
# GdkPixbuf Image Loader Modules file # Automatically generated file, do not edit # Created by gdk-pixbuf-query-loaders.exe from gtk+-2.18.5 # # LoaderDir = lib/gtk-2.0/2.10.0/loaders # "./lib/gtk-2.0/2.10.0/loaders/svg_loader.dll" "svg" 2 "gtk20" "Scalable Vector Graphics" "LGPL" "image/svg+xml" "image/svg" "image/svg-xml" "image/vnd.adobe.svg+xml" "text/xml-svg" "image/svg+xml-compressed" "" "svg" "svgz" "svg.gz" "" " <svg" "* " 100 " <!DOCTYPE svg" "* " 100
comment:10 Changed 14 years ago by
Note: this no longer a problem with the latest PyGTK all-in-one installers which include svg support. see win32 dev for details.
Tried newer gtk and got this:
Doesn't look like something we should try to fix here, the problem is upstream.