From: Roberto Huelga <rhuelga@gmail.com>
To: Roberto Huelga <rhuelga@gmail.com>, emacs-orgmode@gnu.org
Subject: Re: Patch org-capture-set-target-location
Date: Mon, 24 Nov 2014 11:54:57 +0100 [thread overview]
Message-ID: <CAPJ+JL1W8A_9Rdjsu+NdEodYQBcrWWJAJUA1wHj+ZMDU5d-gaQ@mail.gmail.com> (raw)
In-Reply-To: <87h9xp3hra.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 1698 bytes --]
Sorry for make you lose your time.
Using the package version of 20141124 of org, the bug is present, but in
the git master, it's solved in a nicer way. By in the
org-capture-place-entry function getting out of the cond the test of
:exact-position
Package version:
(cond
((org-capture-get :exact-position)
(goto-char (org-capture-get :exact-position)))
((not target-entry-p)
Git Master version:
(and (org-capture-get :exact-position)
(goto-char (org-capture-get :exact-position)))
(cond
((not target-entry-p)
Thank you very much.
On Sun, Nov 23, 2014 at 7:15 PM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> Roberto Huelga <rhuelga@gmail.com> writes:
>
> > Patch proposal for org-capture-set-target-location
>
> Thanks for the patch.
>
> > The idea is that when somebody use the function or file+function targets
> > you can make the template subheading from the heading where the
> > custom-function set the point.
> > org-capture-set-target-loction force the org-capture-plist
> :exact-position
> > to (point).
> > So the template is inserted in the same level not as subheading
> >
> > With my patch the custom-function can (org-capture-put :exact-position
> > nil), and now if point its placed in a heading the template is created as
> > his subheading.
>
> AFAIU, :exact-position is an internal property (it isn't documented in
> (info "(org) Template elements"). You are not expected to set it
> directly.
>
> After a cursory look into "org-capture.el", if (point) is on a headline,
> the template should create a subheading (see `org-capture-place-entry').
> Can't you use that instead?
>
>
> Regards,
>
> --
> Nicolas Goaziou
>
[-- Attachment #2: Type: text/html, Size: 2964 bytes --]
prev parent reply other threads:[~2014-11-24 10:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-22 19:51 Patch org-capture-set-target-location Roberto Huelga
2014-11-23 18:15 ` Nicolas Goaziou
2014-11-24 10:54 ` Roberto Huelga [this message]
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=CAPJ+JL1W8A_9Rdjsu+NdEodYQBcrWWJAJUA1wHj+ZMDU5d-gaQ@mail.gmail.com \
--to=rhuelga@gmail.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).