diff options
| author | Bill Wohler | 2005-12-02 05:54:33 +0000 |
|---|---|---|
| committer | Bill Wohler | 2005-12-02 05:54:33 +0000 |
| commit | 553fb7353b8ff4a44d28521f0f39f66d1e89a65b (patch) | |
| tree | d3dc3cfa5068d723b011f0d3698aa91868e1c055 | |
| parent | 1a18223ec4b5a7f8fc8cbaa88bf2aa9457bf6d9f (diff) | |
| download | emacs-553fb7353b8ff4a44d28521f0f39f66d1e89a65b.tar.gz emacs-553fb7353b8ff4a44d28521f0f39f66d1e89a65b.zip | |
* mh-comp.el (mh-letter-mode): Use mh-highlight-citation-style instead
of mh-highlight-citation-p.
(mh-letter-toggle-header-field-display): "Ellipsed" isn't a word, I
think, so use "truncated".
* mh-customize.el (mh-folder, mh-folder-faces): Group's manual section
is Folders, not Organizing. Parent of mh-folder-faces is mh-folder,
not mh-show.
(mh-speed): Rename to mh-speedbar for consistency with mh-toolbar.
(mh-thread): New group that corresponds with manual's Threading
chapter.
(mh-letter-faces): Group's manual section is Editing Drafts, not
Sending Mail.
(mh-sortm-args): New customization variable that used to be a defvar.
(mh-index-new-messages-folders, mh-index-ticked-messages-folders):
Move from mh-index group to mh-folders group.
(mh-alias-local-users-prefix, mh-large-folder)
(mh-recursive-folders-flag, mh-before-quit-hook)
(mh-folder-mode-hook, mh-kill-folder-suppress-prompt-hook)
(mh-quit-hook, mh-refile-msg-hook): Move from mh-show group to
mh-folder group.
(mh-highlight-citation-style): Rename from mh-highlight-citation-p.
Sync docstrings with manual.
(mh-mhl-format-file): Rename from mhl-formfile. Sync docstrings with
manual.
(mh-show-threads-flag): Move from mh-show group to mh-thread group.
(mh-find-path-hook): Move from mh-show group to mh-e group.
(mh-folder-updated-hook): Add to mh-folder group.
(mh-forward-hook): Move from mh-folder to mh-sending-mail group.
(mh-unseen-updated-hook): Move from mh-show to mh-sequences group.
(mh-bury-show-buffer-flag, mh-clean-message-header-flag)
(mh-decode-mime-flag, mh-display-buttons-for-alternatives-flag)
(mh-display-buttons-for-inline-parts-flag)
(mh-do-not-confirm-flag, mh-fetch-x-image-url)
(mh-graphical-smileys-flag, mh-graphical-emphasis-flag)
(mh-invisible-header-fields-default, mh-invisible-header-fields)
(mh-lpr-command-format, mh-max-inline-image-height)
(mh-max-inline-image-width)
(mh-mime-save-parts-default-directory, mh-print-background-flag)
(mh-show-maximum-size, mh-show-use-goto-addr-flag)
(mh-show-use-xface-flag, mh-store-default-directory)
(mh-summary-height, mh-delete-msg-hook
(mh-show-hook, mh-show-mode-hook): Sync docstrings with manual.
* mh-e.el (mh-scan-format-mh, mh-scan-good-msg-regexp)
(mh-scan-deleted-msg-regexp, mh-scan-refiled-msg-regexp)
(mh-scan-cur-msg-number-regexp, mh-scan-subject-regexp): Use
non-fontification instead of non-fontifying.
(mh-header-display): Use mh-mhl-format-file instead of mhl-formfile.
Sync docstrings with manual.
(mh-next-undeleted-msg, mh-previous-undeleted-msg): Rename arg to
count. Sync docstrings with manual.
(mh-refile-or-write-again): Use output from mh-write-msg-to-file so
that message doesn't change when using this command. Sync docstrings
with manual.
(mh-page-msg, mh-previous-page): Rename arg to lines. Sync docstrings
with manual.
(mh-write-msg-to-file): Rename msg to message. Rename no-headers to
no-header. Sync docstrings with manual.
(mh-ps-print-map): Delete keybindings for deleted commands
mh-ps-print-toggle-mime and mh-ps-print-msg-show.
(mh-help-messages): Updated printing help.
(mh-delete-msg, mh-delete-msg-no-motion, mh-first-msg)
(mh-last-msg, mh-previous-unread-msg, mh-next-button)
(mh-prev-button, mh-folder-toggle-mime-part)
(mh-folder-inline-mime-part, mh-folder-save-mime-part)
(mh-next-unread-msg, mh-toggle-mime-buttons): Sync docstrings with
manual.
* mh-funcs.el (mh-sortm-args): Now a customization option and in
mh-customize.el.
(mh-pipe-msg): Rename include-headers to include-header. Sync
docstrings with manual.
(mh-burst-digest, mh-page-digest, mh-page-digest-backwards)
(mh-store-msg): Sync docstrings with manual.
* mh-mime.el (mh-mime-save-parts): Rename arg to prompt. Sync
docstrings with manual.
(mh-toggle-mh-decode-mime-flag): Use English in message, not Lisp.
Sync docstrings with manual.
(mh-mm-display-part, mh-mm-inline-message): Use
mh-highlight-citation-style instead of mh-highlight-citation-p.
(mh-press-button): Sync docstrings with manual.
(mh-display-with-external-viewer): Fix default output in minibuffer.
Sync docstrings with manual.
* mh-print.el: (mh-ps-print-mime, mh-ps-print-toggle-mime): Deleted.
(mh-ps-print-color-option): Incorporate docstring from
ps-print-color-p.
(mh-ps-spool-buffer): Remove unused code. Fix indent. Slimline
docstring.
(mh-ps-spool-msg): Slimline docstring. Rename from mh-ps-spool-a-msg.
Rewrote to use existing show buffer when available.
(mh-ps-print-range): Extract method from common code in
mh-ps-print-msg and mh-ps-print-msg-file.
(mh-ps-print-preprint): Clean docstring. Use filename "mh-%s".
(mh-ps-print-msg-show): Delete. Can use either mh-ps-print-msg-show or
mh-ps-print-msg-show to same effect with new code in mh-ps-spool-msg.
(mh-print-msg): Use mh-mhl-format-file instead of mhl-formfile. Sync
docstrings with manual.
(mh-ps-print-msg, mh-ps-print-msg-file)
(mh-ps-print-toggle-faces, mh-ps-print-toggle-color): Sync docstrings
with manual.
* mh-utils.el (mh-show-ps-print-msg-show)
(mh-show-ps-print-toggle-mime): Delete.
(mh-show-ps-print-map): Updated accordingly.
(mh-show-mode): Use mh-highlight-citation-style instead of
mh-highlight-citation-p.
(mh-show-xface, mh-display-msg): Use mh-mhl-format-file instead of
mhl-formfile.
(mh-show): Use mh-mhl-format-file instead of mhl-formfile. Sync
docstrings with manual.
(mh-show-font-lock-fontify-region, mh-modify, mh-goto-msg): Sync
docstrings with manual.
| -rw-r--r-- | lisp/mh-e/ChangeLog | 135 | ||||
| -rw-r--r-- | lisp/mh-e/mh-comp.el | 6 | ||||
| -rw-r--r-- | lisp/mh-e/mh-customize.el | 515 | ||||
| -rw-r--r-- | lisp/mh-e/mh-e.el | 244 | ||||
| -rw-r--r-- | lisp/mh-e/mh-funcs.el | 54 | ||||
| -rw-r--r-- | lisp/mh-e/mh-mime.el | 57 | ||||
| -rw-r--r-- | lisp/mh-e/mh-print.el | 230 | ||||
| -rw-r--r-- | lisp/mh-e/mh-utils.el | 83 |
8 files changed, 830 insertions, 494 deletions
diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index 4898113c768..746157e6e51 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog | |||
| @@ -1,3 +1,138 @@ | |||
| 1 | 2005-12-01 Bill Wohler <wohler@newt.com> | ||
| 2 | |||
| 3 | Rewrote Reading Mail chapter in manual which affected mh-show | ||
| 4 | customization group and related functions. | ||
| 5 | |||
| 6 | * mh-comp.el (mh-letter-mode): Use mh-highlight-citation-style | ||
| 7 | instead of mh-highlight-citation-p. | ||
| 8 | (mh-letter-toggle-header-field-display): "Ellipsed" isn't a word, | ||
| 9 | I think, so use "truncated". | ||
| 10 | |||
| 11 | * mh-customize.el (mh-folder, mh-folder-faces): Group's manual | ||
| 12 | section is Folders, not Organizing. Parent of mh-folder-faces is | ||
| 13 | mh-folder, not mh-show. | ||
| 14 | (mh-speed): Rename to mh-speedbar for consistency with mh-toolbar. | ||
| 15 | (mh-thread): New group that corresponds with manual's Threading | ||
| 16 | chapter. | ||
| 17 | (mh-letter-faces): Group's manual section is Editing Drafts, not | ||
| 18 | Sending Mail. | ||
| 19 | (mh-sortm-args): New customization variable that used to be a | ||
| 20 | defvar. | ||
| 21 | (mh-index-new-messages-folders, mh-index-ticked-messages-folders): | ||
| 22 | Move from mh-index group to mh-folders group. | ||
| 23 | (mh-alias-local-users-prefix, mh-large-folder) | ||
| 24 | (mh-recursive-folders-flag, mh-before-quit-hook) | ||
| 25 | (mh-folder-mode-hook, mh-kill-folder-suppress-prompt-hook) | ||
| 26 | (mh-quit-hook, mh-refile-msg-hook): Move from mh-show group to | ||
| 27 | mh-folder group. | ||
| 28 | (mh-highlight-citation-style): Rename from | ||
| 29 | mh-highlight-citation-p. Sync docstrings with manual. | ||
| 30 | (mh-mhl-format-file): Rename from mhl-formfile. Sync docstrings | ||
| 31 | with manual. | ||
| 32 | (mh-show-threads-flag): Move from mh-show group to mh-thread | ||
| 33 | group. | ||
| 34 | (mh-find-path-hook): Move from mh-show group to mh-e group. | ||
| 35 | (mh-folder-updated-hook): Add to mh-folder group. | ||
| 36 | (mh-forward-hook): Move from mh-folder to mh-sending-mail group. | ||
| 37 | (mh-unseen-updated-hook): Move from mh-show to mh-sequences group. | ||
| 38 | (mh-bury-show-buffer-flag, mh-clean-message-header-flag) | ||
| 39 | (mh-decode-mime-flag, mh-display-buttons-for-alternatives-flag) | ||
| 40 | (mh-display-buttons-for-inline-parts-flag) | ||
| 41 | (mh-do-not-confirm-flag, mh-fetch-x-image-url) | ||
| 42 | (mh-graphical-smileys-flag, mh-graphical-emphasis-flag) | ||
| 43 | (mh-invisible-header-fields-default, mh-invisible-header-fields) | ||
| 44 | (mh-lpr-command-format, mh-max-inline-image-height) | ||
| 45 | (mh-max-inline-image-width) | ||
| 46 | (mh-mime-save-parts-default-directory, mh-print-background-flag) | ||
| 47 | (mh-show-maximum-size, mh-show-use-goto-addr-flag) | ||
| 48 | (mh-show-use-xface-flag, mh-store-default-directory) | ||
| 49 | (mh-summary-height, mh-delete-msg-hook | ||
| 50 | (mh-show-hook, mh-show-mode-hook): Sync docstrings with manual. | ||
| 51 | |||
| 52 | * mh-e.el | ||
| 53 | (mh-scan-format-mh, mh-scan-good-msg-regexp) | ||
| 54 | (mh-scan-deleted-msg-regexp, mh-scan-refiled-msg-regexp) | ||
| 55 | (mh-scan-cur-msg-number-regexp, mh-scan-subject-regexp): Use | ||
| 56 | non-fontification instead of non-fontifying. | ||
| 57 | (mh-header-display): Use mh-mhl-format-file instead of | ||
| 58 | mhl-formfile. Sync docstrings with manual. | ||
| 59 | (mh-next-undeleted-msg, mh-previous-undeleted-msg): Rename arg to | ||
| 60 | count. Sync docstrings with manual. | ||
| 61 | (mh-refile-or-write-again): Use output from mh-write-msg-to-file | ||
| 62 | so that message doesn't change when using this command. Sync | ||
| 63 | docstrings with manual. | ||
| 64 | (mh-page-msg, mh-previous-page): Rename arg to lines. Sync | ||
| 65 | docstrings with manual. | ||
| 66 | (mh-write-msg-to-file): Rename msg to message. Rename no-headers | ||
| 67 | to no-header. Sync docstrings with manual. | ||
| 68 | (mh-ps-print-map): Delete keybindings for deleted commands | ||
| 69 | mh-ps-print-toggle-mime and mh-ps-print-msg-show. | ||
| 70 | (mh-help-messages): Updated printing help. | ||
| 71 | (mh-delete-msg, mh-delete-msg-no-motion, mh-first-msg) | ||
| 72 | (mh-last-msg, mh-previous-unread-msg, mh-next-button) | ||
| 73 | (mh-prev-button, mh-folder-toggle-mime-part) | ||
| 74 | (mh-folder-inline-mime-part, mh-folder-save-mime-part) | ||
| 75 | (mh-next-unread-msg, mh-toggle-mime-buttons): Sync docstrings with | ||
| 76 | manual. | ||
| 77 | |||
| 78 | * mh-funcs.el (mh-sortm-args): Now a customization option and | ||
| 79 | in mh-customize.el. | ||
| 80 | (mh-pipe-msg): Rename include-headers to include-header. Sync | ||
| 81 | docstrings with manual. | ||
| 82 | (mh-burst-digest, mh-page-digest, mh-page-digest-backwards) | ||
| 83 | (mh-store-msg): Sync docstrings with manual. | ||
| 84 | |||
| 85 | * mh-mime.el (mh-mime-save-parts): Rename arg to prompt. Sync | ||
| 86 | docstrings with manual. | ||
| 87 | (mh-toggle-mh-decode-mime-flag): Use English in message, not Lisp. | ||
| 88 | Sync docstrings with manual. | ||
| 89 | (mh-mm-display-part, mh-mm-inline-message): Use | ||
| 90 | mh-highlight-citation-style instead of mh-highlight-citation-p. | ||
| 91 | (mh-press-button): Sync docstrings with manual. | ||
| 92 | (mh-display-with-external-viewer): Fix default output in | ||
| 93 | minibuffer. Sync docstrings with manual. | ||
| 94 | |||
| 95 | * mh-print.el: (mh-ps-print-mime, mh-ps-print-toggle-mime): | ||
| 96 | Deleted. | ||
| 97 | (mh-ps-print-color-option): Incorporate docstring from | ||
| 98 | ps-print-color-p. | ||
| 99 | (mh-ps-spool-buffer): Remove unused code. Fix indent. Slimline | ||
| 100 | docstring. | ||
| 101 | (mh-ps-spool-msg): Slimline docstring. Rename from | ||
| 102 | mh-ps-spool-a-msg. Rewrote to use existing show buffer when | ||
| 103 | available. | ||
| 104 | (mh-ps-print-range): Extract method from common code in | ||
| 105 | mh-ps-print-msg and mh-ps-print-msg-file. | ||
| 106 | (mh-ps-print-preprint): Clean docstring. Use filename "mh-%s". | ||
| 107 | (mh-ps-print-msg-show): Delete. Can use either | ||
| 108 | mh-ps-print-msg-show or mh-ps-print-msg-show to same effect with | ||
| 109 | new code in mh-ps-spool-msg. | ||
| 110 | (mh-print-msg): Use mh-mhl-format-file instead of mhl-formfile. | ||
| 111 | Sync docstrings with manual. | ||
| 112 | (mh-ps-print-msg, mh-ps-print-msg-file) | ||
| 113 | (mh-ps-print-toggle-faces, mh-ps-print-toggle-color): Sync | ||
| 114 | docstrings with manual. | ||
| 115 | |||
| 116 | * mh-utils.el (mh-show-ps-print-msg-show, | ||
| 117 | mh-show-ps-print-toggle-mime): Delete. | ||
| 118 | (mh-show-ps-print-map): Updated accordingly. | ||
| 119 | (mh-show-mode): Use mh-highlight-citation-style instead of | ||
| 120 | mh-highlight-citation-p. | ||
| 121 | (mh-show-xface, mh-display-msg): Use mh-mhl-format-file instead of | ||
| 122 | mhl-formfile. | ||
| 123 | (mh-show): Use mh-mhl-format-file instead of mhl-formfile. Sync | ||
| 124 | docstrings with manual. | ||
| 125 | (mh-show-font-lock-fontify-region, mh-modify, mh-goto-msg): Sync | ||
| 126 | docstrings with manual. | ||
| 127 | |||
| 128 | 2005-12-01 Bill Wohler <wohler@newt.com> | ||
| 129 | |||
| 130 | * mh-init.el (mh-defface-compat): Checkdoc fix. | ||
| 131 | |||
| 132 | * mh-junk.el (mh-bogofilter-blacklist, mh-bogofilter-whitelist): | ||
| 133 | Bogofilter is lowercase except at beginning of sentence and in | ||
| 134 | titles. | ||
| 135 | |||
| 1 | 2005-11-04 Bill Wohler <wohler@newt.com> | 136 | 2005-11-04 Bill Wohler <wohler@newt.com> |
| 2 | 137 | ||
| 3 | * mh-customize.el (mh-min-colors-defined-flag, mh-defface-compat): | 138 | * mh-customize.el (mh-min-colors-defined-flag, mh-defface-compat): |
diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el index 7c955cf0353..d8d8b48d74d 100644 --- a/lisp/mh-e/mh-comp.el +++ b/lisp/mh-e/mh-comp.el | |||
| @@ -1000,8 +1000,8 @@ When a message is composed, the hooks `text-mode-hook' and | |||
| 1000 | (mh-funcall-if-exists mh-toolbar-init :letter) | 1000 | (mh-funcall-if-exists mh-toolbar-init :letter) |
| 1001 | (make-local-variable 'font-lock-defaults) | 1001 | (make-local-variable 'font-lock-defaults) |
| 1002 | (cond | 1002 | (cond |
| 1003 | ((or (equal mh-highlight-citation-p 'font-lock) | 1003 | ((or (equal mh-highlight-citation-style 'font-lock) |
| 1004 | (equal mh-highlight-citation-p 'gnus)) | 1004 | (equal mh-highlight-citation-style 'gnus)) |
| 1005 | ;; Let's use font-lock even if gnus is used in show-mode. The reason | 1005 | ;; Let's use font-lock even if gnus is used in show-mode. The reason |
| 1006 | ;; is that gnus uses static text properties which are not appropriate | 1006 | ;; is that gnus uses static text properties which are not appropriate |
| 1007 | ;; for a buffer that will be edited. So the choice here is either fontify | 1007 | ;; for a buffer that will be edited. So the choice here is either fontify |
| @@ -1950,7 +1950,7 @@ except that it is callable from a mouse button." | |||
| 1950 | (defun mh-letter-toggle-header-field-display (arg) | 1950 | (defun mh-letter-toggle-header-field-display (arg) |
| 1951 | "Toggle display of header field at point. | 1951 | "Toggle display of header field at point. |
| 1952 | 1952 | ||
| 1953 | Use this command to display ellipsed header fields. This command is a toggle | 1953 | Use this command to display truncated header fields. This command is a toggle |
| 1954 | so entering it again will hide the field. This command takes a prefix argument | 1954 | so entering it again will hide the field. This command takes a prefix argument |
| 1955 | ARG: if negative then the field is hidden, if positive then the field is | 1955 | ARG: if negative then the field is hidden, if positive then the field is |
| 1956 | displayed." | 1956 | displayed." |
diff --git a/lisp/mh-e/mh-customize.el b/lisp/mh-e/mh-customize.el index 1bac400f93b..0937b7a5843 100644 --- a/lisp/mh-e/mh-customize.el +++ b/lisp/mh-e/mh-customize.el | |||
| @@ -117,7 +117,7 @@ mailutils." | |||
| 117 | (defgroup mh-folder nil | 117 | (defgroup mh-folder nil |
| 118 | "Organizing your mail with folders." | 118 | "Organizing your mail with folders." |
| 119 | :prefix "mh-" | 119 | :prefix "mh-" |
| 120 | :link '(custom-manual "(mh-e)Organizing") | 120 | :link '(custom-manual "(mh-e)Folders") |
| 121 | :group 'mh-e) | 121 | :group 'mh-e) |
| 122 | 122 | ||
| 123 | (defgroup mh-folder-selection nil | 123 | (defgroup mh-folder-selection nil |
| @@ -186,12 +186,18 @@ mailutils." | |||
| 186 | :link '(custom-manual "(mh-e)Reading Mail") | 186 | :link '(custom-manual "(mh-e)Reading Mail") |
| 187 | :group 'mh-e) | 187 | :group 'mh-e) |
| 188 | 188 | ||
| 189 | (defgroup mh-speed nil | 189 | (defgroup mh-speedbar nil |
| 190 | "The speedbar." | 190 | "The speedbar." |
| 191 | :prefix "mh-speed-" | 191 | :prefix "mh-speed-" |
| 192 | :link '(custom-manual "(mh-e)Speedbar") | 192 | :link '(custom-manual "(mh-e)Speedbar") |
| 193 | :group 'mh-e) | 193 | :group 'mh-e) |
| 194 | 194 | ||
| 195 | (defgroup mh-thread nil | ||
| 196 | "Threading." | ||
| 197 | :prefix "mh-thread-" | ||
| 198 | :link '(custom-manual "(mh-e)Threading") | ||
| 199 | :group 'mh-e) | ||
| 200 | |||
| 195 | (defgroup mh-toolbar nil | 201 | (defgroup mh-toolbar nil |
| 196 | "The toolbar" | 202 | "The toolbar" |
| 197 | :link '(custom-manual "(mh-e)Toolbar") | 203 | :link '(custom-manual "(mh-e)Toolbar") |
| @@ -215,10 +221,10 @@ mailutils." | |||
| 215 | 221 | ||
| 216 | (defgroup mh-folder-faces nil | 222 | (defgroup mh-folder-faces nil |
| 217 | "Faces used in scan listing." | 223 | "Faces used in scan listing." |
| 218 | :link '(custom-manual "(mh-e)Organizing") | 224 | :link '(custom-manual "(mh-e)Folders") |
| 219 | :prefix "mh-" | 225 | :prefix "mh-" |
| 220 | :group 'mh-faces | 226 | :group 'mh-faces |
| 221 | :group 'mh-show) | 227 | :group 'mh-folder) |
| 222 | 228 | ||
| 223 | (defgroup mh-index-faces nil | 229 | (defgroup mh-index-faces nil |
| 224 | "Faces used in searching." | 230 | "Faces used in searching." |
| @@ -229,7 +235,7 @@ mailutils." | |||
| 229 | 235 | ||
| 230 | (defgroup mh-letter-faces nil | 236 | (defgroup mh-letter-faces nil |
| 231 | "Faces used in message drafts." | 237 | "Faces used in message drafts." |
| 232 | :link '(custom-manual "(mh-e)Sending Mail") | 238 | :link '(custom-manual "(mh-e)Editing Drafts") |
| 233 | :prefix "mh-" | 239 | :prefix "mh-" |
| 234 | :group 'mh-faces | 240 | :group 'mh-faces |
| 235 | :group 'mh-letter) | 241 | :group 'mh-letter) |
| @@ -250,7 +256,7 @@ mailutils." | |||
| 250 | 256 | ||
| 251 | 257 | ||
| 252 | 258 | ||
| 253 | ;;; Emacs interface to the MH mail system (:group mh) | 259 | ;;; Emacs interface to the MH mail system (:group mh-e) |
| 254 | (eval-when (compile) | 260 | (eval-when (compile) |
| 255 | (setq mh-variant 'none)) | 261 | (setq mh-variant 'none)) |
| 256 | 262 | ||
| @@ -346,7 +352,7 @@ file. For example, use \"ypcat passwd\" to obtain the NIS password file." | |||
| 346 | :group 'mh-alias) | 352 | :group 'mh-alias) |
| 347 | 353 | ||
| 348 | (defcustom mh-alias-local-users-prefix "local." | 354 | (defcustom mh-alias-local-users-prefix "local." |
| 349 | "*String prepended to the real names of users from the password file. | 355 | "*String prefixed to the real names of users from the password file. |
| 350 | This option can also be set to `Use Login'. | 356 | This option can also be set to `Use Login'. |
| 351 | 357 | ||
| 352 | For example, consider the following password file entry: | 358 | For example, consider the following password file entry: |
| @@ -378,6 +384,39 @@ this option off." | |||
| 378 | 384 | ||
| 379 | ;;; Organizing Your Mail with Folders (:group 'mh-folder) | 385 | ;;; Organizing Your Mail with Folders (:group 'mh-folder) |
| 380 | 386 | ||
| 387 | (defcustom mh-index-new-messages-folders t | ||
| 388 | "Folders searched for the \"unseen\" sequence. | ||
| 389 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to | ||
| 390 | search all of the top level folders. Otherwise, list the folders that should | ||
| 391 | be searched with the \"Choose Folders\" menu item. | ||
| 392 | |||
| 393 | See also `mh-recursive-folders-flag'." | ||
| 394 | :type '(choice (const :tag "Inbox" t) | ||
| 395 | (const :tag "All" nil) | ||
| 396 | (repeat :tag "Choose Folders" (string :tag "Folder"))) | ||
| 397 | :group 'mh-folder) | ||
| 398 | |||
| 399 | (defcustom mh-index-ticked-messages-folders t | ||
| 400 | "Folders searched for `mh-tick-seq'. | ||
| 401 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to | ||
| 402 | search all of the top level folders. Otherwise, list the folders that should | ||
| 403 | be searched with the \"Choose Folders\" menu item. | ||
| 404 | |||
| 405 | See also `mh-recursive-folders-flag'." | ||
| 406 | :type '(choice (const :tag "Inbox" t) | ||
| 407 | (const :tag "All" nil) | ||
| 408 | (repeat :tag "Choose Folders" (string :tag "Folder"))) | ||
| 409 | :group 'mh-folder) | ||
| 410 | |||
| 411 | (defcustom mh-large-folder 200 | ||
| 412 | "The number of messages that indicates a large folder. | ||
| 413 | If a folder is deemed to be large, that is the number of messages in it exceed | ||
| 414 | this value, then confirmation is needed when it is visited. Even when | ||
| 415 | `mh-show-threads-flag' is non-nil, the folder is not automatically threaded, if | ||
| 416 | it is large. If set to nil all folders are treated as if they are small." | ||
| 417 | :type '(choice (const :tag "No Limit") integer) | ||
| 418 | :group 'mh-folder) | ||
| 419 | |||
| 381 | (defcustom mh-recenter-summary-flag nil | 420 | (defcustom mh-recenter-summary-flag nil |
| 382 | "*Non-nil means to recenter the summary window. | 421 | "*Non-nil means to recenter the summary window. |
| 383 | If this option is turned on, recenter the summary window when the show window | 422 | If this option is turned on, recenter the summary window when the show window |
| @@ -385,6 +424,20 @@ is toggled off." | |||
| 385 | :type 'boolean | 424 | :type 'boolean |
| 386 | :group 'mh-folder) | 425 | :group 'mh-folder) |
| 387 | 426 | ||
| 427 | (defcustom mh-recursive-folders-flag nil | ||
| 428 | "*Non-nil means that commands which operate on folders do so recursively." | ||
| 429 | :type 'boolean | ||
| 430 | :group 'mh-folder) | ||
| 431 | |||
| 432 | (defcustom mh-sortm-args nil | ||
| 433 | "*Extra arguments to have \\[mh-sort-folder] pass to the \"sortm\" command. | ||
| 434 | The arguments are passed to sortm if \\[mh-sort-folder] is given a | ||
| 435 | prefix argument. Normally default arguments to sortm are specified in the | ||
| 436 | MH profile. | ||
| 437 | For example, '(\"-nolimit\" \"-textfield\" \"subject\") is a useful setting." | ||
| 438 | :type 'string | ||
| 439 | :group 'mh-folder) | ||
| 440 | |||
| 388 | 441 | ||
| 389 | 442 | ||
| 390 | ;;; Folder Selection (:group 'mh-folder-selection) | 443 | ;;; Folder Selection (:group 'mh-folder-selection) |
| @@ -657,18 +710,6 @@ You can use `xbuffy' to automate the incorporation of this mail using the | |||
| 657 | 710 | ||
| 658 | ;;; Searching (:group 'mh-index) | 711 | ;;; Searching (:group 'mh-index) |
| 659 | 712 | ||
| 660 | (defcustom mh-index-new-messages-folders t | ||
| 661 | "Folders searched for the \"unseen\" sequence. | ||
| 662 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to | ||
| 663 | search all of the top level folders. Otherwise, list the folders that should | ||
| 664 | be searched with the \"Choose Folders\" menu item. | ||
| 665 | |||
| 666 | See also `mh-recursive-folders-flag'." | ||
| 667 | :group 'mh-index | ||
| 668 | :type '(choice (const :tag "Inbox" t) | ||
| 669 | (const :tag "All" nil) | ||
| 670 | (repeat :tag "Choose Folders" (string :tag "Folder")))) | ||
| 671 | |||
| 672 | (defcustom mh-index-program nil | 713 | (defcustom mh-index-program nil |
| 673 | "Indexing program that MH-E shall use. | 714 | "Indexing program that MH-E shall use. |
| 674 | The default setting of this option is `Auto-detect' which means that MH-E will | 715 | The default setting of this option is `Auto-detect' which means that MH-E will |
| @@ -687,18 +728,6 @@ found in the documentation of `mh-index-search'." | |||
| 687 | (const :tag "grep" grep)) | 728 | (const :tag "grep" grep)) |
| 688 | :group 'mh-index) | 729 | :group 'mh-index) |
| 689 | 730 | ||
| 690 | (defcustom mh-index-ticked-messages-folders t | ||
| 691 | "Folders searched for `mh-tick-seq'. | ||
| 692 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to | ||
| 693 | search all of the top level folders. Otherwise, list the folders that should | ||
| 694 | be searched with the \"Choose Folders\" menu item. | ||
| 695 | |||
| 696 | See also `mh-recursive-folders-flag'." | ||
| 697 | :group 'mh-index | ||
| 698 | :type '(choice (const :tag "Inbox" t) | ||
| 699 | (const :tag "All" nil) | ||
| 700 | (repeat :tag "Choose Folders" (string :tag "Folder")))) | ||
| 701 | |||
| 702 | 731 | ||
| 703 | 732 | ||
| 704 | ;;; Dealing with Junk Mail (:group 'mh-junk) | 733 | ;;; Dealing with Junk Mail (:group 'mh-junk) |
| @@ -747,9 +776,9 @@ that many messages at the same time, you might try turning on this option." | |||
| 747 | "Spam program that MH-E should use. | 776 | "Spam program that MH-E should use. |
| 748 | 777 | ||
| 749 | The default setting of this option is \"Auto-detect\" which means that MH-E | 778 | The default setting of this option is \"Auto-detect\" which means that MH-E |
| 750 | will automatically choose one of SpamAssassin, Bogofilter, or SpamProbe in | 779 | will automatically choose one of SpamAssassin, bogofilter, or SpamProbe in |
| 751 | that order. If, for example, you have both SpamAssassin and Bogofilter | 780 | that order. If, for example, you have both SpamAssassin and bogofilter |
| 752 | installed and you want to use BogoFilter, then you can set this option to | 781 | installed and you want to use bogofilter, then you can set this option to |
| 753 | \"Bogofilter\"." | 782 | \"Bogofilter\"." |
| 754 | :type '(choice (const :tag "Auto-detect" nil) | 783 | :type '(choice (const :tag "Auto-detect" nil) |
| 755 | (const :tag "SpamAssassin" spamassassin) | 784 | (const :tag "SpamAssassin" spamassassin) |
| @@ -1167,98 +1196,148 @@ commands." | |||
| 1167 | ;;; Reading Your Mail (:group 'mh-show) | 1196 | ;;; Reading Your Mail (:group 'mh-show) |
| 1168 | 1197 | ||
| 1169 | (defcustom mh-bury-show-buffer-flag t | 1198 | (defcustom mh-bury-show-buffer-flag t |
| 1170 | "*Non-nil means that the displayed show buffer for a folder is buried." | 1199 | "*Non-nil means show buffer is buried. |
| 1200 | |||
| 1201 | One advantage of not burying the show buffer is that one can delete the show | ||
| 1202 | buffer more easily in an electric buffer list because of its proximity to its | ||
| 1203 | associated MH-Folder buffer. Try running \\[electric-buffer-list] to see what | ||
| 1204 | I mean." | ||
| 1171 | :type 'boolean | 1205 | :type 'boolean |
| 1172 | :group 'mh-show) | 1206 | :group 'mh-show) |
| 1173 | 1207 | ||
| 1174 | (defcustom mh-clean-message-header-flag t | 1208 | (defcustom mh-clean-message-header-flag t |
| 1175 | "*Non-nil means remove extraneous header fields. | 1209 | "*Non-nil means remove extraneous header fields. |
| 1176 | The header fields listed in the `mh-invisible-header-fields-default' option | 1210 | |
| 1177 | are hidden, although you can check off any field that you would like to see. | 1211 | See also `mh-invisible-header-fields-default' and |
| 1178 | Header fields that you would like to hide that aren't listed can be added to | 1212 | `mh-invisible-header-fields'." |
| 1179 | the `mh-invisible-header-fields' option." | ||
| 1180 | :type 'boolean | 1213 | :type 'boolean |
| 1181 | :group 'mh-show) | 1214 | :group 'mh-show) |
| 1182 | 1215 | ||
| 1183 | (defcustom mh-decode-mime-flag (not (not (locate-library "mm-decode"))) | 1216 | (defcustom mh-decode-mime-flag (not (not (locate-library "mm-decode"))) |
| 1184 | "*Non-nil means that Gnus is used to show MIME attachments with Gnus." | 1217 | "*Non-nil means attachments are handled\\<mh-folder-mode-map>. |
| 1218 | |||
| 1219 | MH-E can handle attachments as well if the Gnus `mm-decode' library is | ||
| 1220 | present. If so, this option will be on. Otherwise, you'll see the MIME body | ||
| 1221 | parts rather than text or attachments. There isn't much point in turning off | ||
| 1222 | this option; however, you can inspect it if it appears that the body parts are | ||
| 1223 | not being interpreted correctly or toggle it with the command | ||
| 1224 | \\[mh-toggle-mh-decode-mime-flag] to view the raw message. | ||
| 1225 | |||
| 1226 | This option also controls the display of quoted-printable messages and other | ||
| 1227 | graphical widgets. See the options `mh-graphical-smileys-flag' and | ||
| 1228 | `mh-graphical-emphasis-flag'." | ||
| 1185 | :type 'boolean | 1229 | :type 'boolean |
| 1186 | :group 'mh-show) | 1230 | :group 'mh-show) |
| 1187 | 1231 | ||
| 1188 | (defcustom mh-display-buttons-for-alternatives-flag nil | 1232 | (defcustom mh-display-buttons-for-alternatives-flag nil |
| 1189 | "*Non-nil means display buttons for all MIME alternatives. | 1233 | "*Non-nil means display buttons for all alternative attachments. |
| 1190 | Default behavior is to display only the preferred alternative. If this | 1234 | |
| 1191 | variable is non-nil, then the preferred part is shown inline and buttons | 1235 | Sometimes, a mail program will produce multiple alternatives of the attachment |
| 1192 | are shown for each of the other alternatives." | 1236 | in increasing degree of faithfulness to the original content. By default, only |
| 1237 | the preferred alternative is displayed. If this option is on, then the | ||
| 1238 | preferred part is shown inline and buttons are shown for each of the other | ||
| 1239 | alternatives." | ||
| 1193 | :type 'boolean | 1240 | :type 'boolean |
| 1194 | :group 'mh-show) | 1241 | :group 'mh-show) |
| 1195 | 1242 | ||
| 1196 | (defcustom mh-display-buttons-for-inline-parts-flag nil | 1243 | (defcustom mh-display-buttons-for-inline-parts-flag nil |
| 1197 | "*Non-nil means display buttons for all inline MIME parts. | 1244 | "*Non-nil means display buttons for all inline attachments\\<mh-folder-mode-map>. |
| 1198 | If non-nil, buttons are displayed for all MIME parts. Inline parts start off | 1245 | |
| 1199 | in displayed state but they can be hidden by clicking the button. If nil no | 1246 | The sender can request that attachments should be viewed inline so that they |
| 1200 | buttons are shown for inline parts." | 1247 | do not really appear like an attachment at all to the reader. Most of the |
| 1248 | time, this is desirable, so by default MH-E suppresses the buttons for inline | ||
| 1249 | attachments. On the other hand, you may receive code or HTML which the sender | ||
| 1250 | has added to his message as inline attachments so that you can read them in | ||
| 1251 | MH-E. In this case, it is useful to see the buttons so that you know you don't | ||
| 1252 | have to cut and paste the code into a file; you can simply save the | ||
| 1253 | attachment. | ||
| 1254 | |||
| 1255 | If you want to make the buttons visible for inline attachments, you can use | ||
| 1256 | the command \\[mh-toggle-mime-buttons] to toggle the visibility of these | ||
| 1257 | buttons. You can turn on these buttons permanently by turning on this option. | ||
| 1258 | |||
| 1259 | MH-E cannot display all attachments inline however. It can display | ||
| 1260 | text (including HTML) and images." | ||
| 1201 | :type 'boolean | 1261 | :type 'boolean |
| 1202 | :group 'mh-show) | 1262 | :group 'mh-show) |
| 1203 | 1263 | ||
| 1204 | (defcustom mh-do-not-confirm-flag nil | 1264 | (defcustom mh-do-not-confirm-flag nil |
| 1205 | "*Non-nil means do not prompt for confirmation. | 1265 | "*Non-nil means non-reversible commands do not prompt for confirmation. |
| 1266 | |||
| 1206 | Commands such as `mh-pack-folder' prompt to confirm whether to process | 1267 | Commands such as `mh-pack-folder' prompt to confirm whether to process |
| 1207 | outstanding moves and deletes or not before continuing. A non-nil setting will | 1268 | outstanding moves and deletes or not before continuing. Turning on this option |
| 1208 | perform the action--which is usually desired but cannot be retracted--without | 1269 | means that these actions will be performed--which is usually desired but |
| 1209 | question." | 1270 | cannot be retracted--without question." |
| 1210 | :type 'boolean | 1271 | :type 'boolean |
| 1211 | :group 'mh-show) | 1272 | :group 'mh-show) |
| 1212 | 1273 | ||
| 1213 | (defcustom mh-fetch-x-image-url 'ask | 1274 | (defcustom mh-fetch-x-image-url 'ask |
| 1214 | "*Control fetching of `X-Image-URL:' header field image. | 1275 | "*Control fetching of \"X-Image-URL:\" header field image. |
| 1215 | If set to \"Always fetch\" (t), the image is always fetched. You probably want | 1276 | |
| 1216 | to avoid this setting for privacy and DOS (denial of service) reasons. For | 1277 | If set to \"Always Fetch\", the image is always fetched. You probably want to |
| 1217 | example, fetching a URL can tip off a spammer that you've read his email. | 1278 | avoid this setting for privacy and denial of service reasons. For example, |
| 1218 | Someone may also flood your network and fill your disk drive by sending a | 1279 | fetching a URL can tip off a spammer that you've read his email. Someone may |
| 1219 | torrent of messages, each specifying a unique URL to a very large file. | 1280 | also flood your network and fill your disk drive by sending a torrent of |
| 1220 | 1281 | messages, each specifying a unique URL to a very large file. | |
| 1221 | If set to \"Ask before fetching\" ('ask), you are prompted before the image is | 1282 | |
| 1222 | fetched. MH-E will remember your reply and will either use the already fetched | 1283 | If set to \"Ask Before Fetching\", you are prompted before the image is |
| 1223 | image the next time the same URL is encountered or silently skip it if you | 1284 | fetched. MH-E will remember your reply and will either use the cached image |
| 1224 | didn't fetch it the first time. This is the default. | 1285 | the next time the same URL is encountered or silently skip it if you didn't |
| 1225 | 1286 | fetch it the first time. This is the default. | |
| 1226 | If set to \"Never fetch\" (nil), images are never fetched and only displayed | 1287 | |
| 1227 | if they are already present in the cache. | 1288 | If set to \"Never Fetch\", images are never fetched and only displayed if they |
| 1228 | 1289 | are already present in the cache. | |
| 1229 | The cache of images is found in the directory `.mhe-x-image-cache' within your | 1290 | |
| 1230 | MH directory. To see how you can add your own face to the `From:' field, see | 1291 | The cache of images is found in the directory \".mhe-x-image-cache\" within |
| 1231 | `mh-x-face-file'. | 1292 | your MH directory. To see how you can add your own face to the \"From:\" |
| 1232 | 1293 | field, see the option `mh-x-face-file'. | |
| 1233 | This setting only has effect if `mh-show-use-xface-flag' is non-nil." | 1294 | |
| 1234 | 1295 | This setting only has effect if the option `mh-show-use-xface-flag' is turned | |
| 1235 | :type '(choice (const :tag "Always fetch" t) | 1296 | on." |
| 1236 | (const :tag "Ask before fetching" ask) | 1297 | |
| 1237 | (const :tag "Never fetch" nil)) | 1298 | :type '(choice (const :tag "Always Fetch" t) |
| 1299 | (const :tag "Ask Before Fetching" ask) | ||
| 1300 | (const :tag "Never Fetch" nil)) | ||
| 1238 | :group 'mh-show) | 1301 | :group 'mh-show) |
| 1239 | 1302 | ||
| 1240 | (defcustom mh-graphical-smileys-flag t | 1303 | (defcustom mh-graphical-smileys-flag t |
| 1241 | "*Non-nil means graphical smileys are displayed. | 1304 | "*Non-nil means graphical smileys are displayed. |
| 1242 | Non-nil means that small graphics will be used in the show buffer instead of | 1305 | |
| 1243 | patterns like :-), ;-) etc. The setting only has effect if | 1306 | It is a long standing custom to inject body language using a cornucopia of |
| 1244 | `mh-decode-mime-flag' is non-nil." | 1307 | punctuation, also known as the \"smileys\". MH-E can render these as graphical |
| 1308 | widgets if this option is turned on, which it is by default. Smileys include | ||
| 1309 | patterns such as :-) and ;-). | ||
| 1310 | |||
| 1311 | This option is disabled if the option `mh-decode-mime-flag' is turned off." | ||
| 1245 | :type 'boolean | 1312 | :type 'boolean |
| 1246 | :group 'mh-show) | 1313 | :group 'mh-show) |
| 1247 | 1314 | ||
| 1248 | (defcustom mh-graphical-emphasis-flag t | 1315 | (defcustom mh-graphical-emphasis-flag t |
| 1249 | "*Non-nil means graphical emphasis is displayed. | 1316 | "*Non-nil means graphical emphasis is displayed. |
| 1250 | Non-nil means that _underline_ will be underlined, *bold* will appear in bold, | 1317 | |
| 1251 | /italic/ will appear in italic etc. See `gnus-emphasis-alist' for the whole | 1318 | A few typesetting features are indicated in ASCII text with certain |
| 1252 | list. The setting only has effect if `mh-decode-mime-flag' is non-nil." | 1319 | characters. If your terminal supports it, MH-E can render these typesetting |
| 1320 | directives naturally if this option is turned on, which it is by default. For | ||
| 1321 | example, _underline_ will be underlined, *bold* will appear in bold, /italics/ | ||
| 1322 | will appear in italics, and so on. See the option `gnus-emphasis-alist' for | ||
| 1323 | the whole list. | ||
| 1324 | |||
| 1325 | This option is disabled if the option `mh-decode-mime-flag' is turned off." | ||
| 1253 | :type 'boolean | 1326 | :type 'boolean |
| 1254 | :group 'mh-show) | 1327 | :group 'mh-show) |
| 1255 | 1328 | ||
| 1256 | (defcustom mh-highlight-citation-p 'gnus | 1329 | (defcustom mh-highlight-citation-style 'gnus |
| 1257 | "How to highlight citations in show buffers. | 1330 | "Style for highlighting citations. |
| 1258 | The gnus method uses a different color for each indentation." | 1331 | |
| 1259 | :type '(choice (const :tag "Use Gnus" gnus) | 1332 | If the sender of the message has cited other messages in his message, then |
| 1260 | (const :tag "Use font-lock" font-lock) | 1333 | MH-E will highlight these citations to emphasize the sender's actual response. |
| 1261 | (const :tag "Don't fontify" nil)) | 1334 | This option can be customized to change the highlighting style. The |
| 1335 | \"Multicolor\" method uses a different color for each indentation while the | ||
| 1336 | \"Monochrome\" method highlights all citations in red. To disable highlighting | ||
| 1337 | of citations entirely, choose \"None\"." | ||
| 1338 | :type '(choice (const :tag "Multicolor" gnus) | ||
| 1339 | (const :tag "Monochrome" font-lock) | ||
| 1340 | (const :tag "None" nil)) | ||
| 1262 | :group 'mh-show) | 1341 | :group 'mh-show) |
| 1263 | 1342 | ||
| 1264 | ;; Keep fields alphabetized. Mention source, if known. | 1343 | ;; Keep fields alphabetized. Mention source, if known. |
| @@ -1470,10 +1549,12 @@ from `mh-invisible-header-fields' are added." | |||
| 1470 | 1549 | ||
| 1471 | (defcustom mh-invisible-header-fields-default nil | 1550 | (defcustom mh-invisible-header-fields-default nil |
| 1472 | "*List of hidden header fields. | 1551 | "*List of hidden header fields. |
| 1552 | |||
| 1473 | The header fields listed in this option are hidden, although you can check off | 1553 | The header fields listed in this option are hidden, although you can check off |
| 1474 | any field that you would like to see. Header fields that you would like to | 1554 | any field that you would like to see. |
| 1475 | hide that aren't listed can be added to the `mh-invisible-header-fields' | 1555 | |
| 1476 | option. | 1556 | Header fields that you would like to hide that aren't listed can be added to |
| 1557 | the option `mh-invisible-header-fields'. | ||
| 1477 | 1558 | ||
| 1478 | See also `mh-clean-message-header-flag'." | 1559 | See also `mh-clean-message-header-flag'." |
| 1479 | :type `(set ,@(mapcar (lambda (x) `(const ,x)) | 1560 | :type `(set ,@(mapcar (lambda (x) `(const ,x)) |
| @@ -1485,11 +1566,14 @@ See also `mh-clean-message-header-flag'." | |||
| 1485 | 1566 | ||
| 1486 | (defcustom mh-invisible-header-fields nil | 1567 | (defcustom mh-invisible-header-fields nil |
| 1487 | "*Additional header fields to hide. | 1568 | "*Additional header fields to hide. |
| 1569 | |||
| 1488 | Header fields that you would like to hide that aren't listed in | 1570 | Header fields that you would like to hide that aren't listed in |
| 1489 | `mh-invisible-header-fields-default' can be added to this option with a couple | 1571 | `mh-invisible-header-fields-default' can be added to this option with a couple |
| 1490 | of caveats. Regular expressions are not allowed. Unique fields should have a | 1572 | of caveats. Regular expressions are not allowed. Unique fields should have a |
| 1491 | `:' suffix; otherwise, the element can be used to render invisible an entire | 1573 | `:' suffix; otherwise, the element can be used to render invisible an entire |
| 1492 | class of fields that start with the same prefix. | 1574 | class of fields that start with the same prefix. If you think a header field |
| 1575 | should be generally ignored, report a bug (see URL | ||
| 1576 | `https://sourceforge.net/tracker/?group_id=13357&atid=113357'). | ||
| 1493 | 1577 | ||
| 1494 | See also `mh-clean-message-header-flag'." | 1578 | See also `mh-clean-message-header-flag'." |
| 1495 | 1579 | ||
| @@ -1500,146 +1584,184 @@ See also `mh-clean-message-header-flag'." | |||
| 1500 | :group 'mh-show) | 1584 | :group 'mh-show) |
| 1501 | 1585 | ||
| 1502 | (defcustom mh-lpr-command-format "lpr -J '%s'" | 1586 | (defcustom mh-lpr-command-format "lpr -J '%s'" |
| 1503 | "*Format for Unix command that prints a message. | 1587 | "*Command used to print\\<mh-folder-mode-map>. |
| 1504 | The string should be a Unix command line, with the string '%s' where | 1588 | |
| 1505 | the job's name (folder and message number) should appear. The formatted | 1589 | This option contains the Unix command line which performs the actual printing |
| 1506 | message text is piped to this command when you type \\<mh-folder-mode-map>`\\[mh-print-msg]'." | 1590 | for the \\[mh-print-msg] command. The string can contain one escape, \"%s\", |
| 1591 | which is replaced by the name of the folder and the message number and is | ||
| 1592 | useful for print job names. I use \"mpage -h'%s' -b Letter -H1of -mlrtb -P\" | ||
| 1593 | which produces a nice header and adds a bit of margin so the text fits within | ||
| 1594 | my printer's margins. | ||
| 1595 | |||
| 1596 | This options is not used by the commands \\[mh-ps-print-msg] or | ||
| 1597 | \\[mh-ps-print-msg-file]." | ||
| 1507 | :type 'string | 1598 | :type 'string |
| 1508 | :group 'mh-show) | 1599 | :group 'mh-show) |
| 1509 | 1600 | ||
| 1510 | (defcustom mh-max-inline-image-height nil | 1601 | (defcustom mh-max-inline-image-height nil |
| 1511 | "*Maximum inline image height if Content-Disposition is not present. | 1602 | "*Maximum inline image height if \"Content-Disposition:\" is not present. |
| 1512 | If nil, image will be displayed if its height is smaller than the height of | 1603 | |
| 1513 | the window." | 1604 | Some older mail programs do not insert this needed plumbing to tell |
| 1605 | MH-E whether to display the attachments inline or not. If this is the | ||
| 1606 | case, MH-E will display these images inline if they are smaller than | ||
| 1607 | the window. However, you might want to allow larger images to be | ||
| 1608 | displayed inline. To do this, you can change the options | ||
| 1609 | `mh-max-inline-image-width' and `mh-max-inline-image-height' from their | ||
| 1610 | default value of zero to a large number. The size of your screen is a | ||
| 1611 | good choice for these numbers." | ||
| 1514 | :type '(choice (const nil) integer) | 1612 | :type '(choice (const nil) integer) |
| 1515 | :group 'mh-show) | 1613 | :group 'mh-show) |
| 1516 | 1614 | ||
| 1517 | (defcustom mh-max-inline-image-width nil | 1615 | (defcustom mh-max-inline-image-width nil |
| 1518 | "*Maximum inline image width if Content-Disposition is not present. | 1616 | "*Maximum inline image width if \"Content-Disposition:\" is not present. |
| 1519 | If nil, image will be displayed if its width is smaller than the width of the | 1617 | |
| 1520 | window." | 1618 | Some older mail programs do not insert this needed plumbing to tell |
| 1619 | MH-E whether to display the attachments inline or not. If this is the | ||
| 1620 | case, MH-E will display these images inline if they are smaller than | ||
| 1621 | the window. However, you might want to allow larger images to be | ||
| 1622 | displayed inline. To do this, you can change the options | ||
| 1623 | `mh-max-inline-image-width' and `mh-max-inline-image-height' from their | ||
| 1624 | default value of zero to a large number. The size of your screen is a | ||
| 1625 | good choice for these numbers." | ||
| 1521 | :type '(choice (const nil) integer) | 1626 | :type '(choice (const nil) integer) |
| 1522 | :group 'mh-show) | 1627 | :group 'mh-show) |
| 1523 | 1628 | ||
| 1629 | (defcustom mh-mhl-format-file nil | ||
| 1630 | "*Specifies the format file to pass to the \"mhl\" program. | ||
| 1631 | |||
| 1632 | Normally MH-E takes care of displaying messages itself (rather than calling an | ||
| 1633 | MH program to do the work). If you'd rather have \"mhl\" display the | ||
| 1634 | message (within MH-E), change this option from its default value of \"Use | ||
| 1635 | Default mhl Format (Printing Only)\". | ||
| 1636 | |||
| 1637 | You can set this option to \"Use Default mhl Format\" to get the same output | ||
| 1638 | as you would get if you ran \"mhl\" from the shell. | ||
| 1639 | |||
| 1640 | If you have a format file that you want MH-E to use, you can set this option | ||
| 1641 | to \"Specify an mhl Format File\" and enter the name of your format file. Your | ||
| 1642 | format file should specify a non-zero value for \"overflowoffset\" to allow | ||
| 1643 | MH-E to parse the header. Note that \"mhl\" is always used for printing and | ||
| 1644 | forwarding; in this case, the value of this option is consulted if you have | ||
| 1645 | specified a format file." | ||
| 1646 | :type '(choice (const :tag "Use Default mhl Format (Printing Only)" nil) | ||
| 1647 | (const :tag "Use Default mhl Format" t) | ||
| 1648 | (file :tag "Specify an mhl Format File")) | ||
| 1649 | :group 'mh-show) | ||
| 1650 | |||
| 1524 | (defcustom mh-mime-save-parts-default-directory t | 1651 | (defcustom mh-mime-save-parts-default-directory t |
| 1525 | "Default directory to use for `mh-mime-save-parts'. | 1652 | "Default directory to use for \\<mh-folder-mode-map>\\[mh-mime-save-parts]. |
| 1526 | If nil, prompt and set for next time the command is used during same session. | 1653 | |
| 1527 | If t, prompt always" | 1654 | The default value for this option is \"Prompt Always\" so that you are always |
| 1528 | :type '(choice (const :tag "Prompt the first time" nil) | 1655 | prompted for the directory in which to save the attachments. However, if you |
| 1529 | (const :tag "Prompt always" t) | 1656 | usually use the same directory within a session, then you can set this option |
| 1657 | to \"Prompt the First Time\" to avoid the prompt each time. you can make this | ||
| 1658 | directory permanent by choosing \"Directory\" and entering the directory's | ||
| 1659 | name." | ||
| 1660 | :type '(choice (const :tag "Prompt the First Time" nil) | ||
| 1661 | (const :tag "Prompt Always" t) | ||
| 1530 | directory) | 1662 | directory) |
| 1531 | :group 'mh-show) | 1663 | :group 'mh-show) |
| 1532 | 1664 | ||
| 1533 | (defcustom mh-print-background-flag nil | 1665 | (defcustom mh-print-background-flag nil |
| 1534 | "*Non-nil means messages should be printed in the background. | 1666 | "*Non-nil means messages should be printed in the background\\<mh-folder-mode-map>. |
| 1535 | WARNING: do not delete the messages until printing is finished; | ||
| 1536 | otherwise, your output may be truncated." | ||
| 1537 | :type 'boolean | ||
| 1538 | :group 'mh-show) | ||
| 1539 | 1667 | ||
| 1540 | (defcustom mh-recursive-folders-flag nil | 1668 | Normally messages are printed in the foreground. If this is slow on your |
| 1541 | "*Non-nil means that commands which operate on folders do so recursively." | 1669 | system, you may elect to turn off this option to print in the background. |
| 1670 | |||
| 1671 | WARNING: If you do this, do not delete the message until it is printed or else | ||
| 1672 | the output may be truncated. | ||
| 1673 | |||
| 1674 | This option is not used by the commands \\[mh-ps-print-msg] or | ||
| 1675 | \\[mh-ps-print-msg-file]." | ||
| 1542 | :type 'boolean | 1676 | :type 'boolean |
| 1543 | :group 'mh-show) | 1677 | :group 'mh-show) |
| 1544 | 1678 | ||
| 1545 | (defcustom mh-show-maximum-size 0 | 1679 | (defcustom mh-show-maximum-size 0 |
| 1546 | "*Maximum size of message (in bytes) to display automatically. | 1680 | "*Maximum size of message (in bytes) to display automatically. |
| 1547 | Provides an opportunity to skip over large messages which may be slow to load. | ||
| 1548 | Use a value of 0 to display all messages automatically regardless of size." | ||
| 1549 | :type 'integer | ||
| 1550 | :group 'mh-show) | ||
| 1551 | 1681 | ||
| 1552 | (defcustom mh-show-threads-flag nil | 1682 | This option provides an opportunity to skip over large messages which may be |
| 1553 | "Non-nil means new folders start in threaded mode. | 1683 | slow to load. The default value of 0 means that all message are shown |
| 1554 | Threading large number of messages can be time consuming. So if the flag is | 1684 | regardless of size." |
| 1555 | non-nil then threading will be done only if the number of messages being | 1685 | :type 'integer |
| 1556 | threaded is less than `mh-large-folder'." | ||
| 1557 | :type 'boolean | ||
| 1558 | :group 'mh-show) | 1686 | :group 'mh-show) |
| 1559 | 1687 | ||
| 1560 | ;; Use goto-addr if it was already loaded (which probably sets this | ||
| 1561 | ;; variable to t), or if this variable is otherwise set to t. | ||
| 1562 | (defcustom mh-show-use-goto-addr-flag (and (boundp 'goto-address-highlight-p) | 1688 | (defcustom mh-show-use-goto-addr-flag (and (boundp 'goto-address-highlight-p) |
| 1563 | goto-address-highlight-p) | 1689 | goto-address-highlight-p) |
| 1564 | "*Non-nil means highlight URLs and email addresses. | 1690 | "*Non-nil means highlight URLs and email addresses\\<goto-address-highlight-keymap>. |
| 1565 | The `goto-addr' module is used." | 1691 | |
| 1692 | To send a message using the highlighted email address or to view the web page | ||
| 1693 | for the highlighted URL, use the middle mouse button or | ||
| 1694 | \\[goto-address-at-point]. | ||
| 1695 | |||
| 1696 | See Info node `(mh-e)Sending Mail' to see how to configure Emacs to send the | ||
| 1697 | message using MH-E. | ||
| 1698 | |||
| 1699 | The default value of this option comes from the value of | ||
| 1700 | `goto-address-highlight-p'." | ||
| 1566 | :type 'boolean | 1701 | :type 'boolean |
| 1567 | :group 'mh-show) | 1702 | :group 'mh-show) |
| 1568 | 1703 | ||
| 1569 | (defcustom mh-show-use-xface-flag (>= emacs-major-version 21) | 1704 | (defcustom mh-show-use-xface-flag (>= emacs-major-version 21) |
| 1570 | "*Non-nil means display face images in `mh-show-mode'. | 1705 | "*Non-nil means display face images in MH-show buffers. |
| 1571 | 1706 | ||
| 1572 | MH-E can display the content of `Face:', `X-Face:', and `X-Image-URL:' header | 1707 | MH-E can display the content of \"Face:\", \"X-Face:\", and \"X-Image-URL:\" |
| 1573 | fields. If any of these fields occur in the header of your message, the | 1708 | header fields. If any of these fields occur in the header of your message, the |
| 1574 | sender's face will appear in the `From:' header field. If more than one of | 1709 | sender's face will appear in the \"From:\" header field. If more than one of |
| 1575 | these fields appear, then the first field found in the order `Face:', | 1710 | these fields appear, then the first field found in the order \"Face:\", |
| 1576 | `X-Face:', and `X-Image-URL:' will be used. Note that versions of GNU Emacs | 1711 | \"X-Face:\", and \"X-Image-URL:\" will be used. |
| 1577 | prior to 21.1 don't support the display of inline images, so face images are | ||
| 1578 | not displayed in these versions. | ||
| 1579 | 1712 | ||
| 1580 | The option `mh-show-use-xface-flag' is used to turn this feature on and off. | 1713 | The option `mh-show-use-xface-flag' is used to turn this feature on and off. |
| 1581 | This feature will be turned on by default if your system supports it. | 1714 | This feature will be turned on by default if your system supports it. |
| 1582 | 1715 | ||
| 1583 | The first header field used, if present, is the Gnus-specific `Face:' field. | 1716 | The first header field used, if present, is the Gnus-specific \"Face:\" field. |
| 1584 | The `Face:' field appeared in GNU Emacs 21 and XEmacs. For more information, | 1717 | The \"Face:\" field appeared in GNU Emacs 21 and XEmacs. For more information, |
| 1585 | see URL `http://quimby.gnus.org/circus/face/'. Next is the traditional | 1718 | see URL `http://quimby.gnus.org/circus/face/'. Next is the traditional |
| 1586 | `X-Face:' header field. The display of this field requires the `uncompface' | 1719 | \"X-Face:\" header field. The display of this field requires the |
| 1587 | program (see URL `ftp://ftp.cs.indiana.edu/pub/faces/compface/compface.tar.Z'). | 1720 | \"uncompface\" program (see URL |
| 1588 | Recent versions of XEmacs have internal support for `X-Face:' images. If your | 1721 | `ftp://ftp.cs.indiana.edu/pub/faces/compface/compface.tar.z'). Recent versions |
| 1589 | version of XEmacs does not, then you'll need both `uncompface' and the x-face | 1722 | of XEmacs have internal support for \"X-Face:\" images. If your version of |
| 1723 | XEmacs does not, then you'll need both \"uncompface\" and the x-face | ||
| 1590 | package (see URL `ftp://ftp.jpl.org/pub/elisp/'). | 1724 | package (see URL `ftp://ftp.jpl.org/pub/elisp/'). |
| 1591 | 1725 | ||
| 1592 | Finally, MH-E will display images referenced by the `X-Image-URL:' header | 1726 | Finally, MH-E will display images referenced by the \"X-Image-URL:\" header |
| 1593 | field if neither the `Face:' nor the `X-Face:' fields are present. The display | 1727 | field if neither the \"Face:\" nor the \"X-Face:\" fields are present. The |
| 1594 | of the images requires `wget' (see URL | 1728 | display of the images requires \"wget\" (see URL |
| 1595 | `http://www.gnu.org/software/wget/wget.html'), `fetch', or `curl' to fetch the | 1729 | `http://www.gnu.org/software/wget/wget.html'), \"fetch\", or \"curl\" to fetch |
| 1596 | image and the `convert' program from the ImageMagick suite (see URL | 1730 | the image and the \"convert\" program from the ImageMagick suite (see URL |
| 1597 | `http://www.imagemagick.org/'). Of the three header fields this is the most | 1731 | `http://www.imagemagick.org/'). Of the three header fields this is the most |
| 1598 | efficient in terms of network usage since the image doesn't need to be | 1732 | efficient in terms of network usage since the image doesn't need to be |
| 1599 | transmitted with every single mail. | 1733 | transmitted with every single mail. |
| 1600 | 1734 | ||
| 1601 | The option `mh-fetch-x-image-url' controls the fetching of the `X-Image-URL:' | 1735 | The option `mh-fetch-x-image-url' controls the fetching of the |
| 1602 | header field image." | 1736 | \"X-Image-URL:\" header field image." |
| 1603 | :type 'boolean | 1737 | :type 'boolean |
| 1604 | :group 'mh-show) | 1738 | :group 'mh-show) |
| 1605 | 1739 | ||
| 1606 | (defcustom mh-store-default-directory nil | 1740 | (defcustom mh-store-default-directory nil |
| 1607 | "*Last directory used by \\[mh-store-msg]; default for next store. | 1741 | "*Default directory for \\<mh-folder-mode-map>\\[mh-store-msg]. |
| 1608 | A directory name string, or nil to use current directory." | 1742 | |
| 1743 | If you would like to change the initial default directory, customize this | ||
| 1744 | option, change the value from `Current' to `Directory', and then enter the | ||
| 1745 | name of the directory for storing the content of these messages." | ||
| 1609 | :type '(choice (const :tag "Current" nil) | 1746 | :type '(choice (const :tag "Current" nil) |
| 1610 | directory) | 1747 | directory) |
| 1611 | :group 'mh-show) | 1748 | :group 'mh-show) |
| 1612 | 1749 | ||
| 1613 | (defcustom mh-summary-height nil | 1750 | (defcustom mh-summary-height nil |
| 1614 | "*Number of lines in MH-Folder window (including the mode line)." | 1751 | "*Number of lines in MH-Folder buffer (including the mode line). |
| 1615 | :type '(choice (const :tag "Automatic" nil) | ||
| 1616 | (integer :tag "Fixed sized")) | ||
| 1617 | :group 'mh-show) | ||
| 1618 | 1752 | ||
| 1619 | (defcustom mhl-formfile nil | 1753 | The default value of this option is \"Automatic\" which means that the |
| 1620 | "*Name of format file to be used by mhl to show and print messages. | 1754 | MH-Folder buffer will maintain the same proportional size if the frame is |
| 1621 | A value of t means use the default format file. | 1755 | resized. If you'd prefer a fixed height, then choose the \"Fixed Size\" option |
| 1622 | nil means don't use mhl to format messages when showing; mhl is still used, | 1756 | and enter the number of lines you'd like to see." |
| 1623 | with the default format file, to format messages when printing them. | 1757 | :type '(choice (const :tag "Automatic" nil) |
| 1624 | The format used should specify a non-zero value for overflowoffset so | 1758 | (integer :tag "Fixed Size")) |
| 1625 | the message continues to conform to RFC 822 and MH-E can parse the headers." | ||
| 1626 | :type '(choice (const nil) (const t) string) | ||
| 1627 | :group 'mh-show) | 1759 | :group 'mh-show) |
| 1628 | (put 'mhl-formfile 'info-file "mh-e") | ||
| 1629 | 1760 | ||
| 1630 | 1761 | ||
| 1631 | 1762 | ||
| 1632 | ;;; The Speedbar (:group 'mh-speed) | 1763 | ;;; The Speedbar (:group 'mh-speed) |
| 1633 | 1764 | ||
| 1634 | (defcustom mh-large-folder 200 | ||
| 1635 | "The number of messages that indicates a large folder. | ||
| 1636 | If a folder is deemed to be large, that is the number of messages in it exceed | ||
| 1637 | this value, then confirmation is needed when it is visited. Even when | ||
| 1638 | `mh-show-threads-flag' is non-nil, the folder is not automatically threaded, if | ||
| 1639 | it is large. If set to nil all folders are treated as if they are small." | ||
| 1640 | :type '(choice (const :tag "No limit") integer) | ||
| 1641 | :group 'mh-speed) | ||
| 1642 | |||
| 1643 | (defcustom mh-speed-flists-interval 60 | 1765 | (defcustom mh-speed-flists-interval 60 |
| 1644 | "Time between calls to flists in seconds. | 1766 | "Time between calls to flists in seconds. |
| 1645 | If 0, flists is not called repeatedly." | 1767 | If 0, flists is not called repeatedly." |
| @@ -1657,6 +1779,19 @@ be updated manually with the \\[mh-speed-flists] command." | |||
| 1657 | 1779 | ||
| 1658 | 1780 | ||
| 1659 | 1781 | ||
| 1782 | ;;; Threading (:group 'mh-thread) | ||
| 1783 | |||
| 1784 | (defcustom mh-show-threads-flag nil | ||
| 1785 | "*Non-nil means new folders start in threaded mode. | ||
| 1786 | |||
| 1787 | Threading large number of messages can be time consuming so this option is | ||
| 1788 | turned off by default. If you turn this option on, then threading will be done | ||
| 1789 | only if the number of messages being threaded is less than `mh-large-folder'." | ||
| 1790 | :type 'boolean | ||
| 1791 | :group 'mh-thread) | ||
| 1792 | |||
| 1793 | |||
| 1794 | |||
| 1660 | ;;; The Toolbar (:group 'mh-toolbar) | 1795 | ;;; The Toolbar (:group 'mh-toolbar) |
| 1661 | 1796 | ||
| 1662 | (defcustom mh-tool-bar-search-function 'mh-search-folder | 1797 | (defcustom mh-tool-bar-search-function 'mh-search-folder |
| @@ -2119,7 +2254,7 @@ Emacs), set `mh-yank-behavior' to \"Body and Header\" (see URL | |||
| 2119 | See also `mh-quit-hook'." | 2254 | See also `mh-quit-hook'." |
| 2120 | :type 'hook | 2255 | :type 'hook |
| 2121 | :group 'mh-hooks | 2256 | :group 'mh-hooks |
| 2122 | :group 'mh-show) | 2257 | :group 'mh-folder) |
| 2123 | 2258 | ||
| 2124 | (defcustom mh-before-send-letter-hook nil | 2259 | (defcustom mh-before-send-letter-hook nil |
| 2125 | "Invoked at the beginning of the \\<mh-letter-mode-map>\\[mh-send-letter] command. | 2260 | "Invoked at the beginning of the \\<mh-letter-mode-map>\\[mh-send-letter] command. |
| @@ -2131,7 +2266,10 @@ sending, add the `ispell-message' function." | |||
| 2131 | :group 'mh-letter) | 2266 | :group 'mh-letter) |
| 2132 | 2267 | ||
| 2133 | (defcustom mh-delete-msg-hook nil | 2268 | (defcustom mh-delete-msg-hook nil |
| 2134 | "Invoked after marking each message for deletion." | 2269 | "Invoked after marking each message for deletion. |
| 2270 | |||
| 2271 | For example, a past maintainer of MH-E used this once when he kept statistics | ||
| 2272 | on his mail usage." | ||
| 2135 | :type 'hook | 2273 | :type 'hook |
| 2136 | :group 'mh-hooks | 2274 | :group 'mh-hooks |
| 2137 | :group 'mh-show) | 2275 | :group 'mh-show) |
| @@ -2146,13 +2284,13 @@ sending, add the `ispell-message' function." | |||
| 2146 | "Invoked by `mh-find-path' after reading the user's MH profile." | 2284 | "Invoked by `mh-find-path' after reading the user's MH profile." |
| 2147 | :type 'hook | 2285 | :type 'hook |
| 2148 | :group 'mh-hooks | 2286 | :group 'mh-hooks |
| 2149 | :group 'mh-show) | 2287 | :group 'mh-e) |
| 2150 | 2288 | ||
| 2151 | (defcustom mh-folder-mode-hook nil | 2289 | (defcustom mh-folder-mode-hook nil |
| 2152 | "Invoked in `mh-folder-mode' on a new folder." | 2290 | "Invoked in `mh-folder-mode' on a new folder." |
| 2153 | :type 'hook | 2291 | :type 'hook |
| 2154 | :group 'mh-hooks | 2292 | :group 'mh-hooks |
| 2155 | :group 'mh-show) | 2293 | :group 'mh-folder) |
| 2156 | 2294 | ||
| 2157 | (defcustom mh-folder-updated-hook nil | 2295 | (defcustom mh-folder-updated-hook nil |
| 2158 | "Invoked when the folder actions (such as moves and deletes) are performed. | 2296 | "Invoked when the folder actions (such as moves and deletes) are performed. |
| @@ -2160,13 +2298,14 @@ Variables that are useful in this hook include `mh-delete-list' and | |||
| 2160 | `mh-refile-list' which can be used to see which changes are being made to | 2298 | `mh-refile-list' which can be used to see which changes are being made to |
| 2161 | current folder, `mh-current-folder'." | 2299 | current folder, `mh-current-folder'." |
| 2162 | :type 'hook | 2300 | :type 'hook |
| 2163 | :group 'mh-hooks) | 2301 | :group 'mh-hooks |
| 2302 | :group 'mh-folder) | ||
| 2164 | 2303 | ||
| 2165 | (defcustom mh-forward-hook nil | 2304 | (defcustom mh-forward-hook nil |
| 2166 | "Invoked on the forwarded letter by \\<mh-folder-mode-map>\\[mh-forward]." | 2305 | "Invoked on the forwarded letter by \\<mh-folder-mode-map>\\[mh-forward]." |
| 2167 | :type 'hook | 2306 | :type 'hook |
| 2168 | :group 'mh-hooks | 2307 | :group 'mh-hooks |
| 2169 | :group 'mh-folder) | 2308 | :group 'mh-sending-mail) |
| 2170 | 2309 | ||
| 2171 | (defcustom mh-inc-folder-hook nil | 2310 | (defcustom mh-inc-folder-hook nil |
| 2172 | "Invoked by \\<mh-folder-mode-map>`\\[mh-inc-folder]' after incorporating mail into a folder." | 2311 | "Invoked by \\<mh-folder-mode-map>`\\[mh-inc-folder]' after incorporating mail into a folder." |
| @@ -2189,7 +2328,7 @@ t on +inbox and you hit \\<mh-folder-mode-map>`\\[mh-kill-folder]' by accident | |||
| 2189 | in the +inbox buffer, you will not be happy." | 2328 | in the +inbox buffer, you will not be happy." |
| 2190 | :type 'hook | 2329 | :type 'hook |
| 2191 | :group 'mh-hooks | 2330 | :group 'mh-hooks |
| 2192 | :group 'mh-show) | 2331 | :group 'mh-folder) |
| 2193 | 2332 | ||
| 2194 | (defcustom mh-letter-insert-signature-hook nil | 2333 | (defcustom mh-letter-insert-signature-hook nil |
| 2195 | "Invoked after signature has been inserted. | 2334 | "Invoked after signature has been inserted. |
| @@ -2216,22 +2355,28 @@ insert the signature with `mh-signature-file-name'." | |||
| 2216 | See also `mh-before-quit-hook'." | 2355 | See also `mh-before-quit-hook'." |
| 2217 | :type 'hook | 2356 | :type 'hook |
| 2218 | :group 'mh-hooks | 2357 | :group 'mh-hooks |
| 2219 | :group 'mh-show) | 2358 | :group 'mh-folder) |
| 2220 | 2359 | ||
| 2221 | (defcustom mh-refile-msg-hook nil | 2360 | (defcustom mh-refile-msg-hook nil |
| 2222 | "Invoked after marking each message for refiling." | 2361 | "Invoked after marking each message for refiling." |
| 2223 | :type 'hook | 2362 | :type 'hook |
| 2224 | :group 'mh-hooks | 2363 | :group 'mh-hooks |
| 2225 | :group 'mh-show) | 2364 | :group 'mh-folder) |
| 2226 | 2365 | ||
| 2227 | (defcustom mh-show-hook nil | 2366 | (defcustom mh-show-hook nil |
| 2228 | "Invoked after \\<mh-folder-mode-map>`\\[mh-show]' shows a message." | 2367 | "Invoked after \\<mh-folder-mode-map>\\[mh-show] shows a message. |
| 2368 | |||
| 2369 | It is the last thing called after messages are displayed. It's used to affect | ||
| 2370 | the behavior of MH-E in general or when `mh-show-mode-hook' is too early." | ||
| 2229 | :type 'hook | 2371 | :type 'hook |
| 2230 | :group 'mh-hooks | 2372 | :group 'mh-hooks |
| 2231 | :group 'mh-show) | 2373 | :group 'mh-show) |
| 2232 | 2374 | ||
| 2233 | (defcustom mh-show-mode-hook nil | 2375 | (defcustom mh-show-mode-hook nil |
| 2234 | "Invoked upon entry to `mh-show-mode'." | 2376 | "Invoked upon entry to `mh-show-mode'. |
| 2377 | |||
| 2378 | This hook is called early on in the process of the message display. It is | ||
| 2379 | usually used to perform some action on the message's content." | ||
| 2235 | :type 'hook | 2380 | :type 'hook |
| 2236 | :group 'mh-hooks | 2381 | :group 'mh-hooks |
| 2237 | :group 'mh-show) | 2382 | :group 'mh-show) |
| @@ -2242,7 +2387,7 @@ The variable `mh-seen-list' can be used to obtain the list of messages which | |||
| 2242 | will be removed from the unseen sequence." | 2387 | will be removed from the unseen sequence." |
| 2243 | :type 'hook | 2388 | :type 'hook |
| 2244 | :group 'mh-hooks | 2389 | :group 'mh-hooks |
| 2245 | :group 'mh-show) | 2390 | :group 'mh-sequences) |
| 2246 | 2391 | ||
| 2247 | 2392 | ||
| 2248 | 2393 | ||
diff --git a/lisp/mh-e/mh-e.el b/lisp/mh-e/mh-e.el index caf870f159e..86d9bbfcddf 100644 --- a/lisp/mh-e/mh-e.el +++ b/lisp/mh-e/mh-e.el | |||
| @@ -132,7 +132,7 @@ The string is displayed after the folder's name. nil for no annotation.") | |||
| 132 | "%<(zero)%17(friendly{from})%> " | 132 | "%<(zero)%17(friendly{from})%> " |
| 133 | "%{subject}%<{body}<<%{body}%>") | 133 | "%{subject}%<{body}<<%{body}%>") |
| 134 | "*Scan format string for MH. | 134 | "*Scan format string for MH. |
| 135 | This string is passed to the scan program via the -format arg. | 135 | This string is passed to the scan program via the -format argument. |
| 136 | This format is identical to the default except that additional hints for | 136 | This format is identical to the default except that additional hints for |
| 137 | fontification have been added to the fifth column (remember that in Emacs, the | 137 | fontification have been added to the fifth column (remember that in Emacs, the |
| 138 | first column is 0). | 138 | first column is 0). |
| @@ -186,7 +186,7 @@ It must match from the beginning of the line. Note that the default setting of | |||
| 186 | parenthesized expression which matches the message number as in the default of | 186 | parenthesized expression which matches the message number as in the default of |
| 187 | \"^\\\\( *[0-9]+\\\\)[^D^0-9]\". This expression includes the leading space | 187 | \"^\\\\( *[0-9]+\\\\)[^D^0-9]\". This expression includes the leading space |
| 188 | within the parenthesis since it looks better to highlight it as well. This | 188 | within the parenthesis since it looks better to highlight it as well. This |
| 189 | regular expression should be correct as it is needed by non-fontifying | 189 | regular expression should be correct as it is needed by non-fontification |
| 190 | functions.") | 190 | functions.") |
| 191 | 191 | ||
| 192 | (defvar mh-scan-deleted-msg-regexp "^\\( *[0-9]+\\)D" | 192 | (defvar mh-scan-deleted-msg-regexp "^\\( *[0-9]+\\)D" |
| @@ -196,8 +196,8 @@ It must match from the beginning of the line. Note that the default setting of | |||
| 196 | parenthesized expression which matches the message number as in the default of | 196 | parenthesized expression which matches the message number as in the default of |
| 197 | \"^\\\\( *[0-9]+\\\\)D\". This expression includes the leading space within | 197 | \"^\\\\( *[0-9]+\\\\)D\". This expression includes the leading space within |
| 198 | the parenthesis since it looks better to highlight it as well. This regular | 198 | the parenthesis since it looks better to highlight it as well. This regular |
| 199 | expression should be correct as it is needed by non-fontifying functions. See | 199 | expression should be correct as it is needed by non-fontification functions. |
| 200 | also `mh-note-deleted'.") | 200 | See also `mh-note-deleted'.") |
| 201 | 201 | ||
| 202 | (defvar mh-scan-refiled-msg-regexp "^\\( *[0-9]+\\)\\^" | 202 | (defvar mh-scan-refiled-msg-regexp "^\\( *[0-9]+\\)\\^" |
| 203 | "This regular expression matches refiled messages. | 203 | "This regular expression matches refiled messages. |
| @@ -206,7 +206,7 @@ It must match from the beginning of the line. Note that the default setting of | |||
| 206 | parenthesized expression which matches the message number as in the default of | 206 | parenthesized expression which matches the message number as in the default of |
| 207 | \"^\\\\( *[0-9]+\\\\)\\\\^\". This expression includes the leading space | 207 | \"^\\\\( *[0-9]+\\\\)\\\\^\". This expression includes the leading space |
| 208 | within the parenthesis since it looks better to highlight it as well. This | 208 | within the parenthesis since it looks better to highlight it as well. This |
| 209 | regular expression should be correct as it is needed by non-fontifying | 209 | regular expression should be correct as it is needed by non-fontification |
| 210 | functions. See also `mh-note-refiled'.") | 210 | functions. See also `mh-note-refiled'.") |
| 211 | 211 | ||
| 212 | (defvar mh-scan-valid-regexp "^ *[0-9]" | 212 | (defvar mh-scan-valid-regexp "^ *[0-9]" |
| @@ -222,7 +222,7 @@ parenthesized expression which matches the message number as in the default of | |||
| 222 | \"^\\\\( *[0-9]+\\\\+\\\\).*\". This expression includes the leading space and | 222 | \"^\\\\( *[0-9]+\\\\+\\\\).*\". This expression includes the leading space and |
| 223 | current message marker \"+\" within the parenthesis since it looks better to | 223 | current message marker \"+\" within the parenthesis since it looks better to |
| 224 | highlight these items as well. This regular expression should be correct as it | 224 | highlight these items as well. This regular expression should be correct as it |
| 225 | is needed by non-fontifying functions. See also `mh-note-cur'.") | 225 | is needed by non-fontification functions. See also `mh-note-cur'.") |
| 226 | 226 | ||
| 227 | (defvar mh-scan-date-regexp "\\([0-9][0-9]/[0-9][0-9]\\)" | 227 | (defvar mh-scan-date-regexp "\\([0-9][0-9]/[0-9][0-9]\\)" |
| 228 | "This regular expression matches a valid date. | 228 | "This regular expression matches a valid date. |
| @@ -262,7 +262,7 @@ the third is expected to match the subject line itself as in the default of | |||
| 262 | ^ *[0-9]+........[ ]*................... | 262 | ^ *[0-9]+........[ ]*................... |
| 263 | \\\\([Rr][Ee]\\\\(\\\\\\=[[0-9]+\\\\]\\\\)?:\\\\s-*\\\\)* | 263 | \\\\([Rr][Ee]\\\\(\\\\\\=[[0-9]+\\\\]\\\\)?:\\\\s-*\\\\)* |
| 264 | \\\\([^<\\n]*\\\\) | 264 | \\\\([^<\\n]*\\\\) |
| 265 | This regular expression should be correct as it is needed by non-fontifying | 265 | This regular expression should be correct as it is needed by non-fontification |
| 266 | functions.") | 266 | functions.") |
| 267 | 267 | ||
| 268 | (defvar mh-scan-format-regexp | 268 | (defvar mh-scan-format-regexp |
| @@ -535,8 +535,15 @@ the Emacs interface to the MH mail system." | |||
| 535 | ;;; User executable MH-E commands: | 535 | ;;; User executable MH-E commands: |
| 536 | 536 | ||
| 537 | (defun mh-delete-msg (range) | 537 | (defun mh-delete-msg (range) |
| 538 | "Mark the specified RANGE for subsequent deletion and move to the next. | 538 | "Delete message\\<mh-folder-mode-map>. |
| 539 | Default is the displayed message. | 539 | |
| 540 | To mark a message for deletion, use this command. A \"D\" is placed by the | ||
| 541 | message in the scan window, and the next undeleted message is displayed. If | ||
| 542 | the previous command had been \\[mh-previous-undeleted-msg], then the next | ||
| 543 | message displayed is the first undeleted message previous to the message just | ||
| 544 | deleted. Use \\[mh-next-undeleted-msg] to force subsequent \\[mh-delete-msg] | ||
| 545 | commands to move forward to the next undeleted message after deleting the | ||
| 546 | message under the cursor. | ||
| 540 | 547 | ||
| 541 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | 548 | Check the documentation of `mh-interactive-range' to see how RANGE is read in |
| 542 | interactive use." | 549 | interactive use." |
| @@ -545,7 +552,11 @@ interactive use." | |||
| 545 | (if (looking-at mh-scan-deleted-msg-regexp) (mh-next-msg))) | 552 | (if (looking-at mh-scan-deleted-msg-regexp) (mh-next-msg))) |
| 546 | 553 | ||
| 547 | (defun mh-delete-msg-no-motion (range) | 554 | (defun mh-delete-msg-no-motion (range) |
| 548 | "Mark the specified RANGE for subsequent deletion. | 555 | "Delete message, don't move to next message. |
| 556 | |||
| 557 | This command marks the message (or messages in RANGE) for deletion but leaves | ||
| 558 | the cursor at the current message in case you wish to perform other operations | ||
| 559 | on the message. | ||
| 549 | 560 | ||
| 550 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | 561 | Check the documentation of `mh-interactive-range' to see how RANGE is read in |
| 551 | interactive use." | 562 | interactive use." |
| @@ -564,24 +575,22 @@ interactive use." | |||
| 564 | t) ; return t for write-file-functions | 575 | t) ; return t for write-file-functions |
| 565 | 576 | ||
| 566 | (defun mh-first-msg () | 577 | (defun mh-first-msg () |
| 567 | "Move to the first message." | 578 | "Display first message." |
| 568 | (interactive) | 579 | (interactive) |
| 569 | (goto-char (point-min)) | 580 | (goto-char (point-min)) |
| 570 | (while (and (not (eobp)) (not (looking-at mh-scan-valid-regexp))) | 581 | (while (and (not (eobp)) (not (looking-at mh-scan-valid-regexp))) |
| 571 | (forward-line 1))) | 582 | (forward-line 1))) |
| 572 | 583 | ||
| 573 | (defun mh-header-display () | 584 | (defun mh-header-display () |
| 574 | "Show the current message with all its headers. | 585 | "Display message with all header fields\\<mh-folder-mode-map>. |
| 575 | Displays headers that might have been suppressed by setting the | 586 | |
| 576 | variables `mh-clean-message-header-flag' or `mhl-formfile', or by the fallback | 587 | Use the command \\[mh-show] to show the message normally again." |
| 577 | behavior of scrolling uninteresting headers off the top of the window. | ||
| 578 | Type \"\\[mh-show]\" to show the message normally again." | ||
| 579 | (interactive) | 588 | (interactive) |
| 580 | (and (not mh-showing-with-headers) | 589 | (and (not mh-showing-with-headers) |
| 581 | (or mhl-formfile mh-clean-message-header-flag) | 590 | (or mh-mhl-format-file mh-clean-message-header-flag) |
| 582 | (mh-invalidate-show-buffer)) | 591 | (mh-invalidate-show-buffer)) |
| 583 | (let ((mh-decode-mime-flag nil) | 592 | (let ((mh-decode-mime-flag nil) |
| 584 | (mhl-formfile nil) | 593 | (mh-mhl-format-file nil) |
| 585 | (mh-clean-message-header-flag nil)) | 594 | (mh-clean-message-header-flag nil)) |
| 586 | (mh-show-msg nil) | 595 | (mh-show-msg nil) |
| 587 | (mh-in-show-buffer (mh-show-buffer) | 596 | (mh-in-show-buffer (mh-show-buffer) |
| @@ -630,21 +639,26 @@ Do not call this function from outside MH-E; use \\[mh-rmail] instead." | |||
| 630 | (run-hooks 'mh-inc-folder-hook))) | 639 | (run-hooks 'mh-inc-folder-hook))) |
| 631 | 640 | ||
| 632 | (defun mh-last-msg () | 641 | (defun mh-last-msg () |
| 633 | "Move to the last message." | 642 | "Display last message." |
| 634 | (interactive) | 643 | (interactive) |
| 635 | (goto-char (point-max)) | 644 | (goto-char (point-max)) |
| 636 | (while (and (not (bobp)) (not (looking-at mh-scan-valid-regexp))) | 645 | (while (and (not (bobp)) (not (looking-at mh-scan-valid-regexp))) |
| 637 | (forward-line -1)) | 646 | (forward-line -1)) |
| 638 | (mh-recenter nil)) | 647 | (mh-recenter nil)) |
| 639 | 648 | ||
| 640 | (defun mh-next-undeleted-msg (&optional arg wait-after-complaining-flag) | 649 | (defun mh-next-undeleted-msg (&optional count wait-after-complaining-flag) |
| 641 | "Move to the next undeleted message ARG in window. | 650 | "Display next message. |
| 642 | If optional argument WAIT-AFTER-COMPLAINING-FLAG is non-nil and we are at the | 651 | |
| 643 | last undeleted message then pause for a second after printing message." | 652 | This command can be given a prefix argument COUNT to specify how many unread |
| 653 | messages to skip. | ||
| 654 | |||
| 655 | In a program, pause for a second after printing message if we are at the last | ||
| 656 | undeleted message and optional argument WAIT-AFTER-COMPLAINING-FLAG is | ||
| 657 | non-nil." | ||
| 644 | (interactive "p") | 658 | (interactive "p") |
| 645 | (setq mh-next-direction 'forward) | 659 | (setq mh-next-direction 'forward) |
| 646 | (forward-line 1) | 660 | (forward-line 1) |
| 647 | (cond ((re-search-forward mh-scan-good-msg-regexp nil t arg) | 661 | (cond ((re-search-forward mh-scan-good-msg-regexp nil t count) |
| 648 | (beginning-of-line) | 662 | (beginning-of-line) |
| 649 | (mh-maybe-show)) | 663 | (mh-maybe-show)) |
| 650 | (t (forward-line -1) | 664 | (t (forward-line -1) |
| @@ -748,24 +762,27 @@ updated." | |||
| 748 | (when (looking-at mh-scan-refiled-msg-regexp) (mh-next-msg))) | 762 | (when (looking-at mh-scan-refiled-msg-regexp) (mh-next-msg))) |
| 749 | 763 | ||
| 750 | (defun mh-refile-or-write-again (range &optional interactive-flag) | 764 | (defun mh-refile-or-write-again (range &optional interactive-flag) |
| 751 | "Re-execute the last refile or write command on the given RANGE. | 765 | "Repeat last output command. |
| 752 | Default is the displayed message. Use the same folder or file as the previous | 766 | |
| 753 | refile or write command. | 767 | If you are refiling several messages into the same folder, you can use this |
| 754 | If INTERACTIVE-FLAG is non-nil then the function was called interactively." | 768 | command to repeat the last refile or write. Or, you can use a range. |
| 769 | |||
| 770 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | ||
| 771 | interactive use. | ||
| 772 | |||
| 773 | In a program, a non-nil INTERACTIVE-FLAG means that the function was called | ||
| 774 | interactively." | ||
| 755 | (interactive (list (mh-interactive-range "Redo") t)) | 775 | (interactive (list (mh-interactive-range "Redo") t)) |
| 756 | (if (null mh-last-destination) | 776 | (if (null mh-last-destination) |
| 757 | (error "No previous refile or write")) | 777 | (error "No previous refile or write")) |
| 758 | (let (output) | 778 | (cond ((eq (car mh-last-destination) 'refile) |
| 759 | (setq output | 779 | (mh-refile-msg range (cdr mh-last-destination)) |
| 760 | (cond ((eq (car mh-last-destination) 'refile) | 780 | (message "%s" (format "Destination folder: %s" |
| 761 | (mh-refile-msg range (cdr mh-last-destination)) | 781 | (cdr mh-last-destination)))) |
| 762 | (format "Destination folder: %s" (cdr mh-last-destination))) | 782 | (t |
| 763 | (t | 783 | (mh-iterate-on-range msg range |
| 764 | (mh-iterate-on-range msg range | 784 | (apply 'mh-write-msg-to-file msg (cdr mh-last-destination))) |
| 765 | (apply 'mh-write-msg-to-file msg (cdr mh-last-destination))) | 785 | (mh-next-msg interactive-flag)))) |
| 766 | (mh-next-msg interactive-flag) | ||
| 767 | (format "Destination: %s" (cdr mh-last-destination))))) | ||
| 768 | (message "%s" output))) | ||
| 769 | 786 | ||
| 770 | (defun mh-quit () | 787 | (defun mh-quit () |
| 771 | "Quit the current MH-E folder. | 788 | "Quit the current MH-E folder. |
| @@ -795,11 +812,12 @@ killed." | |||
| 795 | (set-window-configuration mh-previous-window-config)) | 812 | (set-window-configuration mh-previous-window-config)) |
| 796 | (run-hooks 'mh-quit-hook)) | 813 | (run-hooks 'mh-quit-hook)) |
| 797 | 814 | ||
| 798 | (defun mh-page-msg (&optional arg) | 815 | (defun mh-page-msg (&optional lines) |
| 799 | "Page the displayed message forwards. | 816 | "Display next page in message. |
| 800 | Scrolls ARG lines or a full screen if no argument is supplied. Show buffer | 817 | |
| 801 | first if not displayed. Show the next undeleted message if looking at the | 818 | You can give this command a prefix argument that specifies the number of LINES |
| 802 | bottom of the current message." | 819 | to scroll. This command will also show the next undeleted message if it is |
| 820 | used at the bottom of a message." | ||
| 803 | (interactive "P") | 821 | (interactive "P") |
| 804 | (if mh-showing-mode | 822 | (if mh-showing-mode |
| 805 | (if mh-page-to-next-msg-flag | 823 | (if mh-page-to-next-msg-flag |
| @@ -816,32 +834,40 @@ bottom of the current message." | |||
| 816 | "previous" | 834 | "previous" |
| 817 | "next")) | 835 | "next")) |
| 818 | (setq mh-page-to-next-msg-flag t)) | 836 | (setq mh-page-to-next-msg-flag t)) |
| 819 | (scroll-other-window arg))) | 837 | (scroll-other-window lines))) |
| 820 | (mh-show))) | 838 | (mh-show))) |
| 821 | 839 | ||
| 822 | (defun mh-previous-page (&optional arg) | 840 | (defun mh-previous-page (&optional lines) |
| 823 | "Page the displayed message backwards. | 841 | "Display next page in message. |
| 824 | Scrolls ARG lines or a full screen if no argument is supplied." | 842 | |
| 843 | You can give this command a prefix argument that specifies the number of LINES | ||
| 844 | to scroll." | ||
| 825 | (interactive "P") | 845 | (interactive "P") |
| 826 | (mh-in-show-buffer (mh-show-buffer) | 846 | (mh-in-show-buffer (mh-show-buffer) |
| 827 | (scroll-down arg))) | 847 | (scroll-down lines))) |
| 828 | 848 | ||
| 829 | (defun mh-previous-undeleted-msg (&optional arg wait-after-complaining-flag) | 849 | (defun mh-previous-undeleted-msg (&optional count wait-after-complaining-flag) |
| 830 | "Move to the previous undeleted message ARG in window. | 850 | "Display previous message. |
| 831 | If optional argument WAIT-AFTER-COMPLAINING-FLAG is non-nil and we are at the | 851 | |
| 832 | first undeleted message then pause for a second after printing message." | 852 | This command can be given a prefix argument COUNT to specify how many unread |
| 853 | messages to skip. | ||
| 854 | |||
| 855 | In a program, pause for a second after printing message if we are at the last | ||
| 856 | undeleted message and optional argument WAIT-AFTER-COMPLAINING-FLAG is | ||
| 857 | non-nil." | ||
| 833 | (interactive "p") | 858 | (interactive "p") |
| 834 | (setq mh-next-direction 'backward) | 859 | (setq mh-next-direction 'backward) |
| 835 | (beginning-of-line) | 860 | (beginning-of-line) |
| 836 | (cond ((re-search-backward mh-scan-good-msg-regexp nil t arg) | 861 | (cond ((re-search-backward mh-scan-good-msg-regexp nil t count) |
| 837 | (mh-maybe-show)) | 862 | (mh-maybe-show)) |
| 838 | (t (message "No previous undeleted message") | 863 | (t (message "No previous undeleted message") |
| 839 | (if wait-after-complaining-flag (sit-for 1))))) | 864 | (if wait-after-complaining-flag (sit-for 1))))) |
| 840 | 865 | ||
| 841 | (defun mh-previous-unread-msg (&optional count) | 866 | (defun mh-previous-unread-msg (&optional count) |
| 842 | "Move to previous unread message. | 867 | "Display previous unread message. |
| 843 | With optional argument COUNT, COUNT-1 unread messages before current message | 868 | |
| 844 | are skipped." | 869 | This command can be given a prefix argument COUNT to specify how many unread |
| 870 | messages to skip." | ||
| 845 | (interactive "p") | 871 | (interactive "p") |
| 846 | (unless (> count 0) | 872 | (unless (> count 0) |
| 847 | (error "The function mh-previous-unread-msg expects positive argument")) | 873 | (error "The function mh-previous-unread-msg expects positive argument")) |
| @@ -916,11 +942,13 @@ function must return non-nil at the button we stop." | |||
| 916 | (point)))) | 942 | (point)))) |
| 917 | 943 | ||
| 918 | (defun mh-next-button (&optional backward-flag) | 944 | (defun mh-next-button (&optional backward-flag) |
| 919 | "Go to the next MIME button. | 945 | "Go to the next button. |
| 920 | Advance point to the next MIME button in the show buffer. If the end | 946 | |
| 921 | of buffer is reached then the search wraps over to the start of the | 947 | If the end of the buffer is reached then the search wraps over to the start of |
| 922 | buffer. With prefix argument, BACKWARD-FLAG the point will move to the | 948 | the buffer. |
| 923 | previous MIME button." | 949 | |
| 950 | If an optional prefix argument BACKWARD-FLAG is given, the cursor will move to | ||
| 951 | the previous button." | ||
| 924 | (interactive (list current-prefix-arg)) | 952 | (interactive (list current-prefix-arg)) |
| 925 | (unless mh-showing-mode | 953 | (unless mh-showing-mode |
| 926 | (mh-show)) | 954 | (mh-show)) |
| @@ -928,10 +956,10 @@ previous MIME button." | |||
| 928 | (mh-goto-next-button backward-flag))) | 956 | (mh-goto-next-button backward-flag))) |
| 929 | 957 | ||
| 930 | (defun mh-prev-button () | 958 | (defun mh-prev-button () |
| 931 | "Go to the prev MIME button. | 959 | "Go to the previous button. |
| 932 | Move point to the previous MIME button in the show buffer. If the beginning | 960 | |
| 933 | of the buffer is reached then the search wraps over to the end of the | 961 | If the beginning of the buffer is reached then the search wraps over to the |
| 934 | buffer." | 962 | end of the buffer." |
| 935 | (interactive) | 963 | (interactive) |
| 936 | (mh-next-button t)) | 964 | (mh-next-button t)) |
| 937 | 965 | ||
| @@ -969,31 +997,48 @@ searching for a suitable parts." | |||
| 969 | (funcall action))))))) | 997 | (funcall action))))))) |
| 970 | 998 | ||
| 971 | (defun mh-folder-toggle-mime-part (part-index) | 999 | (defun mh-folder-toggle-mime-part (part-index) |
| 972 | "Toggle display of button. | 1000 | "View attachment. |
| 973 | If point in show buffer is at a button then that part is toggled. | 1001 | |
| 974 | If not at a button and PART-INDEX is non-nil point is moved to that part. | 1002 | This command displays (or hides) the attachment associated with the button |
| 975 | With nil PART-INDEX find the first button after point (search wraps around if | 1003 | under the cursor. If the cursor is not located over a button, then the cursor |
| 976 | end of buffer is reached) and toggle it." | 1004 | first moves to the next button, wrapping to the beginning of the message if |
| 1005 | necessary. This command has the advantage over related commands of working | ||
| 1006 | from the MH-Folder buffer. | ||
| 1007 | |||
| 1008 | You can also provide a numeric prefix argument PART-INDEX to view the | ||
| 1009 | attachment labeled with that number. If Emacs does not know how to display the | ||
| 1010 | attachment, then Emacs offers to save the attachment in a file." | ||
| 977 | (interactive "P") | 1011 | (interactive "P") |
| 978 | (when (consp part-index) (setq part-index (car part-index))) | 1012 | (when (consp part-index) (setq part-index (car part-index))) |
| 979 | (mh-folder-mime-action part-index #'mh-press-button t)) | 1013 | (mh-folder-mime-action part-index #'mh-press-button t)) |
| 980 | 1014 | ||
| 981 | (defun mh-folder-inline-mime-part (part-index) | 1015 | (defun mh-folder-inline-mime-part (part-index) |
| 982 | "Show the raw bytes of MIME part inline. | 1016 | "Show attachment verbatim. |
| 983 | If point in show buffer is at a mime part then that part is inlined. | 1017 | |
| 984 | If not at a mime-part and PART-INDEX is non-nil point is moved to that part. | 1018 | You can view the raw contents of an attachment with this command. This command |
| 985 | With nil PART-INDEX find the first button after point (search wraps around if | 1019 | displays (or hides) the contents of the attachment associated with the button |
| 986 | end of buffer is reached) and inline it." | 1020 | under the cursor verbatim. If the cursor is not located over a button, then |
| 1021 | the cursor first moves to the next button, wrapping to the beginning of the | ||
| 1022 | message if necessary. | ||
| 1023 | |||
| 1024 | You can also provide a numeric prefix argument PART-INDEX to view the | ||
| 1025 | attachment labeled with that number." | ||
| 987 | (interactive "P") | 1026 | (interactive "P") |
| 988 | (when (consp part-index) (setq part-index (car part-index))) | 1027 | (when (consp part-index) (setq part-index (car part-index))) |
| 989 | (mh-folder-mime-action part-index #'mh-mime-inline-part nil)) | 1028 | (mh-folder-mime-action part-index #'mh-mime-inline-part nil)) |
| 990 | 1029 | ||
| 991 | (defun mh-folder-save-mime-part (part-index) | 1030 | (defun mh-folder-save-mime-part (part-index) |
| 992 | "Save MIME part. | 1031 | "Save (output) attachment. |
| 993 | If point in show buffer is at a mime part then that part is saved. | 1032 | |
| 994 | If not at a mime-part and PART-INDEX is non-nil point is moved to that part. | 1033 | This command saves the attachment associated with the button under the cursor. |
| 995 | With nil PART-INDEX find the first button after point (search wraps around if | 1034 | If the cursor is not located over a button, then the cursor first moves to the |
| 996 | end of buffer is reached) and save it." | 1035 | next button, wrapping to the beginning of the message if necessary. |
| 1036 | |||
| 1037 | You can also provide a numeric prefix argument PART-INDEX to save the | ||
| 1038 | attachment labeled with that number. | ||
| 1039 | |||
| 1040 | This command prompts you for a filename and suggests a specific name if it is | ||
| 1041 | available." | ||
| 997 | (interactive "P") | 1042 | (interactive "P") |
| 998 | (when (consp part-index) (setq part-index (car part-index))) | 1043 | (when (consp part-index) (setq part-index (car part-index))) |
| 999 | (mh-folder-mime-action part-index #'mh-mime-save-part nil)) | 1044 | (mh-folder-mime-action part-index #'mh-mime-save-part nil)) |
| @@ -1024,10 +1069,13 @@ refiles aren't carried out." | |||
| 1024 | (cond (threaded-flag (mh-toggle-threads)) | 1069 | (cond (threaded-flag (mh-toggle-threads)) |
| 1025 | (mh-index-data (mh-index-insert-folder-headers))))) | 1070 | (mh-index-data (mh-index-insert-folder-headers))))) |
| 1026 | 1071 | ||
| 1027 | (defun mh-write-msg-to-file (msg file no-headers) | 1072 | (defun mh-write-msg-to-file (message file no-header) |
| 1028 | "Append MSG to the end of a FILE. | 1073 | "Append MESSAGE to end of FILE\\<mh-folder-mode-map>. |
| 1029 | If prefix argument NO-HEADERS is provided, write only the message body. | 1074 | |
| 1030 | Otherwise send the entire message including the headers." | 1075 | You are prompted for the filename. If the file already exists, the message is |
| 1076 | appended to it. You can also write the message to the file without the header | ||
| 1077 | by specifying a prefix argument NO-HEADER. Subsequent writes to the same file | ||
| 1078 | can be made with the command \\[mh-refile-or-write-again]." | ||
| 1031 | (interactive | 1079 | (interactive |
| 1032 | (list (mh-get-msg-num t) | 1080 | (list (mh-get-msg-num t) |
| 1033 | (let ((default-dir (if (eq 'write (car mh-last-destination-write)) | 1081 | (let ((default-dir (if (eq 'write (car mh-last-destination-write)) |
| @@ -1041,16 +1089,16 @@ Otherwise send the entire message including the headers." | |||
| 1041 | (car (cdr mh-last-destination-write)) | 1089 | (car (cdr mh-last-destination-write)) |
| 1042 | (expand-file-name "mail.out" default-dir)))) | 1090 | (expand-file-name "mail.out" default-dir)))) |
| 1043 | current-prefix-arg)) | 1091 | current-prefix-arg)) |
| 1044 | (let ((msg-file-to-output (mh-msg-filename msg)) | 1092 | (let ((msg-file-to-output (mh-msg-filename message)) |
| 1045 | (output-file (mh-expand-file-name file))) | 1093 | (output-file (mh-expand-file-name file))) |
| 1046 | (setq mh-last-destination (list 'write file (if no-headers 'no-headers)) | 1094 | (setq mh-last-destination (list 'write file (if no-header 'no-header)) |
| 1047 | mh-last-destination-write mh-last-destination) | 1095 | mh-last-destination-write mh-last-destination) |
| 1048 | (save-excursion | 1096 | (save-excursion |
| 1049 | (set-buffer (get-buffer-create mh-temp-buffer)) | 1097 | (set-buffer (get-buffer-create mh-temp-buffer)) |
| 1050 | (erase-buffer) | 1098 | (erase-buffer) |
| 1051 | (insert-file-contents msg-file-to-output) | 1099 | (insert-file-contents msg-file-to-output) |
| 1052 | (goto-char (point-min)) | 1100 | (goto-char (point-min)) |
| 1053 | (if no-headers (search-forward "\n\n")) | 1101 | (if no-header (search-forward "\n\n")) |
| 1054 | (append-to-file (point) (point-max) output-file)))) | 1102 | (append-to-file (point) (point-max) output-file)))) |
| 1055 | 1103 | ||
| 1056 | (defun mh-toggle-showing () | 1104 | (defun mh-toggle-showing () |
| @@ -1346,8 +1394,10 @@ any more unread messages." | |||
| 1346 | (mh-previous-undeleted-msg 1 wait-after-complaining-flag))) | 1394 | (mh-previous-undeleted-msg 1 wait-after-complaining-flag))) |
| 1347 | 1395 | ||
| 1348 | (defun mh-next-unread-msg (&optional count) | 1396 | (defun mh-next-unread-msg (&optional count) |
| 1349 | "Move to next unread message. | 1397 | "Display next unread message. |
| 1350 | With optional argument COUNT, COUNT-1 unread messages are skipped." | 1398 | |
| 1399 | This command can be given a prefix argument COUNT to specify how many unread | ||
| 1400 | messages to skip." | ||
| 1351 | (interactive "p") | 1401 | (interactive "p") |
| 1352 | (unless (> count 0) | 1402 | (unless (> count 0) |
| 1353 | (error "The function mh-next-unread-msg expects positive argument")) | 1403 | (error "The function mh-next-unread-msg expects positive argument")) |
| @@ -1577,7 +1627,7 @@ in the mh(1) man page): | |||
| 1577 | `<num>:+N' | 1627 | `<num>:+N' |
| 1578 | `<num>:-N' | 1628 | `<num>:-N' |
| 1579 | Up to N messages beginning with (or ending with) message num. Num may be | 1629 | Up to N messages beginning with (or ending with) message num. Num may be |
| 1580 | any of the pre-defined symbols: first, prev, cur, next or last. | 1630 | any of the predefined symbols: first, prev, cur, next or last. |
| 1581 | 1631 | ||
| 1582 | `first:N' | 1632 | `first:N' |
| 1583 | `prev:N' | 1633 | `prev:N' |
| @@ -1668,7 +1718,7 @@ messages in that region. | |||
| 1668 | (turn-on-font-lock))) ; Force font-lock in XEmacs. | 1718 | (turn-on-font-lock))) ; Force font-lock in XEmacs. |
| 1669 | 1719 | ||
| 1670 | (defun mh-toggle-mime-buttons () | 1720 | (defun mh-toggle-mime-buttons () |
| 1671 | "Toggle display of buttons for inline MIME parts." | 1721 | "Toggle option `mh-display-buttons-for-inline-parts-flag'." |
| 1672 | (interactive) | 1722 | (interactive) |
| 1673 | (setq mh-display-buttons-for-inline-parts-flag | 1723 | (setq mh-display-buttons-for-inline-parts-flag |
| 1674 | (not mh-display-buttons-for-inline-parts-flag)) | 1724 | (not mh-display-buttons-for-inline-parts-flag)) |
| @@ -2475,14 +2525,11 @@ If INCLUDE-INTERNAL-FLAG non-nil, include MH-E internal sequences in list." | |||
| 2475 | 2525 | ||
| 2476 | (gnus-define-keys (mh-ps-print-map "P" mh-folder-mode-map) | 2526 | (gnus-define-keys (mh-ps-print-map "P" mh-folder-mode-map) |
| 2477 | "?" mh-prefix-help | 2527 | "?" mh-prefix-help |
| 2478 | "A" mh-ps-print-toggle-mime | ||
| 2479 | "C" mh-ps-print-toggle-color | 2528 | "C" mh-ps-print-toggle-color |
| 2480 | "F" mh-ps-print-toggle-faces | 2529 | "F" mh-ps-print-toggle-faces |
| 2481 | "M" mh-ps-print-toggle-mime | ||
| 2482 | "f" mh-ps-print-msg-file | 2530 | "f" mh-ps-print-msg-file |
| 2483 | "l" mh-print-msg | 2531 | "l" mh-print-msg |
| 2484 | "p" mh-ps-print-msg | 2532 | "p" mh-ps-print-msg) |
| 2485 | "s" mh-ps-print-msg-show) | ||
| 2486 | 2533 | ||
| 2487 | (gnus-define-keys (mh-sequence-map "S" mh-folder-mode-map) | 2534 | (gnus-define-keys (mh-sequence-map "S" mh-folder-mode-map) |
| 2488 | "'" mh-narrow-to-tick | 2535 | "'" mh-narrow-to-tick |
| @@ -2569,9 +2616,8 @@ If INCLUDE-INTERNAL-FLAG non-nil, include MH-E internal sequences in list." | |||
| 2569 | (?F "[l]ist; [v]isit folder;\n" | 2616 | (?F "[l]ist; [v]isit folder;\n" |
| 2570 | "[n]ew messages; [']ticked messages; [s]earch; [i]ndexed search;\n" | 2617 | "[n]ew messages; [']ticked messages; [s]earch; [i]ndexed search;\n" |
| 2571 | "[p]ack; [S]ort; [r]escan; [k]ill") | 2618 | "[p]ack; [S]ort; [r]escan; [k]ill") |
| 2572 | (?P "PS [p]rint message; [l]non-PS print;\n" | 2619 | (?P "[p]rint message to [f]ile; old-style [l]pr printing;\n" |
| 2573 | "PS Print [s]how window, message to [f]ile;\n" | 2620 | "Toggle printing of [C]olors, [F]aces") |
| 2574 | "Toggle printing of [M]IME parts, [C]olor, [F]aces") | ||
| 2575 | (?S "[p]ut message in sequence, [n]arrow, [']narrow to ticked, [w]iden,\n" | 2621 | (?S "[p]ut message in sequence, [n]arrow, [']narrow to ticked, [w]iden,\n" |
| 2576 | "[s]equences, [l]ist,\n" | 2622 | "[s]equences, [l]ist,\n" |
| 2577 | "[d]elete message from sequence, [k]ill sequence") | 2623 | "[d]elete message from sequence, [k]ill sequence") |
diff --git a/lisp/mh-e/mh-funcs.el b/lisp/mh-e/mh-funcs.el index 755be4a1560..4f9adbe970b 100644 --- a/lisp/mh-e/mh-funcs.el +++ b/lisp/mh-e/mh-funcs.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; mh-funcs.el --- MH-E functions not everyone will use right away | 1 | ;;; mh-funcs.el --- MH-E functions not everyone will use right away |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, | 3 | ;; Copyright (C) 1993, 1995, |
| 4 | ;; 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | 4 | ;; 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -39,15 +39,6 @@ | |||
| 39 | (mh-require-cl) | 39 | (mh-require-cl) |
| 40 | (require 'mh-e) | 40 | (require 'mh-e) |
| 41 | 41 | ||
| 42 | ;;; Customization | ||
| 43 | |||
| 44 | (defvar mh-sortm-args nil | ||
| 45 | "Extra arguments to have \\[mh-sort-folder] pass to the \"sortm\" command. | ||
| 46 | The arguments are passed to sortm if \\[mh-sort-folder] is given a | ||
| 47 | prefix argument. Normally default arguments to sortm are specified in the | ||
| 48 | MH profile. | ||
| 49 | For example, '(\"-nolimit\" \"-textfield\" \"subject\") is a useful setting.") | ||
| 50 | |||
| 51 | ;;; Scan Line Formats | 42 | ;;; Scan Line Formats |
| 52 | 43 | ||
| 53 | (defvar mh-note-copied "C" | 44 | (defvar mh-note-copied "C" |
| @@ -60,9 +51,19 @@ For example, '(\"-nolimit\" \"-textfield\" \"subject\") is a useful setting.") | |||
| 60 | 51 | ||
| 61 | ;;;###mh-autoload | 52 | ;;;###mh-autoload |
| 62 | (defun mh-burst-digest () | 53 | (defun mh-burst-digest () |
| 63 | "Burst apart the current message, which should be a digest. | 54 | "Break up digest into separate messages\\<mh-folder-mode-map>. |
| 64 | The message is replaced by its table of contents and the messages from the | 55 | |
| 65 | digest are inserted into the folder after that message." | 56 | This command uses the MH command \"burst\" to break out each message in the |
| 57 | digest into its own message. Using this command, you can quickly delete | ||
| 58 | unwanted messages, like this: Once the digest is split up, toggle out of | ||
| 59 | MH-Folder Show mode with \\[mh-toggle-showing] so that the scan lines fill the | ||
| 60 | screen and messages aren't displayed. Then use \\[mh-delete-msg] to quickly | ||
| 61 | delete messages that you don't want to read (based on the \"Subject:\" header | ||
| 62 | field). You can also burst the digest to reply directly to the people who | ||
| 63 | posted the messages in the digest. One problem you may encounter is that the | ||
| 64 | \"From:\" header fields are preceded with a \">\" so that your reply can't | ||
| 65 | create the \"To:\" field correctly. In this case, you must correct the \"To:\" | ||
| 66 | field yourself." | ||
| 66 | (interactive) | 67 | (interactive) |
| 67 | (let ((digest (mh-get-msg-num t))) | 68 | (let ((digest (mh-get-msg-num t))) |
| 68 | (mh-process-or-undo-commands mh-current-folder) | 69 | (mh-process-or-undo-commands mh-current-folder) |
| @@ -186,10 +187,12 @@ entire folder." | |||
| 186 | (mh-regenerate-headers range)) | 187 | (mh-regenerate-headers range)) |
| 187 | 188 | ||
| 188 | ;;;###mh-autoload | 189 | ;;;###mh-autoload |
| 189 | (defun mh-pipe-msg (command include-headers) | 190 | (defun mh-pipe-msg (command include-header) |
| 190 | "Pipe the current message through the given shell COMMAND. | 191 | "Pipe message through shell command COMMAND. |
| 191 | If INCLUDE-HEADERS (prefix argument) is provided, send the entire message. | 192 | |
| 192 | Otherwise just send the message's body without the headers." | 193 | You are prompted for the Unix command through which you wish to run your |
| 194 | message. If you give an argument INCLUDE-HEADER to this command, the message | ||
| 195 | header is included in the text passed to the command." | ||
| 193 | (interactive | 196 | (interactive |
| 194 | (list (read-string "Shell command on message: ") current-prefix-arg)) | 197 | (list (read-string "Shell command on message: ") current-prefix-arg)) |
| 195 | (let ((msg-file-to-pipe (mh-msg-filename (mh-get-msg-num t))) | 198 | (let ((msg-file-to-pipe (mh-msg-filename (mh-get-msg-num t))) |
| @@ -199,13 +202,13 @@ Otherwise just send the message's body without the headers." | |||
| 199 | (erase-buffer) | 202 | (erase-buffer) |
| 200 | (insert-file-contents msg-file-to-pipe) | 203 | (insert-file-contents msg-file-to-pipe) |
| 201 | (goto-char (point-min)) | 204 | (goto-char (point-min)) |
| 202 | (if (not include-headers) (search-forward "\n\n")) | 205 | (if (not include-header) (search-forward "\n\n")) |
| 203 | (let ((default-directory message-directory)) | 206 | (let ((default-directory message-directory)) |
| 204 | (shell-command-on-region (point) (point-max) command nil))))) | 207 | (shell-command-on-region (point) (point-max) command nil))))) |
| 205 | 208 | ||
| 206 | ;;;###mh-autoload | 209 | ;;;###mh-autoload |
| 207 | (defun mh-page-digest () | 210 | (defun mh-page-digest () |
| 208 | "Advance displayed message to next digested message." | 211 | "Display next message in digest." |
| 209 | (interactive) | 212 | (interactive) |
| 210 | (mh-in-show-buffer (mh-show-buffer) | 213 | (mh-in-show-buffer (mh-show-buffer) |
| 211 | ;; Go to top of screen (in case user moved point). | 214 | ;; Go to top of screen (in case user moved point). |
| @@ -222,7 +225,7 @@ Otherwise just send the message's body without the headers." | |||
| 222 | 225 | ||
| 223 | ;;;###mh-autoload | 226 | ;;;###mh-autoload |
| 224 | (defun mh-page-digest-backwards () | 227 | (defun mh-page-digest-backwards () |
| 225 | "Back up displayed message to previous digested message." | 228 | "Display previous message in digest." |
| 226 | (interactive) | 229 | (interactive) |
| 227 | (mh-in-show-buffer (mh-show-buffer) | 230 | (mh-in-show-buffer (mh-show-buffer) |
| 228 | ;; Go to top of screen (in case user moved point). | 231 | ;; Go to top of screen (in case user moved point). |
| @@ -274,10 +277,13 @@ argument EXTRA-ARGS is given." | |||
| 274 | 277 | ||
| 275 | ;;;###mh-autoload | 278 | ;;;###mh-autoload |
| 276 | (defun mh-store-msg (directory) | 279 | (defun mh-store-msg (directory) |
| 277 | "Store the file(s) contained in the current message into DIRECTORY. | 280 | "Unpack message created with `uudecode' or `shar'. |
| 278 | The message can contain a shar file or uuencoded file. | 281 | |
| 279 | Default directory is the last directory used, or initially the value of | 282 | The default DIRECTORY for extraction is the current directory; however, you |
| 280 | `mh-store-default-directory' or the current directory." | 283 | have a chance to specify a different extraction directory. The next time you |
| 284 | use this command, the default directory is the last directory you used. If you | ||
| 285 | would like to change the initial default directory, customize the option | ||
| 286 | `mh-store-default-directory'." | ||
| 281 | (interactive (list (let ((udir (or mh-store-default-directory | 287 | (interactive (list (let ((udir (or mh-store-default-directory |
| 282 | default-directory))) | 288 | default-directory))) |
| 283 | (read-file-name "Store message in directory: " | 289 | (read-file-name "Store message in directory: " |
diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el index 14acfd7765c..3d55c5cded1 100644 --- a/lisp/mh-e/mh-mime.el +++ b/lisp/mh-e/mh-mime.el | |||
| @@ -799,11 +799,15 @@ This is used to decide if smileys and graphical emphasis will be displayed." | |||
| 799 | Set from last use.") | 799 | Set from last use.") |
| 800 | 800 | ||
| 801 | ;;;###mh-autoload | 801 | ;;;###mh-autoload |
| 802 | (defun mh-mime-save-parts (arg) | 802 | (defun mh-mime-save-parts (prompt) |
| 803 | "Store the MIME parts of the current message. | 803 | "Save attachments. |
| 804 | If ARG, prompt for directory, else use that specified by the variable | 804 | |
| 805 | `mh-mime-save-parts-default-directory'. These directories may be superseded by | 805 | You can save all of the attachments at once with this command. The attachments |
| 806 | MH profile components, since this function calls on mhstore to do the work." | 806 | are saved in the directory specified by the option |
| 807 | `mh-mime-save-parts-default-directory' unless you use a prefix argument PROMPT | ||
| 808 | in which case you are prompted for the directory. These directories may be | ||
| 809 | superseded by MH profile components, since this function calls on | ||
| 810 | \"mhstore\" (\"mhn\") to do the work." | ||
| 807 | (interactive "P") | 811 | (interactive "P") |
| 808 | (let ((msg (if (eq major-mode 'mh-show-mode) | 812 | (let ((msg (if (eq major-mode 'mh-show-mode) |
| 809 | (mh-show-buffer-message-number) | 813 | (mh-show-buffer-message-number) |
| @@ -814,12 +818,12 @@ MH profile components, since this function calls on mhstore to do the work." | |||
| 814 | (command (if (mh-variant-p 'nmh) "mhstore" "mhn")) | 818 | (command (if (mh-variant-p 'nmh) "mhstore" "mhn")) |
| 815 | (directory | 819 | (directory |
| 816 | (cond | 820 | (cond |
| 817 | ((and (or arg | 821 | ((and (or prompt |
| 818 | (equal nil mh-mime-save-parts-default-directory) | 822 | (equal nil mh-mime-save-parts-default-directory) |
| 819 | (equal t mh-mime-save-parts-default-directory)) | 823 | (equal t mh-mime-save-parts-default-directory)) |
| 820 | (not mh-mime-save-parts-directory)) | 824 | (not mh-mime-save-parts-directory)) |
| 821 | (read-file-name "Store in directory: " nil nil t nil)) | 825 | (read-file-name "Store in directory: " nil nil t nil)) |
| 822 | ((and (or arg | 826 | ((and (or prompt |
| 823 | (equal t mh-mime-save-parts-default-directory)) | 827 | (equal t mh-mime-save-parts-default-directory)) |
| 824 | mh-mime-save-parts-directory) | 828 | mh-mime-save-parts-directory) |
| 825 | (read-file-name (format | 829 | (read-file-name (format |
| @@ -877,11 +881,13 @@ If message has been encoded for transfer take that into account." | |||
| 877 | 881 | ||
| 878 | ;;;###mh-autoload | 882 | ;;;###mh-autoload |
| 879 | (defun mh-toggle-mh-decode-mime-flag () | 883 | (defun mh-toggle-mh-decode-mime-flag () |
| 880 | "Toggle whether MH-E should decode MIME or not." | 884 | "Toggle the value of `mh-decode-mime-flag'." |
| 881 | (interactive) | 885 | (interactive) |
| 882 | (setq mh-decode-mime-flag (not mh-decode-mime-flag)) | 886 | (setq mh-decode-mime-flag (not mh-decode-mime-flag)) |
| 883 | (mh-show nil t) | 887 | (mh-show nil t) |
| 884 | (message "(setq mh-decode-mime-flag %s)" mh-decode-mime-flag)) | 888 | (message "%s" (if mh-decode-mime-flag |
| 889 | "Processing attachments normally" | ||
| 890 | "Displaying raw message"))) | ||
| 885 | 891 | ||
| 886 | ;;;###mh-autoload | 892 | ;;;###mh-autoload |
| 887 | (defun mh-decode-message-header () | 893 | (defun mh-decode-message-header () |
| @@ -1184,7 +1190,7 @@ like \"K v\" which operate on individual MIME parts." | |||
| 1184 | (goto-char (point-min)) | 1190 | (goto-char (point-min)) |
| 1185 | (delete-char 1)) | 1191 | (delete-char 1)) |
| 1186 | (when (equal (mm-handle-media-supertype handle) "text") | 1192 | (when (equal (mm-handle-media-supertype handle) "text") |
| 1187 | (when (eq mh-highlight-citation-p 'gnus) | 1193 | (when (eq mh-highlight-citation-style 'gnus) |
| 1188 | (mh-gnus-article-highlight-citation)) | 1194 | (mh-gnus-article-highlight-citation)) |
| 1189 | (mh-display-smileys) | 1195 | (mh-display-smileys) |
| 1190 | (mh-display-emphasis) | 1196 | (mh-display-emphasis) |
| @@ -1205,9 +1211,10 @@ like \"K v\" which operate on individual MIME parts." | |||
| 1205 | 1211 | ||
| 1206 | ;;;###mh-autoload | 1212 | ;;;###mh-autoload |
| 1207 | (defun mh-press-button () | 1213 | (defun mh-press-button () |
| 1208 | "Press MIME button. | 1214 | "View contents of button. |
| 1209 | If the MIME part is visible then it is removed. Otherwise the part is | 1215 | |
| 1210 | displayed." | 1216 | This command is a toggle so if you use it again on the same attachment, the |
| 1217 | attachment is hidden." | ||
| 1211 | (interactive) | 1218 | (interactive) |
| 1212 | (let ((mm-inline-media-tests mh-mm-inline-media-tests) | 1219 | (let ((mm-inline-media-tests mh-mm-inline-media-tests) |
| 1213 | (data (get-text-property (point) 'mh-data)) | 1220 | (data (get-text-property (point) 'mh-data)) |
| @@ -1279,7 +1286,23 @@ button." | |||
| 1279 | 1286 | ||
| 1280 | ;;;###mh-autoload | 1287 | ;;;###mh-autoload |
| 1281 | (defun mh-display-with-external-viewer (part-index) | 1288 | (defun mh-display-with-external-viewer (part-index) |
| 1282 | "View MIME PART-INDEX externally." | 1289 | "View attachment externally. |
| 1290 | |||
| 1291 | If Emacs does not know how to view an attachment, you could save it into a | ||
| 1292 | file and then run some program to open it. It is easier, however, to launch | ||
| 1293 | the program directly from MH-E with this command. While you'll most likely use | ||
| 1294 | this to view spreadsheets and documents, it is also useful to use your browser | ||
| 1295 | to view HTML attachments with higher fidelity than what Emacs can provide. | ||
| 1296 | |||
| 1297 | This command displays the attachment associated with the button under the | ||
| 1298 | cursor. If the cursor is not located over a button, then the cursor first | ||
| 1299 | moves to the next button, wrapping to the beginning of the message if | ||
| 1300 | necessary. You can provide a numeric prefix argument PART-INDEX to view the | ||
| 1301 | attachment labeled with that number. | ||
| 1302 | |||
| 1303 | This command tries to provide a reasonable default for the viewer by calling | ||
| 1304 | the Emacs function `mailcap-mime-info'. This function usually reads the file | ||
| 1305 | \"/etc/mailcap\"." | ||
| 1283 | (interactive "P") | 1306 | (interactive "P") |
| 1284 | (when (consp part-index) (setq part-index (car part-index))) | 1307 | (when (consp part-index) (setq part-index (car part-index))) |
| 1285 | (mh-folder-mime-action | 1308 | (mh-folder-mime-action |
| @@ -1290,7 +1313,9 @@ button." | |||
| 1290 | (methods (mapcar (lambda (x) (list (cdr (assoc 'viewer x)))) | 1313 | (methods (mapcar (lambda (x) (list (cdr (assoc 'viewer x)))) |
| 1291 | (mailcap-mime-info type 'all))) | 1314 | (mailcap-mime-info type 'all))) |
| 1292 | (def (caar methods)) | 1315 | (def (caar methods)) |
| 1293 | (prompt (format "Viewer: %s" (if def (format "[%s] " def) ""))) | 1316 | (prompt (format "Viewer%s: " (if def |
| 1317 | (format " (default %s)" def) | ||
| 1318 | ""))) | ||
| 1294 | (method (completing-read prompt methods nil nil nil nil def)) | 1319 | (method (completing-read prompt methods nil nil nil nil def)) |
| 1295 | (folder mh-show-folder-buffer) | 1320 | (folder mh-show-folder-buffer) |
| 1296 | (buffer-read-only nil)) | 1321 | (buffer-read-only nil)) |
| @@ -1464,7 +1489,7 @@ message multiple times." | |||
| 1464 | (mh-decode-message-header) | 1489 | (mh-decode-message-header) |
| 1465 | (mh-show-addr) | 1490 | (mh-show-addr) |
| 1466 | ;; The other highlighting types don't need anything special | 1491 | ;; The other highlighting types don't need anything special |
| 1467 | (when (eq mh-highlight-citation-p 'gnus) | 1492 | (when (eq mh-highlight-citation-style 'gnus) |
| 1468 | (mh-gnus-article-highlight-citation)) | 1493 | (mh-gnus-article-highlight-citation)) |
| 1469 | (goto-char (point-min)) | 1494 | (goto-char (point-min)) |
| 1470 | (insert "\n------- Forwarded Message\n\n") | 1495 | (insert "\n------- Forwarded Message\n\n") |
diff --git a/lisp/mh-e/mh-print.el b/lisp/mh-e/mh-print.el index 7190b87c853..8cf91f08d74 100644 --- a/lisp/mh-e/mh-print.el +++ b/lisp/mh-e/mh-print.el | |||
| @@ -25,13 +25,6 @@ | |||
| 25 | ;; Boston, MA 02110-1301, USA. | 25 | ;; Boston, MA 02110-1301, USA. |
| 26 | 26 | ||
| 27 | ;;; Commentary: | 27 | ;;; Commentary: |
| 28 | ;; Pp Print to lpr | Default inline settings | ||
| 29 | ;; Pf Print to file | Generate a postscript file | ||
| 30 | ;; Ps Print show buffer | Fails if no show buffer | ||
| 31 | ;; | ||
| 32 | ;; PA Toggle inline/attachments | ||
| 33 | ;; PC Toggle color | ||
| 34 | ;; PF Toggle faces | ||
| 35 | 28 | ||
| 36 | ;;; Change Log: | 29 | ;;; Change Log: |
| 37 | 30 | ||
| @@ -44,125 +37,120 @@ | |||
| 44 | (require 'mh-funcs) | 37 | (require 'mh-funcs) |
| 45 | (eval-when-compile (require 'mh-seq)) | 38 | (eval-when-compile (require 'mh-seq)) |
| 46 | 39 | ||
| 47 | (defvar mh-ps-print-mime nil | ||
| 48 | "Control printing of MIME parts. | ||
| 49 | The three possible states are: | ||
| 50 | 1. nil to not print inline parts | ||
| 51 | 2. t to print inline parts | ||
| 52 | 3. non-zero to print inline parts and attachments") | ||
| 53 | |||
| 54 | (defvar mh-ps-print-color-option ps-print-color-p | 40 | (defvar mh-ps-print-color-option ps-print-color-p |
| 55 | "MH-E's version of `\\[ps-print-color-p]'.") | 41 | "Specify how buffer's text color is printed. |
| 42 | |||
| 43 | Valid values are: | ||
| 44 | |||
| 45 | nil - Do not print colors. | ||
| 46 | t - Print colors. | ||
| 47 | black-white - Print colors on black/white printer. | ||
| 48 | See also `ps-black-white-faces'. | ||
| 49 | |||
| 50 | Any other value is treated as t. This variable is initialized from | ||
| 51 | `ps-print-color-p'.") | ||
| 56 | 52 | ||
| 57 | (defvar mh-ps-print-func 'ps-spool-buffer-with-faces | 53 | (defvar mh-ps-print-func 'ps-spool-buffer-with-faces |
| 58 | "Function to use to spool a buffer. | 54 | "Function to use to spool a buffer. |
| 55 | |||
| 59 | Sensible choices are the functions `ps-spool-buffer' and | 56 | Sensible choices are the functions `ps-spool-buffer' and |
| 60 | `ps-spool-buffer-with-faces'.") | 57 | `ps-spool-buffer-with-faces'.") |
| 61 | 58 | ||
| 62 | ;; XXX - If buffer is already being displayed, use that buffer | ||
| 63 | ;; XXX - What about showing MIME content? | ||
| 64 | ;; XXX - Default print buffer is bogus | ||
| 65 | (defun mh-ps-spool-buffer (buffer) | 59 | (defun mh-ps-spool-buffer (buffer) |
| 66 | "Send BUFFER to printer queue." | 60 | "Spool BUFFER." |
| 67 | (save-excursion | 61 | (save-excursion |
| 68 | (set-buffer buffer) | 62 | (set-buffer buffer) |
| 69 | (let ((ps-print-color-p mh-ps-print-color-option) | 63 | (let ((ps-print-color-p mh-ps-print-color-option) |
| 70 | (ps-left-header | 64 | (ps-left-header |
| 71 | (list | 65 | (list |
| 72 | (concat "(" | 66 | (concat "(" (mh-get-header-field "Subject:") ")") |
| 73 | (mh-get-header-field "Subject:") ")") | 67 | (concat "(" (mh-get-header-field "From:") ")"))) |
| 74 | (concat "(" | 68 | (ps-right-header |
| 75 | (mh-get-header-field "From:") ")"))) | 69 | (list |
| 76 | (ps-right-header | 70 | "/pagenumberstring load" |
| 77 | (list | 71 | (concat "(" (mh-get-header-field "Date:") ")")))) |
| 78 | "/pagenumberstring load" | 72 | (funcall mh-ps-print-func)))) |
| 79 | (concat "(" | 73 | |
| 80 | (mh-get-header-field "Date:") ")")))) | 74 | (defun mh-ps-spool-msg (msg) |
| 81 | (funcall mh-ps-print-func)))) | 75 | "Spool MSG." |
| 82 | 76 | (let* ((folder mh-current-folder) | |
| 83 | (defun mh-ps-spool-a-msg (msg buffer) | 77 | (buffer (mh-in-show-buffer (mh-show-buffer) |
| 84 | "Print MSG. | 78 | (if (not (equal (mh-msg-filename msg folder) |
| 85 | First the message is decoded in BUFFER before the results are sent to the | 79 | buffer-file-name)) |
| 86 | printer." | 80 | (get-buffer-create mh-temp-buffer))))) |
| 87 | (let ((mh-show-buffer mh-show-buffer) | 81 | (unwind-protect |
| 88 | (folder mh-current-folder) | 82 | (save-excursion |
| 89 | ;; The following is commented out because | 83 | (if buffer |
| 90 | ;; `clean-message-header-flag' isn't used anywhere. I | 84 | (let ((mh-show-buffer buffer)) |
| 91 | ;; commented rather than deleted in case somebody had some | 85 | (mh-display-msg msg folder))) |
| 92 | ;; future plans for it. --SY. | 86 | (mh-ps-spool-buffer (if buffer buffer mh-show-buffer))) |
| 93 | ;(clean-message-header-flag mh-clean-message-header-flag) | 87 | (if buffer |
| 94 | ) | 88 | (kill-buffer buffer))))) |
| 89 | |||
| 90 | (defun mh-ps-print-range (range file) | ||
| 91 | "Print the messages in RANGE to FILE. | ||
| 92 | This is the function that actually does the work. | ||
| 93 | If FILE is nil, then the messages are spooled to the printer." | ||
| 94 | (mh-iterate-on-range msg range | ||
| 95 | (unwind-protect | 95 | (unwind-protect |
| 96 | (progn | 96 | (mh-ps-spool-msg msg)) |
| 97 | (setq mh-show-buffer buffer) | 97 | (mh-notate msg mh-note-printed mh-cmd-note)) |
| 98 | (save-excursion | 98 | (ps-despool file)) |
| 99 | ;; | 99 | |
| 100 | ;; XXX - Use setting of mh-ps-print-mime | 100 | (defun mh-ps-print-preprint (prefix-arg) |
| 101 | ;; | 101 | "Provide a better default file name for `ps-print-preprint'. |
| 102 | (mh-display-msg msg folder) | 102 | Pass along the PREFIX-ARG to it." |
| 103 | (mh-ps-spool-buffer mh-show-buffer) | 103 | (let ((buffer-file-name (format "mh-%s" (substring (buffer-name) 1)))) |
| 104 | (kill-buffer mh-show-buffer)))))) | 104 | (ps-print-preprint prefix-arg))) |
| 105 | 105 | ||
| 106 | ;;;###mh-autoload | 106 | ;;;###mh-autoload |
| 107 | (defun mh-ps-print-msg (range) | 107 | (defun mh-ps-print-msg (range) |
| 108 | "Print the messages in RANGE. | 108 | "Print the messages in RANGE\\<mh-folder-mode-map>. |
| 109 | 109 | ||
| 110 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | 110 | Check the documentation of `mh-interactive-range' to see how RANGE is read in |
| 111 | interactive use." | 111 | interactive use. |
| 112 | (interactive (list (mh-interactive-range "Print"))) | ||
| 113 | (mh-iterate-on-range msg range | ||
| 114 | (let ((buffer (get-buffer-create mh-temp-buffer))) | ||
| 115 | (unwind-protect | ||
| 116 | (mh-ps-spool-a-msg msg buffer) | ||
| 117 | (kill-buffer buffer))) | ||
| 118 | (mh-notate nil mh-note-printed mh-cmd-note)) | ||
| 119 | (ps-despool nil)) | ||
| 120 | 112 | ||
| 121 | (defun mh-ps-print-preprint (prefix-arg) | 113 | This command will print inline text attachments but will not decrypt messages. |
| 122 | "Replacement for `ps-print-preprint'. | 114 | However, when a message is displayed in an MH-Show buffer, then that buffer is |
| 123 | The original function does not handle the fact that MH folders are directories | 115 | used verbatim for printing with the caveat that only text attachments, if |
| 124 | nicely, when generating the default file name. This function works around | 116 | opened inline, are printed. Therefore, encrypted messages can be printed by |
| 125 | that. The function is passed the interactive PREFIX-ARG." | 117 | showing and decrypting them first. |
| 126 | (let ((buffer-file-name (format "/tmp/%s" (substring (buffer-name) 1)))) | 118 | |
| 127 | (ps-print-preprint prefix-arg))) | 119 | MH-E uses the \"ps-print\" package to do the printing, so you can customize |
| 120 | the printing further by going to the `ps-print' customization group. This | ||
| 121 | command does not use the options `mh-lpr-command-format' or | ||
| 122 | `mh-print-background-flag'. See also the commands \\[mh-ps-print-toggle-color] | ||
| 123 | and \\[mh-ps-print-toggle-faces]." | ||
| 124 | (interactive (list (mh-interactive-range "Print"))) | ||
| 125 | (mh-ps-print-range range nil)) | ||
| 128 | 126 | ||
| 129 | ;;;###mh-autoload | 127 | ;;;###mh-autoload |
| 130 | (defun mh-ps-print-msg-file (file range) | 128 | (defun mh-ps-print-msg-file (range file) |
| 131 | "Print to FILE the messages in RANGE. | 129 | "Print the messages in RANGE to FILE\\<mh-folder-mode-map>. |
| 132 | 130 | ||
| 133 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | 131 | Check the documentation of `mh-interactive-range' to see how RANGE is read in |
| 134 | interactive use." | 132 | interactive use. |
| 135 | (interactive (list | ||
| 136 | (mh-ps-print-preprint 1) | ||
| 137 | (mh-interactive-range "Print"))) | ||
| 138 | (mh-iterate-on-range msg range | ||
| 139 | (let ((buffer (get-buffer-create mh-temp-buffer))) | ||
| 140 | (unwind-protect | ||
| 141 | (mh-ps-spool-a-msg msg buffer) | ||
| 142 | (kill-buffer buffer))) | ||
| 143 | (mh-notate nil mh-note-printed mh-cmd-note)) | ||
| 144 | (ps-despool file)) | ||
| 145 | 133 | ||
| 146 | ;;;###mh-autoload | 134 | This command will print inline text attachments but will not decrypt messages. |
| 147 | (defun mh-ps-print-msg-show (file) | 135 | However, when a message is displayed in an MH-Show buffer, then that buffer is |
| 148 | "Print current show buffer to FILE." | 136 | used verbatim for printing with the caveat that only text attachments, if |
| 149 | (interactive (list (mh-ps-print-preprint current-prefix-arg))) | 137 | opened inline, are printed. Therefore, encrypted messages can be printed by |
| 150 | (let ((msg (mh-get-msg-num t)) | 138 | showing and decrypting them first. |
| 151 | (folder mh-current-folder) | 139 | |
| 152 | (show-buffer mh-show-buffer) | 140 | MH-E uses the \"ps-print\" package to do the printing, so you can customize |
| 153 | (show-window (get-buffer-window mh-show-buffer))) | 141 | the printing further by going to the `ps-print' customization group. This |
| 154 | (if (and show-buffer show-window) | 142 | command does not use the options `mh-lpr-command-format' or |
| 155 | (mh-in-show-buffer (show-buffer) | 143 | `mh-print-background-flag'. See also the commands \\[mh-ps-print-toggle-color] |
| 156 | (if (equal (mh-msg-filename msg folder) buffer-file-name) | 144 | and \\[mh-ps-print-toggle-faces]." |
| 157 | (progn | 145 | (interactive (list (mh-interactive-range "Print") (mh-ps-print-preprint 1))) |
| 158 | (mh-ps-spool-buffer show-buffer) | 146 | (mh-ps-print-range range file)) |
| 159 | (ps-despool file)) | ||
| 160 | (message "Current message is not being shown(1)"))) | ||
| 161 | (message "Current message is not being shown(2)")))) | ||
| 162 | 147 | ||
| 163 | ;;;###mh-autoload | 148 | ;;;###mh-autoload |
| 164 | (defun mh-ps-print-toggle-faces () | 149 | (defun mh-ps-print-toggle-faces () |
| 165 | "Toggle whether printing is done with faces or not." | 150 | "Toggle whether printing is done with faces or not. |
| 151 | |||
| 152 | When faces are enabled, the printed message will look very similar to the | ||
| 153 | message in the MH-Show buffer." | ||
| 166 | (interactive) | 154 | (interactive) |
| 167 | (if (eq mh-ps-print-func 'ps-spool-buffer-with-faces) | 155 | (if (eq mh-ps-print-func 'ps-spool-buffer-with-faces) |
| 168 | (progn | 156 | (progn |
| @@ -173,7 +161,15 @@ interactive use." | |||
| 173 | 161 | ||
| 174 | ;;;###mh-autoload | 162 | ;;;###mh-autoload |
| 175 | (defun mh-ps-print-toggle-color () | 163 | (defun mh-ps-print-toggle-color () |
| 176 | "Toggle whether color is used in printing messages." | 164 | "Toggle whether color is used in printing messages. |
| 165 | |||
| 166 | Colors are emulated on black-and-white printers with shades of gray. This | ||
| 167 | might produce illegible output, even if your screen colors only use shades of | ||
| 168 | gray. If this is the case, try using this command to toggle between color, no | ||
| 169 | color, and a black and white representation of the colors and see which works | ||
| 170 | best. You change this setting permanently by customizing the option | ||
| 171 | `ps-print-color-p'." | ||
| 172 | |||
| 177 | (interactive) | 173 | (interactive) |
| 178 | (if (eq mh-ps-print-color-option nil) | 174 | (if (eq mh-ps-print-color-option nil) |
| 179 | (progn | 175 | (progn |
| @@ -186,36 +182,18 @@ interactive use." | |||
| 186 | (setq mh-ps-print-color-option nil) | 182 | (setq mh-ps-print-color-option nil) |
| 187 | (message "Colors will not be printed")))) | 183 | (message "Colors will not be printed")))) |
| 188 | 184 | ||
| 189 | ;;; XXX: Check option 3. Documentation doesn't sound right. | ||
| 190 | ;;;###mh-autoload | ||
| 191 | (defun mh-ps-print-toggle-mime () | ||
| 192 | "Cycle through available choices on how MIME parts should be printed. | ||
| 193 | The available settings are: | ||
| 194 | 1. Print only inline MIME parts. | ||
| 195 | 2. Print all MIME parts. | ||
| 196 | 3. Print no MIME parts." | ||
| 197 | (interactive) | ||
| 198 | (if (eq mh-ps-print-mime nil) | ||
| 199 | (progn | ||
| 200 | (setq mh-ps-print-mime t) | ||
| 201 | (message "Inline parts will be printed, attachments will not be printed")) | ||
| 202 | (if (eq mh-ps-print-mime t) | ||
| 203 | (progn | ||
| 204 | (setq mh-ps-print-mime 1) | ||
| 205 | (message "Both Inline parts and attachments will be printed")) | ||
| 206 | (setq mh-ps-print-mime nil) | ||
| 207 | (message "Neither inline parts nor attachments will be printed")))) | ||
| 208 | |||
| 209 | ;;; Old non-PS based printing | 185 | ;;; Old non-PS based printing |
| 210 | ;;;###mh-autoload | 186 | ;;;###mh-autoload |
| 211 | (defun mh-print-msg (range) | 187 | (defun mh-print-msg (range) |
| 212 | "Print RANGE on printer. | 188 | "Print the messages in RANGE the old fashioned way\\<mh-folder-mode-map>. |
| 189 | |||
| 190 | The message is formatted with \"mhl\" (see option `mh-mhl-format-file') and | ||
| 191 | printed with the \"lpr\" command (see option `mh-lpr-command-format'). | ||
| 213 | 192 | ||
| 214 | Check the documentation of `mh-interactive-range' to see how RANGE is read in | 193 | Check the documentation of `mh-interactive-range' to see how RANGE is read in |
| 215 | interactive use. | 194 | interactive use. |
| 216 | 195 | ||
| 217 | The variable `mh-lpr-command-format' is used to generate the print command. | 196 | Consider using \\[mh-ps-print-msg] instead." |
| 218 | The messages are formatted by mhl. See the variable `mhl-formfile'." | ||
| 219 | (interactive (list (mh-interactive-range "Print"))) | 197 | (interactive (list (mh-interactive-range "Print"))) |
| 220 | (message "Printing...") | 198 | (message "Printing...") |
| 221 | (let (msgs) | 199 | (let (msgs) |
| @@ -247,8 +225,8 @@ The messages are formatted by mhl. See the variable `mhl-formfile'." | |||
| 247 | (dolist (msg msgs) | 225 | (dolist (msg msgs) |
| 248 | (let* ((mhl-command (format "%s %s %s" | 226 | (let* ((mhl-command (format "%s %s %s" |
| 249 | (expand-file-name "mhl" mh-lib-progs) | 227 | (expand-file-name "mhl" mh-lib-progs) |
| 250 | (if mhl-formfile | 228 | (if mh-mhl-format-file |
| 251 | (format " -form %s" mhl-formfile) | 229 | (format " -form %s" mh-mhl-format-file) |
| 252 | "") | 230 | "") |
| 253 | (mh-msg-filename msg))) | 231 | (mh-msg-filename msg))) |
| 254 | (lpr-command | 232 | (lpr-command |
diff --git a/lisp/mh-e/mh-utils.el b/lisp/mh-e/mh-utils.el index 169ccf2a0d5..9de3636169e 100644 --- a/lisp/mh-e/mh-utils.el +++ b/lisp/mh-e/mh-utils.el | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | ;;; mh-utils.el --- MH-E code needed for both sending and reading | 1 | \;;; mh-utils.el --- MH-E code needed for both sending and reading |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, 1997, | 3 | ;; Copyright (C) 1993, 1995, 1997, |
| 4 | ;; 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. | 4 | ;; 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| @@ -414,10 +414,11 @@ Argument LIMIT limits search." | |||
| 414 | 414 | ||
| 415 | (defun mh-show-font-lock-fontify-region (beg end loudly) | 415 | (defun mh-show-font-lock-fontify-region (beg end loudly) |
| 416 | "Limit font-lock in `mh-show-mode' to the header. | 416 | "Limit font-lock in `mh-show-mode' to the header. |
| 417 | Used when `mh-highlight-citation-p' is set to \"'gnus\", leaving the body to | 417 | |
| 418 | be dealt with by gnus highlighting. The region between BEG and END is given | 418 | Used when the option `mh-highlight-citation-style' is set to \"Gnus\", leaving |
| 419 | over to be fontified and LOUDLY controls if a user sees a message about the | 419 | the body to be dealt with by Gnus highlighting. The region between BEG and END |
| 420 | fontification operation." | 420 | is given over to be fontified and LOUDLY controls if a user sees a message |
| 421 | about the fontification operation." | ||
| 421 | (let ((header-end (mh-mail-header-end))) | 422 | (let ((header-end (mh-mail-header-end))) |
| 422 | (cond | 423 | (cond |
| 423 | ((and (< beg header-end)(< end header-end)) | 424 | ((and (< beg header-end)(< end header-end)) |
| @@ -874,12 +875,10 @@ still visible.\n") | |||
| 874 | (mh-defun-show-buffer mh-show-index-sequenced-messages | 875 | (mh-defun-show-buffer mh-show-index-sequenced-messages |
| 875 | mh-index-sequenced-messages) | 876 | mh-index-sequenced-messages) |
| 876 | (mh-defun-show-buffer mh-show-catchup mh-catchup) | 877 | (mh-defun-show-buffer mh-show-catchup mh-catchup) |
| 877 | (mh-defun-show-buffer mh-show-ps-print-toggle-mime mh-ps-print-toggle-mime) | ||
| 878 | (mh-defun-show-buffer mh-show-ps-print-toggle-color mh-ps-print-toggle-color) | 878 | (mh-defun-show-buffer mh-show-ps-print-toggle-color mh-ps-print-toggle-color) |
| 879 | (mh-defun-show-buffer mh-show-ps-print-toggle-faces mh-ps-print-toggle-faces) | 879 | (mh-defun-show-buffer mh-show-ps-print-toggle-faces mh-ps-print-toggle-faces) |
| 880 | (mh-defun-show-buffer mh-show-ps-print-msg-file mh-ps-print-msg-file) | 880 | (mh-defun-show-buffer mh-show-ps-print-msg-file mh-ps-print-msg-file) |
| 881 | (mh-defun-show-buffer mh-show-ps-print-msg mh-ps-print-msg) | 881 | (mh-defun-show-buffer mh-show-ps-print-msg mh-ps-print-msg) |
| 882 | (mh-defun-show-buffer mh-show-ps-print-msg-show mh-ps-print-msg-show) | ||
| 883 | (mh-defun-show-buffer mh-show-toggle-mime-buttons mh-toggle-mime-buttons) | 882 | (mh-defun-show-buffer mh-show-toggle-mime-buttons mh-toggle-mime-buttons) |
| 884 | (mh-defun-show-buffer mh-show-display-with-external-viewer | 883 | (mh-defun-show-buffer mh-show-display-with-external-viewer |
| 885 | mh-display-with-external-viewer) | 884 | mh-display-with-external-viewer) |
| @@ -962,14 +961,11 @@ still visible.\n") | |||
| 962 | 961 | ||
| 963 | (gnus-define-keys (mh-show-ps-print-map "P" mh-show-mode-map) | 962 | (gnus-define-keys (mh-show-ps-print-map "P" mh-show-mode-map) |
| 964 | "?" mh-prefix-help | 963 | "?" mh-prefix-help |
| 965 | "A" mh-show-ps-print-toggle-mime | ||
| 966 | "C" mh-show-ps-print-toggle-color | 964 | "C" mh-show-ps-print-toggle-color |
| 967 | "F" mh-show-ps-print-toggle-faces | 965 | "F" mh-show-ps-print-toggle-faces |
| 968 | "M" mh-show-ps-print-toggle-mime | ||
| 969 | "f" mh-show-ps-print-msg-file | 966 | "f" mh-show-ps-print-msg-file |
| 970 | "l" mh-show-print-msg | 967 | "l" mh-show-print-msg |
| 971 | "p" mh-show-ps-print-msg | 968 | "p" mh-show-ps-print-msg) |
| 972 | "s" mh-show-ps-print-msg-show) | ||
| 973 | 969 | ||
| 974 | (gnus-define-keys (mh-show-thread-map "T" mh-show-mode-map) | 970 | (gnus-define-keys (mh-show-thread-map "T" mh-show-mode-map) |
| 975 | "?" mh-prefix-help | 971 | "?" mh-prefix-help |
| @@ -1110,9 +1106,9 @@ See also `mh-folder-mode'. | |||
| 1110 | (make-local-variable 'font-lock-defaults) | 1106 | (make-local-variable 'font-lock-defaults) |
| 1111 | ;;(set (make-local-variable 'font-lock-support-mode) nil) | 1107 | ;;(set (make-local-variable 'font-lock-support-mode) nil) |
| 1112 | (cond | 1108 | (cond |
| 1113 | ((equal mh-highlight-citation-p 'font-lock) | 1109 | ((equal mh-highlight-citation-style 'font-lock) |
| 1114 | (setq font-lock-defaults '(mh-show-font-lock-keywords-with-cite t))) | 1110 | (setq font-lock-defaults '(mh-show-font-lock-keywords-with-cite t))) |
| 1115 | ((equal mh-highlight-citation-p 'gnus) | 1111 | ((equal mh-highlight-citation-style 'gnus) |
| 1116 | (setq font-lock-defaults '((mh-show-font-lock-keywords) | 1112 | (setq font-lock-defaults '((mh-show-font-lock-keywords) |
| 1117 | t nil nil nil | 1113 | t nil nil nil |
| 1118 | (font-lock-fontify-region-function | 1114 | (font-lock-fontify-region-function |
| @@ -1258,7 +1254,7 @@ is used." | |||
| 1258 | (defun mh-show-xface () | 1254 | (defun mh-show-xface () |
| 1259 | "Display X-Face." | 1255 | "Display X-Face." |
| 1260 | (when (and window-system mh-show-use-xface-flag | 1256 | (when (and window-system mh-show-use-xface-flag |
| 1261 | (or mh-decode-mime-flag mhl-formfile | 1257 | (or mh-decode-mime-flag mh-mhl-format-file |
| 1262 | mh-clean-message-header-flag)) | 1258 | mh-clean-message-header-flag)) |
| 1263 | (funcall mh-show-xface-function))) | 1259 | (funcall mh-show-xface-function))) |
| 1264 | 1260 | ||
| @@ -1560,24 +1556,24 @@ If optional arg MSG is non-nil, display that message instead." | |||
| 1560 | (if mh-showing-mode (mh-show msg))) | 1556 | (if mh-showing-mode (mh-show msg))) |
| 1561 | 1557 | ||
| 1562 | (defun mh-show (&optional message redisplay-flag) | 1558 | (defun mh-show (&optional message redisplay-flag) |
| 1563 | "Show message at cursor. | 1559 | "Display message\\<mh-folder-mode-map>. |
| 1564 | If optional argument MESSAGE is non-nil, display that message instead. | 1560 | |
| 1565 | Force a two-window display with the folder window on top (size given by the | 1561 | If the message under the cursor is already displayed, this command scrolls to |
| 1566 | variable `mh-summary-height') and the show buffer below it. | 1562 | the beginning of the message. MH-E normally hides a lot of the superfluous |
| 1567 | If the message is already visible, display the start of the message. | 1563 | header fields that mailers add to a message, but if you wish to see all of |
| 1568 | 1564 | them, use the command \\[mh-header-display]. | |
| 1569 | If REDISPLAY-FLAG is non-nil, the default when called interactively, the | 1565 | |
| 1570 | message is redisplayed even if the show buffer was already displaying the | 1566 | From a program, optional argument MESSAGE can be used to display an |
| 1571 | correct message. | 1567 | alternative message. The optional argument REDISPLAY-FLAG forces the redisplay |
| 1572 | 1568 | of the message even if the show buffer was already displaying the correct | |
| 1573 | Display of the message is controlled by setting the variables | 1569 | message. |
| 1574 | `mh-clean-message-header-flag' and `mhl-formfile'. The default behavior is | 1570 | |
| 1575 | to scroll uninteresting headers off the top of the window. | 1571 | See the \"mh-show\" customization group for a litany of options that control |
| 1576 | Type \"\\[mh-header-display]\" to see the message with all its headers." | 1572 | what displayed messages look like." |
| 1577 | (interactive (list nil t)) | 1573 | (interactive (list nil t)) |
| 1578 | (when (or redisplay-flag | 1574 | (when (or redisplay-flag |
| 1579 | (and mh-showing-with-headers | 1575 | (and mh-showing-with-headers |
| 1580 | (or mhl-formfile mh-clean-message-header-flag))) | 1576 | (or mh-mhl-format-file mh-clean-message-header-flag))) |
| 1581 | (mh-invalidate-show-buffer)) | 1577 | (mh-invalidate-show-buffer)) |
| 1582 | (mh-show-msg message)) | 1578 | (mh-show-msg message)) |
| 1583 | 1579 | ||
| @@ -1639,13 +1635,14 @@ arguments, after the message has been displayed." | |||
| 1639 | (run-hooks 'mh-show-hook))) | 1635 | (run-hooks 'mh-show-hook))) |
| 1640 | 1636 | ||
| 1641 | (defun mh-modify (&optional message) | 1637 | (defun mh-modify (&optional message) |
| 1642 | "Edit message at cursor. | 1638 | "Edit message. |
| 1643 | If optional argument MESSAGE is non-nil, edit that message instead. | ||
| 1644 | Force a two-window display with the folder window on top (size given by the | ||
| 1645 | value of the variable `mh-summary-height') and the message editing buffer below | ||
| 1646 | it. | ||
| 1647 | 1639 | ||
| 1648 | The message is displayed in raw form." | 1640 | There are times when you need to edit a message. For example, you may need to |
| 1641 | fix a broken Content-Type header field. You can do this with this command. It | ||
| 1642 | displays the raw message in an editable buffer. When you are done editing, | ||
| 1643 | save and kill the buffer as you would any other. | ||
| 1644 | |||
| 1645 | From a program, edit MESSAGE instead if it is non-nil." | ||
| 1649 | (interactive) | 1646 | (interactive) |
| 1650 | (let* ((message (or message (mh-get-msg-num t))) | 1647 | (let* ((message (or message (mh-get-msg-num t))) |
| 1651 | (msg-filename (mh-msg-filename message)) | 1648 | (msg-filename (mh-msg-filename message)) |
| @@ -1700,7 +1697,7 @@ Sets the current buffer to the show buffer." | |||
| 1700 | (unless (mh-buffer-data) | 1697 | (unless (mh-buffer-data) |
| 1701 | (setf (mh-buffer-data) (mh-make-buffer-data))) | 1698 | (setf (mh-buffer-data) (mh-make-buffer-data))) |
| 1702 | ;; Bind variables in folder buffer in case they are local | 1699 | ;; Bind variables in folder buffer in case they are local |
| 1703 | (let ((formfile mhl-formfile) | 1700 | (let ((formfile mh-mhl-format-file) |
| 1704 | (clean-message-header mh-clean-message-header-flag) | 1701 | (clean-message-header mh-clean-message-header-flag) |
| 1705 | (invisible-headers mh-invisible-header-fields-compiled) | 1702 | (invisible-headers mh-invisible-header-fields-compiled) |
| 1706 | (visible-headers nil) | 1703 | (visible-headers nil) |
| @@ -1849,11 +1846,15 @@ If NOTATION is nil then no change in the buffer occurs." | |||
| 1849 | (mh-thread-update-scan-line-map msg notation offset))))))) | 1846 | (mh-thread-update-scan-line-map msg notation offset))))))) |
| 1850 | 1847 | ||
| 1851 | (defun mh-goto-msg (number &optional no-error-if-no-message dont-show) | 1848 | (defun mh-goto-msg (number &optional no-error-if-no-message dont-show) |
| 1852 | "Position the cursor at message NUMBER. | 1849 | "Go to a message\\<mh-folder-mode-map>. |
| 1853 | Optional non-nil second argument NO-ERROR-IF-NO-MESSAGE means return nil | 1850 | |
| 1854 | instead of signaling an error if message does not exist; in this case, the | 1851 | You can enter the message NUMBER either before or after typing |
| 1855 | cursor is positioned near where the message would have been. | 1852 | \\[mh-goto-msg]. In the latter case, Emacs prompts you. |
| 1856 | Non-nil third argument DONT-SHOW means not to show the message." | 1853 | |
| 1854 | In a program, optional non-nil second argument NO-ERROR-IF-NO-MESSAGE means | ||
| 1855 | return nil instead of signaling an error if message does not exist\; in this | ||
| 1856 | case, the cursor is positioned near where the message would have been. Non-nil | ||
| 1857 | third argument DONT-SHOW means not to show the message." | ||
| 1857 | (interactive "NGo to message: ") | 1858 | (interactive "NGo to message: ") |
| 1858 | (setq number (prefix-numeric-value number)) | 1859 | (setq number (prefix-numeric-value number)) |
| 1859 | (let ((point (point)) | 1860 | (let ((point (point)) |