From 132b4488ba5b077bb8900b797007e4a548a6190e Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Fri, 27 Jul 2007 16:14:10 +0000 Subject: [PATCH] Fix blank line in front of list item bug 2007-07-27 Michael Olson * lisp/muse-publish.el (muse-publish-surround-text): Fix bug involving list items that have an extra blank line in front. git-archimport-id: mwolson@gnu.org--2006/muse--main--1.0--patch-408 --- ChangeLog | 5 +++++ lisp/muse-publish.el | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 25844c3..bce3c4c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-07-27 Michael Olson + + * lisp/muse-publish.el (muse-publish-surround-text): Fix bug + involving list items that have an extra blank line in front. + 2007-07-27 Jean Magnan de Bornier * lisp/muse-context.el (muse-context-header): Put diff --git a/lisp/muse-publish.el b/lisp/muse-publish.el index 9acb6ed..71db159 100644 --- a/lisp/muse-publish.el +++ b/lisp/muse-publish.el @@ -1270,10 +1270,15 @@ The following contexts exist in Muse. ;; same type (replace-match "" t t nil 1)) (save-restriction - (narrow-to-region beg (point)) ;; narrow to current item + (narrow-to-region beg (point)) + ;; move to second line of text (goto-char (point-min)) + (while (and (< (point) (point-max)) + (looking-at empty-line)) + (forward-line 1)) (forward-line 1) + ;; strip list indentation (muse-publish-strip-list-indentation list-item empty-line indent post-indent) (skip-chars-backward (concat muse-regexp-blank "\n")) -- 2.11.4.GIT