From: Mark Meyer <mark@ofosos.org>
To: emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Searching for a headline
Date: Sun, 26 Feb 2017 14:41:35 +0100 [thread overview]
Message-ID: <fb9a22fd-3cd4-5648-2337-866d9934038b@ofosos.org> (raw)
Hi,
I'm using org-publish-external-link to look up a the link target for a
headline. The following code works, although I'd expect it to fail:
(org-publish-resolve-external-link
(concat "* " (org-element-property :raw-value headline))
source-file)
``headline'' is a headline as returned by org-element, while
``source-file'' is a ``.org'' file.
I'd expect that this needs to be
(org-publish-resolve-external-link
(concat (make-string (org-element-property :level headline) ?*)
" " (org-element-property :raw-value headline))
source-file)
I.e. for a level 3 headline it should be ``*** foobar'' and not ``*
foobar''. ``org-publish-resolve-external-link'' uses
``org-export-string-to-search-cell'' internally.
Can someone point me to some docuentation on how the searching works?
Cheers, Mark
--
Mark Meyer
mark@ofosos.org
next reply other threads:[~2017-02-26 13:41 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-26 13:41 Mark Meyer [this message]
2017-02-26 15:27 ` Searching for a headline Nicolas Goaziou
2017-02-26 16:11 ` Mark Meyer
2017-02-26 16:39 ` Nicolas Goaziou
2017-02-26 16:58 ` Mark Meyer
2017-02-26 17:28 ` Nicolas Goaziou
2017-02-26 17:54 ` Mark Meyer
2017-02-26 18:12 ` Nicolas Goaziou
2017-02-26 18:21 ` Mark Meyer
2017-02-26 18:28 ` Nicolas Goaziou
2017-02-26 18:30 ` Mark Meyer
2017-02-26 21:46 ` Mark Meyer
2017-02-26 19:32 ` Eric Abrahamsen
2017-02-26 20:40 ` Mark Meyer
2017-02-26 21:34 ` Eric Abrahamsen
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=fb9a22fd-3cd4-5648-2337-866d9934038b@ofosos.org \
--to=mark@ofosos.org \
--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).