Skip to content

Commit db7fa25

Browse files
author
Stephen Gildea
committed
Update documentation for mh-show-mode-hook
* lisp/mh-e/mh-e.el, doc/misc/mh-e.texi (mh-show-mode-hook): Now that the fix for MH-E bug #470 calls mh-show-mode-hook earlier, update the documentation to no longer say that the message contents are available.
1 parent d10be6b commit db7fa25

File tree

4 files changed

+17
-8
lines changed

4 files changed

+17
-8
lines changed

doc/misc/mh-e.texi

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2256,10 +2256,10 @@ signature block is more to your liking.
22562256
Two hooks can be used to control how messages are displayed. The first
22572257
hook, @code{mh-show-mode-hook}, is called early on in the process of
22582258
the message display. It is usually used to perform some action on the
2259-
message's content. The second hook, @code{mh-show-hook}, is the last
2259+
message's buffer. The second hook, @code{mh-show-hook}, is the last
22602260
thing called after messages are displayed. It's used to affect the
2261-
behavior of MH-E in general or when @code{mh-show-mode-hook} is too
2262-
early.
2261+
message's content, the behavior of MH-E in general, or when
2262+
@code{mh-show-mode-hook} is too early.
22632263

22642264
@cindex MH-Show mode
22652265
@cindex modes, MH-Show

etc/NEWS

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2630,6 +2630,14 @@ will be chosen even if you have an entry for "image/*" in your
26302630
overrides all system and Emacs-provided defaults. To get the old
26312631
method back, set 'mailcap-prefer-mailcap-viewers' to nil.
26322632

2633+
** MH-E
2634+
+++
2635+
*** The hook 'mh-show-mode-hook' is now called before the message is inserted.
2636+
Functions that want to affect the message text (for example, to change
2637+
highlighting) can no longer use 'mh-show-mode-hook', because the
2638+
message contents will not yet have been inserted when the hook is
2639+
called. Such functions should now be attached to 'mh-show-hook'.
2640+
26332641
** URL
26342642

26352643
---

lisp/mh-e/mh-e.el

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3380,13 +3380,14 @@ used to affect the behavior of MH-E in general or when
33803380
(defcustom-mh mh-show-mode-hook nil
33813381
"Hook run upon entry to `mh-show-mode'.
33823382
3383-
This hook is called early on in the process of the message
3384-
display. It is usually used to perform some action on the
3385-
message's content. See `mh-show-hook'."
3383+
This hook is called early on in the process of the message display,
3384+
before the message contents have been inserted into the buffer.
3385+
It is usually used to perform some action on the
3386+
buffer itself. See also `mh-show-hook'."
33863387
:type 'hook
33873388
:group 'mh-hooks
33883389
:group 'mh-show
3389-
:package-version '(MH-E . "6.0"))
3390+
:package-version '(MH-E . "8.7"))
33903391

33913392
(defcustom-mh mh-unseen-updated-hook nil
33923393
"Hook run after the unseen sequence has been updated.

lisp/mh-e/mh-show.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ you wish to see all of them, use the command \\[mh-header-display].
6363
Two hooks can be used to control how messages are displayed. The
6464
first hook, `mh-show-mode-hook', is called early on in the
6565
process of the message display. It is usually used to perform
66-
some action on the message's content. The second hook,
66+
some action on the message's buffer. The second hook,
6767
`mh-show-hook', is the last thing called after messages are
6868
displayed. It's used to affect the behavior of MH-E in general or
6969
when `mh-show-mode-hook' is too early.

0 commit comments

Comments
 (0)