# HG changeset patch # User Katsumi Yamaoka # Date 1295583417 0 # Node ID f7e256e5ea88d7ecd9597b474b097a962d13b3c1 # Parent 70d7e5c6e611dd3c76d761aa70d6e3365ab7506a gnus-art.el (gnus-article-remove-images, gnus-article-show-images): Widen article buffer. diff -r 70d7e5c6e611 -r f7e256e5ea88 lisp/gnus/ChangeLog --- a/lisp/gnus/ChangeLog Thu Jan 20 21:48:26 2011 -0600 +++ b/lisp/gnus/ChangeLog Fri Jan 21 04:16:57 2011 +0000 @@ -1,3 +1,8 @@ +2011-01-21 Katsumi Yamaoka + + * gnus-art.el (gnus-article-remove-images, gnus-article-show-images): + Widen article buffer. + 2011-01-20 Stefan Monnier * mm-util.el (mm-find-buffer-file-coding-system): Don't forget to kill diff -r 70d7e5c6e611 -r f7e256e5ea88 lisp/gnus/gnus-art.el --- a/lisp/gnus/gnus-art.el Thu Jan 20 21:48:26 2011 -0600 +++ b/lisp/gnus/gnus-art.el Fri Jan 21 04:16:57 2011 +0000 @@ -2275,19 +2275,23 @@ "Remove all images from the article buffer." (interactive) (gnus-with-article-buffer - (dolist (elem gnus-article-image-alist) - (gnus-delete-images (car elem))))) + (save-restriction + (widen) + (dolist (elem gnus-article-image-alist) + (gnus-delete-images (car elem)))))) (defun gnus-article-show-images () "Show any images that are in the HTML-rendered article buffer. This only works if the article in question is HTML." (interactive) (gnus-with-article-buffer - (dolist (region (gnus-find-text-property-region (point-min) (point-max) - 'image-displayer)) - (destructuring-bind (start end function) region - (funcall function (get-text-property start 'image-url) - start end))))) + (save-restriction + (widen) + (dolist (region (gnus-find-text-property-region (point-min) (point-max) + 'image-displayer)) + (destructuring-bind (start end function) region + (funcall function (get-text-property start 'image-url) + start end)))))) (defun gnus-article-treat-fold-newsgroups () "Unfold folded message headers.