diff options
Diffstat (limited to 'lisp/net/shr.el')
-rw-r--r-- | lisp/net/shr.el | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lisp/net/shr.el b/lisp/net/shr.el index 0effa93b197..7ee382f2f22 100644 --- a/lisp/net/shr.el +++ b/lisp/net/shr.el @@ -259,6 +259,11 @@ DOM should be a parse tree as generated by (* (frame-char-width) 2) 0))))) bidi-display-reordering) + ;; If the window was hscrolled for some reason, shr-fill-lines + ;; below will misbehave, because it silently assumes that it + ;; starts with a non-hscrolled window (vertical-motion will move + ;; to a wrong place otherwise). + (set-window-hscroll nil 0) (shr-descend dom) (shr-fill-lines start (point)) (shr-remove-trailing-whitespace start (point)) |