GNOME Bugzilla – Bug 563264
eog refuses to open svgz-files named .svg.gz
Last modified: 2010-03-07 18:36:27 UTC
Please describe the problem: When opening a file named cg.svg.gz, of type (file -Lkz) SVG Scalable Vector Graphics image [...], eog displays the yellow error bar "Could not load image 'cg.svg.gz'. \n Unrecognized image file format". Steps to reproduce: 1. make-a-call-graph | dot -Tsvg -o cg.svg 2. gzip cg.svg 3. eog cg.svg.gz Actual results: (Like I said) Expected results: eog detects that the file doesn't match a known (naming convention, file type)-pair, does generate type detection, find it's svg xml in a gzip wrapper and shows me (damn) the image ;) Does this happen every time? Yes Other information: Refusing to open a file based on something as trivial as its name is bad usability and very un-unix'y. Especially when the name isn't misleading [but eog should still open svgz files even if they're called cg.c++].
I confirm that this is still true as of Eye of GNOME 2.28.2 Please note that svgz = svg.gz is a SVG standard, see http://lists.w3.org/Archives/Public/www-svg/2006Jan/0388.html
There's two ways to fix this: 1. Make shared-mime-info recognize the svg.gz extension. For this a request needs to be opened on Freedesktop's bugzilla. 2. Make eog sniff the mime type. See bug 490067. Problematic here is the gzip compression which slows down sniffing, which is not nice considering we had huge slowdowns due to sniffing in earlier releases. Paul, note that the "official" W3C standards still recommend the svgz extension nonetheless: http://www.w3.org/TR/SVGTiny12/intro.html#mimetype *** This bug has been marked as a duplicate of bug 490067 ***