Commit 5d2ef6db authored by Gnus developers's avatar Gnus developers Committed by Katsumi Yamaoka
Browse files

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.
parent 23179cb9
2010-10-04 Lars Magne Ingebrigtsen <larsi@gnus.org>
* shr.el (shr-ensure-paragraph): Fix the non-empty line case.
2010-10-04 Julien Danjou <julien@danjou.info>
* gnus-html.el (gnus-html-put-image): Fix resize image code.
2010-10-04 Lars Magne Ingebrigtsen <larsi@gnus.org>
 
* shr.el (shr-insert): Use string anchors instead of line anchors.
......
......@@ -431,17 +431,19 @@ Return a string with image data."
(= (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)
......
......@@ -101,7 +101,7 @@ fit these criteria."
(insert "\n"))
(if (save-excursion
(beginning-of-line)
(looking-at " *"))
(looking-at " *$"))
(insert "\n")
(insert "\n\n")))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment