emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] emacs-25 8a35f83 2/2: Render empty <ul><li><ul> correctly


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] emacs-25 8a35f83 2/2: Render empty <ul><li><ul> correctly
Date: Sun, 20 Mar 2016 12:58:46 +0000

branch: emacs-25
commit 8a35f83c6c2ce602ee4d1e54c64067c851a2a43f
Author: Lars Magne Ingebrigtsen <address@hidden>
Commit: Lars Magne Ingebrigtsen <address@hidden>

    Render empty <ul><li><ul> correctly
    
    * lisp/net/shr.el (shr-tag-ul): Render empty <ul><li><ul>
    correctly (bug#22964).
    (cherry picked from commit 4f6ea3988b66cf132c67fd0cc26d12eb9a300ba1)
    
    Backport:
---
 lisp/net/shr.el |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/lisp/net/shr.el b/lisp/net/shr.el
index 07fcbeb..2c8ff79 100644
--- a/lisp/net/shr.el
+++ b/lisp/net/shr.el
@@ -1480,6 +1480,10 @@ The preference is a float determined from 
`shr-prefer-media-type'."
   (shr-ensure-paragraph)
   (let ((shr-list-mode 'ul))
     (shr-generic dom))
+  ;; If we end on an empty <li>, then make sure we really end on a new
+  ;; paragraph.
+  (unless (bolp)
+    (insert "\n"))
   (shr-ensure-paragraph))
 
 (defun shr-tag-ol (dom)



reply via email to

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