I'm looking to create favicon.ico
files programatically from Python, but PIL only has support for reading ico
files.
views:
537answers:
3
+2
A:
Perhaps the following would work:
- Generate your icon image using PIL
- Convert the image to .ico format using the python interface to ImageMagick, PythonMagick
I have not tried this approach. The ImageMagick convert command line program was able to convert a .png file to .ico format, so at least ImageMagick supports the .ico format.
codeape
2008-09-05 10:36:58
+2
A:
I don't know if this applies for all cases, but on WinXP an .ico can be a bmp of size 16x16, 32x32 or 64x64. Just change the extension to ico from bmp and you're ready to go.
Hope this helps
thing2k
thing2k
2008-09-05 10:38:00
+2
A:
According to Wikipedia modern browsers can handle favicons in PNG format, so maybe you could just generate that?
Alternatively the ICO article describes the format...
Douglas Leeder
2008-09-05 13:35:32