From d90c104299636f2525f8b77001b4374e5b0df72a Mon Sep 17 00:00:00 2001 From: mousebot Date: Mon, 28 Feb 2022 15:21:40 +0100 Subject: add copy-toot-text function --- lisp/mastodon-toot.el | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lisp') diff --git a/lisp/mastodon-toot.el b/lisp/mastodon-toot.el index 48e7d96..1d80e55 100644 --- a/lisp/mastodon-toot.el +++ b/lisp/mastodon-toot.el @@ -271,6 +271,13 @@ Makes a POST request to the server." (kill-new url) (message "Toot URL copied to the clipboard."))) +(defun mastodon-toot--copy-toot-text () + "Copy text of toot at point." + (interactive) + (let* ((toot (mastodon-tl--property 'toot-json))) + (kill-new (mastodon-tl--content toot)) + (message "Toot content copied to the clipboard."))) + (defun mastodon-toot--own-toot-p (toot) "Check if TOOT is user's own, e.g. for deleting it." (and (not (alist-get 'reblog toot)) -- cgit v1.2.3