Merge branch 'master' of https://git.gnus.org/gnus
authorLars Magne Ingebrigtsen <larsi@quimbies.gnus.org>
Mon, 11 Oct 2010 18:00:34 +0000 (20:00 +0200)
committerLars Magne Ingebrigtsen <larsi@quimbies.gnus.org>
Mon, 11 Oct 2010 18:00:34 +0000 (20:00 +0200)
Conflicts:
lisp/ChangeLog

lisp/ChangeLog
lisp/shr.el

index b8497da..3f8b71c 100644 (file)
@@ -3,6 +3,14 @@
        * sieve-manage.el (sieve-manage-open): Allow port names as well as port
        numbers.
 
+2010-10-11  Julien Danjou  <julien@danjou.info>
+
+       * shr.el (shr-hr-line): Add.
+       (shr-tag-hr): Use shr-hr-line to specify which character to use to
+       display hr lines.
+       (shr-max-columns): Do not change state to nil if we just inserting
+       spaces.
+
 2010-10-11  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
        * gnus-topic.el (gnus-topic-read-group): If after the last group,
index 0700621..2ad49dd 100644 (file)
@@ -59,7 +59,12 @@ fit these criteria."
   :type 'char)
 
 (defcustom shr-table-corner ?+
-  "Charater used to draw table corner."
+  "Character used to draw table corner."
+  :group 'shr
+  :type 'char)
+
+(defcustom shr-hr-line ?-
+  "Character used to draw hr line."
   :group 'shr
   :type 'char)
 
@@ -188,7 +193,8 @@ redirects somewhere else."
       (shr-descend sub)))))
 
 (defun shr-insert (text)
-  (when (eq shr-state 'image)
+  (when (and (eq shr-state 'image)
+             (not (string-match "^\\s-*$" text)))
     (insert "\n")
     (setq shr-state nil))
   (cond
@@ -468,7 +474,7 @@ Return a string with image data."
 
 (defun shr-tag-hr (cont)
   (shr-ensure-newline)
-  (insert (make-string shr-width ?-) "\n"))
+  (insert (make-string shr-width shr-hr-line) "\n"))
 
 ;;; Table rendering algorithm.