It seems to me that the following should be renamed to image-type and
moved to image.el, or--probably better--calls to thumbs-image-type
should be replaced by image-type-from-file-header.

(defun thumbs-image-type (img)
  "Return image type from filename IMG."
  (cond ((string-match ".*\\.jpe?g\\'" img) 'jpeg)
        ((string-match ".*\\.xpm\\'" img) 'xpm)
        ((string-match ".*\\.xbm\\'" img) 'xbm)
        ((string-match ".*\\.gif\\'" img) 'gif)
        ((string-match ".*\\.bmp\\'" img) 'bmp)
        ((string-match ".*\\.png\\'" img) 'png)
        ((string-match ".*\\.tiff?\\'" img) 'tiff)))

-- 
Bill Wohler <[EMAIL PROTECTED]>  http://www.newt.com/wohler/  GnuPG ID:610BD9AD
Maintainer of comp.mail.mh FAQ and MH-E. Vote Libertarian!
If you're passed on the right, you're in the wrong lane.


_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

Reply via email to