unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH (draft) 0/2] Allow emacs to toggle display of all parts including multipart
@ 2012-10-25  8:09 Mark Walters
  2012-10-25  8:09 ` [PATCH (draft) 1/2] emacs: allow the user to toggle the visibility of multipart/alternative parts Mark Walters
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Mark Walters @ 2012-10-25  8:09 UTC (permalink / raw)
  To: notmuch

This patch series adds a function to toggle the display of any emacs
part in the show buffer. This is particularly useful for
multipart/alternative where the parts have different information.

The first patch binds this toggle to 't' on the part button. This
patch works by itself.

The second patch makes it that "viewing" (ie v on the part-button) a
"not shown" part displays the part in the buffer. Note this is not a
toggle since having displayed the part in the buffer the user may wish
to view the part externally (eg if it is a text/html part).

Caveats: 
	 the patches work by reloading the whole buffer: this may mean
	 extra messages appear in the thread. This is not ideal but is
	 the same as toggling indentation etc.

	 the reload saves state as normal but this means the view
	 returns to the top of the current message. Since we know
	 exactly where the user was (ie on the button) this should be
	 restored.

	 for technical reasons the "view" part functionality in the
	 second patch only works for view called explicitly: not if
	 the user has customised the default action to be view and
	 calls that. This is easy to fix but the most natural way
	 would break existing customisation of this action.

	 reloading the buffer without keeping state does not currently
	 reset the toggled parts. Again this is easy to fix but lets
	 see if people like the general approach first.

Best wishes

Mark


Mark Walters (2):
  emacs: allow the user to toggle the visibility of
    multipart/alternative parts
  emacs: show: make "view part" show hidden parts

 emacs/notmuch-show.el |   53 ++++++++++++++++++++++++++++++++++++++++--------
 1 files changed, 44 insertions(+), 9 deletions(-)

-- 
1.7.9.1

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-12-03 17:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-25  8:09 [PATCH (draft) 0/2] Allow emacs to toggle display of all parts including multipart Mark Walters
2012-10-25  8:09 ` [PATCH (draft) 1/2] emacs: allow the user to toggle the visibility of multipart/alternative parts Mark Walters
2012-10-28  0:08   ` Ethan Glasser-Camp
2012-10-28  8:00     ` Mark Walters
2012-10-25  8:09 ` [PATCH (draft) 2/2] emacs: show: make "view part" show hidden parts Mark Walters
2012-12-02 19:48 ` [PATCH (draft) 0/2] Allow emacs to toggle display of all parts including multipart Jani Nikula
2012-12-03 17:15   ` Jameson Graef Rollins

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).