From 931bf6013e215a96989d34ef2eefa4a89b31ba67 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Fri, 15 Sep 2006 04:04:15 +0000 Subject: [PATCH] Merged from mwolson@gnu.org--2006-muse-el (patch 92) Patches applied: * mwolson@gnu.org--2006-muse-el/muse-el--devel--0--patch-92 muse-texinfo: selectively protect wikiwords in headings git-archimport-id: mwolson@gnu.org--2006/muse--main--1.0--patch-207 --- lisp/muse-texinfo.el | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/lisp/muse-texinfo.el b/lisp/muse-texinfo.el index 6eacc15..b948d1f 100644 --- a/lisp/muse-texinfo.el +++ b/lisp/muse-texinfo.el @@ -235,6 +235,15 @@ If no description exists for the link, use the link itself." t t string))) string)) +(defun muse-texinfo-protect-wikiwords (start end) + "Protect all wikiwords from START to END from further processing." + (when (featurep 'muse-wiki) + (save-excursion + (goto-char start) + (while (re-search-forward muse-wiki-wikiword-regexp end t) + (muse-publish-mark-read-only (match-beginning 0) + (match-end 0)))))) + (defun muse-texinfo-markup-heading () (save-excursion (muse-publish-markup-heading)) @@ -244,7 +253,7 @@ If no description exists for the link, use the link itself." (delete-region (point) eol) ;; don't allow links to be published in headings (insert (muse-texinfo-remove-links orig-heading)) - (muse-publish-mark-read-only beg (point)))) + (muse-texinfo-protect-wikiwords beg (point)))) (defun muse-texinfo-finalize-buffer () (muse-latex-fixup-dquotes) -- 2.11.4.GIT