all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@gmail.com>
To: Christian Heinrich <com-orgmode-mailinglist@gladbachcity.de>
Cc: emacs-orgmode@gnu.org
Subject: Re: org-capture and fast selection of tags
Date: Sun, 17 Jul 2022 18:14:36 +0800	[thread overview]
Message-ID: <8735f082r7.fsf@localhost> (raw)
In-Reply-To: <e5fe96a6ebfbd47fb55bc9969cf729ed49557953.camel@gladbachcity.de>

Christian Heinrich <com-orgmode-mailinglist@gladbachcity.de> writes:

> thanks for your feedback. I attached a patch, but I'm not sure why you said "all but the last line".
> That last line for me was (org-set-tags tags), which proved important as otherwise the tags were not
> set in the buffer.

By "all but last line" I implied that the part that reads the tags
should be factored out. That part should not modify the tags in file,
just read the tags using the preferred interface and return the selected
tag list. This return value can be used in org-set-tags-command to be
passed to org-set-tags. For org-capture the return value can be used to
insert the tags in place of %^g (rather than putting the tags under
headline unconditionally).

Now, after examining the code of org-set-tags-command more closely, I
found out that org-fast-tag-selection is actually tricky to use as I
described above. org-fast-tag-selection itself is changing the headline
tags even before the user finishes the selection process. So, an
appropriate patch would also need to alter org-fast-tag-selection in
such a way that it could be called without side effects (changing buffer
text) - it can be done by providing a new optional argument to
org-fast-tag-selection.

Best,
Ihor


  reply	other threads:[~2022-07-17 10:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-26  9:32 org-capture and fast selection of tags Christian Heinrich
2022-07-11  2:02 ` Ihor Radchenko
2022-07-14 10:12   ` Christian Heinrich
2022-07-16  9:12     ` Ihor Radchenko
2022-07-16 15:03       ` Christian Heinrich
2022-07-17 10:14         ` Ihor Radchenko [this message]
2022-08-23  2:17           ` Ihor Radchenko
2022-09-28 18:40             ` Christian Heinrich
2022-09-29  3:57               ` Ihor Radchenko
2023-04-02 10:21                 ` Ihor Radchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8735f082r7.fsf@localhost \
    --to=yantar92@gmail.com \
    --cc=com-orgmode-mailinglist@gladbachcity.de \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.