From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ingo Lohmar Subject: [PATCH] fix org-insert-todo-heading-respect-content in plain list item Date: Sun, 27 Oct 2013 17:48:34 +0100 Message-ID: <878uxeu0bh.fsf@acer.localhost.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38465) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VaTWB-0007V6-LC for emacs-orgmode@gnu.org; Sun, 27 Oct 2013 12:48:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VaTW3-0005b2-6m for emacs-orgmode@gnu.org; Sun, 27 Oct 2013 12:48:47 -0400 Received: from mail-ee0-x233.google.com ([2a00:1450:4013:c00::233]:41879) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VaTW2-0005ay-VZ for emacs-orgmode@gnu.org; Sun, 27 Oct 2013 12:48:39 -0400 Received: by mail-ee0-f51.google.com with SMTP id d41so2941078eek.38 for ; Sun, 27 Oct 2013 09:48:37 -0700 (PDT) Received: from localhost (koln-4db4cbe3.pool.mediaWays.net. [77.180.203.227]) by mx.google.com with ESMTPSA id s3sm46133638eeo.3.2013.10.27.09.48.35 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sun, 27 Oct 2013 09:48:36 -0700 (PDT) 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain Hi guys, please find attached a 1-4-char patch fixing the behavior of the above function when inside a plain list. Best, Ingo --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-really-always-insert-heading.patch >From e22f9ffe3f6af69cde2397f56a7efebaaa7710e0 Mon Sep 17 00:00:00 2001 From: Ingo Lohmar Date: Sun, 27 Oct 2013 17:34:22 +0100 Subject: [PATCH] fix org-insert-todo-heading-respect-content in plain list item * lisp/org.el (org-insert-todo-heading-respect-content): pass correct prefix arg to always insert heading TINYCHANGE This function used a second argument t, which is eventually passed to org-insert-heading, adding a list item when inside a plain list. Use the proper argument '(4) now, to always create a heading, just like the function's name and documentation imply. --- lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 0fd531d..275f480 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -7770,7 +7770,7 @@ This is a list with the following elements: "Insert TODO heading with `org-insert-heading-respect-content' set to t." (interactive "P") (let ((org-insert-heading-respect-content t)) - (org-insert-todo-heading force-state t))) + (org-insert-todo-heading force-state '(4)))) (defun org-insert-todo-heading (arg &optional force-heading) "Insert a new heading with the same level and TODO state as current heading. -- 1.7.10.4 --=-=-=--