From 1e6588110aee9f0acbbbfb0b4aa9004d153d56d1 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Mon, 16 Jul 2007 02:25:02 +0000 Subject: [PATCH] Widen before executing code in lisp tags * lisp/muse-publish.el (muse-publish-lisp-tag): Use (point-min) and (point-max) rather than beg and end. Widen before executing code, in order to not surprise those who make custom code. Add forgotten ChangeLog entries from the last commit. git-archimport-id: mwolson@gnu.org--2006/muse--main--1.0--patch-396 --- ChangeLog | 15 +++++++++++++++ lisp/muse-publish.el | 3 ++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index ae75599..13edb7b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -38,6 +38,21 @@ * lisp/muse-publish.el (muse-insert-file-or-string): Use muse-publish-markup-header-footer-tags. I'm not quite sure how this change got reverted. + (muse-markup-tag-info): Make into a function. Move common code + here, rather than duplicating it in two places. Deal with case + where muse-publish-use-header-footer-tags is non-nil. + (muse-publish-markup-specials, muse-publish-inhibit-style-hooks) + (muse-inhibit-style-tags): Move higher to avoid byte-compiler + warning. + (muse-publish-use-header-footer-tags): New variable that indicates + whether we should use just the header and footer tags, rather than + the full set. + (muse-insert-file-or-string): Bind + muse-publish-use-header-footer-tags to t. + (muse-publish-markup-tag, muse-publish-call-tag-on-buffer): + Simplify call to muse-markup-tag-info. + (muse-publish-mark-up-tag): Bind + muse-publish-use-header-footer-tags to nil. * texi/muse.texi (Journal): Update for recent changes. diff --git a/lisp/muse-publish.el b/lisp/muse-publish.el index 32d5e77..f1d1b93 100644 --- a/lisp/muse-publish.el +++ b/lisp/muse-publish.el @@ -1877,7 +1877,8 @@ BEG is modified to be the start of the published markup." (buffer-substring-no-properties (point-min) (point-max)) ")") - (delete-region beg end))))) + (delete-region (point-min) (point-max)) + (widen))))) (set-text-properties 0 (length str) nil str) (insert str))))) -- 2.11.4.GIT