ginopc / svg2ico

Inkscape extension to save image to ico file
MIT License
20 stars 7 forks source link

How to use the extension after installing it? #3

Open max-hk opened 4 years ago

max-hk commented 4 years ago

I can't find svg2ico in the extension menu

ferenk commented 4 years ago

I tried to use it, too. I could find a new output format in the Save as... menu. Save as type: "Win Icon File (*.ico)" However, I get an exception when I try to use it: "IOError: cannot identify image file 'C:\Users\FMoricz\AppData\Local\Temp\ink_ext_XXXXXX.svgAOUFJ0'". I've checked it, the original SVG is copied to the correct path. Maybe the extension cannot recognize all types of SVG files? The original one was created with Inkscape.

ginopc commented 4 years ago

What is inkscape version you use?

nikkiluzader commented 4 years ago

I am having the same problem. here is my Inkscape version:

1.0 (4035a4fb49, 2020-05-01)

and here is the error:

Traceback (most recent call last): File "svg2ico.py", line 79, in e.saveToFilename(args.o) File "svg2ico.py", line 61, in saveToFilename img = Image.open(self.ifName) File "/usr/lib/python3.8/site-packages/PIL/Image.py", line 2818, in open raise IOError("cannot identify image file %r" % (filename if filename else fp)) OSError: cannot identify image file '/tmp/ink_ext_XXXXXX.svg6PJON0'

I am running this on Manjaro Cinnamon image

ginopc commented 4 years ago

I'm work to upgrade extension for Inkscape v 1. There are many changes. Sorry for now

hayden-flintoft commented 2 years ago

Hi, this still seems to be an issue.

Traceback (most recent call last): File "C:\Users**\AppData\Roaming\inkscape\extensions\svg2ico\svg2ico.py", line 79, in e.saveToFilename(args.o) File "C:\Users**\AppData\Roaming\inkscape\extensions\svg2ico\svg2ico.py", line 61, in saveToFilename img = Image.open(self.ifName) File "C:\Program Files\Inkscape\lib\python3.10\site-packages\PIL\Image.py", line 3147, in open raise UnidentifiedImageError( PIL.UnidentifiedImageError: cannot identify image file 'C:\Users\****\AppData\Local\Temp\ink_ext_XXXXXX.svgFJRVS1'

Inkscape 1.2.1 (9c6d41e410, 2022-07-14)

Windows 11

image

watkipet commented 1 year ago

As @ginopc mentioned, version 0.2 of this extension isn't compatible with Inkscape 1.0 and later. I added issue #5 and pull request #6 to update the code for Inkscape 1.0.