From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Brand Subject: Re: [PATCH] Bugfix for heading levels when toggling from list Date: Thu, 9 Jun 2011 13:13:17 +0200 Message-ID: References: <87hb7zphhf.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Return-path: Received: from eggs.gnu.org ([140.186.70.92]:50287) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QUdAu-0004gE-Io for emacs-orgmode@gnu.org; Thu, 09 Jun 2011 07:13:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QUdAt-0004s3-0v for emacs-orgmode@gnu.org; Thu, 09 Jun 2011 07:13:20 -0400 Received: from mail-ey0-f169.google.com ([209.85.215.169]:56171) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QUdAs-0004ry-Sk for emacs-orgmode@gnu.org; Thu, 09 Jun 2011 07:13:18 -0400 Received: by eyd9 with SMTP id 9so584826eyd.0 for ; Thu, 09 Jun 2011 04:13:17 -0700 (PDT) In-Reply-To: <87hb7zphhf.fsf@gmail.com> 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: Michael Brand , Org Mode On Thu, Jun 9, 2011 at 09:54, Nicolas Goaziou wrote: > I would happily apply your patch, but could you explain, before, what > bugs are solved by it ? Thank you. BTW, your bugfix commit mentioned by me was not buggy at all, it just unleashed (before I wrongly wrote "introduced") this buglet hidden before: "C-c *" on an item inside heading and only with "odd": #+begin_src org ,#+STARTUP: odd ,* section , - item #+end_src expected: 3 stars, buglet: 2 stars The second buglet, found in the source code while resolving the first: "M-1 C-c *" on an item before first heading: #+begin_src org ,- item #+end_src expected: 1 star, buglet: 2 stars According to my understanding of the source code of org-toggle-heading I expect no other buglet with "C-c *" on items or body text. At least I found no buglet left when testing my changes with the necessary combinations to cover all 4 cases within each of both "cond" and both "if nstar" in the source code region I changed: - no region / region with body text lines or one item nested in one item - item(s) / body text line(s) - before first heading / inside heading - "C-c *" / "M-1 C-c *" / "M-2 C-c *" - #+STARTUP: oddeven / odd Quite a rigorous testing :-) Michael