# HG changeset patch # User Katsumi Yamaoka # Date 1286187417 0 # Node ID 5c603f558199216ddee59f04a0f05071d1ae7179 # Parent fa69a70cd62e51dfa73ebf56414b0338e9cbc5d3 Merge changes made in Gnus trunk. gnus-html.el (gnus-html-put-image): Fix resize image code. shr.el (shr-ensure-paragraph): Fix the non-empty line case. diff -r fa69a70cd62e -r 5c603f558199 lisp/gnus/ChangeLog --- a/lisp/gnus/ChangeLog Mon Oct 04 07:42:58 2010 +0000 +++ b/lisp/gnus/ChangeLog Mon Oct 04 10:16:57 2010 +0000 @@ -1,3 +1,11 @@ +2010-10-04 Lars Magne Ingebrigtsen + + * shr.el (shr-ensure-paragraph): Fix the non-empty line case. + +2010-10-04 Julien Danjou + + * gnus-html.el (gnus-html-put-image): Fix resize image code. + 2010-10-04 Lars Magne Ingebrigtsen * shr.el (shr-insert): Use string anchors instead of line anchors. diff -r fa69a70cd62e -r 5c603f558199 lisp/gnus/gnus-html.el --- a/lisp/gnus/gnus-html.el Mon Oct 04 07:42:58 2010 +0000 +++ b/lisp/gnus/gnus-html.el Mon Oct 04 10:16:57 2010 +0000 @@ -431,17 +431,19 @@ (= (car size) 30) (= (cdr size) 30)))) ;; Good image, add it! - (let ((image (gnus-html-rescale-image + (let ((image (gnus-rescale-image image - ;; (width . height) - (cons - ;; Aimed width - (truncate - (* gnus-max-image-proportion - (- (nth 2 edges) (nth 0 edges)))) - ;; Aimed height - (truncate (* gnus-max-image-proportion - (- (nth 3 edges) (nth 1 edges)))))))) + (let ((edges (gnus-window-inside-pixel-edges + (get-buffer-window (current-buffer))))) + ;; (width . height) + (cons + ;; Aimed width + (truncate + (* gnus-max-image-proportion + (- (nth 2 edges) (nth 0 edges)))) + ;; Aimed height + (truncate (* gnus-max-image-proportion + (- (nth 3 edges) (nth 1 edges))))))))) (delete-region start end) (gnus-put-image image alt-text 'external) (gnus-put-text-property start (point) 'help-echo alt-text) diff -r fa69a70cd62e -r 5c603f558199 lisp/gnus/shr.el --- a/lisp/gnus/shr.el Mon Oct 04 07:42:58 2010 +0000 +++ b/lisp/gnus/shr.el Mon Oct 04 10:16:57 2010 +0000 @@ -101,7 +101,7 @@ (insert "\n")) (if (save-excursion (beginning-of-line) - (looking-at " *")) + (looking-at " *$")) (insert "\n") (insert "\n\n")))))