From 35408b1a6c92b5cf65ee0ff6e61149eee4ba1604 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Adam=20Sj=C3=B8gren?= Date: Fri, 24 Jan 2014 17:52:16 -0700 Subject: [PATCH] * net/shr.el (shr-tag-img): Prefer the title over the alt text. Fixes: debbugs:16537 --- lisp/ChangeLog | 5 +++++ lisp/net/shr.el | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 193ac3ec71c..4d0f99178f8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-01-25 Adam Sjøgren + + * net/shr.el (shr-tag-img): Prefer the title over the alt text + (bug#16537). + 2014-01-24 Juanma Barranquero * net/eww.el (eww-download-callback): diff --git a/lisp/net/shr.el b/lisp/net/shr.el index 7ef49eaf2d4..1491512087d 100644 --- a/lisp/net/shr.el +++ b/lisp/net/shr.el @@ -1228,7 +1228,9 @@ The preference is a float determined from `shr-prefer-media-type'." (put-text-property start (point) 'image-url url) (put-text-property start (point) 'image-displayer (shr-image-displayer shr-content-function)) - (put-text-property start (point) 'help-echo alt)) + (put-text-property start (point) 'help-echo + (or (cdr (assq :title cont)) + alt))) (setq shr-state 'image))))) (defun shr-tag-pre (cont) -- 2.11.4.GIT