From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: org-set-tag-hook Date: Thu, 13 Sep 2007 08:32:36 +0200 Message-ID: <169e13d372f7da07e56b64ca000366e6@science.uva.nl> References: Mime-Version: 1.0 (Apple Message framework v624) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IViFi-0004UU-NG for emacs-orgmode@gnu.org; Thu, 13 Sep 2007 02:32:38 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IViFh-0004Tb-VZ for emacs-orgmode@gnu.org; Thu, 13 Sep 2007 02:32:38 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IViFh-0004TN-Rc for emacs-orgmode@gnu.org; Thu, 13 Sep 2007 02:32:37 -0400 Received: from korteweg.uva.nl ([146.50.98.70]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IViFh-0002lm-Ib for emacs-orgmode@gnu.org; Thu, 13 Sep 2007 02:32:37 -0400 In-Reply-To: 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: Austin Frank Cc: emacs-orgmode@gnu.org On Sep 11, 2007, at 1:43, Austin Frank wrote: > Hello! > > I am wondering whether it would be possible to introduce a new hook > into > org-mode. This hook would be run after any tags are added to an entry. > The main use would be to check for the presence of some tag among the > entry's tags, and execute some function in response to it. The next version will have `org-after-tags-change-hook'. It will be called whenever the tags in an entry change, with the cursor *somewhere* on that line. To get a list of the tags in the current line, use (only in 5.09, right now this does not work correctly) (org-get-tags) To get the list including inherited tags, use (org-get-tags-at (point)) - Carsten -- Carsten Dominik Sterrenkundig Instituut "Anton Pannekoek" Universiteit van Amsterdam Kruislaan 403 NL-1098SJ Amsterdam phone: +31 20 525 7477