]> git.eshelyaron.com Git - emacs.git/commitdiff
Give ImageMagick lowest priority in image-type-file-name-regexps.
authorChong Yidong <cyd@gnu.org>
Mon, 11 Jun 2012 10:16:47 +0000 (18:16 +0800)
committerChong Yidong <cyd@gnu.org>
Mon, 11 Jun 2012 10:16:47 +0000 (18:16 +0800)
* lisp/image.el (imagemagick-register-types): Put the ImageMagick
entry at the end of image-type-file-name-regexps.

lisp/ChangeLog
lisp/image.el

index 026e84058ef3cbe3ba79c0dd441eba2a55d853a5..6872e3d2235bda3429718c40df3b54ed8561f3f5 100644 (file)
@@ -1,3 +1,8 @@
+2012-06-11  Chong Yidong  <cyd@gnu.org>
+
+       * image.el (imagemagick-register-types): Put the ImageMagick entry
+       at the end of image-type-file-name-regexps.
+
 2012-06-11  Johan Bockgård  <bojohan@gnu.org>
 
        * emacs-lisp/pcase.el (pcase-UPAT, pcase-QPAT): New edebug specs.
index a47e945c26ab006de7fa075fbbeb69d0d3e4695a..f5a2de5e595a9d6a3c06e5cb40ec89c33e355188 100644 (file)
@@ -747,7 +747,10 @@ If Emacs is compiled without ImageMagick support, this does nothing."
          (push (cons re 'image-mode) auto-mode-alist))
        (if itfnr-elt
            (setcar itfnr-elt re)
-         (push (cons re 'imagemagick) image-type-file-name-regexps)))
+         ;; Append to `image-type-file-name-regexps', so that we
+         ;; preferentially use specialized image libraries.
+         (add-to-list 'image-type-file-name-regexps
+                      (cons re 'imagemagick) t)))
       (setq imagemagick--file-regexp re))))
 
 (defcustom imagemagick-types-inhibit