Fix up the padding removal logic
authorLars Ingebrigtsen <larsi@gnus.org>
Wed, 15 Feb 2012 08:20:24 +0000 (09:20 +0100)
committerLars Ingebrigtsen <larsi@gnus.org>
Wed, 15 Feb 2012 08:20:24 +0000 (09:20 +0100)
* shr.el (shr-remove-trailing-whitespace): Really delete the padding on
too-wide lines.

lisp/ChangeLog
lisp/shr.el

index c61dc0d..de13a27 100644 (file)
@@ -1,3 +1,8 @@
+2012-02-15  Lars Ingebrigtsen  <larsi@gnus.org>
+
+       * shr.el (shr-remove-trailing-whitespace): Really delete the padding on
+       too-wide lines.
+
 2012-02-13  Lars Ingebrigtsen  <larsi@gnus.org>
 
        * nnimap.el (nnimap-record-commands): New variable.
index 47622f5..f594a60 100644 (file)
@@ -160,7 +160,7 @@ DOM should be a parse tree as generated by
       (goto-char start)
       (while (not (eobp))
        (end-of-line)
-       (when (> (current-column) width)
+       (when (> (shr-previous-newline-padding-width (current-column)) width)
          (dolist (overlay (overlays-at (point)))
            (when (overlay-get overlay 'before-string)
              (overlay-put overlay 'before-string nil))))