From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: Speed commands (was: Release 6.33) Date: Fri, 20 Nov 2009 17:09:36 +0000 Message-ID: <87lji16s33.wl%ucecesf@ucl.ac.uk> References: <87aayqfh8a.wl%ucecesf@ucl.ac.uk> <8D1991FE-E04A-41DF-8919-C72E4EA9AFF1@uva.nl> <4AFDB0AB.9040607@cs.tu-berlin.de> <78C217F4-D3EA-46BA-A237-CA0E54216D5E@uva.nl> <20091120143546.GA1227@taupan.ath.cx> <95E34029-6EF2-4E77-B303-37676E5FA79F@gmail.com> Reply-To: e.fraga@ucl.ac.uk Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NBWzt-0005u3-Il for emacs-orgmode@gnu.org; Fri, 20 Nov 2009 12:10:13 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NBWzo-0005n9-KC for emacs-orgmode@gnu.org; Fri, 20 Nov 2009 12:10:12 -0500 Received: from [199.232.76.173] (port=33146 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NBWzo-0005mj-1M for emacs-orgmode@gnu.org; Fri, 20 Nov 2009 12:10:08 -0500 Received: from vscane-c.ucl.ac.uk ([144.82.108.43]:41645) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NBWzl-0001eb-QX for emacs-orgmode@gnu.org; Fri, 20 Nov 2009 12:10:06 -0500 In-Reply-To: <95E34029-6EF2-4E77-B303-37676E5FA79F@gmail.com> 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: Carsten Dominik Cc: emacs-orgmode@gnu.org At Fri, 20 Nov 2009 15:57:09 +0100, Carsten Dominik wrote: > This is nice, but I guess you want to stay in fast-key space. > So > > ("," . (progn (org-cycle-agenda-files) > (or (and (bolp) (org-on-heading-p)) > (outline-next-visible-heading 1)))) This is really nice and works like a charm... *except* in a very extreme case: one of my agenda files is typically empty other than a single top level heading. When I cycle through the agenda files, when I land in this file, I am typically placed at the end of the file (emacs remembers my last location). When this happens, speed keys are no longer active and, before I know it, I have a number of ',' added to the end of this file! Actually, I guess this problem generalises so that it would appear whenever the cycling takes you to a file where the current point is at the end (or near the end) of the file so there is actually no "next" heading? Maybe the or statement above needs another clause (which I unfortunately cannot suggest; sorry!).