[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote 917645b0ec: Make denote--get-link-file-path-at-p
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote 917645b0ec: Make denote--get-link-file-path-at-point accept optional POINT |
Date: |
Wed, 31 Jul 2024 06:57:44 -0400 (EDT) |
branch: externals/denote
commit 917645b0ec6513b09bb95c665e61f16ace6a8b23
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>
Make denote--get-link-file-path-at-point accept optional POINT
---
denote.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/denote.el b/denote.el
index 1d9781cf46..495690dfa3 100644
--- a/denote.el
+++ b/denote.el
@@ -4220,8 +4220,11 @@ Implementation based on the function
`org-activate-links'."
(defun denote--get-link-file-path-at-point ()
"Return link to the Denote file path at point.
+(defun denote--get-link-file-path-at-point (&optional point)
+ "Return link to the Denote file path at point or optional POINT.
To be used as a `thing-at' provider."
- (when-let (id (get-text-property (point) 'denote-link-id))
+ (when-let ((position (or point (point)))
+ (id (get-text-property position 'denote-link-id)))
(concat "file:" (denote-get-path-by-id id))))
(defvar thing-at-point-provider-alist)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/denote 917645b0ec: Make denote--get-link-file-path-at-point accept optional POINT,
ELPA Syncer <=