From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: tagging during creation Date: Sun, 4 Nov 2007 08:22:24 +0100 Message-ID: <630A9B9D-9387-45C0-8E0A-82EF38D733D8@science.uva.nl> References: <87ir4nl6rq.fsf@bzg.ath.cx> <87k5p3jotp.fsf@bzg.ath.cx> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IoZoP-0001Tn-9O for emacs-orgmode@gnu.org; Sun, 04 Nov 2007 02:22:25 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IoZoO-0001Si-QX for emacs-orgmode@gnu.org; Sun, 04 Nov 2007 02:22:24 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IoZoO-0001SP-96 for emacs-orgmode@gnu.org; Sun, 04 Nov 2007 02:22:24 -0500 Received: from mx20.gnu.org ([199.232.41.8]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IoZoN-00078F-Jh for emacs-orgmode@gnu.org; Sun, 04 Nov 2007 02:22:23 -0500 Received: from ug-out-1314.google.com ([66.249.92.170]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IoZoM-0005Y1-Ta for emacs-orgmode@gnu.org; Sun, 04 Nov 2007 02:22:23 -0500 Received: by ug-out-1314.google.com with SMTP id a2so866477ugf for ; Sun, 04 Nov 2007 00:22:22 -0700 (PDT) In-Reply-To: <87k5p3jotp.fsf@bzg.ath.cx> 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: Bastien Cc: emacs-orgmode@gnu.org On 31Oct2007, at 4:17 PM, Bastien wrote: > Richard G Riley writes: > >>> (define-key org-mode-map "\C-cc" 'org-set-tags) >>> >>> HTH, >> >> And how to do with the proper tags interface showing "tab for >> free" etc >> so I can see the existing tags to choose from ? e.g as you >> currently get >> when you hit C-c C-c C-c in an org file. > > `org-set-tags' won't use the fast selection interface unless it knows > about a pre-defined set of available tags. Since you cannot set this > directly in the org-remember buffer, you need to use `org-tag-alist' > > See the manual (info "(org)Setting tags"): > > (setq org-tag-alist '(("@WORK" . ?w) ("@HOME" . ?h) ("Laptop" . ? > l))) > > I had to make a patch to get this working with Org 5.13h, otherwise > Org > would just reinitialize `org-tag-alist' each time org-mode is run, > i.e. > each time a new Org buffer is open - including the remember buffer and > regardless of the fact that `org-tag-alist' has been globally defined. > > Please try it and give me feedback. Thanks, > > diff -u /home/guerry/elisp/testing/org/org.el /home/guerry/elisp/ > testing/bzg/org.el > --- /home/guerry/elisp/testing/org/org.el 2007-10-31 > 15:05:32.000000000 +0000 > +++ /home/guerry/elisp/testing/bzg/org.el 2007-10-31 > 15:05:44.000000000 +0000 > @@ -4173,7 +4173,7 @@ > (string-to-char (match-string 2 e))) > tgs)) > (t (push (list e) tgs)))) > - (org-set-local 'org-tag-alist nil) > + (org-set-local 'org-tag-alist org-tag-alist) > (while (setq e (pop tgs)) > (or (and (stringp (car e)) > (assoc (car e) org-tag-alist)) I don't think this patch is correct. This code is only executed when there is a #+TAGS line in the buffer, and then it needs to be executed, to overrule the global settings. If there is no #+TAGS line, the global value will be used. What exactly are you trying to fix with this patch? - Carsten