From: yamaoka Date: Tue, 8 Jan 2002 05:58:46 +0000 (+0000) Subject: Synch with Oort Gnus. X-Git-Tag: t-gnus-6_15_5-00-quimby~1 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=2797d7acb8c71c7d256ba8a7aff618ba4457da0d;p=elisp%2Fgnus.git- Synch with Oort Gnus. --- diff --git a/ChangeLog b/ChangeLog index 85c9dc8..bcb078c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -29,6 +29,15 @@ 2002-01-07 Katsumi Yamaoka + * lisp/gnus-vers.el: T-gnus 6.15.5 revision 00. + +2002-01-02 ShengHuo ZHU + + * etc/gnus/describe-group.xpm: Set pixels of first line to + background color. A bug in Emacs? + +2002-01-07 Katsumi Yamaoka + * lisp/gnus-vers.el (gnus-revision-number): Increment to 10. * lisp/gnus-picon.el: Require `mail-parse'. diff --git a/GNUS-NEWS b/GNUS-NEWS index 4b8d5b5..1305042 100644 --- a/GNUS-NEWS +++ b/GNUS-NEWS @@ -8,9 +8,24 @@ For older news, see Gnus info node "New Features". * Changes in Oort Gnus +** Gnus supports the generation of RFC 2298 Disposition Notification requests. + +This is invoked with the C-c M-n key binding from message mode. + +** Gnus supports Maildir groups. + +Gnus includes a new backend nnmaildir.el, by Paul Jarc. + +** Printing capabilities are enhanced. + +Gnus supports Muttprint natively with O P from the Summary and Article +buffers. Also, each individual MIME part can be printed using p on +the MIME button. + ** Message supports the Importance: header. -In the message buffer, C-c C-p cycles through the valid values. +In the message buffer, C-c C-f C-i or C-c C-u cycles through the valid +values. ** Gnus supports Cancel Locks in News. diff --git a/contrib/ChangeLog b/contrib/ChangeLog index 2868fdb..9f58afd 100644 --- a/contrib/ChangeLog +++ b/contrib/ChangeLog @@ -1,3 +1,8 @@ +2002-01-01 Lars Magne Ingebrigtsen + + * gnus-mdrtn.el (gnus-moderation-cancel-article): Insert an extra + newline. + 2001-12-26 Florian Weimer * gpg.el (gpg-command-default-alist): Using gpg-2comp is no longer diff --git a/etc/gnus/describe-group.xpm b/etc/gnus/describe-group.xpm index 7f7ad67..b4a6f42 100644 --- a/etc/gnus/describe-group.xpm +++ b/etc/gnus/describe-group.xpm @@ -6,7 +6,7 @@ static char * describe_group_xpm[] = { "o c #FFFFF5F5ACAC", "+ c #E1E1E0E0E0E0", "@ c #C7C7C6C6C6C6", -" .. .. .. .. .. .. .. ..", +"........................", "........................", ".................oooo...", " .. .. .. .. .. oo oo o.", diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0694404..748d443 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,15 +1,388 @@ +2002-01-08 ShengHuo ZHU + + * gnus-group.el (gnus-group-read-ephemeral-group): Restore the old + behavior of quit-config. + + * message.el (message-make-from): Don't quote fullname. + From: Bj,Ax(Brn Mork + + * gnus-group.el (gnus-group-suspend): Don't kill message buffers. + From: + +2002-01-07 ShengHuo ZHU + + * gnus-group.el (gnus-group-mark-article-read): Typo. Increase n. + + * gnus-art.el (gnus-header-button-alist): Handle mailto. + + * mml.el (mml-preview): Bind gnus-original-article-buffer because + article-decode-group-name uses it. Bind gnus-article-prepare-hook + because bbdb may use it. + +2002-01-07 TSUCHIYA Masatoshi + + * nneething.el (nneething-request-article): When a non-text file + is converted to an article, its data is encoded in base64. Call + `nneething-make-head' with options to specify MIME types. + (nneething-make-head): Add optional arguments to specify MIME + types. + +2002-01-06 ShengHuo ZHU + + * gnus-fun.el (gnus-display-x-face-in-from): Fake a "From: " + header if there is not. + + * gnus-xmas.el (gnus-xmas-put-image): Insert " " if bobp. + + * gnus-msg.el (gnus-gcc-mark-as-read): New variable. + (gnus-inews-mark-gcc-as-read): Obsolete variable. + (gnus-inews-do-gcc): Use them. + + * gnus-group.el (gnus-group-mark-article-read): Put holes into + gnus-newsgroup-unselected. + +2002-01-06 Simon Josefsson + + * imap.el (imap-ssl-open, imap-ssl-open, imap-parse-fetch): Use + condition-case, not ignore-errors. + +2002-01-06 ShengHuo ZHU + + * gnus-sum.el (gnus-summary-insert-old-articles): Bind + gnus-fetch-old-headers. + + * gnus-art.el (article-display-x-face): Use the current buffer + unless `W f'. Otherwise, X-Face may be shown in the header of a + forwarded part. + (gnus-treatment-function-alist): Treat xface before hiding + headers. + +2002-01-06 Lars Magne Ingebrigtsen + + * gnus-group.el (gnus-group-read-ephemeral-group): Fix + parameters. + +2002-01-06 ShengHuo ZHU + + * mm-util.el (mm-multibyte-p): Define conditionally when load. + (mm-guess-charset): New function. + (mm-charset-after): Use it. + (mm-detect-coding-region): New function. + (mm-detect-mime-charset-region): New function. + + * gnus-sum.el (gnus-summary-show-article): Use + mm-detect-coding-region. + +2002-01-06 Lars Magne Ingebrigtsen + + * message.el (message-make-fqdn): Be less violent. + + * gnus.el (gnus-logo-color-style): Compute custom form + automatically. + + * gnus-sum.el (gnus-summary-enter-digest-group): Feed the adaptive + score file of the parent to the document group. + + * gnus-group.el (gnus-group-read-ephemeral-group): Add an optional + parameters parameter. + + * gnus-score.el (gnus-score-load-file): Clean up. + +2002-01-06 ShengHuo ZHU + + * gnus-sum.el (gnus-thread-sort-by-most-recent-number): Fix typo. + From: Damien Wyart + + * gnus-util.el (gnus-local-map-property): In Emacs 21, use keymap. + +2002-01-05 ShengHuo ZHU + + * gnus-sum.el (gnus-select-group-hook): Typo. + + * rfc2047.el (rfc2047-decode-string): Return immediately if there + is no quoted-printable-encoded STRING. + From: Jesper Harder + + (rfc2047-decode-string): Decode it. + +2002-01-05 Lars Magne Ingebrigtsen + + * gnus.el (gnus-logo-color-alist): Added more colors from Luis. + +2002-01-05 Keiichi Suzuki + + * nntp.el (nntp-possibly-change-group): Erase contents of nntp + buffer to get rid of junk line. + +2002-01-05 Simon Josefsson + + * message.el (message-mode-map): Bind message-goto-from to C-c C-f + C-o. + (message-mode-map): Bind message-insert-or-toggle-importance to + C-c C-u. + (message-mode-map): Bind message-disposition-notification-to to + C-c M-n. + (message-mode-menu): Add m-d-n-t. + (message-mode-field-menu): Add m-goto-from. + (message-mode): Doc fix. + (message-goto-from): New function. + (message-insert-disposition-notification-to): New function. + (message-tool-bar-map): Add receipt button. + +2002-01-05 Lars Magne Ingebrigtsen + + * gnus-sum.el (gnus-thread-latest-date): New function. + (gnus-thread-sort-by-most-recent-number): Renamed. + (gnus-thread-sort-functions): Doc fix. + (gnus-select-group-hook): Don't use setq on a hook. + (gnus-thread-latest-date): Use date, not number + + * gnus-agent.el (gnus-agent-expire-days): Doc fix. + (gnus-agent-expire): Allow regexp of expire-days. + + * gnus-art.el (gnus-article-reply-with-original): Deactivate + region. + (gnus-article-followup-with-original): Ditto. + + * gnus-sum.el (gnus-thread-highest-number): Doc fix. + + * gnus-art.el (gnus-mime-display-alternative): Use + gnus-local-map-property. + (gnus-mime-display-alternative): Ditto. + (gnus-insert-mime-security-button): Ditto. + (gnus-insert-next-page-button): Ditto. + (gnus-button-prev-page): Take optional args. + (gnus-insert-prev-page-button): widget-convert. + + * gnus-util.el (gnus-local-map-property): New function. + + * gnus-art.el (gnus-prev-page-map): Use parent map. + (gnus-next-page-map): Ditto. + + * gnus-spec.el (gnus-parse-format): Clean up. + (gnus-parse-format): Do complex formatting for %=. + + * gnus-fun.el (gnus-display-x-face-in-from): Add the string + "X-Face: " to the data in the built-in scenario. + + * gnus-spec.el (gnus-parse-simple-format): Use gnus-pad-form. + (gnus-correct-pad-form): Renamed. + (gnus-tilde-max-form): Clean up. + (gnus-pad-form): Use gnus-use-correct-string-widths. + + * gnus-fun.el (gnus-display-x-face-in-from): Use native xface + support if that is available. + + * gnus-sum.el (gnus-thread-highest-number): New function. + (gnus-thread-sort-by-most-recent-thread): New function. + (gnus-thread-sort-functions): Doc fix. + +2002-01-04 ShengHuo ZHU + + * gnus-sum.el (gnus-summary-select-article): Disable multibyte in + all cases. + (gnus-summary-mode): Enable it in all cases. + (gnus-summary-display-article): Ditto. + (gnus-summary-edit-article): Ditto. + + * gnus-ems.el (gnus-put-image): Really return glyph. + + * gnus-art.el (gnus-article-x-face-command): Fix :type. + (gnus-treat-smiley): Don't take "P" in the interactive form. + 2002-01-04 Lars Magne Ingebrigtsen + * compface.el (uncompface): XEmacs and Emacs have differing + capabilities. + + * gnus-fun.el (gnus-display-x-face-in-from): Use face. + + * gnus-ems.el (gnus-article-xface-ring-internal): Removed. + (gnus-article-xface-ring-size): Removed. + (gnus-article-display-xface): Removed. + (gnus-remove-image): Cleaned up. + * gnus-xmas.el (gnus-xmas-create-image): Convert pbm to xbm. (gnus-xmas-create-image): Take pbm files. + (gnus-x-face): Removed. + (gnus-xmas-article-display-xface): Removed. + + * gnus-fun.el (gnus-display-x-face-in-from): Bind + default-enable-multibyte-characters. + + * compface.el (uncompface): Doc fix. + + * gnus-art.el (gnus-article-x-face-command): Use + gnus-display-x-face-in-from. + + * gnus-xmas.el (gnus-xmas-put-image): Return the image. + + * gnus-ems.el (gnus-put-image): Return the image. + + * gnus-fun.el (gnus-display-x-face-in-from): New function. + (gnus-x-face): Moved here. + +2002-01-04 ShengHuo ZHU + + * gnus-xmas.el (gnus-xmas-put-image): Don't insert SPC or make + invisible if string is nil. + (gnus-xmas-article-display-xface): Use it. + + * gnus-ems.el (gnus-put-image): Explicitly use SPC, and add text + property when string is nil. + (gnus-article-display-xface): Use it. + +2002-01-04 Lars Magne Ingebrigtsen + + * gnus-art.el (article-display-x-face): Check whether valid grey + face was returned. + (article-display-x-face): Place image in the right spot. + + * gnus-fun.el (gnus-convert-gray-x-face-to-xpm): Get rid of + stderr. + (gnus-convert-gray-x-face-to-xpm): Check whether output is valid. 2002-01-03 Lars Magne Ingebrigtsen * gnus-xmas.el (gnus-xmas-create-image): Take optional - parameters. + parameters. (gnus-xmas-put-image): Allow non-strings to be passed. - * gnus-ems.el (gnus-create-image): Take optional parameters. + * gnus-art.el (article-display-x-face): Use optional parameters. + + * gnus-ems.el (gnus-create-image): Take optional parameters. + + * gnus-fun.el (gnus-convert-gray-x-face-to-xpm): Use uncompface. + + * compface.el (compface-xbm-p): Removed. + + * gnus-ems.el (gnus-article-compface-xbm): Removed. + (gnus-article-display-xface): Use compface. + + * compface.el: New file. + + * gnus-fun.el (gnus-convert-pbm-to-x-face-command): Remove quotes. + (gnus-convert-image-to-x-face-command): Ditto. + (gnus-random-x-face): Quote argument. + (gnus-x-face-from-file): Ditto. + +2002-01-03 Paul Jarc + + * nnmaildir.el (nnmaildir-request-expire-articles): evaluate + the expire-group parameter once per article rather than once + per group; bind `nnmaildir-article-file-name' and `article' + for convenience. Leave article alone when expire-group + specifies the current group. + (nnmaildir--update-nov): be more concurrency-friendly with + temp file names. + +2002-01-03 Lars Magne Ingebrigtsen + + * gnus-start.el (gnus-read-init-file): Cleaned up. + +2002-01-03 Dave Love + + * gnus-start.el (gnus-startup-file-coding-system): Removed. + (gnus-read-init-file): Don't use it. + +2002-01-03 Lars Magne Ingebrigtsen + + * gnus-agent.el (gnus-agent-fetch-session): Run hook. + +2002-01-03 Kai Gro,A_(Bjohann + + * gnus-start.el (gnus-read-init-file): Don't force coding system + for ~/.gnus. From Dave Love . + +2002-01-03 ShengHuo ZHU + + * nntp.el (nntp-send-buffer): Use mm-with-unibyte-current-buffer. + * nnspool.el (nnspool-request-post): Ditto. + + * mm-util.el (mm-use-find-coding-systems-region): New variable. + (mm-find-mime-charset-region): Use it. + +2002-01-03 Per Abrahamsen + + * gnus.el (gnus-summary-line-format): Added :link. + * gnus-topic.el (gnus-topic-line-format): Ditto. + * gnus-sum.el (gnus-summary-dummy-line-format): Ditto. + * gnus-srvr.el (gnus-server-line-format): Ditto. + * gnus-group.el (gnus-group-line-format): Ditto. + + * gnus-sum.el (gnus-summary-make-menu-bar): Use correct syntax for + :keys, it works on both Emacsen. + +2002-01-03 ShengHuo ZHU + + * mm-util.el (mm-charset-to-coding-system): Don't setq charset. + +2002-01-03 Lars Magne Ingebrigtsen + + * gnus-msg.el (gnus-summary-send-map): Fix binding for very-wide. + +2002-01-03 Reiner Steib + + * gnus-sum.el (gnus-summary-make-menu-bar): Menu bar entries for + very wide reply. + +2002-01-03 Lars Magne Ingebrigtsen + + * gnus-picon.el (gnus-picon-transform-address): Cache stuff. + (gnus-picon-cache): New variable. + (gnus-picon-transform-newsgroups): Cache stuff. + + * gnus-art.el (gnus-article-reply-with-original): New command. + (gnus-article-followup-with-original): New command. + + * gnus-msg.el (gnus-copy-article-buffer): Take optional BEG and + END parameters. + (gnus-summary-followup): Take a list of list of articles. + (gnus-inews-yank-articles): Allow lists of article/regions. + + * gnus-art.el (gnus-article-read-summary-keys): `R' and `F' are no + longer the usual commands. + + * gnus-fun.el (gnus-convert-image-to-gray-x-face): Use pnmnoraw. + (gnus-convert-gray-x-face-to-xpm): Don't use six parameters to + shell-command-on-region. + +2002-01-02 ShengHuo ZHU + + * gnus-picon.el (gnus-picon-transform-newsgroups): Fix for the case + "Newsgroups: rec.music.beatles.moderated, rec.music.beatles". + +2002-01-03 Steve Youngs + + * gnus-sum.el (gnus-summary-make-menu-bar): XEmacs doesn't + understand ':keys', wrap it in an featurep 'xemacs. + +2002-01-02 ShengHuo ZHU + + * gnus-ems.el (gnus-article-display-xface): Show xface in the + order of headers (Actually, it is called in a reversed order). Add + 'gnus-image-text-deletable property. + (gnus-remove-image): Remove text with such a property. + + * gnus-xmas.el (gnus-xmas-article-display-xface): Don't use + gnus-put-image. + + * gnus-art.el (gnus-article-treat-fold-newsgroups): Replace ", *" + with ", " + +2002-01-02 Lars Magne Ingebrigtsen + + * gnus-fun.el (gnus-convert-gray-x-face-to-xpm): Renamed. + + * gnus-art.el (gnus-ignored-headers): Hide all X-Faces. + (article-display-x-face): Display grey X-Faces. + + * gnus-fun.el (gnus-convert-gray-x-face-region): New function. + (gnus-convert-gray-x-face-to-ppm): Ditto. + (gnus-convert-image-to-gray-x-face): Ditto. + + * gnus-sum.el (gnus-summary-make-menu-bar): Add a :keys to + gnus-summary0show-raw-article. 2002-01-02 ShengHuo ZHU @@ -21,9 +394,173 @@ (gnus-xmas-put-image): Use end-glyph. Make text invisible. (gnus-xmas-remove-image): Make text visible, remove glyph. + * gnus-picon.el (gnus-picon-transform-newsgroups) + (gnus-picon-transform-address): Insert spec backward, due to the + incompatibility of gnus-xmas-put-image. + +2002-01-02 Pavel Jan,Bm(Bk + + * gnus-fun.el (gnus-convert-pbm-to-x-face-command): Doc fix. + +2002-01-02 Lars Magne Ingebrigtsen + + * gnus.el: Doc fix. + + * gnus-art.el: Doc fix. + + * gnus-agent.el: Doc fix. + +2002-01-01 ShengHuo ZHU + + * gnus-diary.el, gnus-delay.el: Fix copyright lines. + +2002-01-01 Paul Jarc + + * nnmaildir.el (nnmaildir--update-nov): automatically parse + NOV data out of the message again if nnmail-extra-headers has + changed. + +2002-01-02 Lars Magne Ingebrigtsen + + * gnus-fun.el: New file. + (gnus-convert-image-to-x-face-command): New variable. + (gnus-insert-x-face): New function. + (gnus-random-x-face): Renamed. + (gnus-x-face-from-file): Renamed. + + * gnus-art.el (gnus-body-boundary-delimiter): Changed default to + "_". + (gnus-body-boundary-delimiter): Typo fix. + +2002-01-02 Simon Josefsson + + * gnus-art.el (gnus-article-treat-body-boundary): Handle nil. + (gnus-body-boundary-delimiter): Fix type. + +2002-01-01 Simon Josefsson + + * gnus-art.el (gnus-treat-buttonize, gnus-treat-buttonize-head) + (gnus-treat-emphasize, gnus-treat-strip-cr) + (gnus-treat-leading-whitespace, gnus-treat-hide-headers) + (gnus-treat-hide-boring-headers, gnus-treat-hide-signature) + (gnus-treat-fill-article, gnus-treat-hide-citation) + (gnus-treat-hide-citation-maybe) + (gnus-treat-strip-list-identifiers, gnus-treat-strip-pgp) + (gnus-treat-strip-pem, gnus-treat-strip-banner) + (gnus-treat-highlight-headers, gnus-treat-highlight-citation) + (gnus-treat-date-ut, gnus-treat-date-local) + (gnus-treat-date-english, gnus-treat-date-lapsed) + (gnus-treat-date-original, gnus-treat-date-iso8601) + (gnus-treat-date-user-defined, gnus-treat-strip-headers-in-body) + (gnus-treat-strip-trailing-blank-lines) + (gnus-treat-strip-leading-blank-lines) + (gnus-treat-strip-multiple-blank-lines) + (gnus-treat-unfold-headers, gnus-treat-fold-headers) + (gnus-treat-fold-newsgroups, gnus-treat-overstrike) + (gnus-treat-display-xface, gnus-treat-display-smileys) + (gnus-treat-from-picon, gnus-treat-mail-picon) + (gnus-treat-newsgroups-picon, gnus-treat-body-boundary) + (gnus-treat-capitalize-sentences, gnus-treat-fill-long-lines) + (gnus-treat-play-sounds, gnus-treat-translate) + (gnus-treat-x-pgp-sig): Doc fix, add link to manual. + + * gnus-art.el (gnus-body-boundary-delimiter): New variable. + (gnus-article-treat-body-boundary): Use it. + + * message.el (message-mode): Fix doc. + (message-mode-menu): Fix names. + +2002-01-01 Lars Magne Ingebrigtsen + + * gnus-sum.el (gnus-summary-first-subject): Really go to unseen + articles. + + * gnus-picon.el (gnus-picon-find-face): Search MISC for all types. + (gnus-picon-transform-address): Search for unknown faces as well. + (gnus-picon-find-face): Don't search "news" for MISC. + (gnus-picon-user-directories): Changed default back to exclude + "unknown". + + * gnus-sum.el (gnus-summary-hide-all-threads): Reversed logic. + + * gnus-picon.el (gnus-picon-find-face): Search through all + databases. + (gnus-picon-find-face): New implementation. + + * gnus-topic.el (gnus-topic-goto-previous-topic): New command and + keystroke. + (gnus-topic-goto-next-topic): Ditto. + + * gnus.el (gnus-summary-line-format): Changed default. + + * nnmail.el (nnmail-extra-headers): Change default. + + * gnus-sum.el (gnus-extra-headers): Change default. + + * message.el (message-news-other-window): Changed "news" to + "posting". + (message-news-other-frame): Ditto. + (message-do-send-housekeeping): Ditto. + + * gnus-sum.el (gnus-summary-maybe-hide-threads): Use predicate + function. + (gnus-article-unread-p): New function. + (gnus-article-unseen-p): New function. + (gnus-dead-summary-mode-map): Typo. + + * gnus-util.el (gnus-make-predicate): New function. + (gnus-make-predicate-1): New function. + + * gnus-sum.el: New function. + (gnus-map-articles): New function. + + * gnus-art.el (gnus-treat-fold-headers): New variable. + (gnus-article-treat-fold-headers): New command and keystroke. + + * gnus-sum.el (gnus-dead-summary-mode-map): Clean up. + (gnus-dead-summary-mode-map): Bind q to bury-buffer. + +2002-01-01 ShengHuo ZHU + + * message.el (message-fcc-externalize-attachments): New variable. + (message-do-fcc): Use it. + + * gnus-msg.el (gnus-gcc-externalize-attachments): New variable. + (gnus-inews-do-gcc): Use it. + + * mml.el (mml-tweak-sexp-alist): New variable. + (mml-externalize-attachments): New variable. + (mml-tweak-part): Use mml-tweak-sexp-alist. + (mml-tweak-externalize-attachments): New function. + +2002-01-01 Steve Youngs + + * gnus-xmas.el (gnus-xmas-article-display-xface): Uncomment + 'set-glyph-face' so x-face back/foreground can be set. + +2001-12-31 ShengHuo ZHU + + * message.el (message-fix-before-sending): Fix a typo. + +2002-01-01 Lars Magne Ingebrigtsen + + * gnus-art.el (gnus-treat-smiley): Renamed command. + (gnus-article-remove-images): New command and keystroke. + + * gnus-sum.el (gnus-summary-toggle-smiley): Removed. + + * smiley-ems.el (gnus-smiley-display): Removed. + + * gnus.el (gnus-version-number): Update version. + + * message.el (message-text-with-property): Renamed and moved + here. + (message-fix-before-sending): Highlight invisible text and place + point there. + 2002-01-01 02:32:53 Lars Magne Ingebrigtsen - * gnus.el: Oort Gnus v0.04 is released. + * gnus.el: Oort Gnus v0.04 is released. 2002-01-01 Lars Magne Ingebrigtsen @@ -413,7 +950,7 @@ 2001-12-19 17:00:00 ShengHuo ZHU - * nnmaildir.el: New. + * nnmaildir.el: New file. From Paul Jarc . 2001-12-19 16:00:00 ShengHuo ZHU @@ -427,7 +964,7 @@ 2001-12-19 01:00:00 ShengHuo ZHU - * gnus-win.el (gnus-frames-on-display-list): New. + * gnus-win.el (gnus-frames-on-display-list): New function. (gnus-get-buffer-window): Use it. 2001-12-19 00:00:00 ShengHuo ZHU @@ -525,15 +1062,15 @@ 2001-12-13 20:00:00 ShengHuo ZHU - * uudecode.el (uudecode-use-external): New. + * uudecode.el (uudecode-use-external): New variable. (uudecode-decode-region): Automatically detect external program. - * binhex.el (binhex-use-external): New. - (binhex-decode-region-internal): New. + * binhex.el (binhex-use-external): New variable. + (binhex-decode-region-internal): New function. (binhex-decode-region): Automatically detect external program. - * mm-uu.el (mm-uu-decode-function): - (mm-uu-binhex-decode-function): Use them. + * mm-uu.el (mm-uu-decode-function,mm-uu-binhex-decode-function): + Use them. 2001-12-12 Simon Josefsson @@ -632,7 +1169,7 @@ 2001-12-07 01:00:00 ShengHuo ZHU - * gnus-sum.el (gnus-summary-print-truncate-and-quote): New. + * gnus-sum.el (gnus-summary-print-truncate-and-quote): New function. (gnus-summary-print-article): Use it. * gnus-util.el (gnus-replace-in-string): Typo. @@ -686,7 +1223,7 @@ 2001-12-03 09:00:00 ShengHuo ZHU - * mm-url.el: New. + * mm-url.el: New file. * nnslashdot.el: Use it. * mm-extern.el (mm-extern-url): Use it. @@ -848,8 +1385,8 @@ 2001-11-20 09:00:00 ShengHuo ZHU - * mm-util.el (mm-coding-system-priorities): New. - (mm-sort-coding-systems-predicate): New. + * mm-util.el (mm-coding-system-priorities): New variable. + (mm-sort-coding-systems-predicate): New function. (mm-find-mime-charset-region): Resort coding systems if needed. Suggested by Katsumi Yamaoka . @@ -1198,7 +1735,7 @@ (message-send-mail): Add Mail-Followup-To. (message-make-mft): New function. - * gnus.el (gnus-find-subscribed-addresses): New. + * gnus.el (gnus-find-subscribed-addresses): New function. 2001-10-31 07:00:00 ShengHuo ZHU @@ -1218,7 +1755,7 @@ mm-coding-system-p. Don't correct it only in XEmacs. (mm-charset-to-coding-system): Use mm-coding-system-p and mm-get-coding-system-list. - (mm-emacs-mule, mm-mule4-p): New. + (mm-emacs-mule, mm-mule4-p): New variables. (mm-enable-multibyte, mm-disable-multibyte, mm-enable-multibyte-mule4, mm-disable-multibyte-mule4, mm-with-unibyte-current-buffer, @@ -1285,8 +1822,8 @@ message-news-p, which widens the buffer. (message-forward-make-body): New function. (message-forward): Use it. - (message-insinuate-rmail): New. - (message-forward-rmail-make-body): New. + (message-insinuate-rmail): New function. + (message-forward-rmail-make-body): New function. 2001-10-30 02:00:00 ShengHuo ZHU @@ -2280,7 +2817,7 @@ * nnslashdot.el (nnslashdot-retrieve-headers-1): Replace nnslashdot-*-retrieve-headers. (nnslashdot-request-article): Fix for slashcode 2.2. - (nnslashdot-make-tuple): New. + (nnslashdot-make-tuple): New function. (nnslashdot-read-groups): Use it. 2001-08-20 01:34:03 Lars Magne Ingebrigtsen @@ -2385,7 +2922,7 @@ * gnus.el (gnus-expand-group-parameters): Fix. - * gnus-spec.el (gnus-char-width): New. + * gnus-spec.el (gnus-char-width): New function. (gnus-correct-substring, gnus-correct-length): Use it. * message.el (message-required-mail-headers): Fix doc. @@ -2435,7 +2972,7 @@ * gnus.el (gnus-info-find-node): Take an argument. - * gnus-art.el (gnus-button-handle-info): New. + * gnus-art.el (gnus-button-handle-info): New function. (gnus-url-unhex-string): Replace "+" with " ". 2001-08-17 21:00:00 ShengHuo ZHU @@ -2474,7 +3011,7 @@ 2001-08-17 14:00:00 ShengHuo ZHU * smime.el (smime-point-at-eol): eval-and-compile. - (smime-make-temp-file): New. + (smime-make-temp-file): New function. (smime-sign-region, smime-encrypt-region, smime-decrypt-region): Use it. @@ -2585,12 +3122,12 @@ 2001-08-10 21:00:00 ShengHuo ZHU * nndoc.el (nndoc-article-type): Fix doc. - (nndoc-generate-article-function): New. - (nndoc-dissection-function): New. + (nndoc-generate-article-function): New variable. + (nndoc-dissection-function): New variable. (nndoc-type-alist): Add oe-dbx. - (nndoc-oe-dbx-type-p): New. - (nndoc-oe-dbx-dissection): New. - (nndoc-oe-dbx-generate-article): New. + (nndoc-oe-dbx-type-p): New function. + (nndoc-oe-dbx-dissection): New function. + (nndoc-oe-dbx-generate-article): New function. 2001-08-11 Kai Gro,A_(Bjohann @@ -2609,7 +3146,7 @@ 2001-08-10 01:00:00 ShengHuo ZHU - * message.el (message-bogus-system-names): New. + * message.el (message-bogus-system-names): New variable. (message-make-fqdn): Use it. 2001-08-09 15:00:00 ShengHuo ZHU @@ -2822,7 +3359,7 @@ 2001-07-31 17:00:00 ShengHuo ZHU Originally from Pavel Jan,Bm(Bk - * gnus-agent.el (gnus-agent-make-mode-line-string): New. + * gnus-agent.el (gnus-agent-make-mode-line-string): New function. (gnus-agent-toggle-plugged): Use it. 2001-07-31 ShengHuo ZHU @@ -2840,8 +3377,8 @@ 2001-07-30 15:00:00 ShengHuo ZHU Originally from Andreas Fuchs - * mml2015.el (mml2015-trust-boundaries-alist) - (mml2015-gpg-pretty-print-fpr): New. + * mml2015.el (mml2015-trust-boundaries-alist): New variable. + (mml2015-gpg-pretty-print-fpr): New function. (mml2015-gpg-extract-signature-details): More details, rename from `m-g-e-from'. (mml2015-gpg-verify): Use them. @@ -2948,12 +3485,12 @@ 2001-07-27 23:00:00 ShengHuo ZHU - * mm-decode.el (mm-image-type-from-buffer): New. + * mm-decode.el (mm-image-type-from-buffer): New function. (mm-get-image): Use it. 2001-07-27 18:00:00 ShengHuo ZHU - * gnus.el (gnus-large-newsgroup): If it is nil, ... + * gnus.el (gnus-large-newsgroup): Add doc, "If it is nil, ..." * gnus-art.el (gnus-mime-view-all-parts): buffer-read-only covers mm-display-parts too. @@ -2974,9 +3511,9 @@ 2001-07-27 07:00:00 ShengHuo ZHU - * mml.el (mml-tweak-type-alist): New. - (mml-tweak-function-alist): New. - (mml-tweak-part): New. + * mml.el (mml-tweak-type-alist): New variable. + (mml-tweak-function-alist): New variable. + (mml-tweak-part): New function. (mml-generate-mime-1): Use it. 2001-07-26 22:00:00 ShengHuo ZHU @@ -3007,7 +3544,7 @@ 2001-07-26 14:00:00 ShengHuo ZHU - * mm-decode.el (mm-readable-p): New. + * mm-decode.el (mm-readable-p): New function. (mm-inline-media-tests): Fix the default testers. 2001-07-26 Simon Josefsson @@ -3050,8 +3587,8 @@ 2001-07-25 11:00:00 ShengHuo ZHU - * gnus-util.el (gnus-byte-compile): New. - (gnus-use-byte-compile): New. + * gnus-util.el (gnus-byte-compile): New function. + (gnus-use-byte-compile): New variable. (gnus-make-sort-function): Use it. * nnmail.el (nnmail-get-new-mail): Use it. @@ -3089,7 +3626,7 @@ * message.el (message-bounce): If no Return-Path, the whole content is considered as the original message. - * nnml.el (nnml-check-directory-twice): New. + * nnml.el (nnml-check-directory-twice): New variable. (nnml-article-to-file): Use it. (nnml-retrieve-headers): Hack it. @@ -3120,13 +3657,13 @@ * gnus-sum.el (gnus-articles-to-read): Use gnus-group-decoded-name. - * mm-util.el (mm-string-as-multibyte): New. + * mm-util.el (mm-string-as-multibyte): New function. * nnmh.el (nnmh-request-list-1): Encode, not decode! 2001-07-23 18:00:00 ShengHuo ZHU - * mm-util.el (mm-universal-coding-system): New. + * mm-util.el (mm-universal-coding-system): New variable. * gnus-start.el (gnus-startup-file-coding-system): Use it. @@ -3218,8 +3755,8 @@ 2001-07-18 11:00:00 ShengHuo ZHU - * mml.el (mml-content-type-parameters): New. - (mml-content-disposition-parameters): New. + * mml.el (mml-content-type-parameters): New variable. + (mml-content-disposition-parameters): New variable. (mml-insert-mime-headers): Use them. (mml-parse-1): Accept charset. @@ -3297,8 +3834,8 @@ * gnus-msg.el (gnus-msg-treat-broken-reply-to): Add force. (gnus-summary-reply): Use it. - (gnus-summary-reply-broken-reply-to): New. - (gnus-msg-force-broken-reply-to): New. + (gnus-summary-reply-broken-reply-to): New function. + (gnus-msg-force-broken-reply-to): New function. * mm-view.el (mm-inline-text): Showing as text/plain when error. @@ -3840,7 +4377,7 @@ * nnrss.el (nnrss-request-expire-articles): Correct the return value. * nnslashdot.el (nnslashdot-request-list): Add time. - (nnslashdot-request-expire-articles): New. + (nnslashdot-request-expire-articles): New function. * gnus-start.el (gnus-check-bogus-newsgroups): Remove bogus secondary methods too. @@ -4159,11 +4696,9 @@ 2001-03-21 Didier Verna - * gnus-start.el: * gnus-start.el (gnus-subscribe-newsgroup-hooks): New. * gnus-start.el (gnus-subscribe-newsgroup): use it. - 2001-03-15 09:47:23 Lars Magne Ingebrigtsen * nnultimate.el (nnultimate-retrieve-headers): Understand @@ -4347,7 +4882,7 @@ 2001-02-23 23:00:00 ShengHuo ZHU - * nnslashdot.el (nnslashdot-backslash-url): New. + * nnslashdot.el (nnslashdot-backslash-url): New variable. (nnslashdot-request-list): Use it. 2001-02-23 22:00:00 ShengHuo ZHU @@ -4356,9 +4891,9 @@ no file. * gnus-sum.el (gnus-summary-import-article): Display it. Enable edit. - (gnus-summary-create-article): New. + (gnus-summary-create-article): New function. - * gnus-group.el (gnus-group-mark-article-read): New. + * gnus-group.el (gnus-group-mark-article-read): New function. * gnus-msg.el (gnus-inews-do-gcc): Use it. @@ -4370,9 +4905,9 @@ gnus-article-edit-exit. (gnus-article-edit-exit): Confirm and insert original-article-buffer. - * gnus.el (gnus-parameters): New. + * gnus.el (gnus-parameters): New variable. Suggested by NAGY Andras . - (gnus-parameters-get-parameter): New. + (gnus-parameters-get-parameter): New function. (gnus-group-find-parameter): Use it. 2001-02-23 Simon Josefsson @@ -4392,11 +4927,11 @@ 2001-02-22 22:00:00 ShengHuo ZHU - * gnus-sum.el (gnus-fetch-headers): New. + * gnus-sum.el (gnus-fetch-headers): New function. (gnus-select-newsgroup): Use it. - (gnus-summary-insert-articles): New. - (gnus-summary-insert-old-articles): New. - (gnus-summary-insert-new-articles): New. + (gnus-summary-insert-articles): New function. + (gnus-summary-insert-old-articles): New function. + (gnus-summary-insert-new-articles): New function. * gnus-group.el (gnus-group-prepare-flat-list-dead): Use decoded-name. (gnus-group-list-active): Ditto. @@ -4418,8 +4953,8 @@ * gnus-msg.el (gnus-inews-do-gcc): Activate group anyway. * gnus-art.el (gnus-mime-display-multipart-alternative-as-mixed): - New. - (gnus-mime-display-multipart-related-as-mixed): New. + New variable. + (gnus-mime-display-multipart-related-as-mixed): New variable. (gnus-mime-display-part): Use them. 2001-02-20 16:00:00 ShengHuo ZHU @@ -4487,9 +5022,9 @@ * gnus-srvr.el (gnus-server-regenerate-server): Use gnus-get-function. - * nnagent.el (nnagent-request-regenerate): New. + * nnagent.el (nnagent-request-regenerate): New function. - * nnfolder.el (nnfolder-request-regenerate): Deffoo. + * nnfolder.el (nnfolder-request-regenerate): New deffoo. * nnml.el (nnml-generate-nov-databases): Accept argument server. Don't open server if it is opened. @@ -4532,9 +5067,9 @@ 2001-02-13 19:00:00 ShengHuo ZHU - * gnus-draft.el (gnus-draft-reminder): New. + * gnus-draft.el (gnus-draft-reminder): New function. - * gnus-art.el (gnus-sender-save-name): New. + * gnus-art.el (gnus-sender-save-name): New function. 2001-02-13 18:00:00 ShengHuo ZHU @@ -4549,7 +5084,7 @@ * gnus-topic.el (gnus-subscribe-topics): Return nil if not subscribe. - * gnus-start.el (gnus-call-subscribe-functions): New. + * gnus-start.el (gnus-call-subscribe-functions): New function. (gnus-find-new-newsgroups): Use it. (gnus-ask-server-for-new-groups): Use it. (gnus-check-first-time-used): Use it. @@ -4574,9 +5109,9 @@ * gnus-group.el (gnus-group-suspend): Offer save summaries. - * gnus-art.el (gnus-treat-leading-whitespace): New. + * gnus-art.el (gnus-treat-leading-whitespace): New variable. (gnus-treatment-function-alist): Use it. - (article-remove-leading-whitespace): New. + (article-remove-leading-whitespace): New function. (gnus-article-make-menu-bar): Use it. * gnus-sum.el (gnus-summary-wash-empty-map): Add @@ -4661,7 +5196,7 @@ 2001-02-06 21:00:00 ShengHuo ZHU - * gnus-group.el (gnus-group-listing-limit): New. + * gnus-group.el (gnus-group-listing-limit): New variable. (gnus-group-prepare-flat-list-dead): Use old trick to speed up. * gnus-topic.el (gnus-group-prepare-topics): Use gnus-killed-hashtb. @@ -4870,7 +5405,7 @@ 2001-01-20 09:00:00 ShengHuo ZHU - * mm-util.el (mm-string-as-unibyte): New. + * mm-util.el (mm-string-as-unibyte): New function. * message.el (message-forward): Use it. @@ -5356,7 +5891,7 @@ * message.el (message-tool-bar-map): Use it. - * Makefile.in (install-el): New. + * Makefile.in (install-el): New rule. 2000-12-21 Katsumi Yamaoka @@ -6765,7 +7300,7 @@ * mml2015.el (mml2015-function-alist): Clear verify and decrypt. * mm-uu.el: Reorganized. Add gnatsweb, pgp-signed, pgp-encrypted. - * mm-decode.el (mm-snarf-option): New. + * mm-decode.el (mm-snarf-option): New variable. 2000-11-04 13:08:02 ShengHuo ZHU diff --git a/lisp/gnus-agent.el b/lisp/gnus-agent.el index bdab1d6..8534895 100644 --- a/lisp/gnus-agent.el +++ b/lisp/gnus-agent.el @@ -57,13 +57,20 @@ :group 'gnus-agent :type 'hook) +(defcustom gnus-agent-fetched-hook nil + "Hook run after finishing fetching articles." + :group 'gnus-agent + :type 'hook) + (defcustom gnus-agent-handle-level gnus-level-subscribed "Groups on levels higher than this variable will be ignored by the Agent." :group 'gnus-agent :type 'integer) (defcustom gnus-agent-expire-days 7 - "Read articles older than this will be expired." + "Read articles older than this will be expired. +This can also be a list of regexp/day pairs. The regexps will +be matched against group names." :group 'gnus-agent :type 'integer) @@ -1172,6 +1179,7 @@ the actual number of articles toggled is returned." err)) (signal 'quit "Cannot fetch articles into the Gnus agent")))) (pop methods)) + (run-hooks 'gnus-agent-fetch-hook) (gnus-message 6 "Finished fetching articles into the Gnus agent")))) (defun gnus-agent-fetch-group-1 (group method) @@ -1259,7 +1267,14 @@ the actual number of articles toggled is returned." "Hook run in `gnus-category-mode' buffers.") (defvar gnus-category-line-format " %(%20c%): %g\n" - "Format of category lines.") + "Format of category lines. + +Valid specifiers include: +%c Topic name (string) +%g The number of groups in the topic (integer) + +General format specifiers can also be used. See +(gnus)Formatting Variables.") (defvar gnus-category-mode-line-format "Gnus: %%b" "The format specification for the category mode line.") @@ -1587,10 +1602,13 @@ The following commands are available: "Expire all old articles." (interactive) (let ((methods gnus-agent-covered-methods) - (day (- (time-to-days (current-time)) gnus-agent-expire-days)) + (day (if (numberp gnus-agent-expire-days) + (- (time-to-days (current-time)) gnus-agent-expire-days) + nil)) + (current-day (time-to-days (current-time))) gnus-command-method sym group articles history overview file histories elem art nov-file low info - unreads marked article orig lowest highest) + unreads marked article orig lowest highest found days) (save-excursion (setq overview (gnus-get-buffer-create " *expire overview*")) (while (setq gnus-command-method (pop methods)) @@ -1614,7 +1632,19 @@ The following commands are available: (skip-chars-forward "^\t") (if (let ((fetch-date (read (current-buffer)))) (if (numberp fetch-date) - (> fetch-date day) + ;; We now have the arrival day, so we see + ;; whether it's old enough to be expired. + (if (numberp day) + (> fetch-date day) + (skip-chars-forward "\t") + (setq found nil + days gnus-agent-expire-days) + (while (and (not found) + days) + (when (looking-at (caar days)) + (setq found (cadar days))) + (pop days)) + (> fetch-date (- current-day found))) ;; History file is corrupted. (gnus-message 5 diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index 60768c3..35ba3ee 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -121,7 +121,7 @@ "^X-UIDL:" "^MIME-Version:" "^Return-Path:" "^In-Reply-To:" "^Content-Type:" "^Content-Transfer-Encoding:" "^X-WebTV-Signature:" "^X-MimeOLE:" "^X-MSMail-Priority:" "^X-Priority:" "^X-Loop:" - "^X-Authentication-Warning:" "^X-MIME-Autoconverted:" "^X-Face:" + "^X-Authentication-Warning:" "^X-MIME-Autoconverted:" "^X-Face" "^X-Attribution:" "^X-Originating-IP:" "^Delivered-To:" "^NNTP-[-A-Za-z]+:" "^Distribution:" "^X-no-archive:" "^X-Trace:" "^X-Complaints-To:" "^X-NNTP-Posting-Host:" "^X-Orig.*:" @@ -151,7 +151,8 @@ "^X-Content-length:" "^X-Posting-Agent:" "^Original-Received:" "^X-Request-PGP:" "^X-Fingerprint:" "^X-WRIEnvto:" "^X-WRIEnvfrom:" "^X-Virus-Scanned:" "^X-Delivery-Agent:" "^Posted-Date:" "^X-Gateway:" - "^X-Local-Origin:" "^X-Local-Destination:" "^X-UserInfo1:") + "^X-Local-Origin:" "^X-Local-Destination:" "^X-UserInfo1:" + "^X-Received-Date:") "*All headers that start with this regexp will be hidden. This variable can also be a list of regexps of headers to be ignored. If `gnus-visible-headers' is non-nil, this variable will be ignored." @@ -238,19 +239,17 @@ regexp. If it matches, the text in question is not a signature." (cond ((featurep 'xemacs) (if (or (gnus-image-type-available-p 'xface) - (gnus-image-type-available-p 'xpm)) - 'gnus-xmas-article-display-xface + (gnus-image-type-available-p 'pbm)) + 'gnus-display-x-face-in-from "{ echo '/* Width=48, Height=48 */'; uncompface; } | icontopbm | ee -")) ((and (fboundp 'image-type-available-p) (module-installed-p 'x-face-e21)) 'x-face-decode-message-header) - ((gnus-image-type-available-p 'xbm) - 'gnus-article-display-xface) + ((gnus-image-type-available-p 'pbm) + 'gnus-display-x-face-in-from) ((and window-system (module-installed-p 'x-face-mule)) 'x-face-mule-gnus-article-display-x-face) - (gnus-article-compface-xbm - "{ echo '/* Width=48, Height=48 */'; uncompface; } | display -") (t "{ echo '/* Width=48, Height=48 */'; uncompface; } | icontopbm | \ display -")) @@ -266,10 +265,9 @@ asynchronously. The compressed face will be piped to this command." (delq nil (list 'string - (if (and (featurep 'xemacs) - (or (featurep 'xface) - (featurep 'xpm))) - '(function-item gnus-xmas-article-display-xface)) + (if (or (gnus-image-type-available-p 'xface) + (gnus-image-type-available-p 'pbm)) + '(function-item gnus-display-x-face-in-from)) (if (and x-face-e21 (fboundp 'image-type-available-p)) '(function-item @@ -747,6 +745,14 @@ To see e.g. security buttons you could set this to :group 'gnus-article-mime :type '(repeat regexp)) +(defcustom gnus-body-boundary-delimiter "_" + "String used to delimit header and body. +This variable is used by `gnus-article-treat-body-boundary' which can +be controlled by `gnus-treat-body-boundary'." + :group 'gnus-article-various + :type '(choice (item :tag "None" :value nil) + string)) + (defcustom gnus-article-mime-part-function nil "Function called with a MIME handle as the argument. This is meant for people who want to do something automatic based @@ -855,7 +861,7 @@ See Info node `(gnus)Customizing Articles'." (defcustom gnus-treat-buttonize 100000 "Add buttons. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :type gnus-article-treat-custom) (put 'gnus-treat-buttonize 'highlight t) @@ -863,7 +869,7 @@ See the manual for details." (defcustom gnus-treat-buttonize-head 'head "Add buttons to the head. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (put 'gnus-treat-buttonize-head 'highlight t) @@ -875,7 +881,7 @@ See the manual for details." 50000) "Emphasize text. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (put 'gnus-treat-emphasize 'highlight t) @@ -883,63 +889,63 @@ See the manual for details." (defcustom gnus-treat-strip-cr nil "Remove carriage returns. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-leading-whitespace nil "Remove leading whitespace in headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-hide-headers 'head "Hide headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-hide-boring-headers nil "Hide boring headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-hide-signature nil "Hide the signature. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-fill-article nil "Fill the article. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-hide-citation nil "Hide cited text. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-hide-citation-maybe nil "Hide cited text. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-strip-list-identifiers 'head "Strip list identifiers from `gnus-list-identifiers`. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -947,14 +953,14 @@ See the manual for details." (defcustom gnus-treat-strip-pgp t "Strip PGP signatures. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-strip-pem nil "Strip PEM signatures. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -962,14 +968,14 @@ See the manual for details." "Strip banners from articles. The banner to be stripped is specified in the `banner' group parameter. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-highlight-headers 'head "Highlight the headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (put 'gnus-treat-highlight-headers 'highlight t) @@ -977,7 +983,7 @@ See the manual for details." (defcustom gnus-treat-highlight-citation t "Highlight cited text. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (put 'gnus-treat-highlight-citation 'highlight t) @@ -985,42 +991,42 @@ See the manual for details." (defcustom gnus-treat-date-ut nil "Display the Date in UT (GMT). Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-date-local nil "Display the Date in the local timezone. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-date-english nil "Display the Date in a format that can be read aloud in English. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-date-lapsed nil "Display the Date header in a way that says how much time has elapsed. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-date-original nil "Display the date in the original timezone. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-date-iso8601 nil "Display the date in the ISO8601 format. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-head-custom) @@ -1029,14 +1035,14 @@ See the manual for details." "Display the date in a user-defined format. The format is defined by the `gnus-article-time-format' variable. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (defcustom gnus-treat-strip-headers-in-body t "Strip the X-No-Archive header line from the beginning of the body. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -1044,42 +1050,49 @@ See the manual for details." (defcustom gnus-treat-strip-trailing-blank-lines nil "Strip trailing blank lines. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-strip-leading-blank-lines nil "Strip leading blank lines. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-strip-multiple-blank-lines nil "Strip multiple blank lines. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-unfold-headers 'head "Unfold folded header lines. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." + :group 'gnus-article-treat + :type gnus-article-treat-custom) + +(defcustom gnus-treat-fold-headers nil + "Fold headers. +Valid values are nil, t, `head', `last', an integer or a predicate. +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-fold-newsgroups 'head "Fold the Newsgroups and Followup-To headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-overstrike t "Treat overstrike highlighting. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (put 'gnus-treat-overstrike 'highlight t) @@ -1095,7 +1108,8 @@ See the manual for details." 'head) "Display X-Face headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' and Info node +`(gnus)X-Face' for details." :group 'gnus-article-treat ;;:version "21.1" :type gnus-article-treat-head-custom) @@ -1113,7 +1127,8 @@ See the manual for details." nil) "Display smileys. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' and Info node +`(gnus)Smileys' for details." :group 'gnus-article-treat ;;:version "21.1" :type gnus-article-treat-custom) @@ -1124,7 +1139,8 @@ See the manual for details." 'head nil) "Display picons in the From header. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' and Info node +`(gnus)Picons' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (put 'gnus-treat-from-picon 'highlight t) @@ -1134,7 +1150,8 @@ See the manual for details." 'head nil) "Display picons in To and Cc headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' and Info node +`(gnus)Picons' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (put 'gnus-treat-mail-picon 'highlight t) @@ -1144,7 +1161,8 @@ See the manual for details." 'head nil) "Display picons in the Newsgroups and Followup-To headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' and Info node +`(gnus)Picons' for details." :group 'gnus-article-treat :type gnus-article-treat-head-custom) (put 'gnus-treat-newsgroups-picon 'highlight t) @@ -1156,7 +1174,7 @@ See the manual for details." 'head nil) "Draw a boundary at the end of the headers. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -1164,7 +1182,7 @@ See the manual for details." (defcustom gnus-treat-capitalize-sentences nil "Capitalize sentence-starting words. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -1172,14 +1190,14 @@ See the manual for details." (defcustom gnus-treat-fill-long-lines nil "Fill long lines. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :type gnus-article-treat-custom) (defcustom gnus-treat-play-sounds nil "Play sounds. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -1197,7 +1215,7 @@ decode the body, '(or header t) for the whole article, etc." (defcustom gnus-treat-translate nil "Translate articles from one language to another. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :version "21.1" :group 'gnus-article-treat :type gnus-article-treat-custom) @@ -1206,7 +1224,7 @@ See the manual for details." "Verify X-PGP-Sig. To automatically treat X-PGP-Sig, set it to head. Valid values are nil, t, `head', `last', an integer or a predicate. -See the manual for details." +See Info node `(gnus)Customizing Articles' for details." :group 'gnus-article-treat :group 'mime-security :type gnus-article-treat-custom) @@ -1251,6 +1269,7 @@ It is a string, such as \"PGP\". If nil, ask user." (gnus-treat-date-original gnus-article-date-original) (gnus-treat-date-user-defined gnus-article-date-user) (gnus-treat-date-iso8601 gnus-article-date-iso8601) + (gnus-treat-display-xface gnus-article-display-x-face) (gnus-treat-hide-headers gnus-article-maybe-hide-headers) (gnus-treat-hide-boring-headers gnus-article-hide-boring-headers) (gnus-treat-hide-signature gnus-article-hide-signature) @@ -1274,15 +1293,12 @@ It is a string, such as \"PGP\". If nil, ask user." gnus-article-strip-multiple-blank-lines) (gnus-treat-overstrike gnus-article-treat-overstrike) (gnus-treat-unfold-headers gnus-article-treat-unfold-headers) + (gnus-treat-fold-headers gnus-article-treat-fold-headers) (gnus-treat-fold-newsgroups gnus-article-treat-fold-newsgroups) (gnus-treat-buttonize-head gnus-article-add-buttons-to-head) - (gnus-treat-display-smileys ,(if (or (featurep 'xemacs) - (>= emacs-major-version 21)) - 'gnus-smiley-display - 'gnus-article-smiley-display)) + (gnus-treat-display-smileys gnus-treat-smiley) (gnus-treat-capitalize-sentences gnus-article-capitalize-sentences) (gnus-treat-emphasize gnus-article-emphasize) - (gnus-treat-display-xface gnus-article-display-x-face) (gnus-treat-body-boundary gnus-article-treat-body-boundary) (gnus-treat-play-sounds gnus-earcon-display))) @@ -1807,6 +1823,36 @@ unfolded." (replace-match " " t t))) (goto-char (point-max))))))) +(defun gnus-article-treat-fold-headers () + "Fold message headers." + (interactive) + (gnus-with-article-headers + (while (not (eobp)) + (save-restriction + (mail-header-narrow-to-field) + (mail-header-fold-field) + (goto-char (point-max)))))) + +(defun gnus-treat-smiley () + "Display textual emoticons (\"smileys\") as small graphical icons." + (interactive) + (gnus-with-article-buffer + (if (memq 'smiley gnus-article-wash-types) + (gnus-delete-images 'smiley) + (article-goto-body) + (let ((images (smiley-region (point) (point-max)))) + (when images + (gnus-add-wash-type 'smiley) + (dolist (image images) + (gnus-add-image 'smiley image))))))) + +(defun gnus-article-remove-images () + "Remove all images from the article buffer." + (interactive) + (gnus-with-article-buffer + (dolist (elem gnus-article-image-alist) + (gnus-delete-images (car elem))))) + (defun gnus-article-treat-fold-newsgroups () "Unfold folded message headers. Only the headers that fit into the current window width will be @@ -1816,7 +1862,7 @@ unfolded." (while (gnus-article-goto-header "newsgroups\\|followup-to") (save-restriction (mail-header-narrow-to-field) - (while (search-forward "," nil t) + (while (re-search-forward ", *" nil t) (replace-match ", " t t)) (mail-header-fold-field) (goto-char (point-max)))))) @@ -1824,13 +1870,18 @@ unfolded." (defun gnus-article-treat-body-boundary () "Place a boundary line at the end of the headers." (interactive) - (gnus-with-article-headers - (goto-char (point-max)) - (let ((start (point))) - (insert "X-Boundary: ") - (gnus-add-text-properties start (point) '(invisible t intangible t)) - (insert (make-string (1- (window-width)) ?-) - "\n")))) + (when (and gnus-body-boundary-delimiter + (> (length gnus-body-boundary-delimiter) 0)) + (gnus-with-article-headers + (goto-char (point-max)) + (let ((start (point))) + (insert "X-Boundary: ") + (gnus-add-text-properties start (point) '(invisible t intangible t)) + (insert (let (str) + (while (>= (1- (window-width)) (length str)) + (setq str (concat str gnus-body-boundary-delimiter))) + (substring str 0 (1- (window-width)))) + "\n"))))) (defun article-fill-long-lines () "Fill lines that are wider than the window width." @@ -1893,52 +1944,74 @@ unfolded." (defun article-display-x-face (&optional force) "Look for an X-Face header and display it if present." (interactive (list 'force)) - (gnus-with-article-headers - ;; Delete the old process, if any. - (when (process-status "article-x-face") - (delete-process "article-x-face")) - (if (memq 'xface gnus-article-wash-types) - ;; We have already displayed X-Faces, so we remove them - ;; instead. - (gnus-delete-images 'xface) - ;; Display X-Faces. - (let (x-faces from face) - (save-excursion - (set-buffer gnus-original-article-buffer) - (save-restriction - (mail-narrow-to-head) - (while (gnus-article-goto-header "x-face") - (push (mail-header-field-value) x-faces)) - (setq from (message-fetch-field "from")))) - ;; Sending multiple EOFs to xv doesn't work, so we only do a - ;; single external face. - (when (stringp gnus-article-x-face-command) - (setq x-faces (list (car x-faces)))) - (while (and (setq face (pop x-faces)) - gnus-article-x-face-command - (or force - ;; Check whether this face is censored. - (not gnus-article-x-face-too-ugly) - (and gnus-article-x-face-too-ugly from - (not (string-match gnus-article-x-face-too-ugly - from))))) - ;; We display the face. - (if (symbolp gnus-article-x-face-command) - ;; The command is a lisp function, so we call it. - (if (gnus-functionp gnus-article-x-face-command) - (funcall gnus-article-x-face-command face) - (error "%s is not a function" gnus-article-x-face-command)) - ;; The command is a string, so we interpret the command - ;; as a, well, command, and fork it off. - (let ((process-connection-type nil)) - (process-kill-without-query - (start-process - "article-x-face" nil shell-file-name shell-command-switch - gnus-article-x-face-command)) - (with-temp-buffer - (insert face) - (process-send-region "article-x-face" (point-min) (point-max))) - (process-send-eof "article-x-face")))))))) + (let ((wash-face-p buffer-read-only)) ;; When type `W f' + (gnus-with-article-headers + ;; Delete the old process, if any. + (when (process-status "article-x-face") + (delete-process "article-x-face")) + (if (memq 'xface gnus-article-wash-types) + ;; We have already displayed X-Faces, so we remove them + ;; instead. + (gnus-delete-images 'xface) + ;; Display X-Faces. + (let (x-faces from face grey) + (save-excursion + (when (and wash-face-p + (progn + (goto-char (point-min)) + (not (re-search-forward + "^X-Face\\(-[0-9]+\\)?:[\t ]*" nil t))) + (gnus-buffer-live-p gnus-original-article-buffer)) + ;; If type `W f', use gnus-original-article-buffer, + ;; otherwise use the current buffer because displaying + ;; RFC822 parts calls this function too. + (set-buffer gnus-original-article-buffer)) + (save-restriction + (mail-narrow-to-head) + (while (gnus-article-goto-header "x-face\\(-[0-9]+\\)?") + (when (match-beginning 2) + (setq grey t)) + (push (mail-header-field-value) x-faces)) + (setq from (message-fetch-field "from")))) + (if grey + (let ((xpm (gnus-convert-gray-x-face-to-xpm x-faces)) + image) + (when xpm + (setq image (gnus-create-image xpm 'xpm t)) + (gnus-article-goto-header "from") + (gnus-add-wash-type 'xface) + (gnus-add-image 'xface image) + (gnus-put-image image))) + ;; Sending multiple EOFs to xv doesn't work, so we only do a + ;; single external face. + (when (stringp gnus-article-x-face-command) + (setq x-faces (list (car x-faces)))) + (while (and (setq face (pop x-faces)) + gnus-article-x-face-command + (or force + ;; Check whether this face is censored. + (not gnus-article-x-face-too-ugly) + (and gnus-article-x-face-too-ugly from + (not (string-match gnus-article-x-face-too-ugly + from))))) + ;; We display the face. + (if (symbolp gnus-article-x-face-command) + ;; The command is a lisp function, so we call it. + (if (gnus-functionp gnus-article-x-face-command) + (funcall gnus-article-x-face-command face) + (error "%s is not a function" gnus-article-x-face-command)) + ;; The command is a string, so we interpret the command + ;; as a, well, command, and fork it off. + (let ((process-connection-type nil)) + (process-kill-without-query + (start-process + "article-x-face" nil shell-file-name shell-command-switch + gnus-article-x-face-command)) + (with-temp-buffer + (insert face) + (process-send-region "article-x-face" + (point-min) (point-max))) + (process-send-eof "article-x-face")))))))))) (defun article-decode-mime-words () "Decode all MIME-encoded words in the article." @@ -3304,6 +3377,8 @@ If variable `gnus-use-long-file-name' is non-nil, it is ">" end-of-buffer "\C-c\C-i" gnus-info-find-node "\C-c\C-b" gnus-bug + "R" gnus-article-reply-with-original + "F" gnus-article-followup-with-original "\C-hk" gnus-article-describe-key "\C-hc" gnus-article-describe-key-briefly @@ -3765,14 +3840,19 @@ value of the variable `gnus-show-mime' is non-nil." ;;; (defvar gnus-mime-button-line-format "%{%([%p. %d%T]%)%}%e\n" - "The following specs can be used: + "Format of the MIME buttons. + +Valid specifiers include: %t The MIME type %T MIME type, along with additional info %n The `name' parameter %d The description, if any %l The length of the encoded part %p The part identifier number -%e Dots if the part isn't displayed") +%e Dots if the part isn't displayed + +General format specifiers can also be used. See +(gnus)Formatting Variables.") (defvar gnus-mime-button-line-format-alist '((?t gnus-tmp-type ?s) @@ -4288,14 +4368,11 @@ If no internal viewer is available, use an external viewer." (setq b (point)) (gnus-eval-format gnus-mime-button-line-format gnus-mime-button-line-format-alist - `(keymap ,gnus-mime-button-map - ,@(if (>= (string-to-number emacs-version) 21) - nil - (list 'local-map gnus-mime-button-map)) - gnus-callback gnus-mm-display-part - gnus-part ,gnus-tmp-id - article-type annotation - gnus-data ,handle)) + `(,@(gnus-local-map-property gnus-mime-button-map) + gnus-callback gnus-mm-display-part + gnus-part ,gnus-tmp-id + article-type annotation + gnus-data ,handle)) (setq e (point)) (widget-convert-button 'link b e @@ -4548,12 +4625,9 @@ If no internal viewer is available, use an external viewer." ',gnus-article-mime-handle-alist)) (gnus-mime-display-alternative ',ihandles ',not-pref ',begend ,id)) - ,@(if (>= (string-to-number emacs-version) 21) - nil ;; XEmacs doesn't care - (list 'local-map gnus-mime-button-map)) + ,@(gnus-local-map-property gnus-mime-button-map) ,gnus-mouse-face-prop ,gnus-article-mouse-face face ,gnus-article-button-face - keymap ,gnus-mime-button-map gnus-part ,id gnus-data ,handle)) (widget-convert-button 'link from (point) @@ -4575,12 +4649,9 @@ If no internal viewer is available, use an external viewer." ',gnus-article-mime-handle-alist)) (gnus-mime-display-alternative ',ihandles ',handle ',begend ,id)) - ,@(if (>= (string-to-number emacs-version) 21) - nil ;; XEmacs doesn't care - (list 'local-map gnus-mime-button-map)) + ,@(gnus-local-map-property gnus-mime-button-map) ,gnus-mouse-face-prop ,gnus-article-mouse-face face ,gnus-article-button-face - keymap ,gnus-mime-button-map gnus-part ,id gnus-data ,handle)) (widget-convert-button 'link from (point) @@ -4884,7 +4955,7 @@ Argument LINES specifies lines to be scrolled down." (interactive "P") (gnus-article-check-buffer) (let ((nosaves - '("q" "Q" "c" "r" "R" "\C-c\C-f" "m" "a" "f" "F" + '("q" "Q" "c" "r" "\C-c\C-f" "m" "a" "f" "Zc" "ZC" "ZE" "ZJ" "ZQ" "ZZ" "Zn" "ZR" "ZG" "ZN" "ZP" "=" "^" "\M-^" "|")) (nosave-but-article @@ -4997,6 +5068,36 @@ Argument LINES specifies lines to be scrolled down." (describe-key-briefly key insert)) (describe-key-briefly key insert))) +(defun gnus-article-reply-with-original (&optional wide) + "Start composing a reply mail to the current message. +The text in the region will be yanked. If the region isn't active, +the entire article will be yanked." + (interactive "P") + (let ((article (cdr gnus-article-current))) + (if (not mark-active) + (gnus-summary-reply (list (list article)) wide) + ;; Deactivate active regions. + (when (and (boundp 'transient-mark-mode) + transient-mark-mode) + (setq mark-active nil)) + (gnus-summary-reply + (list (list article (buffer-substring (point) (mark)))) wide)))) + +(defun gnus-article-followup-with-original () + "Compose a followup to the current article. +The text in the region will be yanked. If the region isn't active, +the entire article will be yanked." + (interactive) + (let ((article (cdr gnus-article-current))) + (if (not mark-active) + (gnus-summary-followup (list (list article))) + ;; Deactivate active regions. + (when (and (boundp 'transient-mark-mode) + transient-mark-mode) + (setq mark-active nil)) + (gnus-summary-followup + (list (list article (buffer-substring (point) (mark)))))))) + (defun gnus-article-hide (&optional arg force) "Hide all the gruft in the current article. This means that PGP stuff, signatures, cited text and (some) @@ -5503,6 +5604,7 @@ variable it the real callback function." ("^X-[Uu][Rr][Ll]:" ,gnus-button-url-regexp 0 t browse-url 0) ("^Subject:" ,gnus-button-url-regexp 0 t browse-url 0) ("^[^:]+:" ,gnus-button-url-regexp 0 t browse-url 0) + ("^[^:]+:" "\\bmailto:\\([-a-zA-Z.@_+0-9%=?]+\\)" 0 t gnus-url-mailto 1) ("^[^:]+:" "\\(<\\(url: \\)?news:\\([^>\n ]*\\)>\\)" 1 t gnus-button-message-id 3)) "*Alist of headers and regexps to match buttons in article heads. @@ -5985,39 +6087,41 @@ specified by `gnus-button-alist'." (defvar gnus-next-page-line-format "%{%(Next page...%)%}\n") (defvar gnus-prev-page-line-format "%{%(Previous page...%)%}\n") -(defvar gnus-prev-page-map nil) -(unless gnus-prev-page-map - (setq gnus-prev-page-map (make-sparse-keymap)) - (define-key gnus-prev-page-map gnus-mouse-2 'gnus-button-prev-page) - (define-key gnus-prev-page-map "\r" 'gnus-button-prev-page)) +(defvar gnus-prev-page-map + (let ((map (make-sparse-keymap))) + (unless (>= emacs-major-version 21) + ;; XEmacs doesn't care. + (set-keymap-parent map gnus-article-mode-map)) + (define-key map gnus-mouse-2 'gnus-button-prev-page) + (define-key map "\r" 'gnus-button-prev-page) + map)) -(static-if (featurep 'xemacs) - (defun gnus-insert-prev-page-button () - (let ((buffer-read-only nil)) - (gnus-eval-format - gnus-prev-page-line-format nil - `(gnus-prev t local-map ,gnus-prev-page-map - gnus-callback gnus-article-button-prev-page - article-type annotation)))) - (defun gnus-insert-prev-page-button () - (let ((buffer-read-only nil) - (situation (get-text-property (point-min) 'mime-view-situation))) - (set-keymap-parent gnus-prev-page-map (current-local-map)) - (gnus-eval-format - gnus-prev-page-line-format nil - `(gnus-prev t local-map ,gnus-prev-page-map - gnus-callback gnus-article-button-prev-page - article-type annotation - mime-view-situation ,situation)))) - ) +(defun gnus-insert-prev-page-button () + (let ((b (point)) + (buffer-read-only nil) + (situation (get-text-property (point-min) 'mime-view-situation))) + (gnus-eval-format + gnus-prev-page-line-format nil + `(,@(gnus-local-map-property gnus-prev-page-map) + gnus-prev t + gnus-callback gnus-article-button-prev-page + article-type annotation + mime-view-situation ,situation)) + (widget-convert-button + 'link b (point) + :action 'gnus-button-prev-page + :button-keymap gnus-prev-page-map))) -(defvar gnus-next-page-map nil) -(unless gnus-next-page-map - (setq gnus-next-page-map (make-sparse-keymap)) - (define-key gnus-next-page-map gnus-mouse-2 'gnus-button-next-page) - (define-key gnus-next-page-map "\r" 'gnus-button-next-page)) +(defvar gnus-next-page-map + (let ((map (make-sparse-keymap))) + (unless (>= emacs-major-version 21) + ;; XEmacs doesn't care. + (set-keymap-parent map gnus-article-mode-map)) + (define-key map gnus-mouse-2 'gnus-button-next-page) + (define-key map "\r" 'gnus-button-next-page) + map)) -(defun gnus-button-next-page () +(defun gnus-button-next-page (&optional args more-args) "Go to the next page." (interactive) (let ((win (selected-window))) @@ -6025,7 +6129,7 @@ specified by `gnus-button-alist'." (gnus-article-next-page) (select-window win))) -(defun gnus-button-prev-page () +(defun gnus-button-prev-page (&optional args more-args) "Go to the prev page." (interactive) (let ((win (selected-window))) @@ -6033,25 +6137,20 @@ specified by `gnus-button-alist'." (gnus-article-prev-page) (select-window win))) -(static-if (featurep 'xemacs) - (defun gnus-insert-next-page-button () - (let ((buffer-read-only nil)) - (gnus-eval-format gnus-next-page-line-format nil - `(gnus-next - t local-map ,gnus-next-page-map - gnus-callback gnus-article-button-next-page - article-type annotation)))) - (defun gnus-insert-next-page-button () - (let ((buffer-read-only nil) - (situation (get-text-property (point-min) 'mime-view-situation))) - (set-keymap-parent gnus-next-page-map (current-local-map)) - (gnus-eval-format gnus-next-page-line-format nil - `(gnus-next - t local-map ,gnus-next-page-map +(defun gnus-insert-next-page-button () + (let ((b (point)) + (buffer-read-only nil) + (situation (get-text-property (point-min) 'mime-view-situation))) + (gnus-eval-format gnus-next-page-line-format nil + `(,@(gnus-local-map-property gnus-next-page-map) + gnus-next t gnus-callback gnus-article-button-next-page article-type annotation - mime-view-situation ,situation)))) - ) + mime-view-situation ,situation)) + (widget-convert-button + 'link b (point) + :action 'gnus-button-next-page + :button-keymap gnus-next-page-map))) (defun gnus-article-button-next-page (arg) "Go to the next page." @@ -6398,14 +6497,11 @@ For example: (gnus-eval-format gnus-mime-security-button-line-format gnus-mime-security-button-line-format-alist - `(keymap ,gnus-mime-security-button-map - ,@(if (>= (string-to-number emacs-version) 21) - nil ;; XEmacs doesn't care - (list 'local-map gnus-mime-security-button-map)) - gnus-callback gnus-mime-security-press-button - gnus-line-format ,gnus-mime-security-button-line-format - article-type annotation - gnus-data ,handle)) + `(,@(gnus-local-map-property gnus-mime-security-button-map) + gnus-callback gnus-mime-security-press-button + gnus-line-format ,gnus-mime-security-button-line-format + article-type annotation + gnus-data ,handle)) (setq e (point)) (widget-convert-button 'link b e diff --git a/lisp/gnus-delay.el b/lisp/gnus-delay.el index c7652da..7e712b8 100644 --- a/lisp/gnus-delay.el +++ b/lisp/gnus-delay.el @@ -5,15 +5,17 @@ ;; Author: Kai Großjohann ;; Keywords: mail, news, extensions -;; This file is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; This file is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published +;; by the Free Software Foundation; either version 2, or (at your +;; option) any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to diff --git a/lisp/gnus-diary.el b/lisp/gnus-diary.el index 0e8a1af..5f1f6e2 100644 --- a/lisp/gnus-diary.el +++ b/lisp/gnus-diary.el @@ -1,24 +1,24 @@ ;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend -;; Copyright (C) 1999-2001 Didier Verna. +;; Copyright (c) 2001, 2002 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001 Didier Verna. ;; Author: Didier Verna ;; Maintainer: Didier Verna ;; Created: Tue Jul 20 10:42:55 1999 -;; Last Revision: Wed Sep 12 12:31:09 2001 ;; Keywords: calendar mail news -;; This file is part of Gnus. +;; This file is part of GNU Emacs. -;; Gnus is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2 of the License, or -;; (at your option) any later version. +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published +;; by the Free Software Foundation; either version 2 of the License, +;; or (at your option) any later version. -;; Gnus is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. +;; GNU Emacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, write to the Free Software diff --git a/lisp/gnus-ems.el b/lisp/gnus-ems.el index 083a3ba..22e9dfb 100644 --- a/lisp/gnus-ems.el +++ b/lisp/gnus-ems.el @@ -1,5 +1,5 @@ ;;; gnus-ems.el --- functions for making Semi-gnus work under different Emacsen -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -49,8 +49,8 @@ (autoload 'appt-select-lowest-window "appt")) (if (featurep 'xemacs) - (autoload 'gnus-smiley-display "smiley") - (autoload 'gnus-smiley-display "smiley-ems")) ; override XEmacs version + (autoload 'smiley-region "smiley") + (autoload 'smiley-region "smiley-ems")) ; override XEmacs version (defun gnus-kill-all-overlays () "Delete all overlays in the current buffer." @@ -219,86 +219,6 @@ (goto-char (point-min)) (sit-for 0)))))) -(defvar gnus-article-xface-ring-internal nil - "Cache for face data.") - -;; Worth customizing? -(defvar gnus-article-xface-ring-size 6 - "Length of the ring used for `gnus-article-xface-ring-internal'.") - -(defvar gnus-article-compface-xbm - (condition-case () - (eq 0 (string-match "#define" - (shell-command-to-string "uncompface -X"))) - (error nil)) - "Non-nil means the compface program supports the -X option. -That produces XBM output.") - -(defun gnus-article-display-xface (data) - "Display the XFace header FACE in the current buffer. -Requires support for images in your Emacs and the external programs -`uncompface', and `icontopbm'. On a GNU/Linux system these -might be in packages with names like `compface' or `faces-xface' and -`netpbm' or `libgr-progs', for instance. See also -`gnus-article-compface-xbm'. - -This function is for Emacs 21+. See `gnus-xmas-article-display-xface' -for XEmacs." - ;; It might be worth converting uncompface's output in Lisp. - - (when (if (fboundp 'display-graphic-p) - (display-graphic-p)) - (unless gnus-article-xface-ring-internal ; Only load ring when needed. - (setq gnus-article-xface-ring-internal - (make-ring gnus-article-xface-ring-size))) - (save-excursion - (let* ((cur (current-buffer)) - (image (cdr-safe (assoc data (ring-elements - gnus-article-xface-ring-internal)))) - default-enable-multibyte-characters) - (unless image - (with-temp-buffer - (insert data) - (and (eq 0 (apply #'call-process-region (point-min) (point-max) - "uncompface" - 'delete '(t nil) nil - (if gnus-article-compface-xbm - '("-X")))) - (if gnus-article-compface-xbm - t - (goto-char (point-min)) - (progn (insert "/* Width=48, Height=48 */\n") t) - (eq 0 (call-process-region (point-min) (point-max) - "icontopbm" - 'delete '(t nil)))) - ;; Miles Bader says that faces don't look right as - ;; light on dark. - (if (eq 'dark (cdr-safe (assq 'background-mode - (frame-parameters)))) - (setq image (create-image (buffer-string) - (if gnus-article-compface-xbm - 'xbm - 'pbm) - t - :ascent 'center - :foreground "black" - :background "white")) - (setq image (create-image (buffer-string) - (if gnus-article-compface-xbm - 'xbm - 'pbm) - t - :ascent 'center))))) - (ring-insert gnus-article-xface-ring-internal (cons data image))) - (when image - (goto-char (point-min)) - (re-search-forward "^From:" nil 'move) - (while (get-text-property (point) 'display) - (goto-char (next-single-property-change (point) 'display))) - (gnus-add-wash-type 'xface) - (gnus-add-image 'xface image) - (insert-image image)))))) - ;;; Image functions. (defun gnus-image-type-available-p (type) @@ -313,12 +233,18 @@ for XEmacs." (apply 'create-image file type data-p props))) (defun gnus-put-image (glyph &optional string) - (insert-image glyph string)) + (insert-image glyph (or string " ")) + (unless string + (put-text-property (1- (point)) (point) + 'gnus-image-text-deletable t)) + glyph) (defun gnus-remove-image (image) - (dolist (position (gnus-text-with-property 'display)) + (dolist (position (message-text-with-property 'display)) (when (equal (get-text-property position 'display) image) - (put-text-property position (1+ position) 'display nil)))) + (put-text-property position (1+ position) 'display nil) + (when (get-text-property position 'gnus-image-text-deletable) + (delete-region position (1+ position)))))) (defun-maybe assoc-ignore-case (key alist) "Like `assoc', but assumes KEY is a string and ignores case when comparing." diff --git a/lisp/gnus-fun.el b/lisp/gnus-fun.el index 978bccf..876b5e7 100644 --- a/lisp/gnus-fun.el +++ b/lisp/gnus-fun.el @@ -176,6 +176,9 @@ colors of the displayed X-Faces." (save-restriction (article-narrow-to-head) (gnus-article-goto-header "from") + (when (bobp) + (insert "From: \n") + (forward-char -2)) (gnus-add-image 'xface (gnus-put-image diff --git a/lisp/gnus-group.el b/lisp/gnus-group.el index afb29cf..8465b31 100644 --- a/lisp/gnus-group.el +++ b/lisp/gnus-group.el @@ -179,9 +179,6 @@ with some simple extensions. will be inserted into the buffer just like information from any other group specifier. -Text between %( and %) will be highlighted with `gnus-mouse-face' when -the mouse point move inside the area. There can only be one such area. - Note that this format specification is not always respected. For reasons of efficiency, when listing killed groups, this specification is ignored altogether. If the spec is changed considerably, your @@ -192,7 +189,11 @@ If you use %o or %O, reading the active file will be slower and quite a bit of extra memory will be used. %D will also worsen performance. Also note that if you change the format specification to include any of these specs, you must probably re-start Gnus to see them go into -effect." +effect. + +General format specifiers can also be used. +See (gnus)Formatting Variables." + :link '(custom-manual "(gnus)Formatting Variables") :group 'gnus-group-visual :type 'string) @@ -1880,13 +1881,15 @@ Returns whether the fetching was successful or not." ;; if selection was successful. (defun gnus-group-read-ephemeral-group (group method &optional activate quit-config request-only - select-articles) + select-articles + parameters) "Read GROUP from METHOD as an ephemeral group. If ACTIVATE, request the group first. If QUIT-CONFIG, use that window configuration when exiting from the ephemeral group. If REQUEST-ONLY, don't actually read the group; just request it. If SELECT-ARTICLES, only select those articles. +If PARAMETERS, use those as the group parameters. Return the name of the group if selection was successful." ;; Transform the select method into a unique server. @@ -1903,10 +1906,13 @@ Return the name of the group if selection was successful." group `(-1 nil (,group ,gnus-level-default-subscribed nil nil ,method - ((quit-config . - ,(if quit-config quit-config - (cons gnus-summary-buffer - gnus-current-window-configuration)))))) + ,(cons + (if quit-config + (cons 'quit-config quit-config) + (cons 'quit-config + (cons gnus-summary-buffer + gnus-current-window-configuration))) + parameters))) gnus-newsrc-hashtb) (push method gnus-ephemeral-servers) (set-buffer gnus-group-buffer) @@ -3701,7 +3707,11 @@ The hook gnus-suspend-gnus-hook is called before actually suspending." ;; Kill Gnus buffers except for group mode buffer. (let ((group-buf (get-buffer gnus-group-buffer))) (mapcar (lambda (buf) - (unless (member buf (list group-buf gnus-dribble-buffer)) + (unless (or (member buf (list group-buf gnus-dribble-buffer)) + (progn + (save-excursion + (set-buffer buf) + (eq major-mode 'message-mode)))) (gnus-kill-buffer buf))) (gnus-buffers)) (gnus-kill-gnus-frames) @@ -4021,22 +4031,28 @@ This command may read the active file." (defun gnus-group-mark-article-read (group article) "Mark ARTICLE read." - (gnus-activate-group group) (let ((buffer (gnus-summary-buffer-name group)) - (mark gnus-read-mark)) - (unless - (and - (get-buffer buffer) - (with-current-buffer buffer - (when gnus-newsgroup-prepared - (when (and gnus-newsgroup-auto-expire - (memq mark gnus-auto-expirable-marks)) - (setq mark gnus-expirable-mark)) - (setq mark (gnus-request-update-mark - group article mark)) - (gnus-mark-article-as-read article mark) - (setq gnus-newsgroup-active (gnus-active group)) - t))) + (mark gnus-read-mark) + active n) + (if (get-buffer buffer) + (with-current-buffer buffer + (setq active gnus-newsgroup-active) + (gnus-activate-group group) + (when gnus-newsgroup-prepared + (when (and gnus-newsgroup-auto-expire + (memq mark gnus-auto-expirable-marks)) + (setq mark gnus-expirable-mark)) + (setq mark (gnus-request-update-mark + group article mark)) + (gnus-mark-article-as-read article mark) + (setq gnus-newsgroup-active (gnus-active group)) + (when active + (setq n (1+ (cdr active))) + (while (<= n (cdr gnus-newsgroup-active)) + (unless (eq n article) + (push n gnus-newsgroup-unselected)) + (setq n (1+ n)))))) + (gnus-activate-group group) (gnus-group-make-articles-read group (list article)) (when (gnus-group-auto-expirable-p group) diff --git a/lisp/gnus-msg.el b/lisp/gnus-msg.el index 51d8a53..5dfbfd8 100644 --- a/lisp/gnus-msg.el +++ b/lisp/gnus-msg.el @@ -1,5 +1,5 @@ ;;; gnus-msg.el --- mail and post interface for Semi-gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Masanobu UMEDA @@ -137,11 +137,27 @@ See Info node `(gnus)Posting Styles'." (variable) (sexp))))))) -(defcustom gnus-inews-mark-gcc-as-read nil +(defcustom gnus-gcc-mark-as-read nil "If non-nil, automatically mark Gcc articles as read." :group 'gnus-message :type 'boolean) +(defvar gnus-inews-mark-gcc-as-read nil + "Obsolete variable. Use `gnus-gcc-mark-as-read' instead.") + +(make-obsolete-variable 'gnus-inews-mark-gcc-as-read + 'gnus-gcc-mark-as-read) + +(defcustom gnus-gcc-externalize-attachments nil + "Should local-file attachments be included as external parts in Gcc copies? +If it is `all', attach files as external parts; +if a regexp and matches the Gcc group name, attach files as external parts; +If nil, attach files as normal parts." + :group 'gnus-message + :type '(choice (const nil :tag "None") + (const all :tag "Any") + (string :tag "Regexp"))) + (defcustom gnus-group-posting-charset-alist '(("^\\(no\\|fr\\)\\.[^,]*\\(,[ \t\n]*\\(no\\|fr\\)\\.[^,]*\\)*$" iso-8859-1 (iso-8859-1)) ("^\\(fido7\\|relcom\\)\\.[^,]*\\(,[ \t\n]*\\(fido7\\|relcom\\)\\.[^,]*\\)*$" koi8-r (koi8-r)) @@ -558,12 +574,19 @@ a news." (defun gnus-summary-followup (yank &optional force-news) "Compose a followup to an article. -If prefix argument YANK is non-nil, original article is yanked automatically." +If prefix argument YANK is non-nil, the original article is yanked +automatically. +YANK is a list of elements, where the car of each element is the +article number, and the two following numbers is the region to be +yanked." (interactive (list (and current-prefix-arg (gnus-summary-work-articles 1)))) (when yank - (gnus-summary-goto-subject (car yank))) + (gnus-summary-goto-subject + (if (listp (car yank)) + (caar yank) + (car yank)))) (save-window-excursion (gnus-summary-select-article)) (let ((headers (gnus-summary-article-header (gnus-summary-article-number))) @@ -591,11 +614,15 @@ If prefix argument YANK is non-nil, original article is yanked automatically." (gnus-summary-followup (gnus-summary-work-articles arg) t)) (defun gnus-inews-yank-articles (articles) - (let ((more-than-one (cdr articles)) - (cur (current-buffer)) - refs beg article window) + (let (beg article yank-string + (more-than-one (cdr articles)) + (cur (current-buffer)) + refs window) (message-goto-body) (while (setq article (pop articles)) + (when (listp article) + (setq yank-string (nth 1 article) + article (nth 0 article))) (save-window-excursion (set-buffer gnus-summary-buffer) (gnus-summary-select-article nil nil nil article) @@ -611,11 +638,11 @@ If prefix argument YANK is non-nil, original article is yanked automatically." (when (setq window (get-buffer-window cur t)) (select-frame (window-frame window))))) - (gnus-copy-article-buffer) + (gnus-copy-article-buffer nil yank-string) (let ((message-reply-buffer gnus-article-copy) (message-reply-headers + ;; The headers are decoded. (with-current-buffer gnus-article-copy - ;; The headers are decoded. (nnheader-parse-head t)))) (message-yank-original) (setq beg (or beg (mark t)))) @@ -687,7 +714,7 @@ header line with the old Message-ID." -(defun gnus-copy-article-buffer (&optional article-buffer) +(defun gnus-copy-article-buffer (&optional article-buffer yank-string) ;; make a copy of the article buffer with all text properties removed ;; this copy is in the buffer gnus-article-copy. ;; if ARTICLE-BUFFER is nil, gnus-article-buffer is used @@ -712,6 +739,10 @@ header line with the old Message-ID." (let ((inhibit-read-only t)) (copy-to-buffer gnus-article-copy (point-min) (point-max)) (set-buffer gnus-article-copy) + (when yank-string + (message-goto-body) + (delete-region (point) (point-max)) + (insert yank-string)) ;; Encode bitmap smileys to ordinary text. ;; Possibly, the original text might be restored. (static-unless (featurep 'xemacs) @@ -735,8 +766,8 @@ header line with the old Message-ID." (goto-char (point-min)) (while (looking-at message-unix-mail-delimiter) (forward-line 1)) - (setq beg (point)) - (setq end (or (message-goto-body) beg)) + (setq beg (point) + end (or (message-goto-body) beg)) ;; Delete the headers from the displayed articles. (set-buffer gnus-article-copy) (delete-region (goto-char (point-min)) @@ -1006,7 +1037,10 @@ If VERY-WIDE, make a very wide reply." (gnus-summary-work-articles 1)))) ;; Stripping headers should be specified with mail-yank-ignored-headers. (when yank - (gnus-summary-goto-subject (car yank))) + (gnus-summary-goto-subject + (if (listp (car yank)) + (caar yank) + (car yank)))) (let ((gnus-article-reply (or yank (gnus-summary-article-number))) (headers "")) (gnus-setup-message (if yank 'reply-yank 'reply) @@ -1510,7 +1544,8 @@ this is a reply." (let ((gcc (or gcc (mail-fetch-field "gcc" nil t))) (coding-system-for-write 'raw-text) (output-coding-system 'raw-text) - groups group method group-art) + groups group method group-art + mml-externalize-attachments) (when gcc (message-remove-header "gcc") (widen) @@ -1524,6 +1559,10 @@ this is a reply." (car method)))) (unless (gnus-request-group group nil method) (gnus-request-create-group group method)) + (setq mml-externalize-attachments + (if (stringp gnus-gcc-externalize-attachments) + (string-match gnus-gcc-externalize-attachments group) + gnus-gcc-externalize-attachments)) (save-excursion (nnheader-set-temp-buffer " *acc*") (insert-buffer-substring message-encoding-buffer) @@ -1538,7 +1577,9 @@ this is a reply." (gnus-message 1 "Couldn't store article in group %s: %s" group (gnus-status-message method)) (sit-for 2)) - (when (and group-art gnus-inews-mark-gcc-as-read) + (when (and group-art + (or gnus-gcc-mark-as-read + gnus-inews-mark-gcc-as-read)) (gnus-group-mark-article-read group (cdr group-art))) (kill-buffer (current-buffer))))))))) diff --git a/lisp/gnus-picon.el b/lisp/gnus-picon.el index c9847a1..704c03a 100644 --- a/lisp/gnus-picon.el +++ b/lisp/gnus-picon.el @@ -1,6 +1,6 @@ ;;; gnus-picon.el --- displaying pretty icons in Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Wes Hardaker @@ -98,6 +98,7 @@ Some people may want to add \"unknown\" to this list." (defvar gnus-picon-glyph-alist nil "Picon glyphs cache. List of pairs (KEY . GLYPH) where KEY is either a filename or an URL.") +(defvar gnus-picon-cache nil) ;;; Functions: @@ -109,29 +110,30 @@ List of pairs (KEY . GLYPH) where KEY is either a filename or an URL.") (split-string (car address) "\\.")))) (defun gnus-picon-find-face (address directories &optional exact) - (let* ((databases gnus-picon-databases) - (address (gnus-picon-split-address address)) + (let* ((address (gnus-picon-split-address address)) (user (pop address)) - database directory found instance base) - (while (and (not found) - (setq database (pop databases))) - (while (and (not found) - (setq directory (pop directories))) - (setq base (expand-file-name directory database)) - ;; Kludge to search misc/MISC for users. - (when (string= directory "misc") - (setq address '("MISC"))) - (while (and (not found) - address) - (setq found (gnus-picon-find-image - (concat base "/" (mapconcat 'identity - (reverse address) - "/") - "/" user "/"))) - (if exact - (setq address nil) - (pop address))))) - found)) + (faddress address) + database directory result instance base) + (catch 'found + (dolist (database gnus-picon-databases) + (dolist (directory directories) + (setq address faddress + base (expand-file-name directory database)) + (while address + (when (setq result (gnus-picon-find-image + (concat base "/" (mapconcat 'identity + (reverse address) + "/") + "/" user "/"))) + (throw 'found result)) + (if exact + (setq address nil) + (pop address))) + ;; Kludge to search MISC as well. But not in "news". + (unless (string= directory "news") + (when (setq result (gnus-picon-find-image + (concat base "/MISC/" user "/"))) + (throw 'found result)))))))) (defun gnus-picon-find-image (directory) (let ((types gnus-picon-file-types) @@ -163,67 +165,78 @@ GLYPH can be either a glyph or a string." (gnus-with-article-headers (let ((addresses (mail-header-parse-addresses (mail-fetch-field header))) - first spec file) + spec file point cache) (dolist (address addresses) - (setq address (car address) - first t) + (setq address (car address)) (when (and (stringp address) (setq spec (gnus-picon-split-address address))) - (when (setq file (gnus-picon-find-face - address gnus-picon-user-directories)) - (setcar spec (cons (gnus-picon-create-glyph file) - (car spec)))) - (dotimes (i (1- (length spec))) - (when (setq file (gnus-picon-find-face - (concat "unknown@" - (mapconcat - 'identity (nthcdr (1+ i) spec) ".")) - gnus-picon-domain-directories t)) - (setcar (nthcdr (1+ i) spec) - (cons (gnus-picon-create-glyph file) - (nth (1+ i) spec))))) + (if (setq cache (cdr (assoc address gnus-picon-cache))) + (setq spec cache) + (when (setq file (or (gnus-picon-find-face + address gnus-picon-user-directories) + (gnus-picon-find-face + (concat "unknown@" + (mapconcat + 'identity (cdr spec) ".")) + gnus-picon-user-directories))) + (setcar spec (cons (gnus-picon-create-glyph file) + (car spec)))) + + (dotimes (i (1- (length spec))) + (when (setq file (gnus-picon-find-face + (concat "unknown@" + (mapconcat + 'identity (nthcdr (1+ i) spec) ".")) + gnus-picon-domain-directories t)) + (setcar (nthcdr (1+ i) spec) + (cons (gnus-picon-create-glyph file) + (nth (1+ i) spec))))) + (setq spec (nreverse spec)) + (push (cons address spec) gnus-picon-cache)) (gnus-article-goto-header header) (mail-header-narrow-to-field) (when (search-forward address nil t) (delete-region (match-beginning 0) (match-end 0)) + (setq point (point)) (while spec - (gnus-picon-insert-glyph (pop spec) category) - (when spec - (if (not first) - (insert ".") - (insert "@") - (setq first nil)))))))))) + (goto-char point) + (if (> (length spec) 2) + (insert ".") + (if (= (length spec) 2) + (insert "@"))) + (gnus-picon-insert-glyph (pop spec) category)))))))) (defun gnus-picon-transform-newsgroups (header) (interactive) (gnus-with-article-headers - (let ((groups - (sort - (message-tokenize-header (mail-fetch-field header)) - (lambda (g1 g2) (> (length g1) (length g2))))) - spec file) + (gnus-article-goto-header header) + (mail-header-narrow-to-field) + (let ((groups (message-tokenize-header (mail-fetch-field header))) + spec file point) (dolist (group groups) - (setq spec (nreverse (split-string group "[.]"))) - (dotimes (i (length spec)) - (when (setq file (gnus-picon-find-face - (concat "unknown@" - (mapconcat - 'identity (nthcdr i spec) ".")) - gnus-picon-news-directories t)) - (setcar (nthcdr i spec) - (cons (gnus-picon-create-glyph file) - (nth i spec))))) - - (gnus-article-goto-header header) - (mail-header-narrow-to-field) + (unless (setq spec (cdr (assoc group gnus-picon-cache))) + (setq spec (nreverse (split-string group "[.]"))) + (dotimes (i (length spec)) + (when (setq file (gnus-picon-find-face + (concat "unknown@" + (mapconcat + 'identity (nthcdr i spec) ".")) + gnus-picon-news-directories t)) + (setcar (nthcdr i spec) + (cons (gnus-picon-create-glyph file) + (nth i spec))))) + (push (cons group spec) gnus-picon-cache)) (when (search-forward group nil t) (delete-region (match-beginning 0) (match-end 0)) - (setq spec (nreverse spec)) - (while spec - (gnus-picon-insert-glyph (pop spec) 'newsgroups-picon) - (when spec - (insert ".")))))))) + (save-restriction + (narrow-to-region (point) (point)) + (while spec + (goto-char (point-min)) + (if (> (length spec) 1) + (insert ".")) + (gnus-picon-insert-glyph (pop spec) 'newsgroups-picon)) + (goto-char (point-max)))))))) ;;; Commands: diff --git a/lisp/gnus-score.el b/lisp/gnus-score.el index 171c026..6da1cb0 100644 --- a/lisp/gnus-score.el +++ b/lisp/gnus-score.el @@ -1243,7 +1243,6 @@ EXTRA is the possible non-standard header." (setq gnus-newsgroup-adaptive t) adapt) (t - ;;(setq gnus-newsgroup-adaptive gnus-use-adaptive-scoring) gnus-default-adaptive-score-alist))) (setq gnus-thread-expunge-below (or thread-mark-and-expunge gnus-thread-expunge-below)) diff --git a/lisp/gnus-spec.el b/lisp/gnus-spec.el index ce0460c..edaf2ea 100644 --- a/lisp/gnus-spec.el +++ b/lisp/gnus-spec.el @@ -32,7 +32,7 @@ (require 'alist) (require 'gnus) -(defcustom gnus-use-correct-string-widths t +(defcustom gnus-use-correct-string-widths (featurep 'xemacs) "*If non-nil, use correct functions for dealing with wide characters." :group 'gnus-format :type 'boolean) @@ -328,11 +328,11 @@ "Return a form that limits EL to MAX-WIDTH." (let ((max (abs max-width)) (length-fun (if gnus-use-correct-string-widths - 'gnus-correct-length - 'length)) + 'gnus-correct-length + 'length)) (substring-fun (if gnus-use-correct-string-widths - 'gnus-correct-substring - 'substring))) + 'gnus-correct-substring + 'substring))) (if (symbolp el) `(if (> (,length-fun ,el) ,max) ,(if (< max-width 0) @@ -377,21 +377,26 @@ (if (equal val ,ignore-value) "" val)))) -(defun gnus-correct-pad-form (el pad-width) +(defun gnus-pad-form (el pad-width) "Return a form that pads EL to PAD-WIDTH accounting for multi-column characters correctly. This is because `format' may pad to columns or to characters when given a pad value." (let ((pad (abs pad-width)) (side (< 0 pad-width))) (if (symbolp el) - `(let ((need (- ,pad (gnus-correct-length ,el)))) + `(let ((need (- ,pad (,(if gnus-use-correct-string-widths + 'gnus-correct-length + 'length) + ,el)))) (if (> need 0) (concat ,(when side '(make-string need ?\ )) ,el ,(when (not side) '(make-string need ?\ ))) ,el)) `(let* ((val (eval ,el)) - (need (- ,pad (gnus-correct-length ,el)))) + (need (- ,pad (,(if gnus-use-correct-string-widths + 'gnus-correct-length + 'length) ,el)))) (if (> need 0) (concat ,(when side '(make-string need ?\ )) ,el @@ -407,9 +412,9 @@ characters when given a pad value." ;; them will have the balloon-help text property. (let ((case-fold-search nil)) (if (string-match - "\\`\\(.*\\)%[0-9]?[{(«]\\(.*\\)%[0-9]?[»})]\\(.*\n?\\)\\'" - format) - (gnus-parse-complex-format format spec-alist) + "\\`\\(.*\\)%[0-9]?[{(«]\\(.*\\)%[0-9]?[»})]\\(.*\n?\\)\\'\\|%[-0-9]*=" + format) + (gnus-parse-complex-format format spec-alist) ;; This is a simple format. (gnus-parse-simple-format format spec-alist insert)))) @@ -604,7 +609,7 @@ characters when given a pad value." (when max-width (setq el (gnus-tilde-max-form el max-width))) (when pad-width - (setq el (gnus-correct-pad-form el pad-width))) + (setq el (gnus-pad-form el pad-width))) (push el flist))) (insert elem-type) (push (car elem) flist)))) diff --git a/lisp/gnus-srvr.el b/lisp/gnus-srvr.el index e49c9fe..eb0ba28 100644 --- a/lisp/gnus-srvr.el +++ b/lisp/gnus-srvr.el @@ -1,5 +1,5 @@ ;;; gnus-srvr.el --- virtual server support for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -55,7 +55,11 @@ The following specs are understood: %n name %w address %s status -%a agent covered" +%a agent covered + +General format specifiers can also be used. +See (gnus)Formatting Variables." + :link '(custom-manual "(gnus)Formatting Variables") :group 'gnus-server-visual :type 'string) diff --git a/lisp/gnus-start.el b/lisp/gnus-start.el index b570854..fb983be 100644 --- a/lisp/gnus-start.el +++ b/lisp/gnus-start.el @@ -415,17 +415,14 @@ Can be used to turn version control on or off." :group 'gnus-newsrc :type 'boolean) -(defvar gnus-startup-file-coding-system (static-if (boundp 'MULE) - '*ctext* - 'ctext) - "*Coding system for startup file.") +;;; Internal variables -(defvar gnus-ding-file-coding-system gnus-startup-file-coding-system - "*Coding system for ding file.") +(defvar gnus-ding-file-coding-system (static-if (boundp 'MULE) + '*ctext* + 'ctext) + "Coding system for ding file.") ;; Note that the ding file for T-gnus ought not to have byte-codes. -;;; Internal variables - (defvar gnus-newsrc-file-version nil) (defvar gnus-override-subscribe-method nil) (defvar gnus-dribble-buffer nil) @@ -452,21 +449,15 @@ Can be used to turn version control on or off." (if gnus-init-inhibit (setq gnus-init-inhibit nil) (setq gnus-init-inhibit inhibit-next) - (let ((files (list gnus-site-init-file gnus-init-file)) - file) - (while files - (and (setq file (pop files)) - (or (and (file-exists-p file) - ;; Don't try to load a directory. - (not (file-directory-p file))) - (file-exists-p (concat file ".el")) - (file-exists-p (concat file ".elc"))) - (if (or debug-on-error debug-on-quit) - (load file nil t) - (condition-case var - (load file nil t) - (error - (error "Error in %s: %s" file var)))))))))) + (dolist (file (list gnus-site-init-file gnus-init-file)) + (when (and file + (locate-library file)) + (if (or debug-on-error debug-on-quit) + (load file nil t) + (condition-case var + (load file nil t) + (error + (error "Error in %s: %s" file var))))))))) ;; For subscribing new newsgroup diff --git a/lisp/gnus-sum.el b/lisp/gnus-sum.el index 66b3528..92428dd 100644 --- a/lisp/gnus-sum.el +++ b/lisp/gnus-sum.el @@ -1,5 +1,5 @@ ;;; gnus-sum.el --- summary mode commands for Semi-gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -246,6 +246,7 @@ simplification is selected." (defcustom gnus-thread-hide-subtree nil "*If non-nil, hide all threads initially. +This can be a predicate specifier which says which threads to hide. If threads are hidden, you have to run the command `gnus-summary-show-thread' by hand or use `gnus-select-article-hook' to expose hidden threads." @@ -597,7 +598,11 @@ list of parameters to that command." It works along the same lines as a normal formatting string, with some simple extensions. -%S The subject" +%S The subject + +General format specifiers can also be used. +See (gnus)Formatting Variables." + :link '(custom-manual "(gnus)Formatting Variables") :group 'gnus-threading :type 'string) @@ -682,7 +687,9 @@ was sent, sorting by number means sorting by arrival time.) Ready-made functions include `gnus-thread-sort-by-number', `gnus-thread-sort-by-author', `gnus-thread-sort-by-subject', -`gnus-thread-sort-by-date', `gnus-thread-sort-by-score' and +`gnus-thread-sort-by-date', `gnus-thread-sort-by-score', +`gnus-thread-sort-by-most-recent-number', +`gnus-thread-sort-by-most-recent-date', and `gnus-thread-sort-by-total-score' (see `gnus-thread-score-function'). When threading is turned off, the variable @@ -774,15 +781,14 @@ If you'd like to simplify subjects like the `gnus-summary-next-same-subject' command does, you can use the following hook: - (setq gnus-select-group-hook - (list - (lambda () - (mapcar (lambda (header) - (mail-header-set-subject - header - (gnus-simplify-subject - (mail-header-subject header) 're-only))) - gnus-newsgroup-headers))))" + (add-hook gnus-select-group-hook + (lambda () + (mapcar (lambda (header) + (mail-header-set-subject + header + (gnus-simplify-subject + (mail-header-subject header) 're-only))) + gnus-newsgroup-headers)))" :group 'gnus-group-select :type 'hook) @@ -922,7 +928,7 @@ which it may alter in any way.") (mime-find-field-decoder 'From 'nov) "Variable that says which function should be used to decode a string with encoded words.") -(defcustom gnus-extra-headers nil +(defcustom gnus-extra-headers '(To Newsgroups) "*Extra headers to parse." :version "21.1" :group 'gnus-summary @@ -1741,9 +1747,7 @@ increase the score of each group you read." "l" gnus-summary-stop-page-breaking "r" gnus-summary-caesar-message "t" gnus-article-toggle-headers - "g" gnus-summary-toggle-smiley - "u" gnus-article-treat-unfold-headers - "n" gnus-article-treat-fold-newsgroups + "g" gnus-treat-smiley "v" gnus-summary-verbose-headers "m" gnus-summary-toggle-mime "a" gnus-article-strip-headers-in-body ;; mnemonic: wash archive @@ -1769,9 +1773,15 @@ increase the score of each group you read." "c" gnus-article-highlight-citation "s" gnus-article-highlight-signature) + (gnus-define-keys (gnus-summary-wash-header-map "G" gnus-summary-wash-map) + "f" gnus-article-treat-fold-headers + "u" gnus-article-treat-unfold-headers + "n" gnus-article-treat-fold-newsgroups) + (gnus-define-keys (gnus-summary-wash-display-map "D" gnus-summary-wash-map) "x" gnus-article-display-x-face - "s" gnus-summary-toggle-smiley + "s" gnus-treat-smiley + "D" gnus-article-remove-images "f" gnus-treat-from-picon "m" gnus-treat-mail-picon "n" gnus-treat-newsgroups-picon) @@ -1905,7 +1915,8 @@ increase the score of each group you read." ["Lapsed" gnus-article-date-lapsed t] ["User-defined" gnus-article-date-user t]) ("Display" - ["Toggle smiley" gnus-summary-toggle-smiley t] + ["Remove images" gnus-article-remove-images t] + ["Toggle smiley" gnus-treat-smiley t] ["Show X-Face" gnus-article-display-x-face t] ["Show picons in From" gnus-treat-from-picon t] ["Show picons in mail headers" gnus-treat-mail-picon t] @@ -2005,7 +2016,7 @@ increase the score of each group you read." ["Fetch article with id..." gnus-summary-refer-article t] ["Setup Mailing List Params" gnus-mailing-list-insinuate t] ["Redisplay" gnus-summary-show-article t] - ["Raw article" gnus-summary-show-raw-article t]))) + ["Raw article" gnus-summary-show-raw-article :keys "C-u g"]))) (easy-menu-define gnus-summary-article-menu gnus-summary-mode-map "" (cons "Article" innards)) @@ -2060,6 +2071,10 @@ increase the score of each group you read." ["Wide reply and yank" gnus-summary-wide-reply-with-original ,@(if (featurep 'xemacs) '(t) '(:help "Mail a reply, quoting this article"))] + ["Very wide reply" gnus-summary-very-wide-reply t] + ["Very wide reply and yank" gnus-summary-very-wide-reply-with-original + ,@(if (featurep 'xemacs) '(t) + '(:help "Mail a very wide reply, quoting this article"))] ["Mail forward" gnus-summary-mail-forward t] ["Post forward" gnus-summary-post-forward t] ["Digest and mail" gnus-summary-digest-mail-forward t] @@ -3287,9 +3302,7 @@ If SHOW-ALL is non-nil, already read articles are also listed." ;; Hide conversation thread subtrees. We cannot do this in ;; gnus-summary-prepare-hook since kill processing may not ;; work with hidden articles. - (and gnus-show-threads - gnus-thread-hide-subtree - (gnus-summary-hide-all-threads)) + (gnus-summary-maybe-hide-threads) (when kill-buffer (gnus-kill-or-deaden-summary kill-buffer)) (gnus-summary-auto-select-subject) @@ -4165,15 +4178,47 @@ Unscored articles will be counted as having a score of zero." (defun gnus-thread-total-score (thread) ;; This function find the total score of THREAD. - (cond ((null thread) - 0) - ((consp thread) - (if (stringp (car thread)) - (apply gnus-thread-score-function 0 - (mapcar 'gnus-thread-total-score-1 (cdr thread))) - (gnus-thread-total-score-1 thread))) - (t - (gnus-thread-total-score-1 (list thread))))) + (cond + ((null thread) + 0) + ((consp thread) + (if (stringp (car thread)) + (apply gnus-thread-score-function 0 + (mapcar 'gnus-thread-total-score-1 (cdr thread))) + (gnus-thread-total-score-1 thread))) + (t + (gnus-thread-total-score-1 (list thread))))) + +(defun gnus-thread-sort-by-most-recent-number (h1 h2) + "Sort threads such that the thread with the most recently arrived article comes first." + (> (gnus-thread-highest-number h1) (gnus-thread-highest-number h2))) + +(defun gnus-thread-highest-number (thread) + "Return the highest article number in THREAD." + (apply 'max (mapcar (lambda (header) + (mail-header-number header)) + (message-flatten-list thread)))) + +(defun gnus-thread-sort-by-most-recent-date (h1 h2) + "Sort threads such that the thread with the most recently dated article comes first." + (> (gnus-thread-latest-date h1) (gnus-thread-latest-date h2))) + +(defun gnus-thread-latest-date (thread) + "Return the highest article date in THREAD." + (let ((previous-time 0)) + (apply 'max (mapcar + (lambda (header) + (setq previous-time + (time-to-seconds + (mail-header-parse-date + (condition-case () + (mail-header-date header) + (error previous-time)))))) + (sort + (message-flatten-list thread) + (lambda (h1 h2) + (< (mail-header-number h1) + (mail-header-number h2)))))))) (defun gnus-thread-total-score-1 (root) ;; This function find the total score of the thread below ROOT. @@ -6184,10 +6229,11 @@ The state which existed when entering the ephemeral is reset." (suppress-keymap gnus-dead-summary-mode-map) (substitute-key-definition 'undefined 'gnus-summary-wake-up-the-dead gnus-dead-summary-mode-map) - (let ((keys '("\C-d" "\r" "\177" [delete]))) - (while keys - (define-key gnus-dead-summary-mode-map - (pop keys) 'gnus-summary-wake-up-the-dead)))) + (dolist (key '("\C-d" "\r" "\177" [delete])) + (define-key gnus-dead-summary-mode-map + key 'gnus-summary-wake-up-the-dead)) + (dolist (key '("q" "Q")) + (define-key gnus-dead-summary-mode-map key 'bury-buffer))) (defvar gnus-dead-summary-mode nil "Minor mode for Gnus summary buffers.") @@ -6369,9 +6415,12 @@ Returns the article selected or nil if there are no unread articles." (and (not (and undownloaded (eq gnus-undownloaded-mark (gnus-data-mark (car data))))) - (not (and unseen - (memq (car data) gnus-newsgroup-unseen))) - (not (gnus-data-unread-p (car data))))) + (if unseen + (or (not (memq + (gnus-data-number (car data)) + gnus-newsgroup-unseen)) + (not (gnus-data-unread-p (car data)))) + (not (gnus-data-unread-p (car data)))))) (setq data (cdr data))) (when data (goto-char (gnus-data-pos (car data))) @@ -6462,7 +6511,8 @@ Given a prefix, will force an `article' buffer configuration." (when (gnus-buffer-live-p gnus-article-buffer) (with-current-buffer gnus-article-buffer (setq gnus-article-charset gnus-newsgroup-charset) - (setq gnus-article-ignored-charsets gnus-newsgroup-ignored-charsets))) + (setq gnus-article-ignored-charsets gnus-newsgroup-ignored-charsets) + (set-buffer-multibyte t))) (if (null article) nil (prog1 @@ -7242,9 +7292,7 @@ If ALL, mark even excluded ticked and dormants as read." ;; according to the new limit. (gnus-summary-prepare) ;; Hide any threads, possibly. - (and gnus-show-threads - gnus-thread-hide-subtree - (gnus-summary-hide-all-threads)) + (gnus-summary-maybe-hide-threads) ;; Try to return to the article you were at, or one in the ;; neighborhood. (when data @@ -7657,7 +7705,10 @@ to guess what the document format is." (gnus-group-read-ephemeral-group name `(nndoc ,name (nndoc-address ,(get-buffer dig)) (nndoc-article-type - ,(if force 'mbox 'guess))) t)) + ,(if force 'mbox 'guess))) + t nil nil nil + `((adapt-file . ,(gnus-score-file-name gnus-newsgroup-name + "ADAPT"))))) ;; Make all postings to this group go to the parent group. (nconc (gnus-info-params (gnus-get-info name)) params) @@ -8115,13 +8166,10 @@ are `C-u g'." (let ((gnus-newsgroup-charset (or (cdr (assq arg gnus-summary-show-article-charset-alist)) (mm-read-coding-system - "View as charset: " + "View as charset: " ;; actually it is coding system. (save-excursion (set-buffer gnus-article-buffer) - (let ((coding-systems - (detect-coding-region (point) (point-max)))) - (or (car-safe coding-systems) - coding-systems)))))) + (mm-detect-coding-region (point) (point-max)))))) (gnus-newsgroup-ignored-charsets 'gnus-all)) (gnus-summary-select-article nil 'force) (let ((deps gnus-newsgroup-dependencies) @@ -8880,13 +8928,6 @@ groups." (execute-kbd-macro (concat (this-command-keys) key)) (gnus-article-edit-done)) -(defun gnus-summary-toggle-smiley (&optional arg) - "Toggle the display of smilies as small graphical icons." - (interactive "P") - (save-excursion - (set-buffer gnus-article-buffer) - (gnus-smiley-display arg))) - ;;; Respooling (defun gnus-summary-respool-query (&optional silent trace) @@ -9805,18 +9846,49 @@ Returns nil if no thread was there to be shown." (goto-char orig) (gnus-summary-position-point)))) -(defun gnus-summary-hide-all-threads () - "Hide all thread subtrees." +(defun gnus-summary-maybe-hide-threads () + "If requested, hide the threads that should be hidden." + (when (and gnus-show-threads + gnus-thread-hide-subtree) + (gnus-summary-hide-all-threads + (if (or (consp gnus-thread-hide-subtree) + (gnus-functionp gnus-thread-hide-subtree)) + (gnus-make-predicate gnus-thread-hide-subtree) + nil)))) + +;;; Hiding predicates. + +(defun gnus-article-unread-p (header) + (memq (mail-header-number header) gnus-newsgroup-unreads)) + +(defun gnus-article-unseen-p (header) + (memq (mail-header-number header) gnus-newsgroup-unseen)) + +(defun gnus-map-articles (predicate articles) + "Map PREDICATE over ARTICLES and return non-nil if any predicate is non-nil." + (apply 'gnus-or (mapcar predicate + (mapcar 'gnus-summary-article-header articles)))) + +(defun gnus-summary-hide-all-threads (&optional predicate) + "Hide all thread subtrees. +If PREDICATE is supplied, threads that satisfy this predicate +will not be hidden." (interactive) (save-excursion (goto-char (point-min)) - (gnus-summary-hide-thread) - (while (zerop (gnus-summary-next-thread 1 t)) - (gnus-summary-hide-thread))) + (let ((end nil)) + (while (not end) + (when (or (not predicate) + (gnus-map-articles + predicate (gnus-summary-article-children))) + (gnus-summary-hide-thread)) + (setq end (not (zerop (gnus-summary-next-thread 1 t))))))) (gnus-summary-position-point)) (defun gnus-summary-hide-thread () "Hide thread subtrees. +If PREDICATE is supplied, threads that satisfy this predicate +will not be hidden. Returns nil if no threads were there to be hidden." (interactive) (let ((buffer-read-only nil) @@ -10012,8 +10084,7 @@ Argument REVERSE means reverse order." ;; We do the sorting by regenerating the threads. (gnus-summary-prepare) ;; Hide subthreads if needed. - (when (and gnus-show-threads gnus-thread-hide-subtree) - (gnus-summary-hide-all-threads)))) + (gnus-summary-maybe-hide-threads))) (defun gnus-summary-sort (predicate reverse) "Sort summary buffer by PREDICATE. REVERSE means reverse order." @@ -10036,8 +10107,7 @@ Argument REVERSE means reverse order." ;; We do the sorting by regenerating the threads. (gnus-summary-prepare) ;; Hide subthreads if needed. - (when (and gnus-show-threads gnus-thread-hide-subtree) - (gnus-summary-hide-all-threads)))) + (gnus-summary-maybe-hide-threads))) ;; Summary saving commands. @@ -11076,7 +11146,8 @@ If ALL is a number, fetch this number of articles." (setq older (subseq older 0 all)))))))) (if (not older) (message "No old news.") - (gnus-summary-insert-articles older) + (let ((gnus-fetch-old-headers t)) + (gnus-summary-insert-articles older)) (gnus-summary-limit (gnus-union older old)))) (gnus-summary-position-point))) diff --git a/lisp/gnus-topic.el b/lisp/gnus-topic.el index 53072f2..88f4a6e 100644 --- a/lisp/gnus-topic.el +++ b/lisp/gnus-topic.el @@ -1,5 +1,5 @@ ;;; gnus-topic.el --- a folding minor mode for Gnus group buffers -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Ilja Weis @@ -61,7 +61,10 @@ with some simple extensions. %g Number of groups in the topic. %a Number of unread articles in the groups in the topic. %A Number of unread articles in the groups in the topic and its subtopics. -" + +General format specifiers can also be used. +See (gnus)Formatting Variables." + :link '(custom-manual "(gnus)Formatting Variables") :type 'string :group 'gnus-topic) @@ -250,6 +253,28 @@ If RECURSIVE is t, return groups in its subtopics too." (cdr recursive))) visible-groups)) +(defun gnus-topic-goto-previous-topic (n) + "Go to the N'th previous topic." + (interactive "p") + (gnus-topic-goto-next-topic (- n))) + +(defun gnus-topic-goto-next-topic (n) + "Go to the N'th next topic." + (interactive "p") + (let ((backward (< n 0)) + (n (abs n)) + (topic (gnus-current-topic))) + (while (and (> n 0) + (setq topic + (if backward + (gnus-topic-previous-topic topic) + (gnus-topic-next-topic topic)))) + (gnus-topic-goto-topic topic) + (setq n (1- n))) + (when (/= 0 n) + (gnus-message 7 "No more topics")) + n)) + (defun gnus-topic-previous-topic (topic) "Return the previous topic on the same level as TOPIC." (let ((top (cddr (gnus-topic-find-topology @@ -1029,6 +1054,8 @@ articles in the topic and its subtopics." "j" gnus-topic-jump-to-topic "M" gnus-topic-move-matching "C" gnus-topic-copy-matching + "\M-p" gnus-topic-goto-previous-topic + "\M-n" gnus-topic-goto-next-topic "\C-i" gnus-topic-indent [tab] gnus-topic-indent "r" gnus-topic-rename @@ -1068,6 +1095,8 @@ articles in the topic and its subtopics." ["Mark" gnus-topic-mark-topic t] ["Indent" gnus-topic-indent t] ["Sort" gnus-topic-sort-topics t] + ["Previous topic" gnus-topic-goto-previous-topic t] + ["Next topic" gnus-topic-goto-next-topic t] ["Toggle hide empty" gnus-topic-toggle-display-empty-topics t] ["Edit parameters" gnus-topic-edit-parameters t]) ["List active" gnus-topic-list-active t])))) diff --git a/lisp/gnus-util.el b/lisp/gnus-util.el index a332aa3..85a3646 100644 --- a/lisp/gnus-util.el +++ b/lisp/gnus-util.el @@ -1,5 +1,5 @@ ;;; gnus-util.el --- utility functions for Semi-gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -247,17 +247,6 @@ (delete-char 1)) (goto-char (next-single-property-change (point) prop nil (point-max)))))) -(defun gnus-text-with-property (prop) - "Return a list of all points where the text has PROP." - (let ((points nil) - (point (point-min))) - (save-excursion - (while (< point (point-max)) - (when (get-text-property point prop) - (push point points)) - (incf point))) - (nreverse points))) - (require 'nnheader) (defun gnus-newsgroup-directory-form (newsgroup) "Make hierarchical directory name from NEWSGROUP name." @@ -1264,6 +1253,31 @@ forbidden in URL encoding." (setq tmp (concat tmp str)) tmp)) +(defun gnus-make-predicate (spec) + "Transform SPEC into a function that can be called. +SPEC is a predicate specifier that contains stuff like `or', `and', +`not', lists and functions. The functions all take one parameter." + `(lambda (elem) ,(gnus-make-predicate-1 spec))) + +(defun gnus-make-predicate-1 (spec) + (cond + ((symbolp spec) + `(,spec elem)) + ((listp spec) + (if (memq (car spec) '(or and not)) + `(,(car spec) ,@(mapcar 'gnus-make-predicate-1 (cdr spec))) + (error "Invalid predicate specifier: %s" spec))))) + +(defun gnus-local-map-property (map) + "Return a list suitable for a text property list specifying keymap MAP." + (cond + ((featurep 'xemacs) + (list 'keymap map)) + ((>= emacs-major-version 21) + (list 'keymap map)) + (t + (list 'local-map map)))) + (provide 'gnus-util) ;;; gnus-util.el ends here diff --git a/lisp/gnus-vers.el b/lisp/gnus-vers.el index a53dc26..21d7083 100644 --- a/lisp/gnus-vers.el +++ b/lisp/gnus-vers.el @@ -34,16 +34,16 @@ (require 'product) (provide 'gnus-vers) -(defconst gnus-revision-number "10" +(defconst gnus-revision-number "00" "Revision number for this version of gnus.") ;; Product information of this gnus. (product-provide 'gnus-vers (product-define "T-gnus" nil - (list 6 15 4 + (list 6 15 5 (string-to-number gnus-revision-number)))) -(defconst gnus-original-version-number "0.04" +(defconst gnus-original-version-number "0.05" "Version number for this version of Gnus.") (provide 'running-pterodactyl-gnus-0_73-or-later) diff --git a/lisp/gnus-xmas.el b/lisp/gnus-xmas.el index 022b936..ddcdfae 100644 --- a/lisp/gnus-xmas.el +++ b/lisp/gnus-xmas.el @@ -1,6 +1,6 @@ ;;; gnus-xmas.el --- Gnus functions for XEmacs -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -721,41 +721,6 @@ XEmacs compatibility workaround." 'call-process-region (point-min) (point-max) command t '(t nil) nil args)) -(defface gnus-x-face '((t (:foreground "black" :background "white"))) - "Face to show X face" - :group 'gnus-xmas) - -(defun gnus-xmas-article-display-xface (data) - "Display the XFace in DATA." - (save-excursion - (let ((xface-glyph - (cond - ((featurep 'xface) - (make-glyph (vector 'xface :data - (concat "X-Face: " data)))) - ((featurep 'xpm) - (let ((cur (current-buffer))) - (save-excursion - (gnus-set-work-buffer) - (insert data) - (let ((coding-system-for-read 'binary) - (coding-system-for-write 'binary)) - (gnus-xmas-call-region "uncompface") - (goto-char (point-min)) - (insert "/* Width=48, Height=48 */\n") - (gnus-xmas-call-region "icontopbm") - (gnus-xmas-call-region "ppmtoxpm") - (make-glyph - (vector 'xpm :data (buffer-string))))))) - (t - (make-glyph [nothing]))))) - ;;(set-glyph-face xface-glyph 'gnus-x-face) - - (gnus-article-goto-header "from") - (gnus-put-image xface-glyph " ") - (gnus-add-wash-type 'xface) - (gnus-add-image 'xface xface-glyph)))) - (defvar gnus-xmas-modeline-left-extent (let ((ext (copy-extent modeline-buffer-id-left-extent))) ext)) @@ -935,6 +900,8 @@ XEmacs compatibility workaround." Warning: Don't insert text immediately after the image." (let ((begin (point)) extent) + (if (and (bobp) (not string)) + (setq string " ")) (if string (insert string) (setq begin (1- begin))) diff --git a/lisp/gnus.el b/lisp/gnus.el index 87b1852..0edf11c 100644 --- a/lisp/gnus.el +++ b/lisp/gnus.el @@ -1,5 +1,5 @@ ;;; gnus.el --- a newsreader for GNU Emacs -;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, +;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, ;; 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA @@ -272,6 +272,11 @@ is restarted, and sometimes reloaded." :link '(custom-manual "(gnus)Exiting Gnus") :group 'gnus) +(defgroup gnus-fun nil + "Frivolous Gnus extensions." + :link '(custom-manual "(gnus)Exiting Gnus") + :group 'gnus) + (defcustom gnus-inhibit-startup-message nil "If non-nil, the startup message will not be displayed. This variable is used before `.gnus.el' is loaded, so it should @@ -800,17 +805,17 @@ be set in `.emacs' instead." (berry "#cc6485" "#ff7db5") (dino "#724214" "#1e3f03") (oort "#cccccc" "#888888") + (storm "#666699" "#99ccff") + (pdino "#9999cc" "#99ccff") + (purp "#9999cc" "#666699") (neutral "#b4b4b4" "#878787") (september "#bf9900" "#ffcc00")) "Color alist used for the Gnus logo.") (defcustom gnus-logo-color-style 'oort "*Color styles used for the Gnus logo." - :type '(choice (const flame) (const pine) (const moss) - (const irish) (const sky) (const tin) - (const velvet) (const grape) (const labia) - (const berry) (const neutral) (const september) - (const dino)) + :type `(choice ,@(mapcar (lambda (elem) (list 'const (car elem))) + gnus-logo-color-alist)) :group 'gnus-xmas) (defvar gnus-logo-colors @@ -2046,6 +2051,8 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.") gnus-demon-remove-handler) ("gnus-demon" :interactive t gnus-demon-init gnus-demon-cancel) + ("gnus-fun" gnus-convert-gray-x-face-to-xpm gnus-display-x-face-in-from + gnus-convert-image-to-gray-x-face) ("gnus-salt" gnus-highlight-selected-tree gnus-possibly-generate-tree gnus-tree-open gnus-tree-close gnus-carpal-setup-buffer) ("gnus-nocem" gnus-nocem-scan-groups gnus-nocem-close @@ -2120,7 +2127,7 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.") ("gnus-picon" :interactive t gnus-treat-from-picon) ("gnus-gl" bbb-login bbb-logout bbb-grouplens-group-p gnus-grouplens-mode) - ("smiley" :interactive t gnus-smiley-display) + ("smiley" :interactive t smiley-region) ("gnus-win" gnus-configure-windows gnus-add-configuration) ("gnus-sum" gnus-summary-insert-line gnus-summary-read-group gnus-list-of-unread-articles gnus-list-of-read-articles @@ -2227,7 +2234,7 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.") ;;; gnus-sum.el thingies -(defcustom gnus-summary-line-format "%U%R%z%I%(%[%4L: %-23,23n%]%) %s\n" +(defcustom gnus-summary-line-format "%U%R%z%I%(%[%4L: %-23,23f%]%) %s\n" "*The format specification of the lines in the summary buffer. It works along the same lines as a normal formatting string, @@ -2275,10 +2282,6 @@ with some simple extensions. will be inserted into the summary just like information from any other summary specifier. -Text between %( and %) will be highlighted with `gnus-mouse-face' -when the mouse point is placed inside the area. There can only be one -such area. - The %U (status), %R (replied) and %z (zcore) specs have to be handled with care. For reasons of efficiency, Gnus will compute what column these characters will end up in, and \"hard-code\" that. This means that @@ -2289,7 +2292,11 @@ which is bad enough. The smart choice is to have these specs as far to the left as possible. -This restriction may disappear in later versions of Gnus." +This restriction may disappear in later versions of Gnus. + +General format specifiers can also be used. +See (gnus)Formatting Variables." + :link '(custom-manual "(gnus)Formatting Variables") :type 'string :group 'gnus-summary-format) diff --git a/lisp/imap.el b/lisp/imap.el index 519690c..6b84ab8 100644 --- a/lisp/imap.el +++ b/lisp/imap.el @@ -589,7 +589,9 @@ If ARGS, PROMPT is used as an argument to `format'." (let ((cmds (if (listp imap-ssl-program) imap-ssl-program (list imap-ssl-program))) cmd done) - (ignore-errors (require 'ssl)) + (condition-case () + (require 'ssl) + (error)) (while (and (not done) (setq cmd (pop cmds))) (message "imap: Opening SSL connection with `%s'..." cmd) (let* ((port (or port imap-default-ssl-port)) @@ -601,17 +603,18 @@ If ARGS, PROMPT is used as an argument to `format'." ?p (number-to-string port))))) process) (when (setq process - (ignore-errors - (cond ((eq system-type 'windows-nt) - (let (selective-display - (coding-system-for-write 'binary) - (coding-system-for-read 'raw-text-dos) - (output-coding-system 'binary) - (input-coding-system 'raw-text-dos)) - (open-ssl-stream name buffer server port))) - (t - (as-binary-process - (open-ssl-stream name buffer server port)))))) + (condition-case nil + (cond ((eq system-type 'windows-nt) + (let (selective-display + (coding-system-for-write 'binary) + (coding-system-for-read 'raw-text-dos) + (output-coding-system 'binary) + (input-coding-system 'raw-text-dos)) + (open-ssl-stream name buffer server port))) + (t + (as-binary-process + (open-ssl-stream name buffer server port)))) + (error nil))) (with-current-buffer buffer (goto-char (point-min)) (while (and (memq (process-status process) '(open run)) @@ -2193,7 +2196,9 @@ Return nil if no complete line has arrived." (let ((token (read (current-buffer)))) (imap-forward) (cond ((eq token 'UID) - (setq uid (ignore-errors (read (current-buffer))))) + (setq uid (condition-case () + (read (current-buffer)) + (error)))) ((eq token 'FLAGS) (setq flags (imap-parse-flag-list)) (if (not flags) diff --git a/lisp/message.el b/lisp/message.el index c5cfd07..7540ff4 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -1,5 +1,5 @@ ;;; message.el --- composing mail and news messages -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -158,6 +158,11 @@ mailbox format." :group 'message-sending :type '(repeat (symbol :tag "Type"))) +(defcustom message-fcc-externalize-attachments nil + "If non-nil, attachments are included as external parts in Fcc copies." + :type 'boolean + :group 'message-sending) + (defcustom message-courtesy-message "The following message is a courtesy copy of an article\nthat has been posted to %s as well.\n\n" "*This is inserted at the start of a mailed copy of a posted message. @@ -1751,6 +1756,7 @@ Point is left at the beginning of the narrowed-to region." (define-key message-mode-map "\C-c?" 'describe-mode) (define-key message-mode-map "\C-c\C-f\C-t" 'message-goto-to) + (define-key message-mode-map "\C-c\C-f\C-o" 'message-goto-from) (define-key message-mode-map "\C-c\C-f\C-b" 'message-goto-bcc) (define-key message-mode-map "\C-c\C-f\C-w" 'message-goto-fcc) (define-key message-mode-map "\C-c\C-f\C-c" 'message-goto-cc) @@ -1772,6 +1778,9 @@ Point is left at the beginning of the narrowed-to region." (define-key message-mode-map "\C-c\C-t" 'message-insert-to) (define-key message-mode-map "\C-c\C-n" 'message-insert-newsgroups) + (define-key message-mode-map "\C-c\C-u" 'message-insert-or-toggle-importance) + (define-key message-mode-map "\C-c\M-n" 'message-insert-disposition-notification-to) + (define-key message-mode-map "\C-c\C-y" 'message-yank-original) (define-key message-mode-map "\C-c\M-\C-y" 'message-yank-buffer) (define-key message-mode-map "\C-c\C-q" 'message-fill-yanked-message) @@ -1814,12 +1823,16 @@ Point is left at the beginning of the narrowed-to region." ["Kill To Signature" message-kill-to-signature t] ["Newline and Reformat" message-newline-and-reformat t] ["Rename buffer" message-rename-buffer t] - ["Flag as important" message-insert-importance-high + ["Flag As Important" message-insert-importance-high ,@(if (featurep 'xemacs) '(t) '(:help "Mark this message as important"))] - ["Flag as unimportant" message-insert-importance-low + ["Flag As Unimportant" message-insert-importance-low ,@(if (featurep 'xemacs) '(t) '(:help "Mark this message as unimportant"))] + ["Request Receipt" + message-insert-disposition-notification-to + ,@(if (featurep 'xemacs) '(t) + '(:help "Request a Disposition Notification of this article"))] ["Spellcheck" ispell-message ,@(if (featurep 'xemacs) '(t) '(:help "Spellcheck this message"))] @@ -1847,6 +1860,7 @@ Point is left at the beginning of the narrowed-to region." ["Fetch Newsgroups" message-insert-newsgroups t] "----" ["To" message-goto-to t] + ["From" message-goto-from t] ["Subject" message-goto-subject t] ["Cc" message-goto-cc t] ["Reply-To" message-goto-reply-to t] @@ -1937,6 +1951,7 @@ C-c C-f move to a header field (and create it if there isn't): C-c C-f C-k move to Keywords C-c C-f C-d move to Distribution C-c C-f C-f move to Followup-To C-c C-f C-m move to Mail-Followup-To + C-c C-f C-i cycle through Importance values C-c C-f c move to Mail-Copies-To C-c C-t `message-insert-to' (add a To header to a news followup) C-c C-n `message-insert-newsgroups' (add a Newsgroup header to a news reply) @@ -1949,7 +1964,8 @@ C-c C-e `message-elide-region' (elide the text between point and mark). C-c C-v `message-delete-not-region' (remove the text outside the region). C-c C-z `message-kill-to-signature' (kill the text up to the signature). C-c C-r `message-caesar-buffer-body' (rot13 the message body). -C-c C-p `message-insert-or-toggle-importance' (insert or cycle importance) +C-c C-u `message-insert-or-toggle-importance' (insert or cycle importance). +C-c M-n `message-insert-disposition-notification-to' (request receipt). M-RET `message-newline-and-reformat' (break the line and reformat)." (set (make-local-variable 'message-reply-buffer) nil) (make-local-variable 'message-send-actions) @@ -2054,6 +2070,11 @@ M-RET `message-newline-and-reformat' (break the line and reformat)." (interactive) (message-position-on-field "To")) +(defun message-goto-from () + "Move point to the From header." + (interactive) + (message-position-on-field "From")) + (defun message-goto-subject () "Move point to the Subject header." (interactive) @@ -2431,6 +2452,16 @@ and `low'." (message-goto-eoh) (insert (format "Importance: %s\n" new))))) +(defun message-insert-disposition-notification-to () + "Request a disposition notification (return receipt) to this message. +Note that this should not be used in newsgroups." + (interactive) + (save-excursion + (message-remove-header "Disposition-Notification-To") + (message-goto-eoh) + (insert (format "Disposition-Notification-To: %s\n" + (or (message-fetch-field "From") (message-make-from)))))) + (defun message-elide-region (b e) "Elide the text in the region. An ellipsis (from `message-elide-ellipsis') will be inserted where the @@ -3059,6 +3090,17 @@ used to distinguish whether the invisible text is a MIME part or not." '(invisible t mime-edit-invisible t)) (put-text-property start end 'invisible t)))))) +(defun message-text-with-property (prop) + "Return a list of all points where the text has PROP." + (let ((points nil) + (point (point-min))) + (save-excursion + (while (< point (point-max)) + (when (get-text-property point prop) + (push point points)) + (incf point))) + (nreverse points))) + (defun message-fix-before-sending () "Do various things to make the message nice before sending it." ;; Make sure there's a newline at the end of the message. @@ -4049,7 +4091,8 @@ Otherwise, generate and save a value for `canlock-password' first." (let ((case-fold-search t) (coding-system-for-write 'raw-text) (output-coding-system 'raw-text) - list file) + list file + (mml-externalize-attachments message-fcc-externalize-attachments)) (save-excursion (save-restriction (message-narrow-to-headers) @@ -4319,16 +4362,6 @@ If NOW, use that time instead." (aset tmp (1- (match-end 0)) ?-)) (string-match "[\\()]" tmp))))) (insert fullname) - (goto-char (point-min)) - ;; Look for a character that cannot appear unquoted - ;; according to RFC 822. - (when (re-search-forward "[^- !#-'*+/-9=?A-Z^-~]" nil 1) - ;; Quote fullname, escaping specials. - (goto-char (point-min)) - (insert "\"") - (while (re-search-forward "[\"\\]" nil 1) - (replace-match "\\\\\\&" t)) - (insert "\"")) (insert " <" login ">")) (t ; 'parens or default (insert login " (") @@ -4390,7 +4423,7 @@ give as trustworthy answer as possible." (match-string 1 user-mail)) ;; Default to this bogus thing. (t - (concat system-name ".i-did-not-set--mail-host-address--so-shoot-me"))))) + (concat system-name ".i-did-not-set--mail-host-address--so-tickle-me"))))) (defun message-make-host-name () "Return the name of the host." @@ -4561,6 +4594,8 @@ Headers already prepared in the buffer are not modified." (goto-char (point-max)) (insert (if (stringp header) header (symbol-name header)) ": " value) + ;; We check whether the value was ended by a + ;; newline. If now, we insert one. (unless (bolp) (insert "\n")) (forward-line -1)) @@ -4857,7 +4892,7 @@ than 988 characters long, and if they are not, trim them until they are." to group) (if (not (or (null name) (string-equal name "mail") - (string-equal name "news"))) + (string-equal name "posting"))) (setq name (concat "*sent " name "*")) (message-narrow-to-headers) (setq to (message-fetch-field "to")) @@ -4869,7 +4904,7 @@ than 988 characters long, and if they are not, trim them until they are." (or (car (mail-extract-address-components to)) to) "*")) ((and group (not (string= group ""))) - (concat "*sent news on " group "*")) + (concat "*sent posting on " group "*")) (t "*sent mail*")))) (unless (string-equal name (buffer-name)) (rename-buffer name t))))) @@ -5052,7 +5087,7 @@ OTHER-HEADERS is an alist of header/value pairs." "Start editing a news article to be sent." (interactive) (let ((message-this-is-news t)) - (message-pop-to-buffer (message-buffer-name "news" nil newsgroups)) + (message-pop-to-buffer (message-buffer-name "posting" nil newsgroups)) (message-setup `((Newsgroups . ,(or newsgroups "")) (Subject . ,(or subject "")))))) @@ -5849,7 +5884,7 @@ you." (special-display-regexps nil) (same-window-buffer-names nil) (same-window-regexps nil)) - (message-pop-to-buffer (message-buffer-name "news" nil newsgroups))) + (message-pop-to-buffer (message-buffer-name "posting" nil newsgroups))) (let ((message-this-is-news t)) (message-setup `((Newsgroups . ,(or newsgroups "")) (Subject . ,(or subject "")))))) @@ -5863,7 +5898,7 @@ you." (special-display-regexps nil) (same-window-buffer-names nil) (same-window-regexps nil)) - (message-pop-to-buffer (message-buffer-name "news" nil newsgroups))) + (message-pop-to-buffer (message-buffer-name "posting" nil newsgroups))) (let ((message-this-is-news t)) (message-setup `((Newsgroups . ,(or newsgroups "")) (Subject . ,(or subject "")))))) @@ -5937,6 +5972,9 @@ which specify the range to operate on." (tool-bar-add-item-from-menu 'message-insert-importance-low "unimportant" message-mode-map) + (tool-bar-add-item-from-menu + 'message-insert-disposition-notification-to "receipt" + message-mode-map) tool-bar-map))))) ;;; Group name completion. @@ -6176,11 +6214,11 @@ regexp varstr." (message-narrow-to-headers-or-head) (message-remove-first-header "Content-Type") (message-remove-first-header "Content-Transfer-Encoding")) - ;; We always make sure that the message has a Content-Type header. - ;; This is because some broken MTAs and MUAs get awfully confused - ;; when confronted with a message with a MIME-Version header and - ;; without a Content-Type header. For instance, Solaris' - ;; /usr/bin/mail. + ;; We always make sure that the message has a Content-Type + ;; header. This is because some broken MTAs and MUAs get + ;; awfully confused when confronted with a message with a + ;; MIME-Version header and without a Content-Type header. For + ;; instance, Solaris' /usr/bin/mail. (unless content-type-p (goto-char (point-min)) ;; For unknown reason, MIME-Version doesn't exist. diff --git a/lisp/mm-util.el b/lisp/mm-util.el index 59dae6d..642462b 100644 --- a/lisp/mm-util.el +++ b/lisp/mm-util.el @@ -1,5 +1,5 @@ ;;; mm-util.el --- Utility functions for Mule and low level things -;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -284,6 +284,10 @@ prefer iso-2022-jp to japanese-shift-jis: '(iso-2022-jp iso-2022-jp-2 japanese-shift-jis utf-8)) ") +(defvar mm-use-find-coding-systems-region + (fboundp 'find-coding-systems-region) + "Use `find-coding-systems-region' to find proper coding systems.") + ;;; Internal variables: ;;; Functions: @@ -334,10 +338,8 @@ used as the line break code type of the coding system." ) charset) ;; Translate invalid charsets. - ((mm-coding-system-p (setq charset - (cdr (assq charset - mm-charset-synonym-alist)))) - charset) + ((let ((cs (cdr (assq charset mm-charset-synonym-alist)))) + (and cs (mm-coding-system-p charset) cs))) ;; Last resort: search the coding system list for entries which ;; have the right mime-charset in case the canonical name isn't ;; defined (though it should be). @@ -399,6 +401,26 @@ Only used in Emacs Mule 4." (or (get-charset-property charset 'preferred-coding-system) (get-charset-property charset 'prefered-coding-system))) +(defsubst mm-guess-charset () + "Guess Mule charset from the language environment." + (or + mail-parse-mule-charset ;; cached mule-charset + (progn + (setq mail-parse-mule-charset + (and (boundp 'current-language-environment) + (car (last + (assq 'charset + (assoc current-language-environment + language-info-alist)))))) + (if (or (not mail-parse-mule-charset) + (eq mail-parse-mule-charset 'ascii)) + (setq mail-parse-mule-charset + (or (car (last (assq mail-parse-charset + mm-mime-mule-charset-alist))) + ;; default + 'latin-iso8859-1))) + mail-parse-mule-charset))) + (defun mm-charset-after (&optional pos) "Return charset of a character in current buffer at position POS. If POS is nil, it defauls to the current point. @@ -415,23 +437,7 @@ If the charset is `composition', return the actual one." (if (and charset (not (memq charset '(ascii eight-bit-control eight-bit-graphic)))) charset - (or - mail-parse-mule-charset ;; cached mule-charset - (progn - (setq mail-parse-mule-charset - (and (boundp 'current-language-environment) - (car (last - (assq 'charset - (assoc current-language-environment - language-info-alist)))))) - (if (or (not mail-parse-mule-charset) - (eq mail-parse-mule-charset 'ascii)) - (setq mail-parse-mule-charset - (or (car (last (assq mail-parse-charset - mm-mime-mule-charset-alist))) - ;; Fixme: don't fix that! - 'latin-iso8859-1))) - mail-parse-mule-charset))))))) + (mm-guess-charset)))))) (defun mm-mime-charset (charset) "Return the MIME charset corresponding to the given Mule CHARSET." @@ -459,14 +465,13 @@ If the charset is `composition', return the actual one." (setq result (cons head result))) (nreverse result))) -;; It's not clear whether this is supposed to mean the global or local -;; setting. I think it's used inconsistently. -- fx -(defsubst mm-multibyte-p () - "Say whether multibyte is enabled." - (if (and (not (featurep 'xemacs)) - (boundp 'enable-multibyte-characters)) - enable-multibyte-characters - (featurep 'mule))) +(if (and (not (featurep 'xemacs)) + (boundp 'enable-multibyte-characters)) + (defalias 'mm-multibyte-p + (lambda () + "Say whether multibyte is enabled in the current buffer." + enable-multibyte-characters)) + (defalias 'mm-multibyte-p (lambda () (featurep 'mule)))) (defun mm-iso-8859-x-to-15-region (&optional b e) (if (fboundp 'char-charset) @@ -500,7 +505,7 @@ charset, and a longer list means no appropriate charset." (let (charsets) ;; The return possibilities of this function are a mess... (or (and (mm-multibyte-p) - (fboundp 'find-coding-systems-region) + mm-use-find-coding-systems-region ;; Find the mime-charset of the most preferred coding ;; system that has one. (let ((systems (find-coding-systems-region b e))) @@ -725,6 +730,31 @@ If INHIBIT is non-nil, inhibit mm-inhibit-file-name-handlers." (push dir result)) (push path result)))) +(if (fboundp 'detect-coding-region) + (defun mm-detect-coding-region (start end) + "Like 'detect-coding-region' except returning the best one." + (let ((coding-systems + (detect-coding-region (point) (point-max)))) + (or (car-safe coding-systems) + coding-systems))) + (defun mm-detect-coding-region (start end) + (let ((point (point))) + (goto-char start) + (skip-chars-forward "\0-\177" end) + (prog1 + (if (eq (point) end) 'ascii (mm-guess-charset)) + (goto-char point))))) + +(if (fboundp 'coding-system-get) + (defun mm-detect-mime-charset-region (start end) + "Detect MIME charset of the text in the region between START and END." + (let ((cs (mm-detect-coding-region start end))) + (coding-system-get cs 'mime-charset))) + (defun mm-detect-mime-charset-region (start end) + "Detect MIME charset of the text in the region between START and END." + (let ((cs (mm-detect-coding-region start end))) + cs))) + (provide 'mm-util) ;;; mm-util.el ends here diff --git a/lisp/mml.el b/lisp/mml.el index 725632b..04bf91c 100644 --- a/lisp/mml.el +++ b/lisp/mml.el @@ -1,5 +1,5 @@ ;;; mml.el --- A package for parsing and validating MML documents -;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -64,6 +64,16 @@ NAME is a string containing the name of the TWEAK parameter in the MML handle. FUNCTION is a Lisp function which is called with the MML handle to tweak the part.") +(defvar mml-tweak-sexp-alist + '((mml-externalize-attachments . mml-tweak-externalize-attachments)) + "A list of (SEXP . FUNCTION) for tweaking MML parts. +SEXP is a s-expression. If the evaluation of SEXP is non-nil, FUNCTION +is called. FUNCTION is a Lisp function which is called with the MML +handle to tweak the part.") + +(defvar mml-externalize-attachments nil + "*If non-nil, local-file attachments are generated as external parts.") + (defvar mml-generate-multipart-alist nil "*Alist of multipart generation functions. Each entry has the form (NAME . FUNCTION), where @@ -626,6 +636,9 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (message-encode-message-body) (save-restriction (message-narrow-to-headers-or-head) + ;; Skip past any From_ headers. + (while (looking-at "From ") + (forward-line 1)) (let ((mail-parse-charset message-default-charset)) (mail-encode-encoded-word-buffer)))) @@ -928,7 +941,8 @@ If RAW, don't highlight the article." (erase-buffer) (mm-disable-multibyte) (insert s))) - (let ((gnus-newsgroup-charset (car message-posting-charset))) + (let ((gnus-newsgroup-charset (car message-posting-charset)) + gnus-article-prepare-hook gnus-original-article-buffer) (run-hooks 'gnus-article-decode-hook) (let ((gnus-newsgroup-name "dummy")) (gnus-article-prepare-display)))) @@ -962,7 +976,23 @@ If RAW, don't highlight the article." (setq alist (cdr alist))))))) (if func (funcall func cont) - cont))) + cont) + (let ((alist mml-tweak-sexp-alist)) + (while alist + (if (eval (caar alist)) + (funcall (cdar alist) cont)) + (setq alist (cdr alist))))) + cont) + +(defun mml-tweak-externalize-attachments (cont) + "Tweak attached files as external parts." + (let (filename-cons) + (when (and (eq (car cont) 'part) + (not (cdr (assq 'buffer cont))) + (and (setq filename-cons (assq 'filename cont)) + (not (equal (cdr (assq 'nofile cont)) "yes")))) + (setcar cont 'external) + (setcar filename-cons 'name)))) (provide 'mml) diff --git a/lisp/nneething.el b/lisp/nneething.el index 7b713c4..a5c3c2d 100644 --- a/lisp/nneething.el +++ b/lisp/nneething.el @@ -128,9 +128,20 @@ included.") (save-excursion (nnmail-find-file file) ; Insert the file in the nntp buf. (unless (nnheader-article-p) ; Either it's a real article... - (goto-char (point-min)) - (nneething-make-head - file (current-buffer)) ; ... or we fake some headers. + (let ((type + (unless (file-directory-p file) + (or (cdr (assoc (concat "." (file-name-extension file)) + mailcap-mime-extensions)) + "text/plain"))) + (charset + (mm-detect-mime-charset-region (point-min) (point-max))) + (encoding)) + (unless (string-match "\\`text/" type) + (base64-encode-region (point-min) (point-max)) + (setq encoding "base64")) + (goto-char (point-min)) + (nneething-make-head file (current-buffer) + nil type charset encoding)) (insert "\n")) t)))) @@ -272,7 +283,8 @@ included.") (insert-buffer-substring nneething-work-buffer) (goto-char (point-max)))) -(defun nneething-make-head (file &optional buffer extra-msg) +(defun nneething-make-head (file &optional buffer extra-msg + mime-type mime-charset mime-encoding) "Create a head by looking at the file attributes of FILE." (let ((atts (file-attributes file))) (insert @@ -297,6 +309,19 @@ included.") (concat "Lines: " (int-to-string (count-lines (point-min) (point-max))) "\n")) + "") + (if mime-type + (concat "Content-Type: " mime-type + (if mime-charset + (concat "; charset=" + (if (stringp mime-charset) + mime-charset + (symbol-name mime-charset))) + "") + (if mime-encoding + (concat "\nContent-Transfer-Encoding: " mime-encoding) + "") + "\nMIME-Version: 1.0\n") "")))) (defun nneething-from-line (uid &optional file) diff --git a/lisp/nnmail.el b/lisp/nnmail.el index d659d11..78305fa 100644 --- a/lisp/nnmail.el +++ b/lisp/nnmail.el @@ -1,5 +1,5 @@ ;;; nnmail.el --- mail support functions for the Gnus mail backends -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -465,7 +465,7 @@ parameter. It should return nil, `warn' or `delete'." (const warn) (const delete))) -(defcustom nnmail-extra-headers nil +(defcustom nnmail-extra-headers '(To Newsgroups) "*Extra headers to parse." :version "21.1" :group 'nnmail diff --git a/lisp/nnmaildir.el b/lisp/nnmaildir.el index 61c7c41..9525854 100644 --- a/lisp/nnmaildir.el +++ b/lisp/nnmaildir.el @@ -1,5 +1,5 @@ ;;; nnmaildir.el --- maildir backend for Gnus -;; Copyright (c) 2001 Free Software Foundation, Inc. +;; Copyright (c) 2001, 2002 Free Software Foundation, Inc. ;; Copyright (c) 2000, 2001 Paul Jarc ;; Author: Paul Jarc @@ -30,17 +30,15 @@ ;; ;; Some goals of nnmaildir: ;; * Everything Just Works, and correctly. E.g., stale NOV data is -;; ignored when articles have been edited; no need for -;; -generate-nov-databases. +;; ignored; no need for -generate-nov-databases. ;; * Perfect reliability: [C-g] will never corrupt its data in memory, ;; and SIGKILL will never corrupt its data in the filesystem. ;; * We make it easy to manipulate marks, etc., from outside Gnus. ;; * All information about a group is stored in the maildir, for easy -;; backup and restoring. +;; backup, copying, restoring, etc. ;; * We use the filesystem as a database. ;; ;; Todo: -;; * Ignore old NOV data when gnus-extra-headers has changed. ;; * Don't force article renumbering, so nnmaildir can be used with ;; the cache and agent. Alternatively, completely rewrite the Gnus ;; backend interface, which would have other advantages. @@ -136,7 +134,9 @@ by nnmaildir-request-article.") ["subject\tfrom\tdate" "references\tchars\lines" "extra" - article-file-modtime]] + article-file-modtime + ;; The value of nnmail-extra-headers when this NOV data was parsed: + (to in-reply-to)]] (defmacro nnmaildir--srv-new () '(make-vector 11 nil)) (defmacro nnmaildir--srv-get-name (server) `(aref ,server 0)) @@ -213,15 +213,17 @@ by nnmaildir-request-article.") (defmacro nnmaildir--art-set-msgid (article val) `(aset ,article 3 ,val)) (defmacro nnmaildir--art-set-nov (article val) `(aset ,article 4 ,val)) -(defmacro nnmaildir--nov-new () '(make-vector 4 nil)) +(defmacro nnmaildir--nov-new () '(make-vector 5 nil)) (defmacro nnmaildir--nov-get-beg (nov) `(aref ,nov 0)) (defmacro nnmaildir--nov-get-mid (nov) `(aref ,nov 1)) (defmacro nnmaildir--nov-get-end (nov) `(aref ,nov 2)) (defmacro nnmaildir--nov-get-mtime (nov) `(aref ,nov 3)) +(defmacro nnmaildir--nov-get-neh (nov) `(aref ,nov 4)) (defmacro nnmaildir--nov-set-beg (nov val) `(aset ,nov 0 ,val)) (defmacro nnmaildir--nov-set-mid (nov val) `(aset ,nov 1 ,val)) (defmacro nnmaildir--nov-set-end (nov val) `(aset ,nov 2 ,val)) (defmacro nnmaildir--nov-set-mtime (nov val) `(aset ,nov 3 ,val)) +(defmacro nnmaildir--nov-set-neh (nov val) `(aset ,nov 4 ,val)) (defmacro nnmaildir--srv-grp-dir (srv-dir gname) `(file-name-as-directory (concat ,srv-dir ,gname))) @@ -289,7 +291,8 @@ by nnmaildir-request-article.") (defun nnmaildir--update-nov (srv-dir group article) (let ((nnheader-file-coding-system 'binary) dir gname pgname msgdir prefix suffix file attr mtime novdir novfile - nov msgid nov-beg nov-mid nov-end field pos extra val deactivate-mark) + nov msgid nov-beg nov-mid nov-end field pos extra val old-neh new-neh + deactivate-mark) (catch 'return (setq suffix (nnmaildir--art-get-suffix article)) (if (stringp suffix) nil @@ -315,17 +318,35 @@ by nnmaildir-request-article.") novfile (concat novdir prefix)) (save-excursion (set-buffer (get-buffer-create " *nnmaildir nov*")) - (when (file-exists-p novfile) - (and nov - (equal mtime (nnmaildir--nov-get-mtime nov)) - (throw 'return nov)) - (erase-buffer) - (nnheader-insert-file-contents novfile) - (setq nov (read (current-buffer))) - (nnmaildir--art-set-msgid article (car nov)) - (setq nov (cadr nov)) - (and (equal mtime (nnmaildir--nov-get-mtime nov)) - (throw 'return nov))) + (when (file-exists-p novfile) ;; If not, force reparsing the message. + (if nov nil ;; It's already in memory. + ;; Else read the data from the NOV file. + (erase-buffer) + (nnheader-insert-file-contents novfile) + (setq nov (read (current-buffer))) + (nnmaildir--art-set-msgid article (car nov)) + (setq nov (cadr nov))) + ;; If the NOV's modtime matches the file's current modtime, + ;; and it has the right length (i.e., it wasn't produced by + ;; a too-much older version of nnmaildir), then we may use + ;; this NOV data rather than parsing the message file, + ;; unless nnmail-extra-headers has been augmented since this + ;; data was last parsed. + (when (and (equal mtime (nnmaildir--nov-get-mtime nov)) + (= (length nov) (length (nnmaildir--nov-new)))) + ;; This NOV data is potentially up-to-date. + (setq old-neh (nnmaildir--nov-get-neh nov) + new-neh nnmail-extra-headers) + (if (equal new-neh old-neh) (throw 'return nov)) ;; Common case. + ;; They're not equal, but maybe the new is a subset of the old... + (if (null new-neh) (throw 'return nov)) + (while new-neh + (if (memq (car new-neh) old-neh) + (progn + (setq new-neh (cdr new-neh)) + (if new-neh nil (throw 'return nov))) + (setq new-neh nil))))) + ;; Parse the NOV data out of the message. (erase-buffer) (nnheader-insert-file-contents file) (insert "\n") @@ -399,8 +420,9 @@ by nnmaildir-request-article.") (nnmaildir--nov-set-mid nov nov-mid) (nnmaildir--nov-set-end nov nov-end) (nnmaildir--nov-set-mtime nov mtime) + (nnmaildir--nov-set-neh nov (copy-sequence nnmail-extra-headers)) (prin1 (list msgid nov) (current-buffer)) - (setq file (concat novdir ":")) + (setq file (concat novfile ":")) (nnmaildir--unlink file) (write-region (point-min) (point-max) file nil 'no-message)) (rename-file file novfile 'replace) @@ -1438,7 +1460,8 @@ by nnmaildir-request-article.") (let ((no-force (not force)) (group (nnmaildir--prepare server gname)) pgname time boundary time-iter bound-iter high low target dir nlist - stop num article didnt suffix nnmaildir--file deactivate-mark) + stop number article didnt suffix nnmaildir--file + nnmaildir-article-file-name deactivate-mark) (catch 'return (if group nil (nnmaildir--srv-set-error nnmaildir--cur-server @@ -1460,11 +1483,7 @@ by nnmaildir-request-article.") high (1- high))) (setcar (cdr boundary) low) (setcar boundary high) - (setq target (nnmaildir--param pgname 'expire-group) - target (and (stringp target) - (not (string-equal target pgname)) - target) - dir (nnmaildir--srv-get-dir nnmaildir--cur-server) + (setq dir (nnmaildir--srv-get-dir nnmaildir--cur-server) dir (nnmaildir--srv-grp-dir dir gname) dir (nnmaildir--cur dir) nlist (nnmaildir--grp-get-lists group) @@ -1473,17 +1492,17 @@ by nnmaildir-request-article.") (save-excursion (set-buffer (get-buffer-create " *nnmaildir move*")) (while ranges - (setq num (car ranges) ranges (cdr ranges)) - (while (eq num (car ranges)) + (setq number (car ranges) ranges (cdr ranges)) + (while (eq number (car ranges)) (setq ranges (cdr ranges))) - (if (numberp num) (setq stop num) - (setq stop (car num) num (cdr num))) - (setq nlist (nthcdr (- (nnmaildir--art-get-num (car nlist)) num) + (if (numberp number) (setq stop number) + (setq stop (car number) number (cdr number))) + (setq nlist (nthcdr (- (nnmaildir--art-get-num (car nlist)) number) nlist)) (while (and nlist (setq article (car nlist) - num (nnmaildir--art-get-num article)) - (>= num stop)) + number (nnmaildir--art-get-num article)) + (>= number stop)) (setq nlist (cdr nlist) suffix (nnmaildir--art-get-suffix article)) (catch 'continue @@ -1509,14 +1528,20 @@ by nnmaildir-request-article.") time-iter (cdr time-iter))) (and bound-iter time-iter (car-less-than-car bound-iter time-iter)))) - (setq didnt (cons (nnmaildir--art-get-num article) didnt)) - (when target + (setq didnt (cons number didnt)) + (save-excursion + (setq nnmaildir-article-file-name nnmaildir--file + target (nnmaildir--param pgname 'expire-group))) + (when (and (stringp target) + (not (string-equal target pgname))) ;; Move it. (erase-buffer) (nnheader-insert-file-contents nnmaildir--file) (gnus-request-accept-article target nil nil 'no-encode)) - (nnmaildir--unlink nnmaildir--file) - (nnmaildir--art-set-suffix article 'expire) - (nnmaildir--art-set-nov article nil))))) + (if (equal target pgname) + (setq didnt (cons number didnt)) ;; Leave it here. + (nnmaildir--unlink nnmaildir--file) + (nnmaildir--art-set-suffix article 'expire) + (nnmaildir--art-set-nov article nil)))))) (erase-buffer)) didnt))) diff --git a/lisp/nnspool.el b/lisp/nnspool.el index dfc4ebd..40dbfc1 100644 --- a/lisp/nnspool.el +++ b/lisp/nnspool.el @@ -1,7 +1,8 @@ ;;; nnspool.el --- spool access for GNU Emacs ;; Copyright (C) 1988, 1989, 1990, 1993, 1994, 1995, 1996, 1997, 1998, -;; 2000 Free Software Foundation, Inc. +;; 2000, 2002 +;; Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -331,7 +332,8 @@ there.") () (nnheader-report 'nnspool "") (set-process-sentinel proc 'nnspool-inews-sentinel) - (process-send-region proc (point-min) (point-max)) + (mm-with-unibyte-current-buffer + (process-send-region proc (point-min) (point-max))) ;; We slap a condition-case around this, because the process may ;; have exited already... (ignore-errors diff --git a/lisp/nntp.el b/lisp/nntp.el index afb439f..2576e0c 100644 --- a/lisp/nntp.el +++ b/lisp/nntp.el @@ -1,6 +1,6 @@ ;;; nntp.el --- nntp access for Gnus -;; Copyright (C) 1987, 1988, 1989, 1990, 1992, 1993, 1994, 1995, 1996, -;; 1997, 1998, 2000, 2001 +;; Copyright (C) 1987, 1988, 1989, 1990, 1992, 1993, 1994, 1995, 1996, +;; 1997, 1998, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -490,8 +490,10 @@ noticing asynchronous data.") (set-buffer (nntp-find-connection-buffer nntp-server-buffer)) (erase-buffer))) (nntp-encode-text) - (process-send-region (nntp-find-connection nntp-server-buffer) - (point-min) (point-max)) + (mm-with-unibyte-current-buffer + ;; Some encoded unicode text contains character 0x80-0x9f e.g. Euro. + (process-send-region (nntp-find-connection nntp-server-buffer) + (point-min) (point-max))) (nntp-retrieve-data nil nntp-address nntp-port-number nntp-server-buffer wait-for nnheader-callback-function)) @@ -602,7 +604,8 @@ noticing asynchronous data.") (last-point (point-min)) (nntp-inhibit-erase t) (buf (nntp-find-connection-buffer nntp-server-buffer)) - (command (if nntp-server-list-active-group "LIST ACTIVE" "GROUP"))) + (command (if nntp-server-list-active-group + "LIST ACTIVE" "GROUP"))) (while groups ;; Send the command to the server. (nntp-send-command nil command (pop groups)) @@ -1231,7 +1234,10 @@ password contained in '~/.nntp-authinfo'." (erase-buffer) (nntp-send-command "^[245].*\n" "GROUP" group) (setcar (cddr entry) group) - (erase-buffer)))))) + (erase-buffer) + (save-excursion + (set-buffer nntp-server-buffer) + (erase-buffer))))))) (defun nntp-decode-text (&optional cr-only) "Decode the text in the current buffer." diff --git a/lisp/rfc2047.el b/lisp/rfc2047.el index 9e308a7..8054b6a 100644 --- a/lisp/rfc2047.el +++ b/lisp/rfc2047.el @@ -1,5 +1,5 @@ ;;; rfc2047.el --- Functions for encoding and decoding rfc2047 messages -;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -535,13 +535,20 @@ The buffer may be narrowed." (defun rfc2047-decode-string (string) "Decode the quoted-printable-encoded STRING and return the results." (let ((m (mm-multibyte-p))) - (with-temp-buffer - (when m - (mm-enable-multibyte)) - (insert string) - (inline - (rfc2047-decode-region (point-min) (point-max))) - (buffer-string)))) + (if (string-match "=\\?" string) + (with-temp-buffer + (when m + (mm-enable-multibyte)) + (insert string) + (inline + (rfc2047-decode-region (point-min) (point-max))) + (buffer-string)) + (if (and m + mail-parse-charset + (not (eq mail-parse-charset 'us-ascii)) + (not (eq mail-parse-charset 'gnus-decoded))) + (mm-decode-coding-string string mail-parse-charset) + string)))) (defun rfc2047-parse-and-decode (word) "Decode WORD and return it if it is an encoded word. diff --git a/lisp/smiley-ems.el b/lisp/smiley-ems.el index 459299f..3822fe1 100644 --- a/lisp/smiley-ems.el +++ b/lisp/smiley-ems.el @@ -1,6 +1,6 @@ ;;; smiley-ems.el --- displaying smiley faces -;; Copyright (C) 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Dave Love ;; Keywords: news mail multimedia @@ -162,25 +162,6 @@ With arg, turn displaying on if and only if arg is positive." (mouse-set-point event) (smiley-toggle-buffer)))) -(eval-when-compile (defvar gnus-article-buffer)) - -(defun gnus-smiley-display (&optional arg) - "Display textual emoticaons (\"smilies\") as small graphical icons. -With arg, turn displaying on if and only if arg is positive." - (interactive "P") - (gnus-with-article-buffer - (if (memq 'smiley gnus-article-wash-types) - (gnus-delete-images 'smiley) - (article-goto-body) - (let ((images (smiley-region (point) (point-max)))) - (when images - (gnus-add-wash-type 'smiley) - (dolist (image images) - (gnus-add-image 'smiley image)))) - (when (and (numberp arg) - (<= arg 0)) - (smiley-toggle-buffer arg))))) - (provide 'smiley) ;;; smiley-ems.el ends here diff --git a/texi/ChangeLog b/texi/ChangeLog index de3983b..19c96ec 100644 --- a/texi/ChangeLog +++ b/texi/ChangeLog @@ -1,6 +1,85 @@ +2002-01-06 ShengHuo ZHU + + * gnus.texi (Archived Messages): Rename + gnus-inews-mark-gcc-as-read to gnus-gcc-mark-as-read. + + * Makefile.in (clean): Clean thumb*. + +2002-01-05 Harry Putnam + + * gnus.texi (Score Variables): Clarify. + +2002-01-05 Lars Magne Ingebrigtsen + + * gnus.texi (Agent Expiry): Addition. + (Sorting the Summary Buffer): Addition. + +2002-01-05 Simon Josefsson + + * gnus.texi (Conformity): Add MIME and Disposition Notifications. + + * message.texi (Header Commands): Fix. Add m-goto-from. + (Insertion): Add m-i-disposition-notification-to. + +2002-01-05 ShengHuo ZHU + + * Makefile.in (.latexi.pdf-x): Use thumbpdf. + + * gnus.texi (Advanced Formatting): Double @'s. Use thumbpdf. + colorlinks=true. + +2002-01-05 Norman Walsh + + * gnus-faq.texi: Fix typo. + +2002-01-05 Lars Magne Ingebrigtsen + + * gnus.texi (Sorting the Summary Buffer): Addition. + +2002-01-04 Lars Magne Ingebrigtsen + + * gnus.texi (Virtual Groups): Addition. + +2002-01-03 Lars Magne Ingebrigtsen + + * gnus.texi (Article Keymap): Addition. + (Summary Mail Commands): Fix. + +2002-01-02 Lars Magne Ingebrigtsen + + * gnus.texi (Group Timestamp): Addition. Example from Andras + BALI. + (X-Face): Addition. + (Advanced Formatting): Add example. + +2002-01-01 Simon Josefsson + + * gnus.texi (Conformity): Add and fix. + + * message.texi (Security): Mention gpg-temp-directory. + + * gnus.texi (Article Washing): Link to Security section. + (Security): Fix. + (Signing and Encrypting): Renamed from Using GPG. + (IMAP): Fixes. + +2002-01-01 Simon Josefsson + + * gnus.texi (Customizing Articles): Add crossreference links. Add + gnus-body-boundary-delimiter. + 2002-01-01 Lars Magne Ingebrigtsen * gnus.texi (Choosing Commands): Addition. + (Article Display): Update. + (Article Display): Addition. + (Article Header): New. + (Slow Terminal Connection): Addition. + (Predicate Specifiers): New. + (To From Newsgroups): Addition. + (Topic Commands): Addition. + Update the menus. + Fix some references b0rked up by the menu fixing. 2001-12-31 Rui Zhu diff --git a/texi/Makefile.in b/texi/Makefile.in index 76428ac..5c546cd 100644 --- a/texi/Makefile.in +++ b/texi/Makefile.in @@ -97,12 +97,12 @@ refcard.pdf: refcard.tex gnuslogo-refcard.eps gnusref.tex TEXINPUTS=$(srcdir):$$TEXINPUTS $(PDFLATEX) refcard.tex clean: - rm -f gnus.*.bak *.ky *.cp *.fn *.cps *.kys *.log *.aux *.dvi *.vr \ - *.pdf *.tp *.toc *.pg gnus.latexi *.aux *.[cgk]idx \ - gnus.ilg gnus.ind gnus.[cgk]ind gnus.idx \ - gnustmp.texi *.tmplatexi gnus.tmplatexi1 texput.log *.orig *.rej \ - gnus.latexi*~* xface.tex picons.tex smiley.tex *.latexi *.dvi-x \ - *.pdf-x gnus.out + rm -f *.[cgk]idx *.aux *.cp *.cps *.dvi *.dvi-x *.fn *.ky \ + *.kys *.latexi *.log *.orig *.pdf *.pdf-x *.pg *.rej \ + *.tmplatexi *.toc *.tp *.vr gnus.*.bak gnus.[cgk]ind gnus.idx \ + gnus.ilg gnus.ind gnus.latexi*~* gnus.out gnus.tmplatexi1 \ + gnustmp.texi picons.tex smiley.tex texput.log thumb*.png \ + thumbdta.tex xface.tex makeinfo: makeinfo -o gnus gnus.texi @@ -150,6 +150,7 @@ gnus.latexi gnus-faq.latexi message.latexi emacs-mime.latexi sieve.latexi: $(src egrep -v "end\{document\}" $< > gnus.tmplatexi cat $(srcdir)/postamble.tex >> gnus.tmplatexi TEXINPUTS=$(srcdir):$$TEXINPUTS $(PDFLATEX) gnus.tmplatexi + thumbpdf gnus.pdf TEXINPUTS=$(srcdir):$$TEXINPUTS $(PDFLATEX) gnus.tmplatexi mv gnus.pdf $@ diff --git a/texi/gnus-faq.texi b/texi/gnus-faq.texi index c3159d4..5bf8977 100644 --- a/texi/gnus-faq.texi +++ b/texi/gnus-faq.texi @@ -262,7 +262,7 @@ being responded to. These commands are also selectable as @i{Followup and Yank} and @i{Reply and Yank} in the Post menu. @kbd{C-c C-y} grabs the previous message and prefixes each line with -@code{ail-indentation-spaces} spaces or @code{mail-yank-prefix} if that is +@code{message-indentation-spaces} spaces or @code{message-yank-prefix} if that is non-nil, unless you have set your own @code{mail-citation-hook}, which will be called to do the job. diff --git a/texi/gnus-ja.texi b/texi/gnus-ja.texi index 9258aa6..3167e19 100644 --- a/texi/gnus-ja.texi +++ b/texi/gnus-ja.texi @@ -25,14 +25,15 @@ \ifx\pdfoutput\undefined \else -\usepackage[pdftex,bookmarks]{hyperref} +\usepackage[pdftex,bookmarks,colorlinks=true]{hyperref} +\usepackage{thumbpdf} \pdfcompresslevel=9 \fi \makeindex \begin{document} -\newcommand{\gnusversionname}{T-gnus v.} +\newcommand{\gnusversionname}{T-gnus v6.15} \newcommand{\gnuschaptername}{} \newcommand{\gnussectionname}{} @@ -574,7 +575,7 @@ Summary Buffer * Choosing Articles:: $B5-;v$rFI$`(B * Paging the Article:: $BFI$s$G$$$k5-;v$r%9%/%m!<%k$9$k(B * Reply Followup and Post:: $B5-;v$rEj9F$9$k(B -* Delayed Articles:: +* Delayed Articles:: * Marking Articles:: $B5-;v$K4{FI$d4|8B@Z$l:o=|2DG=Ey$N0u$rIU$1(B $B$k(B * Limiting:: $B35N,%P%C%U%!$K@)8B$r2C$($k$3$H$,$G$-$k(B @@ -628,7 +629,7 @@ Reply, Followup and Post * Summary Mail Commands:: $B%a!<%k$rAw$k(B * Summary Post Commands:: $B%K%e!<%9$rAw$k(B * Summary Message Commands:: $BB>$N%a%C%;!<%84XO"$NL?Na(B -* Canceling and Superseding:: +* Canceling and Superseding:: Marking Articles @@ -680,9 +681,11 @@ Article Treatment * Article Hiding:: $BFCDj$N>pJs$O>C$75n$j$?$$$H$b;W$&(B * Article Washing:: $B?M@8$r$b$C$H$h$/$9$k$?$/$5$s$N5$$NMx$$$?(B $B4X?t(B +* Article Header:: $B%X%C%@!<$r$$$m$$$mJQ7A$5$;$k(B * Article Buttons:: URL $B$d(B Message-ID $B$d(B $B%"%I%l%9$J$I$r%/%j%C(B $B%/$9$k(B * Article Date:: $B$0$:$0$:8@$&$J!"@$3&;~$@(B! +* Article Display:: X-Face, Picons, Smileys $B$rI=<($9$k(B * Article Signature:: $B=pL>$C$F2?(B? * Article Miscellania:: $BB>$N$$$m$$$m$J$b$N(B @@ -695,7 +698,7 @@ Various Summary Stuff * Summary Group Information:: $B>pJs;X8~$NL?Na(B * Searching for Articles:: $BJ#?t5-;vL?Na(B -* Summary Generation Commands:: +* Summary Generation Commands:: * Really Various Summary Commands:: $B$"$N$d$C$+$$$JB>$KE,9g$7$J$$L?Na(B Article Buffer @@ -718,7 +721,7 @@ Composing Messages * Drafts:: $B%a%C%;!<%8$N1d4|$H5qH]$5$l$?%a%C%;!<%8(B * Rejected Articles:: $B%5!<%P!<$,$"$J$?$N5-;v$r9%$-$G$J$$$H$-$K(B $B2?$,5/$3$k(B? -@c * Using GPG:: How to use GPG and MML to sign and encrypt messages +@c * Signing and encrypting:: How to compose secure messages. Select Methods @@ -774,7 +777,6 @@ Getting Mail * Not Reading Mail:: $BB>$N%U%!%$%k$rFI$`$?$a$K%a!<%k%P%C%/%((B $B%s%I$r;H$&(B * Choosing a Mail Back End:: Gnus $B$O?'!9$J%a!<%kMM<0$rFI$`;v$,$G$-$k(B -* Archiving Mail:: $B%a!<%k$r%P%C%/%"%C%W$9$k$K$O(B Mail Sources @@ -795,6 +797,7 @@ Choosing a Mail Back End Browsing the Web +* Archiving Mail:: * Web Searches:: $BJ8;zNs$K%^%C%A$9$k5-;v$+$i%0%k!<%W$r:n$k(B * Slashdot:: Slashdot $B$N%3%a%s%H$rFI$`(B * Ultimate:: Ultimate Bulletin Board $B%7%9%F%`(B @@ -860,9 +863,9 @@ Agent Categories Agent Commands -* Group Agent Commands:: -* Summary Agent Commands:: -* Server Agent Commands:: +* Group Agent Commands:: +* Summary Agent Commands:: +* Server Agent Commands:: Scoring @@ -926,6 +929,7 @@ Various $B$-$k(B * NoCeM:: Spam $B$dB>$NB@$j$d$9$$?);v$rHr$1$kJ}K!(B * Undo:: $B$$$/$D$+$NF0:n$O85$KLa$9;v$,$G$-$k(B +* Predicate Specifiers:: $B=R8l$r@_Dj$9$k(B * Moderation:: $B$"$J$?$,%b%G%l!<%?!<$@$C$?$i$I$&$9$k$+(B * Image Enhancements:: $B:G?7$N(B Emacs/XEmacs $B$O3($rI=<($G$-$k(B * Fuzzy Matching:: $BBg$-$JLJLS$C$F2?(B? @@ -945,11 +949,12 @@ Formatting Variables * Tabulation:: $B=PNO$N@0Ns(B * Wide Characters:: $BI}$,9-$$J8;z$r07$&(B -XEmacs Enhancements +Image Enhancements * Picons:: $B$"$J$?$,FI$s$G$$$k$b$N$N3($rI=<($9$kJ}K!(B * Smileys:: $BI=<($5$l$k$Y$/@8$^$l$?9,$;$=$&$J4i$rI=<((B $B$9$kJ}K!(B +* X-Face:: $B%U%!%s%-!<$J$A$C$A$c$JGr9u$N3($rI=<($9$k(B * Toolbar:: $B%/%j%C%/1n(B * XVarious:: $B$=$NB>$N(B XEmacs $B$G(B Gnus $B$JJQ?t(B @@ -966,6 +971,7 @@ Picons Appendices +* XEmacs:: XEmacs $B$G%$%s%9%H!<%k$9$k$?$a$NMW7o(B * History:: $B$I$&$d$C$F(B gnus $B$,:#F|$N$h$&$K$J$C$?$+(B * On Writing Manuals:: $B$J$<$3$l$,=i?4$_$J$i!"%f!<%6!e5-$NCM$O(B gnus $B$N%G%#%U%)%k%HCM$G$9!#$"$J$?$NLr$KN)$D$h$&$KJQ$($F2<$5(B +$B$$!#(B) + $B$5$F!"$3$l$O:n@.$5$l$k(B @sc{nov} $B%U%!%$%k$rA`:n$G$-$k%a!<%k%0%k!<%W$G$O$?(B $B$$$F$$$N>l9gLrN)$A$^$9!#$7$+$7!"0J2<$N$b$N$r(B @file{overview.fmt} $B%U%!%$(B $B%k$N:G8e$KDI2C$9$k$h$&$K(B nntp $B4IM}H$7$F2<$5$$!#(B * Summary Mail Commands:: $B%a!<%k$rAw$k(B * Summary Post Commands:: $B%K%e!<%9$rAw$k(B * Summary Message Commands:: $BB>$N%a%C%;!<%84XO"$NL?Na(B -* Canceling and Superseding:: +* Canceling and Superseding:: @end menu @node Summary Mail Commands @@ -6459,13 +6489,18 @@ gnus $B$OA4$F$N5-;v$N40A4$J(B @code{References} $BMs$r8+$F!"F1$8%9%l%C%I$KB0$ @findex gnus-thread-sort-by-author @findex gnus-thread-sort-by-number @vindex gnus-thread-sort-functions +@findex gnus-thread-sort-by-most-recent-thread $B$b$7%9%l%C%I$N35N,I=<($r;H$C$F$$$k$N$G$"$l$P!"(B @code{gnus-thread-sort-functions} $B$r@_Dj$9$k$3$H$G%9%l%C%I$rJB$SBX$($k$3(B $B$H$,$G$-$^$9!#$=$l$O!"C1FH$N4X?t!"4X?t$N%j%9%H!"4X?t$H(B @code{($B4X?t$G$J$$(B $B$b$N(B)} $B$NMWAG$G$"$k$3$H$,$G$-$^$9!#%G%#%U%)%k%H$G$O!"JB$SBX$($O5-;vHV9f(B $B$K$h$C$F$J$5$l$^$9!#4{$K:n$i$l$F$$$kJB$SBX$(=R8l4X?t(B -$B$O(B @code{gnus-thread-sort-by-number}, @code{gnus-thread-sort-by-author}, @code{gnus-thread-sort-by-subject}, @code{gnus-thread-sort-by-date}, @code{gnus-thread-sort-by-score} $B$H(B @code{gnus-thread-sort-by-total-score} $B$G(B -$B$9!#(B +$B$O(B @code{gnus-thread-sort-by-number}$B!"(B@code{gnus-thread-sort-by-author}$B!"(B +@code{gnus-thread-sort-by-subject}$B!"(B@code{gnus-thread-sort-by-date}$B!"(B +@code{gnus-thread-sort-by-score}$B!"(B +@code{gnus-thread-sort-by-most-recent-number}$B!"(B +@code{gnus-thread-sort-by-most-recent-date} $B$*$h$S(B +@code{gnus-thread-sort-by-total-score} $B$G$9!#(B $B3F4X?t$OFs$D$N%9%l%C%I$r$H$j!":G=i$N%9%l%C%I$,B>$N%9%l%C%I$h$j@h$KJB$SBX(B $B$($i$l$k$Y$-$G$"$l$P!"(B@code{nil} $B$G$J$$CM$r$+$($7$^$9!#IaDL!"JB$SBX$($O(B @@ -7430,6 +7465,7 @@ Gnus $B$O%U%!%$%k$r1\Mw$9$k$N$r7hDj$9$k$N$K(B@dfn{$B5,B'JQ?t(B}$B$rMQ$$$^$9 * Article Hiding:: $BFCDj$N>pJs$O>C$75n$j$?$$$H$b;W$&(B * Article Washing:: $B?M@8$r$b$C$H$h$/$9$k$?$/$5$s$N5$$NMx$$$?(B $B4X?t(B +* Article Header:: $B%X%C%@!<$r$$$m$$$mJQ7A$5$;$k(B * Article Buttons:: URL $B$d(B Message-ID $B$d(B $B%"%I%l%9$J$I$r%/%j%C(B $B%/$9$k(B * Article Date:: $B$0$:$0$:8@$&$J!"@$3&;~$@(B! @@ -7935,19 +7971,7 @@ HZ $B$^$?$O(B HZP $B$r=hM}$7$^$9!#(BHZ ($B$^$?$O(B HZP) $B$OCf9q8l$N5-;v$ @c @kindex W s (Summary) @c @findex gnus-summary-force-verify-and-decrypt @c Verify a signed (PGP, PGP/MIME or S/MIME) message -@c (@code{gnus-summary-force-verify-and-decrypt}). - -@item W u -@kindex W u ($B35N,(B) -@findex gnus-article-treat-unfold-headers -$B@^$jJV$5$l$?%X%C%@!<9T$r0l9T$K$7$^(B -$B$9(B (@code{gnus-article-treat-unfold-headers})$B!#(B - -@item W n -@kindex W n ($B35N,(B) -@findex gnus-article-treat-fold-newsgroups -@code{Newsgroups} $B$H(B @code{Followup-To} $B%X%C%@!<$r@^$jJV$7$^(B -$B$9(B (@code{gnus-article-treat-fold-newsgroups})$B!#(B +@c (@code{gnus-summary-force-verify-and-decrypt}). @xref{Security}. @item W W H @kindex W W H ($B35N,(B) @@ -7999,6 +8023,31 @@ HZ $B$^$?$O(B HZP $B$r=hM}$7$^$9!#(BHZ ($B$^$?$O(B HZP) $B$OCf9q8l$N5-;v$ $B5-;v$N@vBu$r<+F0E*$K$9$k$?$a$NJ}K!$O(B @xref{Customizing Articles} $B$r;2>H(B $B$7$F2<$5$$!#(B +@node Article Header +@subsection $B5-;v%X%C%@!<(B + +$B$3$l$i$N%3%^%s%I$O5-;v%X%C%@!<$r$$$m$$$mJQ7A$5$;$^$9!#(B + +@table @kbd +@item W G u +@kindex W G u ($B35N,(B) +@findex gnus-article-treat-unfold-headers +$B@^$jJV$5$l$?%X%C%@!<9T$r0l9T$K$7$^(B +$B$9(B (@code{gnus-article-treat-unfold-headers})$B!#(B + +@item W G n +@kindex W G n ($B35N,(B) +@findex gnus-article-treat-fold-newsgroups +@code{Newsgroups} $B$H(B @code{Followup-To} $B%X%C%@!<$r@^$jJV$7$^(B +$B$9(B (@code{gnus-article-treat-fold-newsgroups})$B!#(B + +@item W G f +@kindex W G f ($B35N,(B) +@findex gnus-article-treat-fold-header +$B$9$Y$F$N%a%C%;!<%8%X%C%@!<$r@^$jJV$7$^(B +$B$9(B (@code{gnus-article-treat-fold-headers})$B!#(B +@end table + @node Article Buttons @subsection $B5-;v$N%\%?%s(B @cindex buttons @@ -8192,8 +8241,8 @@ gnus $B$G%a!<%k$rFI$`$3$H$NM-Mx$JE@$O!"C1=c$J%P%0$rAG@2$i$7$$IT>rM}$KCV$-(B @item W D s @kindex W D s ($B35N,(B) -@findex gnus-article-toggle-smiley -$B%9%^%$%j!<$NI=<($r%H%0%k$7$^$9(B (@code{gnus-article-toggle-smiley})$B!#(B +@findex gnus-treat-smiley +$B%9%^%$%j!<$rI=<($7$^$9(B (@code{gnus-treat-smiley})$B!#(B @item W D f @kindex W D f ($B35N,(B) @@ -8212,6 +8261,12 @@ gnus $B$G%a!<%k$rFI$`$3$H$NM-Mx$JE@$O!"C1=c$J%P%0$rAG@2$i$7$$IT>rM}$KCV$-(B $B$9$Y$F$N%K%e!<%9%X%C%@!<(B ($B$9$J$o(B $B$A(B @code{Newsgroups} $B$H(B @code{Followup-To}) $B$r(B Picon $B2=$7$^(B $B$9(B (@code{gnus-treat-from-picon})$B!#(B + +@item W D D +@kindex W D D ($B35N,(B) +@findex gnus-article-remove-images +$B5-;v%P%C%U%!$+$i$9$Y$F$N2hA|$r:o=|$7$^(B +$B$9(B (@code{gnus-article-remove-images})$B!#(B @end table @node Article Signature @@ -8845,7 +8900,7 @@ Line Formatting})$B!#%G%#%U%)%k%H$O(B @samp{Gnus: %%b %S %Z} $B$G$9!#;HMQ2DG= @menu * Summary Group Information:: $B>pJs;X8~$NL?Na(B * Searching for Articles:: $BJ#?t5-;vL?Na(B -* Summary Generation Commands:: +* Summary Generation Commands:: * Really Various Summary Commands:: $B$"$N$d$C$+$$$JB>$KE,9g$7$J$$L?Na(B @end menu @@ -9305,23 +9360,22 @@ Gnus $B$K$$$D$G$b@5$7$$(B @code{Xref} $B$rpJs$O(B @pxref{Canceling and @@ -10118,8 +10221,8 @@ Gnus $B$O30$X=P$F9T$/A4$F$N%a%C%;!<%8$K!"0l$D$+$=$l0J>e$N$=$N%5!<%P!<$N%0(B $B$3$NJQ?t$O(B @code{gnus-message-archive-group} $B$NBe$o$j$K;H$&;v$,$G$-$^$9(B $B$,!"8ee$N$=$N%5!<%P!<$N%0(B $B$j$^$9!#(B @ignore -@node Using GPG -@section Using GPG +@node Signing and encrypting +@section Signing and encrypting @cindex using gpg +@cindex using s/mime +@cindex using smime -Gnus has an ALPHA support to GPG that's provided by @file{gpg.el}. See -@code{mm-verify-option} and @code{mm-decrypt-option} to enable Gnus to -verify or decrypt messages accordingly. +Gnus can digitally sign and encrypt your messages, using vanilla PGP +format or PGP/MIME or S/MIME. For decoding such messages, see the +@code{mm-verify-option} and @code{mm-decrypt-option} options +(@pxref{Security}). -To use this correctly with GPG, you'll need the following lisp code in your -@file{~/.emacs} or @file{~/.gnus}: +For PGP, Gnus supports two external libraries, @sc{gpg.el} and +@sc{Mailcrypt}, you need to install at least one of them. The S/MIME +support in Gnus requires the external program OpenSSL. -@lisp -(require 'gpg) -(setq mml2015-use 'gpg) -(setq mml1991-use 'gpg) -(setq gpg-temp-directory (expand-file-name "~/.gnupg/tmp")) -@end lisp +Instructing MML to perform security operations on a MIME part is done +using the @code{C-c C-m s} key map for signing and the @code{C-c C-m +c} key map for encryption, as follows. + +@table @kbd + +@item C-c C-m s s +@kindex C-c C-m s s +@findex mml-secure-sign-smime + +Digitally sign current MIME part using S/MIME. -The @code{gpg-temp-directory} need to point to a directory with permissions set -to 700, for your own safety. +@item C-c C-m s o +@kindex C-c C-m s o +@findex mml-secure-sign-pgp -To sign or encrypt your message you may choose to use the MML Security -menu or @kbd{C-c C-m s p} to sign your message using PGP/MIME, -@kbd{C-c C-m s s} to sign your message using S/MIME. There's also -@kbd{C-c C-m c p} to encrypt your message with PGP/MIME and @kbd{C-c -C-m c s} to encrypt using S/MIME. @xref{Security, ,Security, message, -The Message Manual}. +Digitally sign current MIME part using PGP. + +@item C-c C-m s p +@kindex C-c C-m s p +@findex mml-secure-sign-pgp + +Digitally sign current MIME part using PGP/MIME. + +@item C-c C-m c s +@kindex C-c C-m c s +@findex mml-secure-encrypt-smime + +Digitally encrypt current MIME part using S/MIME. + +@item C-c C-m c o +@kindex C-c C-m c o +@findex mml-secure-encrypt-pgp + +Digitally encrypt current MIME part using PGP. + +@item C-c C-m c p +@kindex C-c C-m c p +@findex mml-secure-encrypt-pgpmime + +Digitally encrypt current MIME part using PGP/MIME. + +@end table -Gnus will ask for your passphrase and then it will send your message, if -you've typed it correctly. +Also @xref{Security, ,Security, message, Message Manual}. @end ignore @node Select Methods @@ -11306,7 +11439,6 @@ Emacs $B$N%;%C%7%g%sA4BN$r%i%C%W$7$F!"%G%#%U%)%k%H$N%a%=%C%I$r;H$&$H$$$&$N(B * Not Reading Mail:: $BB>$N%U%!%$%k$rFI$`$?$a$K%a!<%k%P%C%/%((B $B%s%I$r;H$&(B * Choosing a Mail Back End:: Gnus $B$O?'!9$J%a!<%kMM<0$rFI$`;v$,$G$-$k(B -* Archiving Mail:: $B%a!<%k$r%P%C%/%"%C%W$9$k$K$O(B @end menu @node Mail in a Newsreader @@ -13206,6 +13338,7 @@ Gnus $B$O$3$l$i$N%=!<%9$X$N3&LL$rDs6!$9$k%P%C%/%(%s%I72$r>/$7Hw$($D$D$"$j(B $B$^$9!#(B @menu +* Archiving Mail:: * Web Searches:: $BJ8;zNs$K%^%C%A$9$k5-;v$+$i%0%k!<%W$r:n$k(B * Slashdot:: Slashdot $B$N%3%a%s%H$rFI$`(B * Ultimate:: Ultimate Bulletin Board $B%7%9%F%`(B @@ -13837,22 +13970,24 @@ IMAP $B$O%a!<%k(B ($B$b$7$/$O!"%K%e!<%9!"$b$7$/$O(B ...) $B$rFI$`$?$a$N%M%C @sc{imap} $B$K$OFs$D$NFCH$7$F2<$5$$!#(B @sc{imap} $B$r%a!<%k$rCyB"$9$k%W%m%H%3%k$H$7$F;H$$$?$$$H$-$O!"(B -gnus-secondary-select-methods $B$K(B nnimap $B$rEPO?$7$F2<$5$$!#$3$l$K$h$C(B -$B$F(B gnus $B$O(B @sc{imap} $B%5!<%P!<$KCyB"$5$l$F$$$k%a!<%k$rA`:n$9$k$h$&$K$J$j(B -$B$^$9!#$3$l$,$3$3$G@bL@$9$k;H$$J}$G$9!#(B +@code{gnus-secondary-select-methods} $B$K(B nnimap $B$rEPO?$7$F2<$5$$!#$3$l$K(B +$B$h$C$F(B gnus $B$O(B @sc{imap} $B%5!<%P!<$KCyB"$5$l$F$$$k%a!<%k$rA`:n$9$k$h$&$K(B +$B$J$j$^$9!#$3$l$,$3$3$G@bL@$9$k;H$$J}$G$9!#(B -$B$$$/$D$+$N(B @sc{imap} $B%5!<%P!<$r(B @code{~/.gnus} $B$G@_Dj$9$k$H!"$?$V$s$3$N(B -$B$h$&$J$b$N$K$J$k$G$7$g$&(B: +$B$$$/$D$+$N(B @sc{imap} $B%5!<%P!<$r(B @code{~/.gnus} $B$G@_Dj$9$k$H!"$?$V$s0J2<(B +$B$N$h$&$J$b$N$K$J$k$G$7$g$&!#(B($BCm(B: SSL/TLS $B$G$O30It%W%m%0%i%`$H%i%$%V%i%j(B +$B$,I,MW$G$9!#0J2<$r;2>H$7$F2<$5$$!#(B) @lisp (setq gnus-secondary-select-methods @@ -13878,9 +14013,6 @@ gnus-secondary-select-methods $B$K(B nnimap $B$rEPO?$7$F2<$5$$!#$3$l$K$h$C(B (nnimap-stream ssl)))) @end lisp -(SSL/TLS $B$r;H$&$K$O30It%i%$%V%i%j(B @samp{ssl.el} $B$,I,MW$G$9!#0J2<$r;2>H$7(B -$B$F2<$5$$!#(B) - $B0J2<$NJQ?t$O2>A[(B @code{nnimap} $B%5!<%P!<$r:n@.$9$k$?$a$K;H$&$3$H$,$G$-$^(B $B$9!#(B @@ -13942,10 +14074,10 @@ gnus-secondary-select-methods $B$K(B nnimap $B$rEPO?$7$F2<$5$$!#$3$l$K$h$C(B @itemize @bullet @item -@dfn{gssapi:} GSSAPI ($BIaDL$O(B kerberos 5) $B$r;H$$$^$9!#(B@samp{imtest} $B%W%m(B +@dfn{gssapi:} GSSAPI ($BIaDL$O(B Kerberos 5) $B$r;H$$$^$9!#(B@samp{imtest} $B%W%m(B $B%0%i%`$,I,MW$G$9!#(B @item -@dfn{kerberos4:} kerberos 4 $B$r;H$$$^$9!#(B@samp{imtest} $B%W%m%0%i%`$,I,MW$G(B +@dfn{kerberos4:} Kerberos 4 $B$r;H$$$^$9!#(B@samp{imtest} $B%W%m%0%i%`$,I,MW$G(B $B$9!#(B @item @dfn{starttls:} STARTTLS (SSL $B$KN`;w(B) $B$r;H$$$^$9!#30It%i%$%V%i(B @@ -14004,11 +14136,11 @@ nnimap $B$O$=$l$b%5%]!<%H$7$^$9!#$7$+$7!"(BSSLeay $B$N:G?7HG$G$"$k(B 0.9.x  @itemize @bullet @item -@dfn{gssapi:} GSSAPI ($BIaDL$O(B kerberos 5) $BG'>Z$G$9!#30It%W%m%0%i(B +@dfn{gssapi:} GSSAPI ($BIaDL$O(B Kerberos 5) $BG'>Z$G$9!#30It%W%m%0%i(B $B%`(B @code{imtest} $B$,I,MW$G$9!#(B @item -@dfn{kerberos4:} Kerberos $BG'>Z$G$9!#30It%W%m%0%i%`(B @code{imtest} $B$,I,MW(B -$B$G$9!#(B +@dfn{kerberos4:} Kerberos 4 $B$K$h$kG'>Z$G$9!#30It%W%m%0%i(B +$B%`(B @code{imtest} $B$,I,MW$G$9!#(B @item @dfn{digest-md5:} DIGEST-MD5 $B$G0E9f2=$5$l$?(B $BMxMQ(B/$B%Q%9%o!<%I(B $B$G$9!#30(B $BIt%i%$%V%i%j(B @code{digest-md5.el} $B$,I,MW$G$9!#(B @@ -15060,6 +15192,9 @@ nnvirtual $B%0%k!<%W(B (@dfn{nnvirtual group}) $B$O$N%0%k!<%W$N=89g0J>e $B$3$N$h$&$J>l9g$O!"%a%C%;!<%8%P%C%U%!$G$N(B @kbd{C-c C-n} $B$,1~Ez$7$h$&$H$7(B $B$F$$$k5-;v$+$i(B @code{Newsgroups} $B9T$rH4$-=P$7$FA^F~$7$^$9!#(B +@code{nnvirtual} $B%0%k!<%W$O!"9=@.%0%k!<%W$+$i5-;v$H0u0J30$O7Q>5$7$^$;$s!#(B +$BNc$($P%0%k!<%W%Q%i%a!<%?$b$=$&$J$N$G$9$,!"$=$l$i$O7Q>5$5$l$^$;$s!#(B + @node Kibozed Groups @subsection Kiboze $B%0%k!<%W(B @cindex nnkiboze @@ -15705,9 +15840,9 @@ file $B$GF0:n$7!"(Bgnus $B%(!<%8%'%s%H$N@Z$jN%$7(B/$B:9$79~$_>uBV$r@Z$jBX$($^$9!#(B @menu -* Group Agent Commands:: -* Summary Agent Commands:: -* Server Agent Commands:: +* Group Agent Commands:: +* Summary Agent Commands:: +* Server Agent Commands:: @end menu $B40A4$J0l3g$G(B) $BCfCG$9$k$3$H$b$"(B $B$^$jNI$$$3$H$G$O$"$j$^$;$s!#(B +@code{gnus-agent-expire-days} $B$O@55,I=8=(B/$BF|?t$N%Z%"$N%j%9%H$G$"$C$F$b9=(B +$B$$$^$;$s!#@55,I=8=$O%0%k!<%WL>$K%^%C%A$7!"0[$J$k%0%k!<%W$G0[$J$k4|8B@Z$l(B +$B>C5n$r9T$J$&$3$H$r2DG=$K$7$^$9!#(B + +@lisp +(setq gnus-agent-expire-days + '(("alt\\." 7) + (".*binary" 1) + ("." 21))) +@end lisp + +$B$b$7%j%9%H$N7A<0$r;H$&>l9g$O!":G8e$NMWAG$O%G%#%U%)%k%H$N%a%=%C%I!"$9$J$o(B +$B$A$9$Y$F$N%0%k!<%W$K%^%C%A$9$k$b$N$K$7$J$1$l$P$J$j$^$;$s!#(B + @vindex gnus-agent-expire-all @code{gnus-agent-expire-all} $B$,(B @code{nil} $B$G$J$1$l$P!"$3$NL?Na$OA4$F$N(B $B5-;v(B --- $BL$FI!"4{FI!"2D;k!"J]N15-;v$r>C5n$7$^$9!#$b$7(B @code{nil} ($B$3$l$,(B @@ -15925,6 +16074,10 @@ Gnus $B%(!<%8%'%s%H$,%U%!%$%k$r3JG<$9$k>l=j!#=i4|@_DjCM(B @item gnus-agent-unplugged-hook @vindex gnus-agent-unplugged-hook $B%M%C%H%o!<%/$+$i@ZCG$5$l$?$H$-$KC5n$rA`:n$7$F$$$kJ}K!$G$9(B---$BA4$F$N9gCW$7$J$$EPO?(B -$B$O8E$/$J$j$9$.!"9gCW$9$kEPO?$r?7A/$GLL$9$k;v$K$J$k$G$7$g$&!#(B +$B$3$NJQ?t$,(B @code{nil} $B$G$J$$$H!"0l;~E*$K9gCW$7$?%9%3%"EPO?$OF|IU$,99?7$5(B +$B$l$^$9!#(B($B$3$l$O(B gnus $B$,4|8B@Z$l>C5n$rA`:n$7$F$$$kJ}K!$G$9(B---$BA4$F$N9gCW$7(B +$B$J$$EPO?$O8E$/$J$j$9$.!"9gCW$9$kEPO?$r?7A/$GLL$9$k;v$K$J$k$G$7$g$&!#(B @item gnus-score-after-write-file-function @vindex gnus-score-after-write-file-function @@ -17885,6 +18038,7 @@ Gnus $B$O0lF|$K0l2s%9%3%"$rIeGT$5$;$h$&$H$7$^$9!#Nc$($P!"$b$7(B gnus $B$r;MF| $B$-$k(B * NoCeM:: Spam $B$dB>$NB@$j$d$9$$?);v$rHr$1$kJ}K!(B * Undo:: $B$$$/$D$+$NF0:n$O85$KLa$9;v$,$G$-$k(B +* Predicate Specifiers:: $B=R8l$r@_Dj$9$k(B * Moderation:: $B$"$J$?$,%b%G%l!<%?!<$@$C$?$i$I$&$9$k$+(B * Image Enhancements:: $B:G?7$N(B Emacs/XEmacs $B$O3($rI=<($G$-$k(B * Fuzzy Matching:: $BBg$-$JLJLS$C$F2?(B? @@ -18122,6 +18276,12 @@ Emacs $B$,(B @samp{%b} $B$r.7?$N(B ISO0861 $BMM(B @@ -19016,6 +19176,31 @@ Gnus $B$O!"MxMQo$N(B Emacs $B$N(B @code{undo} $BL?Na$K$A$g$C$H$@$1;w$F$$$k$H;W$o$l$k$G$7$g$&!#(B +@node Predicate Specifiers +@section $B=R8l$N@_Dj(B +@cindex predicate specifiers + +$B$$$/$D$+$N(B gnus $B$NJQ?t(B +$B$O(B @dfn{$B=R8l;X<(;R(B} (@dfn{predicate specifiers}) $B$G$9!#$3$l$O=R8l$N;EMM(B +$B$KM;DL$r8z$+$;$k$3$H$,$G$-$kFCJL$J7A<0$G$9!#(B + +$B$3$l$i$N;X<(;R$O4X?t$K$h$k%j%9%H!"%7%s%\%k$^$?$O%j%9%H$G$9!#(B + +$B$3$l$ONc$G$9(B: + +@lisp +(or gnus-article-unseen-p + gnus-article-unread-p) +@end lisp + +$BMxMQ$G$-$k%7%s%\%k$O(B @code{or}$B!"(B@code{and} $B$*$h$S(B @code{not} $B$G$9!#4X?t(B +$B$O$9$Y$F0l$D$N%Q%i%a!<%?$r$N$b$N$rI=<($9$k$3$H$,$G$-$k$N$G!" gnus $B$O$3$l$rMxMQ$9$k$3$H$K$7$^$9!#(B @menu -* Picons:: $B$"$J$?$,FI$s$G$$$k$b$N$N3($rI=<($9$kJ}K!(B -* Smileys:: $BI=<($5$l$k$Y$/@8$^$l$?9,$;$=$&$J4i$rI=<($9$kJ}K!(B -* X-Face:: $B%U%!%s%-!<$J$A$C$A$c$JGr9u$N3($rI=<($9$k(B -* Toolbar:: $B%/%j%C%/1n(B -* XVarious:: $B$=$NB>$N(B XEmacs $B$G(B Gnus $B$JJQ?t(B +* Picons:: $B$"$J$?$,FI$s$G$$$k$b$N$N3($rI=<($9$kJ}K!(B +* Smileys:: $BI=<($5$l$k$Y$/@8$^$l$?9,$;$=$&$J4i$rI=<((B + $B$9$kJ}K!(B +* X-Face:: $B%U%!%s%-!<$J$A$C$A$c$JGr9u$N3($rI=<($9$k(B +* Toolbar:: $B%/%j%C%/1n(B +* XVarious:: $B$=$NB>$N(B XEmacs $B$G(B Gnus $B$JJQ?t(B @end menu @node Picons @@ -19411,8 +19597,8 @@ Gnus $B$r=*N;$9$k$H$-$K(B picon $B%-%c%C%7%e$r>C$75n$k$+$I$&$+!#(BGnus $B$O @cindex x-face @code{X-Face} $B%X%C%@!<$O!"%a%C%;!<%8$NCx$K$O(B @code{xface} $B$G$O$J$/(B @code{x-face} $B$,;H$o$l$^$9!#(B) +gnus $B$O!"30$K=P$9%a%C%;!<%8$K(B X-Face $B%X%C%@!<$r4JC1$KA^F~$9$k$?$a$N!"JX(B +$BMx$J4X?t$HJQ?t$r>/$7$P$+$jDs6!$7$^$9!#(B + +@findex gnus-random-x-face +@code{gnus-random-x-face} $B$O(B @code{gnus-x-face-directory} $B$K$"$k$9$Y$F(B +$B$N(B @samp{pbm} $B$r$/$^$J$/C5$7$F%i%s%@%`$K0l$D$rA*$S/99?7$5(B +$B$l$F$$$^$9!#(BRFC 2195 $B$O(B IMAP $B$N(B CRAM-MD5 $BG'>Z$K$D$$$F=R$Y$F$$$^$9!#(BRFC +2086 $B$O(B IMAP $B$N;HMQ@)8B0lMw(B (ACL) $B$K$D$$$F=R$Y$F$$$^$9!#(BRFC +2359 $B$O(B IMAP $B$N%W%m%H%3%k$N3HD%$K$D$$$F=R$Y$F$$$^$9!#(BRFC 2595 $B$O(B IMAP $B$K(B +$B$*$1$kE,@Z$J(B TLS $B$NE}9g(B (STARTTLS) $B$K$D$$$F=R$Y$F$$$^$9!#(BRFC +1731 $B$O(B IMAP $B$N(B GSSAPI/Kerberos4 $B$Ne$K=q$+$l$F$$$kJ8>O$K4X$9$k;v$G!"(BGnus $B$,$=$l$rK~$?$7$F$$$J$$$h$&$JF0:n(B @@ -21484,6 +21741,21 @@ Gnus $B$,>o$K35N,%P%C%U%!$rCf?4:F@_Dj$r$9$k$3$H$r6X;_$9$k$?$a$K$3$l(B $B$3$l$,(B @code{nil} $B$G$J$1$l$P!"A4$F$N35N,%P%C%U%!$N%9%l%C%I$O=i$a$K1#$5$l(B $B$^$9!#(B +$B$3$l$O=R8l;X<(;R$G$"$k$3$H$b$G$-$^$9(B (@pxref{Predicate Specifiers})$B!#Mx(B +$BMQ$G$-$k=R8l(B +$B$O(B @code{gnus-article-unread-p} $B$H(B @code{gnus-article-unseen-p} $B$G$9!#(B + +$B$3$l$ONc$G$9(B: + +@lisp +(setq gnus-thread-hide-subtree + '(or gnus-article-unread-p + gnus-article-unseen-p)) +@end lisp + +($B$3$l$O$+$J$j$P$+$2$?Nc$G$9!#$J$<$J$i$9$Y$F$N$^$@FI$^$l$?$3$H$,L5$$5-;v(B +$B$OL$FI$G$b$"$k$+$i$J$N$G$9$,!"pJs$rF~$l$^$;$s(B $B$N$G!";~4V$r@aLs$G$-$k$G$7$g$&!#(B @@ -21831,8 +22103,8 @@ Gnus $B$O%0%k!<%WL>$H5-;vHV9f$K$h$C$F$=$l$>$l$N%a%C%;!<%8$rFCDj$7$^$9!#$=(B @cindex @code{nnchoke} @menu -* Required Back End Functions:: $B