From 0bd9981e0d9ed64ff1426698692d15b9c8a1d439 Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Tue, 22 Nov 2011 07:56:00 -0700 Subject: [PATCH] Don't license to kill text inside blocks when getting a title * lisp/org-exp.el (org-export-grab-title-from-buffer): Don't license to kill text inside blocks when getting a title. --- lisp/org-exp.el | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lisp/org-exp.el b/lisp/org-exp.el index 911188772..69f0280de 100644 --- a/lisp/org-exp.el +++ b/lisp/org-exp.el @@ -2151,9 +2151,10 @@ can work correctly." (save-excursion (outline-next-heading) (point))))) (when (re-search-forward "^[ \t]*[^|# \t\r\n].*\n" end t) ;; Mark the line so that it will not be exported as normal text. - (org-unmodified - (add-text-properties (match-beginning 0) (match-end 0) - (list :org-license-to-kill t))) + (unless (org-in-block-p org-list-forbidden-blocks) + (org-unmodified + (add-text-properties (match-beginning 0) (match-end 0) + (list :org-license-to-kill t)))) ;; Return the title string (org-trim (match-string 0))))))) -- 2.11.4.GIT