emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 7e012d0: Tweak shr link text property adjustments w


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 7e012d0: Tweak shr link text property adjustments when folding
Date: Sat, 14 Apr 2018 15:14:10 -0400 (EDT)

branch: master
commit 7e012d038422605e44afbc916769e51f6682dbce
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Tweak shr link text property adjustments when folding
    
    * lisp/net/shr.el (shr-fill-line): If a link starts at the first
    word on a new folded line, then don't copy the link properties to
    the newline inserted.
---
 lisp/net/shr.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lisp/net/shr.el b/lisp/net/shr.el
index fb17b85..d12ee68 100644
--- a/lisp/net/shr.el
+++ b/lisp/net/shr.el
@@ -734,10 +734,10 @@ size, and full-buffer size."
            (skip-chars-forward " ")
            (search-forward " " (line-end-position) 'move)))
       ;; Success; continue.
-      (when (= (preceding-char) ?\s)
-       (delete-char -1))
       (let ((props (copy-sequence (text-properties-at (point))))
            (gap-start (point)))
+        (when (= (preceding-char) ?\s)
+         (delete-char -1))
         ;; We don't want to use the faces on the indentation, because
         ;; that's ugly, but we want all the other properties to be
         ;; continuous so that links do not split up into many links



reply via email to

[Prev in Thread] Current Thread [Next in Thread]