[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] fetching the description from a link string
From: |
Rasmus |
Subject: |
Re: [O] fetching the description from a link string |
Date: |
Mon, 16 Nov 2015 10:45:41 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
Alan Schmitt <address@hidden> writes:
> Hello,
>
> I cannot seem to find in org.el a function that will return the
> description part of a link. I'm probably missing it … Could someone tell
> me if such a function exists?
org-element-context on a link will give you what you want. It lives in
org-element, though.
Something like this when point is on a link,
(let ((e (org-element-context)))
(buffer-substring-no-properties
(org-element-property :contents-begin e)
(org-element-property :contents-end e)))
Hope it helps,
Rasmus
--
Sådan en god dansk lagereddike kan man slet ikke bruge mere