From: David Bremner <david@tethera.net>
To: notmuch@notmuchmail.org
Subject: [PATCH v2 1/4] emacs: save undisplayer function for MIME parts
Date: Sun, 24 Sep 2023 06:51:49 -0300 [thread overview]
Message-ID: <20230924095152.1394168-2-david@tethera.net> (raw)
In-Reply-To: <20230924095152.1394168-1-david@tethera.net>
For some kinds of MIME parts (at least images), our trickery with
overlays will not work, so save the more drastic function created by
Gnus that actually deletes the part from the buffer. In an ideal world
we would return this function as (part of) a value, but here the call
stack is too complicated for anything that simple, so we stash it in
the part plist and rely on that being preserved (unlike the mm handle,
which is transient).
---
emacs/notmuch-lib.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el
index 84ba8c5e..a09f4ab8 100644
--- a/emacs/notmuch-lib.el
+++ b/emacs/notmuch-lib.el
@@ -703,6 +703,7 @@ current buffer, if possible."
(when (mm-inlinable-p handle)
(set-buffer display-buffer)
(mm-display-part handle)
+ (plist-put part :undisplayer (mm-handle-undisplayer handle))
t))))))
;;; Generic Utilities
--
2.40.1
next prev parent reply other threads:[~2023-09-24 9:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-24 9:51 v2 Image toggle fixes for emacs 29.1 David Bremner
2023-09-24 9:51 ` David Bremner [this message]
2023-09-24 9:51 ` [PATCH v2 2/4] emacs/show: save redisplay redisplay data when showing lazy part David Bremner
2023-09-24 9:51 ` [PATCH v2 3/4] emacs: save image redisplay data during non-lazy display David Bremner
2023-09-24 9:51 ` [PATCH v2 4/4] emacs/show: special case toggling display of images David Bremner
2023-10-01 11:13 ` v2 Image toggle fixes for emacs 29.1 David Bremner
2023-10-01 13:39 ` Michael J Gruber
2023-10-01 19:08 ` David Bremner
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://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230924095152.1394168-2-david@tethera.net \
--to=david@tethera.net \
--cc=notmuch@notmuchmail.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://yhetil.org/notmuch.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).