From 688a42315caf5840c9db5ab957670c33d1921e92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20B=C3=B6cker?= Date: Mon, 18 Jan 2010 11:54:00 +0100 Subject: [PATCH] org-narrow-to-subtree: prevent prepending text to the next headline while narrowed --- lisp/ChangeLog | 6 ++++++ lisp/org.el | 2 +- 2 files changed, 7 insertions(+), 1 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b85a716..cb6ebe9 100755 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2010-01-18 Jan Böcker + + * org.el (org-narrow-to-subtree): Position the end of the narrowed + region before the line with the next heading, to prevent the user + from prepending text to the next headline. + 2010-01-18 Carsten Dominik * org-ctags.el (org-ctags-enable): Change order of functions. diff --git a/lisp/org.el b/lisp/org.el index 626720f..a4755a2 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -6829,7 +6829,7 @@ If yes, remember the marker and the distance to BEG." (save-match-data (narrow-to-region (progn (org-back-to-heading t) (point)) - (progn (org-end-of-subtree t t) (point)))))) + (progn (org-end-of-subtree t nil) (point)))))) (defun org-clone-subtree-with-time-shift (n &optional shift) "Clone the task (subtree) at point N times. -- 1.6.6