Merge remote branch 'origin/no-gnus'
[gnus] / lisp / shr.el
index e4f6bb7..ba1ca1b 100644 (file)
@@ -333,6 +333,7 @@ size, and full-buffer size."
 
 (defun shr-insert (text)
   (when (and (eq shr-state 'image)
+            (not (bolp))
             (not (string-match "\\`[ \t\n]+\\'" text)))
     (insert "\n")
     (setq shr-state nil))
@@ -367,6 +368,7 @@ size, and full-buffer size."
       (unless shr-start
        (setq shr-start (point)))
       (insert elem)
+      (setq shr-state nil)
       (let (found)
        (while (and (> (current-column) shr-width)
                    (progn
@@ -1042,7 +1044,7 @@ ones, in case fg and bg are nil."
     (shr-generic cont)))
 
 (defun shr-tag-br (cont)
-  (unless (bobp)
+  (unless (bolp)
     (insert "\n")
     (shr-indent))
   (shr-generic cont))