emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Phil Hudson <phil.hudson@iname.com>
To: emacs-orgmode@gnu.org
Subject: History list for %^{...} in capture
Date: Fri, 20 May 2016 17:11:55 +0100	[thread overview]
Message-ID: <8760u86a1s.fsf@quiz.hudson-it.ddns.net> (raw)

Arising from a discussion here a couple of weeks ago, I'm thinking about
how best to add a history list to org-capture's current
%^{prompt|default|choice2|...|choiceN} escape syntax. Here's my thinking
so far.

%^{prompt|'histList}
%^{prompt|default|'histList}
%^{prompt|default|choiceToPrepend|...|'histList|choiceToAppend|...}

Note the quote distinguishing the variable name.

Effectively the third example means: merge choices "default" and
"choiceTo*" into 'histList, prepending or appending each choice (if it
is not already an element of `histList') according to whether it occurs
before or after 'histList. Usually we would not expect prepending and
appending, just the prompt, default and history list as in the second
example. However, this form might be useful for pre-populating an
otherwise empty list.

I've identified the place in the code where the changes would need to be
coded, but I thought I should get your ideas before I dive in.
Effectively something similar is being done behind the scenes already
and then discarded; I would just be bringing it into the light of day
and making it persistent across calls.

WDYT? Good idea? Too complex? Too "busy"? Useful? Not useful?

-- 
Phil Hudson                   http://hudson-it.ddns.net
@UWascalWabbit                 PGP/GnuPG ID: 0x887DCA63

             reply	other threads:[~2016-05-20 16:12 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-20 16:11 Phil Hudson [this message]
2016-05-26 15:55 ` History list for %^{...} in capture Aaron Ecay
2016-05-26 21:58   ` Philip Hudson

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

  List information: https://www.orgmode.org/

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

  git send-email \
    --in-reply-to=8760u86a1s.fsf@quiz.hudson-it.ddns.net \
    --to=phil.hudson@iname.com \
    --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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).