emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/gnus/mm-decode.el, v [EMACS_22_BASE]


From: Miles Bader
Subject: [Emacs-diffs] Changes to emacs/lisp/gnus/mm-decode.el, v [EMACS_22_BASE]
Date: Thu, 14 Jun 2007 10:02:58 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Branch:         EMACS_22_BASE
Changes by:     Miles Bader <miles>     07/06/14 10:02:56

Index: lisp/gnus/mm-decode.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/gnus/mm-decode.el,v
retrieving revision 1.42
retrieving revision 1.42.2.1
diff -u -b -r1.42 -r1.42.2.1
--- lisp/gnus/mm-decode.el      21 Jan 2007 02:54:13 -0000      1.42
+++ lisp/gnus/mm-decode.el      14 Jun 2007 10:02:55 -0000      1.42.2.1
@@ -1371,18 +1371,19 @@
 (defun mm-image-fit-p (handle)
   "Say whether the image in HANDLE will fit the current window."
   (let ((image (mm-get-image handle)))
+    (or (not image)
     (if (fboundp 'glyph-width)
        ;; XEmacs' glyphs can actually tell us about their width, so
        ;; lets be nice and smart about them.
        (or mm-inline-large-images
-           (and (< (glyph-width image) (window-pixel-width))
-                (< (glyph-height image) (window-pixel-height))))
+               (and (<= (glyph-width image) (window-pixel-width))
+                    (<= (glyph-height image) (window-pixel-height))))
       (let* ((size (image-size image))
             (w (car size))
             (h (cdr size)))
        (or mm-inline-large-images
-           (and (< h (1- (window-height))) ; Don't include mode line.
-                (< w (window-width))))))))
+               (and (<= h (1- (window-height))) ; Don't include mode line.
+                    (<= w (window-width)))))))))
 
 (defun mm-valid-image-format-p (format)
   "Say whether FORMAT can be displayed natively by Emacs."




reply via email to

[Prev in Thread] Current Thread [Next in Thread]