From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: org-map-entries moves point Date: Thu, 06 Feb 2014 00:30:03 +0100 Message-ID: <87zjm59lz8.fsf@bzg.ath.cx> References: <52F295B1.6090806@miszellen.de> <87mwi5uvh2.fsf@alphaville.bos.redhat.com> <52F2B6F1.6040102@miszellen.de> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:59133) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WBBv3-0004NI-Hv for emacs-orgmode@gnu.org; Wed, 05 Feb 2014 18:30:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WBBuy-0006ar-5s for emacs-orgmode@gnu.org; Wed, 05 Feb 2014 18:30:13 -0500 Received: from rs249.mailgun.us ([209.61.151.249]:45242) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WBBux-0006XA-VD for emacs-orgmode@gnu.org; Wed, 05 Feb 2014 18:30:08 -0500 In-Reply-To: <52F2B6F1.6040102@miszellen.de> (Florian Beck's message of "Wed, 05 Feb 2014 23:10:57 +0100") 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: Florian Beck Cc: Nick Dokos , emacs-orgmode@gnu.org Hi Florian, Florian Beck writes: > Missed that. But this reverts commit > 3ec38f5c064c3270f54876ba33c5ca1097b46853 [1] (in org-map-entries) > > I was talking about > fe3379bda6ca23474639b114592958bf14431c88 [2] (which did the same to > org-agenda-prepare-buffer) > > In fact, the revert *caused* my bug. Again, the recipe: > > The bug doesn't really move the point, rather it recenters the current > line. To see it, move into the middle of a document, unfold a second > level headline and in the middle of the window execute > > (org-map-entries (lambda () > ;; do something or even nothing > ) nil 'tree) > > This works correctly if either commit [1] is restored or [2] is > reverted. I partially revert [2] (only replacing `save-window-excursion' by `save-excursion') and didn't touch [1] -- if we can produce a bug from there, let's fix it the right way this time. Thanks in advance for digging further, -- Bastien