aboutsummaryrefslogtreecommitdiff
path: root/lisp/mastodon-media.el
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus@riseup.net>2024-03-05 18:45:32 +0100
committermarty hiatt <martianhiatus@riseup.net>2024-03-05 18:45:32 +0100
commit0dc21c9c3ed39b489e9220864fa47a1f9daade6a (patch)
tree09aa3e15d6512c51ffd260c06a8cb745fe1d49a3 /lisp/mastodon-media.el
parent6ad2af2d9b5ea4fb0fdf7efd1a781f660bbda842 (diff)
optional full-size image in emacs, RET as fallback for browse-url too
Diffstat (limited to 'lisp/mastodon-media.el')
-rw-r--r--lisp/mastodon-media.el9
1 files changed, 7 insertions, 2 deletions
diff --git a/lisp/mastodon-media.el b/lisp/mastodon-media.el
index 9014add..ff40633 100644
--- a/lisp/mastodon-media.el
+++ b/lisp/mastodon-media.el
@@ -205,8 +205,13 @@ IMAGE-OPTIONS are the precomputed options to apply to the image."
(erase-buffer)
(insert " ")
(when image
- (put-text-property (point-min) (point-max)
- 'display image)
+ (add-text-properties (point-min) (point-max)
+ `( display ,image
+ keymap ,(if (boundp 'shr-image-map)
+ shr-image-map
+ shr-map)
+ image-url ,url
+ shr-url ,url))
(image-mode)
(goto-char (point-min))
(switch-to-buffer-other-window (current-buffer))))))))