summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: fa28b23)
raw | patch | inline | side by side (parent: fa28b23)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 23 May 2008 17:42:34 +0000 (17:42 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 23 May 2008 17:42:34 +0000 (17:42 +0000) |
share/extensions/embedimage.py | patch | blob | history |
index 059bc063e177369ceabb7fef1b75be4dabe76c80..80030a0007f3a0791c586866b13e446b2e397806 100644 (file)
type='image/bmp'
elif (file[:6]=='GIF87a' or file[:6]=='GIF89a'):
type='image/gif'
+ elif (file[:4]=='MM\x00\x2a' or file[:4]=='II\x2a\x00'):
+ type='image/tiff'
#ico files lack any magic... therefore we check the filename instead
elif(path.endswith('.ico')):
type='image/x-icon' #official IANA registered MIME is 'image/vnd.microsoft.icon' tho
if (absref != None):
del node.attrib[inkex.addNS('absref',u'sodipodi')]
else:
- inkex.errormsg(_("%s is not of type image/png, image/jpeg, image/bmp, image/gif or image/x-icon") % path)
+ inkex.errormsg(_("%s is not of type image/png, image/jpeg, image/bmp, image/gif, image/tiff, or image/x-icon") % path)
else:
inkex.errormsg(_("Sorry we could not locate %s") % path)