From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Subject: Re: [BUG] Changing TODO states sometimes modifies the schedulingof the next heading Date: Mon, 4 Apr 2011 20:25:00 +0000 (UTC) Message-ID: References: <878vvrv4l7.fsf@fastmail.fm> <877hbbjngq.fsf@fastmail.fm> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=52527 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q6qKo-00057A-As for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 16:25:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q6qKn-0002a9-CW for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 16:25:14 -0400 Received: from lo.gmane.org ([80.91.229.12]:48741) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q6qKn-0002ZZ-5V for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 16:25:13 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Q6qKl-0002Lm-L4 for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 22:25:11 +0200 Received: from 77-234-78-148.pool.digikabel.hu ([77.234.78.148]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 04 Apr 2011 22:25:11 +0200 Received: from adatgyujto by 77-234-78-148.pool.digikabel.hu with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 04 Apr 2011 22:25:11 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Tom gmail.com> writes: > > Bottom line: the problem does not occur in the English locale, > because there all day abbreviations are 3 chars long, so the > above described simple way of restoring the cursor position > always works. But this is not true for all locales, so org > shouldn't rely on that. > > I created a temporary fix for the problem with advice until it is fixed in the code properly. Here it is if someone needs it: (defadvice org-todo (around my-org-todo activate) (save-restriction (narrow-to-region (save-excursion (org-back-to-heading t) (point)) (save-excursion (outline-next-heading) (point))) ad-do-it))