From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Vivier Subject: Re: [PATCH 1/2] Fix narrowing for 1-line subtrees Date: Tue, 19 Feb 2019 16:40:32 +0100 Message-ID: <874l8zn5vz.fsf@hidden> References: <20190218002547.30325-1-leo.vivier@gmail.com> <87mumsqepg.fsf@nicolasgoaziou.fr> <871s44cbzb.fsf@hidden> <87sgwkoue5.fsf@nicolasgoaziou.fr> <87d0nnnbkf.fsf@hidden> <877edvn6g3.fsf@hidden> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([209.51.188.92]:36339) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gw7Vg-0002qk-3k for emacs-orgmode@gnu.org; Tue, 19 Feb 2019 10:40:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gw7Vf-0008L0-5Y for emacs-orgmode@gnu.org; Tue, 19 Feb 2019 10:40:39 -0500 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:52401) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gw7Ve-0008JO-RK for emacs-orgmode@gnu.org; Tue, 19 Feb 2019 10:40:39 -0500 Received: by mail-wm1-x341.google.com with SMTP id m1so3329636wml.2 for ; Tue, 19 Feb 2019 07:40:35 -0800 (PST) In-Reply-To: <877edvn6g3.fsf@hidden> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Nicolas Goaziou Cc: emacs-orgmode@gnu.org Sorry, the patch I've submitted wasn't right: it had part of another test I was running, hence the `end-of-line'. Here's the proper version: --------------------------------[START]-------------------------------- lisp/org.el | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index ef6e40ca9..4514407e7 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -13046,17 +13046,17 @@ WHAT entry will also be removed." (unless (=3D (skip-chars-backward " \t" p) 0) (delete-region (point) (line-end-position))))))) ((not what) (throw 'exit nil)) ; Nothing to do. - (t (insert-before-markers "\n") - (backward-char 1) + (t (backward-char 1) (when org-adapt-indentation (indent-to-column (1+ (org-outline-level)))))) (when what ;; Insert planning keyword. - (insert (cl-case what - (closed org-closed-string) - (deadline org-deadline-string) - (scheduled org-scheduled-string) - (otherwise (error "Invalid planning type: %s" what))) + (insert "\n" + (cl-case what + (closed org-closed-string) + (deadline org-deadline-string) + (scheduled org-scheduled-string) + (otherwise (error "Invalid planning type: %s" what))) " ") ;; Insert associated timestamp. (let ((ts (org-insert-time-stamp --=20 2.20.1 ---------------------------------[END]--------------------------------- Best, --=20 Leo Vivier English Studies & General Linguistics Master Student, English Department Universit=C3=A9 Rennes 2