From: yamaoka Date: Tue, 11 Apr 2006 22:55:25 +0000 (+0000) Subject: Import No Gnus v0.4. X-Git-Tag: ngnus-0_4~1 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=ab6b58ba032f3baaf4c78e63be9e39e9d8de5e62;p=elisp%2Fgnus.git- Import No Gnus v0.4. --- diff --git a/ChangeLog b/ChangeLog index 9aadcc0..b74c155 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,237 @@ +2006-04-11 Reiner Steib + + * README: No Gnus v0.4 is released. + +2006-04-11 Reiner Steib + + * Makefile.in (release-sign-files): Use rm -f. + (RELEASE_COMMIT_FILES): Add ./ChangeLog. + (release-bump-version): Add README. + (release-check-settings): OLD_TAG, not OLDTAG. + (release-commit): Echo command lines before prompt. + (RELEASE_COMMIT_FILES): Add README. + (OLD_PATTERN): Fix. + (release-bump-version): Fix gnusversionname substitution. + (OLD_PATTERN): Add grouping. + +2006-04-10 Reiner Steib + + * Makefile.in (GZIP_PROG): Use gzip -f. + (release-bump-version, RELEASE_COMMIT_FILES): Add README. + (release-sign-files): Remove old *.sig files. + + * README: Say "development version". Let sentences end with + double space. + +2006-04-07 Reiner Steib + + * Makefile.in (GZIP_PROG): New variable. + (release-diff): Use it. + (release-sign-files): New sign-only target. Use GPG_AGENT_INFO. + +2006-04-04 Reiner Steib + + * Makefile.in (TAR_BALL_EXTRA, release-make-tar-ball, README): + Remove; README is in CVS now. + (release-files, release-files-signed, release-cvs-export) + (release-make-tar-ball): Use $(VERSION) instead of $(TAG). + (OLD_PATTERN): Catch stable and trunk. + (CIN): New variable. + (release-files, release-files-signed, release-cvs-export) + (release-make-tar-ball, release-diff, release-post-clean): Add + CIN. + (OLD_PATTERN): Remove quotes. + (release-bump-version): Fix typo. + + * etc/images/README: Add more Emacs 22 icons. Add suggestion on + how to use those in Emacs 21. + + * etc/images/close.xpm, etc/images/cut.xpm, etc/images/home.xpm, + etc/images/index.xpm, etc/images/jump-to.xpm, etc/images/new.xpm, + etc/images/next-node.xpm, etc/images/open.xpm, + etc/images/preferences.xpm, etc/images/prev-node.xpm, + etc/images/saveas.xpm, etc/images/spell.xpm: New icons duplicated + from Emacs 22. + + * README: Addition from 5.10.6 tar ball. Clarify "beta". + Simplify Info directory setting. Update required Emacs and XEmacs + version. Use current Gnus version in examples. + +2006-03-31 Reiner Steib + + * GNUS-NEWS: Generated. + + * Makefile.in (CVS_IGNORE_FILES): Additions. + (release-files-signed): New target. + + * etc/images/README: Update separator.xpm. + +2006-03-30 Romain Francoise + + * GNUS-NEWS: Generated. + +2006-03-30 Reiner Steib + + * etc/images/separator.xpm: Update from Emacs CVS. + + * GNUS-NEWS: Generated. + +2006-03-29 Reiner Steib + + * Makefile.in (release-bump-version): Consider named Gnus versions + in replacements. + + * todo: Update "tool bar icons". + +2006-03-27 Reiner Steib + + * Makefile.in (release-revert-files): Replace + release-revert-changelog. + (release-diff): Remove garbage. + +2006-03-07 Reiner Steib + + * etc/images/README: Add GIMP script. + (attach.xpm): Move to top level. + (sort-*.xpm) Add. + + * etc/images/sort-ascending.xpm, + etc/images/sort-column-ascending.xpm, + etc/images/sort-criteria.xpm, etc/images/sort-descending.xpm, + etc/images/sort-row-ascending.xpm: New icons from GNOME 2.6. + +2006-03-10 Reiner Steib + + * Makefile.in (release-check-settings): Add status and + suggestions. + (release-files): Remove duplicate release-cvs-export. + (README): New target. + (release-files, release-make-tar-ball, release-diff): List files. + (README, release-make-tar-ball): Fix. + +2006-03-06 Reiner Steib + + * GNUS-NEWS: Generated. + + * Makefile.in (release-*): New targets. + +2006-02-28 Reiner Steib + + * todo: Remove nnweb. Add: widget for posting styles, doc string + for utility functions, LIST SUBSCRIPTIONS, divide emacs-mime.texi, + change servers. + + * etc/images/README (next-page.xpm): From Gnome, not from Emacs + 22. + + * cancel.xpm, copy.xpm, diropen.xpm, help.xpm, left-arrow.xpm, + next-page.xpm, paste.xpm, print.xpm, redo.xpm, right-arrow.xpm, + save.xpm, search.xpm: New icons duplicated from Emacs 22. + + * etc/images/README: Add these icons. + + * etc/images/README: Describe the new images. + + * etc/gnus/gnus-setup.ast, etc/gnus/news-server.ast: Use + texinfo-mode. + + * etc/images/mail/save.xpm, etc/images/mail/preview.xpm: Rename + char*. + +2006-03-03 Reiner Steib + + * xemacs.mak: Remove outdated file. Use make.bat instead. + +2006-03-02 Reiner Steib + + * make.bat: Add note about "Out of environment space" on Windows + 98 SE. Avoid `>' in echo. + +2006-02-27 Reiner Steib + + * ChangeLog, texi/ChangeLog, lisp/ChangeLog: Fix "From so-and-so" + and "(tiny change)" entries. + +2006-02-22 Reiner Steib + + * etc/images/gnus/mail_send.xpm: Emacs 21 icon for + message-tool-bar-retro. + +2006-02-21 Reiner Steib + + * make.bat (:etc): Also consider images in images/mail and + images/. + + * etc/Makefile.in (install, uninstall): Also consider images in + images/mail and images/. + + * etc/images/connect.xpm, etc/images/contact.xpm, + etc/images/delete.xpm, etc/images/describe.xpm, + etc/images/disconnect.xpm, etc/images/exit.xpm, + etc/images/lock-broken.xpm, etc/images/lock-ok.xpm, + etc/images/lock.xpm, etc/images/refresh.xpm, + etc/images/gnus/toggle-subscription.xpm, + etc/images/mail/attach.xpm, etc/images/mail/compose.xpm, + etc/images/mail/copy.xpm, etc/images/mail/forward.xpm, + etc/images/mail/inbox.xpm, etc/images/mail/move.xpm, + etc/images/mail/not-spam.xpm, etc/images/mail/outbox.xpm, + etc/images/mail/reply-all.xpm, etc/images/mail/reply.xpm, + etc/images/mail/save-draft.xpm, etc/images/mail/send.xpm, + etc/images/mail/spam.xpm: New icons from GNOME 2.6. + +2006-02-21 Miguel Frasson + + * etc/images/separator.xpm: Copy of sep.xpm from AUCTeX. + +2006-02-21 Adam Sj,Ax(Bgren + + * etc/images/mail/save.xpm, etc/images/mail/preview.xpm: New icons. + +2006-01-26 Katsumi Yamaoka + + * Makefile.in (clean): Clean all subdirectories; remove *~. + (elclean): Remove lisp/auto-autoloads.el, lisp/custom-load.el, and + lisp/gnus-load.el. + (distclean): Don't use sub-make to run clean; use $(MAKE) instead + of make. + + * etc/Makefile.in (clean): New rule. + (distclean): Use it; remove Makefile. + +2005-12-06 Katsumi Yamaoka + + * GNUS-NEWS: Generated. + +2005-10-31 Lars Magne Ingebrigtsen + + * Testing CVS setup. Yes. Yes. Yes. Yes. + +2005-10-04 Katsumi Yamaoka + + * aclocal.m4 (AC_PATH_LISPDIR): Default to .../site-lisp/gnus for + Emacs. + (AC_PATH_ETCDIR): Don't change the default value for Emacs. + + * configure: Generated. + + * Makefile.in (list-installed-shadows): New entry. + (remove-installed-shadows): New entry. + + * GNUS-NEWS: Generated. + +2005-09-28 Reiner Steib + + * todo: Remove some items that are already done. Add some new + items. Add some comments. + +2005-08-10 Romain Francoise + + * GNUS-NEWS: Generated. + +2005-07-18 Romain Francoise + + * GNUS-NEWS: Generated. + 2005-02-19 Miles Bader * etc/Makefile.in (install): Create $(etcdir)/images/gnus dir. @@ -72,19 +306,18 @@ * etc/gnus/news-server.ast: Use library validation. -2004-03-08 Kevin Greiner +2004-03-08 Kevin Greiner * make.bat: Make sure that gnus-load.el and sieve are writable to avoid breakage. -2004-03-01 Reiner Steib +2004-03-01 Michael Schierl (tiny change) - * make.bat: Fix directory test for Windows 9x/ME. From Michael - Schierl (tiny change). + * make.bat: Fix directory test for Windows 9x/ME. -2004-01-07 Hiroshi Fujishima +2004-01-07 Hiroshi Fujishima (tiny change) - * etc/gnus-tut.txt: `G m' instead of `G V' (tiny patch). + * etc/gnus-tut.txt: `G m' instead of `G V' 2004-01-05 Jesper Harder @@ -391,7 +624,7 @@ * configure.in: Use it. -2001-01-15 Jesper Harder +2001-01-15 Jesper Harder * make.bat: Fix doc. @@ -399,16 +632,16 @@ * configure.in: Add etc/Makefile. -2000-12-20 Jesper Harder +2000-12-20 Jesper Harder * make.bat: set max-lisp-eval-depth. -2000-10-12 Jesper Harder +2000-10-12 Jesper Harder * make.bat: Makes it possible to generate the Info files on windows again. -2000-08-24 Jesper Harder +2000-08-24 Jesper Harder * make.bat: Use emacs.exe if emacs.bat does not exist. diff --git a/GNUS-NEWS b/GNUS-NEWS index 01da5fd..7ead1e8 100644 --- a/GNUS-NEWS +++ b/GNUS-NEWS @@ -1,113 +1,180 @@ GNUS NEWS -- history of user-visible changes. -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. +Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, + 2006 Free Software Foundation, Inc. See the end for copying conditions. Please send Gnus bug reports to bugs@gnus.org. For older news, see Gnus info node "New Features". - -* Changes in No Gnus +* Installation changes ** Upgrading from previous (stable) version if you have used No Gnus. If you have tried No Gnus (the unstable Gnus branch leading to this -release) but went back to a stable version, be careful when upgrading -to this version. In particular, you will probably want to remove the -`~/News/marks' directory (perhaps selectively), so that flags are -read from your `~/.newsrc.eld' instead of from the stale marks file, -where this release will store flags for nntp. See a later entry for -more information about nntp marks. Note that downgrading isn't safe -in general. +release) but went back to a stable version, be careful when upgrading to +this version. In particular, you will probably want to remove the +`~/News/marks' directory (perhaps selectively), so that flags are read +from your `~/.newsrc.eld' instead of from the stale marks file, where +this release will store flags for nntp. See a later entry for more +information about nntp marks. Note that downgrading isn't safe in +general. + +** Lisp files are now installed in `.../site-lisp/gnus/' by default. It +defaulted to `.../site-lisp/' formerly. In addition to this, the new +installer issues a warning if other Gnus installations which will shadow +the latest one are detected. You can then remove those shadows manually +or remove them using `make remove-installed-shadows'. + + +* New packages and libraries within Gnus -** The nntp back end store article marks in `~/News/marks'. +** Gnus includes the Emacs Lisp SASL library. -The directory can be changed using the (customizable) variable -`nntp-marks-directory', and marks can be disabled using the (back -end) variable `nntp-marks-is-evil'. The advantage of this is that -you can copy `~/News/marks' (using rsync, scp or whatever) to another -Gnus installation, and it will realize what articles you have read -and marked. The data in `~/News/marks' has priority over the same -data in `~/.newsrc.eld'. +This provides a clean API to SASL mechanisms from within Emacs. The +user visible aspects of this, compared to the earlier situation, include +support for DIGEST-MD5 and NTLM. *Note Emacs SASL: (sasl)Top. + +** ManageSieve connections uses the SASL library by default. + +The primary change this brings is support for DIGEST-MD5 and NTLM, when +the server supports it. + +** Gnus includes a password cache mechanism in password.el. + +It is enabled by default (see `password-cache'), with a short timeout of +16 seconds (see `password-cache-expiry'). If PGG is used as the PGP +back end, the PGP passphrase is managed by this mechanism. Passwords +for ManageSieve connections are managed by this mechanism, after +querying the user about whether to do so. + + +* Changes in summary and article mode + +** International host names (IDNA) can now be decoded inside article bodies +using `W i' (`gnus-summary-idna-message'). This requires that GNU Libidn +(`http://www.gnu.org/software/libidn/') has been installed. + +** Gnus now displays DNS master files sent as text/dns using dns-mode. + +** Gnus supports new limiting commands in the Summary buffer: `/ r' +(`gnus-summary-limit-to-replied') and `/ R' +(`gnus-summary-limit-to-recipient'). *Note Limiting::. + +** Gnus supports a new sort command in the Summary buffer: `C-c C-s C-t' +(`gnus-summary-sort-by-recipient'). *Note Summary Sorting::. + +** S/MIME now features LDAP user certificate searches. You need to +configure the server in `smime-ldap-host-list'. + +** URLs inside OpenPGP headers are retrieved and imported to your PGP key +ring when you click on them. ** Picons can be displayed right from the textual address, see `gnus-picon-style'. *Note Picons::. -** You can import and export your RSS subscriptions from OPML files. -*Note RSS::. +** ANSI SGR control sequences can be transformed using `W A'. + +ANSI sequences are used in some Chinese hierarchies for highlighting +articles (`gnus-article-treat-ansi-sequences'). + +** Gnus now MIME decodes articles even when they lack "MIME-Version" header. +This changes the default of `gnus-article-loose-mime'. + +** `gnus-decay-scores' can be a regexp matching score files. For example, +set it to `\\.ADAPT\\'' and only adaptive score files will be decayed. + *Note Score Decays::. + +** Strings prefixing to the `To' and `Newsgroup' headers in summary lines +when using `gnus-ignored-from-addresses' can be customized with +`gnus-summary-to-prefix' and `gnus-summary-newsgroup-prefix'. *Note To +From Newsgroups::. + +** You can replace MIME parts with external bodies. See +`gnus-mime-replace-part' and `gnus-article-replace-part'. *Note MIME +Commands::, *Note Using MIME::. ** The option `mm-fill-flowed' can be used to disable treatment of format=flowed messages. Also, flowed text is disabled when sending -inline PGP signed messages. +inline PGP signed messages. *Note Flowed text: (emacs-mime)Flowed text. -** You can now drag and drop attachments to the Message buffer. -** ANSI SGR control sequences can be transformed using `W A'. + +* Changes in Message mode -ANSI sequences are used in some Chinese hierarchies for highlighting -articles (`gnus-article-treat-ansi-sequences'). +** Gnus now supports the "hashcash" client puzzle anti-spam mechanism. Use +`(setq message-generate-hashcash t)' to enable. *Note Hashcash::. -** International host names (IDNA) can now be decoded inside article -bodies using `W i' (`gnus-summary-idna-message'). This require that -GNU Libidn (`http://www.gnu.org/software/libidn/') has been installed. +** You can now drag and drop attachments to the Message buffer. See +`mml-dnd-protocol-alist' and `mml-dnd-attach-options'. *Note MIME: +(message)MIME. -** Gnus includes an Emacs Lisp SASL library. +** The option `message-yank-empty-prefix' now controls how empty lines are +prefixed in cited text. *Note Insertion Variables: (message)Insertion +Variables. -This provide a clean API to SASL mechanisms from within Emacs. The -user visible aspects of this, compared to the earlier situation, -include support for DIGEST-MD5 and NTLM. +** Gnus uses narrowing to hide headers in Message buffers. The +`References' header is hidden by default. To make all headers visible, +use `(setq message-hidden-headers nil)'. *Note Message Headers: +(message)Message Headers. -** ManageSieve connections uses the SASL library by default. + +* Changes in back ends -The primary change this brings is support for DIGEST-MD5 and NTLM, -when the server support it. +** The nntp back end stores article marks in `~/News/marks'. -** Gnus include a password cache mechanism in password.el. +The directory can be changed using the (customizable) variable +`nntp-marks-directory', and marks can be disabled using the (back end) +variable `nntp-marks-is-evil'. The advantage of this is that you can +copy `~/News/marks' (using rsync, scp or whatever) to another Gnus +installation, and it will realize what articles you have read and +marked. The data in `~/News/marks' has priority over the same data in +`~/.newsrc.eld'. -It is enabled by default (see `password-cache'), with a short timeout -of 16 seconds (see `password-cache-expiry'). If PGG is used as the -PGP back end, the PGP passphrase is managed by this mechanism. -Passwords for ManageSieve connections are managed by this mechanism, -after quering the user about whether to do so. +** You can import and export your RSS subscriptions from OPML files. *Note +RSS::. ** IMAP identity (RFC 2971) is supported. -By default, Gnus do not send any information about itself, but you can +By default, Gnus does not send any information about itself, but you can customize it using the variable `nnimap-id'. -** The `all.SCORE' file can be edited from the group buffer using `W e'. +** The `nnrss' back end now supports multilingual text. Non-ASCII group +names for the `nnrss' groups are also supported. *Note RSS::. -** Gnus now MIME decode articles even when they lack "MIME-Version" -header. This changes the default of `gnus-article-loose-mime'. +** Retrieving mail with POP3 is supported over SSL/TLS and with StartTLS. -** Gnus now view DNS master files sent as text/dns using dns-mode. +** The nnml back end allows other compression programs beside `gzip' for +compressed message files. *Note Mail Spool::. -** Gnus now support the "hashcash" client puzzle anti-spam idea. See -the Gnus manual, section Hashcash, for more information. Use `(setq -message-generate-hashcash t)' to enable. + +* Appearance -** Gnus supports new limiting commands in the Summary buffer: `/ r' -(`gnus-summary-limit-to-replied') and `/ R' -(`gnus-summary-limit-to-recipient'). *Note Limiting::. +** The tool bar has been updated to use GNOME icons. You can also +customize the tool bar. There's no documentation in the manual yet, but +`M-x customize-apropos RET -tool-bar$' should get you started. (Only +for Emacs, not in XEmacs.) -** Gnus supports a new sort command in the Summary buffer: `C-c C-s C-t' -(`gnus-summary-sort-by-recipient'). *Note Summary Sorting:: +** The tool bar icons are now (de)activated correctly in the group buffer, +see the variable `gnus-group-update-tool-bar'. Its default value +depends on your Emacs version. -** The `nnrss' back end now supports multilingual text. Non-ASCII group -names for the `nnrss' groups are also supported. *Note RSS::. +** You can change the location of XEmacs' toolbars in Gnus buffers. See +`gnus-use-toolbar' and `message-use-toolbar'. -** URLs inside OpenPGP: headers are retrieved and imported to your PGP -key ring when you click on them. -** Gnus uses narrowing to hide headers in Message buffers. The -`References' header is hidden by default. To make all headers -visible, use `(setq message-hidden-headers nil)'. + +* Miscellaneous changes -** `gnus-decay-scores' can be a regexp matching score files. This -allows to decay only adaptive score files. *Note Score Decays::. +** Having edited the select-method for the foreign server in the server +buffer is immediately reflected to the subscription of the groups which +use the server in question. For instance, if you change +`nntp-via-address' into `bar.example.com' from `foo.example.com', Gnus +will connect to the news host by way of the intermediate host +`bar.example.com' from next time. + +** The `all.SCORE' file can be edited from the group buffer using `W e'. -** S/MIME now feature LDAP user certificate searches. You need to -configure the server in `smime-ldap-host-list'. * For older news, see Gnus info node "New Features". @@ -115,7 +182,8 @@ configure the server in `smime-ldap-host-list'. ---------------------------------------------------------------------- Copyright information: -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. +Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, + 2006 Free Software Foundation, Inc. Permission is granted to anyone to make or distribute verbatim copies of this document as received, in any medium, provided that the diff --git a/Makefile.in b/Makefile.in index d5bc65a..766ab90 100644 --- a/Makefile.in +++ b/Makefile.in @@ -7,6 +7,38 @@ srcdir = @srcdir@ EMACS = @EMACS@ XEMACS = @EMACS@ +GZIP_PROG = gzip -f + +# # # # # # # # # # Release variables (for maintainer only): +# +# Files removed from `cvs export' output before creating the tar-ball: +CVS_IGNORE_FILES = .cvsignore contrib/.cvsignore etc/.cvsignore \ + lisp/.cvsignore texi/.cvsignore texi/ps/.cvsignore .arch-inventory +# Name and mail address in ChangeLog format for the release commit: +COMMITTER = Lars Magne Ingebrigtsen +# CODENAME for development releases (CODENAME must have a trailing space, +# (e.g. "Oort ") +CODENAME = +# Codename initial (lower case), e.g. 'n' for "No Gnus". +CIN = +# Files with hard-coded versions numbers: +RELEASE_COMMIT_FILES = ChangeLog README \ + lisp/ChangeLog lisp/gnus.el \ + texi/ChangeLog texi/gnus.texi texi/message.texi texi/gnus-faq.texi +# Pattern matching previous version(s): +OLD_PATTERN = \(5.10.[0-9]*\|0\.[1-9][0-9]*\) +# CVS tag of the previous version: +OLD_TAG = v5-10-6 +# CVS tag of the current release: +TAG = v5-10 +# +# Procedure: +# - release-bump-version +# - release-commit +# - release-files or release-files-signed +# +# # # # # # # # # # End of release variables + all: lick info lick: @@ -17,6 +49,12 @@ install: cd texi && $(MAKE) EMACS="$(EMACS)" install cd etc && $(MAKE) EMACS="$(EMACS)" install +list-installed-shadows: + cd lisp && $(MAKE) EMACS="$(EMACS)" lispdir="$(lispdir)" list-installed-shadows + +remove-installed-shadows: + cd lisp && $(MAKE) EMACS="$(EMACS)" lispdir="$(lispdir)" remove-installed-shadows + uninstall: cd lisp && $(MAKE) lispdir="$(lispdir)" uninstall cd texi && $(MAKE) uninstall @@ -35,10 +73,11 @@ info: cd texi && $(MAKE) EMACS="$(EMACS)" all clean: - rm -f */*.orig */*.rej *.orig *.rej + for i in lisp texi etc texi/ps; do (cd $$i; $(MAKE) clean); done + rm -f *.orig *.rej *~ elclean: - rm lisp/*.elc + cd lisp && rm -f *.elc auto-autoloads.el custom-load.el gnus-load.el x: $(MAKE) EMACS=$(XEMACS) @@ -46,10 +85,8 @@ x: xsome: $(MAKE) EMACS="$(XEMACS)" some -distclean: - make clean - rm -rf *~ - for i in lisp texi etc texi/ps; do (cd $$i; make distclean); done +distclean: clean + for i in lisp texi etc texi/ps; do (cd $$i; $(MAKE) distclean); done rm -f config.log config.status config.cache Makefile config.status: $(srcdir)/configure @@ -59,6 +96,129 @@ $(srcdir)/configure: $(srcdir)/configure.in Makefile: $(srcdir)/Makefile.in config.status CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status +# # # # # # # # # # Release targets (for maintainer only): + +release-check-settings: + @echo + @echo "COMMITTER = '$(COMMITTER)'" + @echo " (example: 'Foo Bar ')" + @echo "VERSION = '$(VERSION)' (example: '5.10.6')" + @echo "CODENAME = '$(CODENAME)' (example: 'No ')" + @echo "CIN = '$(CIN)' (example: 'n', codename initial)" + @echo "TAG = '$(TAG)' (example: 'v5-10-6')" + @echo "OLD_TAG = '$(OLD_TAG)' (example: 'v5-10-5')" + @echo + @if [ x"$(VERSION)" = x ]; then echo "error: No VERSION given."; exit 1; else :; fi + @if [ x"$(TAG)" = x ]; then echo "error: No TAG given."; exit 1; else :; fi + @echo + @echo Settings checked successfully. + @echo + @echo You may now make... + @echo release-bump-version + @echo release-commit + @echo release-files or release-files-signed + +# Needs GNU grep and a recent GNU sed: +release-bump-version: release-check-settings + sed -i -e '/^(defconst gnus-version-number /s,"$(OLD_PATTERN)","$(VERSION)",' lisp/gnus.el + sed -i -e '/^.newcommand{.gnusversionname}{[A-Za-z ]*Gnus v/s,$(OLD_PATTERN),$(VERSION),' texi/gnus.texi + sed -i -e '/^This manual corresponds to [A-Za-z ]*Gnus v/s,$(OLD_PATTERN),$(VERSION),' texi/gnus.texi + sed -i -e '/^corresponding to this manual is [A-Za-z ]*Gnus v/s,$(OLD_PATTERN),$(VERSION),' texi/message.texi + sed -i -e 's,/[a-z]*gnus-[0-9.]*/,/$(CIN)gnus-$(VERSION)/,' README + if [ "x$(CODENAME)" = "x" ]; then \ + sed -i -e '/The current release ($(OLD_PATTERN)) should/s,$(OLD_PATTERN),$(VERSION),' texi/gnus-faq.texi; \ + else \ + true; \ + fi + @if grep -q "$(CODENAME)Gnus v$(VERSION) is released" ChangeLog; then \ + echo "ChangeLog is already updated"; \ + else \ + sed -i -e "1s|^|`date -I` $(COMMITTER)\n\n\t* README: $(CODENAME)Gnus v$(VERSION) is released.\n\n|" ChangeLog; \ + fi + @if grep -q "$(CODENAME)Gnus v$(VERSION) is released" texi/ChangeLog; then \ + echo "texi/ChangeLog is already updated"; \ + else \ + sed -i -e "1s|^|`date -I` $(COMMITTER)\n\n\t* gnus.texi, gnus-faq.texi, message.texi: $(CODENAME)Gnus v$(VERSION) is released.\n\n|" texi/ChangeLog; \ + fi + @if grep -q "$(CODENAME)Gnus v$(VERSION) is released" lisp/ChangeLog; then \ + echo "lisp/ChangeLog is already updated"; \ + else \ + sed -i -e "1s|^|`date -I` $(COMMITTER)\n\n\t* gnus.el: $(CODENAME)Gnus v$(VERSION) is released.\n\n|" lisp/ChangeLog; \ + fi + cvs diff -U0 $(RELEASE_COMMIT_FILES); sleep 2 + +release-revert-files: + rm -i $(RELEASE_COMMIT_FILES) + cvs update $(RELEASE_COMMIT_FILES) + +release-commit: release-check-settings + @echo -e '\007' + @echo + @echo "Really do the release-commit for $(CODENAME)Gnus v$(VERSION)?" + @echo "Command line:" + @echo " " cvs commit -m "$(CODENAME)Gnus v$(VERSION) is released." $(RELEASE_COMMIT_FILES) + @echo + @echo "Hit RET to continue or Ctrl-C to abort." + @echo + @read dummy + cvs commit -m "$(CODENAME)Gnus v$(VERSION) is released." $(RELEASE_COMMIT_FILES) + @echo + @echo "Add tag $(TAG) to CVS?" + @echo "Command line:" + @echo " " cvs tag $(TAG) + @echo "Hit RET to continue or Ctrl-C to abort." + @echo + @read dummy + cvs tag $(TAG) + +release-files: release-make-tar-ball release-diff + @echo "Release files have been created:" + @ls -l $(CIN)gnus-$(VERSION).tar.gz + @ls -l $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff.gz + +release-files-signed: release-files release-sign-files + +# Sign prepared files: +release-sign-files: + if [ "x$$GPG_AGENT_INFO" = "x" ]; then \ + read -sp "Enter pass phrase: " phrase ; \ + gpg_opt="--passphrase-fd 0"; \ + else \ + gpg_opt=""; phrase=""; \ + fi; \ + for i in $(CIN)gnus-$(VERSION).tar.gz \ + $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff.gz; do \ + rm -f $$i.sig; \ + echo "$$phrase" | gpg --detach-sign $$gpg_opt $$i; \ + done; true + @ls -l $(CIN)gnus-$(VERSION).tar.gz{.sig,} + @ls -l $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff.gz{.sig,} + @gpg --verify $(CIN)gnus-$(VERSION).tar.gz{.sig,} + @gpg --verify $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff.gz{.sig,} + +release-cvs-export $(CIN)gnus-$(VERSION): release-check-settings + rm -fr $(CIN)gnus-$(VERSION) + cvs export -d $(CIN)gnus-$(VERSION) -r $(TAG) gnus + +release-make-tar-ball: $(CIN)gnus-$(VERSION) + [ -d $(CIN)gnus-$(VERSION) ] && cd $(CIN)gnus-$(VERSION) && \ + rm $(CVS_IGNORE_FILES) || true + tar zcvf $(CIN)gnus-$(VERSION).tar.gz $(CIN)gnus-$(VERSION) + ls -l $(CIN)gnus-$(VERSION).tar.gz + +# Make a diff between current and previous release. Example: +# ftp://quimby.gnus.org/pub/gnus/ding-patches/gnus-5.10.5-5.10.6.diff.gz +release-diff: release-check-settings + cvs diff -r $(OLD_TAG) -r $(TAG) | sed -e '/^\? /d' > temp.diff || true + mv temp.diff $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff + $(GZIP_PROG) $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff + ls -l $(CIN)gnus-`echo $(OLD_TAG)%$(TAG)|tr - .|tr -d v|tr % -`.diff.gz + +release-post-clean: release-check-settings + rm -fr $(CIN)gnus-$(TAG) temp.diff + +# # # # # # # # # # End of release targets + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/README b/README index e3627c8..dc69f8a 100644 --- a/README +++ b/README @@ -1,11 +1,11 @@ -This package contains a beta version of Gnus. The lisp directory -contains the source lisp files, and the texi directory contains a -draft of the Gnus info pages. +This package contains a development version of Gnus. The lisp directory +contains the source lisp files, and the texi directory contains the Gnus info +pages. To use Gnus you first have to unpack the files, which you've obviously done, because you are reading this. -You should definitely byte-compile the source files. To do that, you +You should definitely byte-compile the source files. To do that, you can simply say "./configure && make" in this directory. Do not say "make install". I repeat, do *NOT* say "make install". If @@ -16,10 +16,10 @@ won't. If you are using XEmacs, you *must* say "./configure && make EMACS=xemacs". -Then you have to tell Emacs where Gnus is. You might put something +Then you have to tell Emacs where Gnus is. You might put something like - (setq load-path (cons (expand-file-name "~/gnus-5.6.53/lisp") load-path)) + (setq load-path (cons (expand-file-name "~/ngnus-0.4/lisp") load-path)) (require 'gnus-load) in your .emacs file, or wherever you keep such things. @@ -27,36 +27,24 @@ in your .emacs file, or wherever you keep such things. To enable reading the Gnus manual, you could say something like: (require 'info) - (setq Info-default-directory-list - (cons "~/gnus-5.6.53/texi" Info-default-directory-list)) + (if (featurep 'xemacs) + (add-to-list 'Info-directory-list "~/ngnus-0.4/texi/") + (add-to-list 'Info-default-directory-list "~/ngnus-0.4/texi/")) -or - - (require 'info) - (setq Info-directory-list - (cons "~/gnus-5.6.53/texi" Info-directory-list)) - -depending on which version of Emacs or XEmacs you're using. - -Note that Gnus and GNUS can't coexist in a single Emacs. They both use -the same function and variable names. If you have been running GNUS -in your Emacs, you should probably exit that Emacs and start a new one -to fire up Gnus. - -Gnus does absolutely not work with anything older than Emacs 21.1 or -XEmacs 21.4. You definitely need a relatively current Emacs. +No Gnus does absolutely not work with anything older than Emacs 21.1 or +XEmacs 21.4. To compile the Gnus manual, you either need a pretty new Emacs, or a pretty new version of the texinfo tools. Then you do a `M-x gnus', and everything should... uhm... it should -work, but it might not. Set `debug-on-error' to t, and mail me the +work, but it might not. Set `debug-on-error' to t, and mail me the backtraces, or, better yet, find out why Gnus does something wrong, -fix it, and send me the diffs. :-) +fix it, and send me the diffs. :-) There are four main things I want your help and input on: -1) Startup. Does everything go smoothly, and why not? +1) Startup. Does everything go smoothly, and why not? 2) Any errors while you read news normally? @@ -66,4 +54,4 @@ There are four main things I want your help and input on: bit, and features you would like to see. Send any comments and all your bug fixes/complaints to -`bugs@gnus.org'. +`bugs@gnus.org'. diff --git a/aclocal.m4 b/aclocal.m4 index fbf1b2a..3566926 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -87,7 +87,7 @@ AC_DEFUN(AC_PATH_LISPDIR, [ datadir="\$(prefix)/lib" lispdir="\$(datadir)/${EMACS_FLAVOR}/site-packages/lisp/gnus" else - lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp" + lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp/gnus" fi for thedir in share lib; do potential= @@ -95,7 +95,7 @@ AC_DEFUN(AC_PATH_LISPDIR, [ if test "$EMACS_FLAVOR" = "xemacs"; then lispdir="\$(prefix)/${thedir}/${EMACS_FLAVOR}/site-packages/lisp/gnus" else - lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp" + lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp/gnus" fi break fi @@ -113,7 +113,7 @@ AC_DEFUN(AC_PATH_ETCDIR, [ if test "$EMACS_FLAVOR" = "xemacs"; then etcdir="\$(lispdir)/../../etc" else - etcdir="\$(lispdir)/../etc" + etcdir="\$(lispdir)/../../etc" fi fi AC_MSG_RESULT($etcdir) diff --git a/configure b/configure index 3b8a811..6e43d36 100755 --- a/configure +++ b/configure @@ -1,40 +1,288 @@ #! /bin/sh - # Guess values for system-dependent variables and create Makefiles. -# Generated automatically using autoconf version 2.13 -# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. +# Generated by GNU Autoconf 2.59. # +# Copyright (C) 2003 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. +## --------------------- ## +## M4sh Initialization. ## +## --------------------- ## + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' +elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then + set -o posix +fi +DUALCASE=1; export DUALCASE # for MKS sh + +# Support unset when possible. +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + as_unset=unset +else + as_unset=false +fi + -# Defaults: -ac_help= +# Work around bugs in pre-3.0 UWIN ksh. +$as_unset ENV MAIL MAILPATH +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +for as_var in \ + LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ + LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ + LC_TELEPHONE LC_TIME +do + if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then + eval $as_var=C; export $as_var + else + $as_unset $as_var + fi +done + +# Required to use basename. +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi + +if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + + +# Name of the executable. +as_me=`$as_basename "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)$' \| \ + . : '\(.\)' 2>/dev/null || +echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; } + /^X\/\(\/\/\)$/{ s//\1/; q; } + /^X\/\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` + + +# PATH needs CR, and LINENO needs CR and PATH. +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + + + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" || { + # Find who we are. Look in the path if we contain no path at all + # relative or not. + case $0 in + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break +done + + ;; + esac + # We did not find ourselves, most probably we were run as `sh COMMAND' + # in which case we are not to be found in the path. + if test "x$as_myself" = x; then + as_myself=$0 + fi + if test ! -f "$as_myself"; then + { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2 + { (exit 1); exit 1; }; } + fi + case $CONFIG_SHELL in + '') + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for as_base in sh bash ksh sh5; do + case $as_dir in + /*) + if ("$as_dir/$as_base" -c ' + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then + $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; } + $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; } + CONFIG_SHELL=$as_dir/$as_base + export CONFIG_SHELL + exec "$CONFIG_SHELL" "$0" ${1+"$@"} + fi;; + esac + done +done +;; + esac + + # Create $as_me.lineno as a copy of $as_myself, but with $LINENO + # uniformly replaced by the line number. The first 'sed' inserts a + # line-number line before each line; the second 'sed' does the real + # work. The second script uses 'N' to pair each line-number line + # with the numbered line, and appends trailing '-' during + # substitution so that $LINENO is not a special case at line end. + # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the + # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-) + sed '=' <$as_myself | + sed ' + N + s,$,-, + : loop + s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3, + t loop + s,-$,, + s,^['$as_cr_digits']*\n,, + ' >$as_me.lineno && + chmod +x $as_me.lineno || + { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 + { (exit 1); exit 1; }; } + + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensible to this). + . ./$as_me.lineno + # Exit status is that of the last command. + exit +} + + +case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in + *c*,-n*) ECHO_N= ECHO_C=' +' ECHO_T=' ' ;; + *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; + *) ECHO_N= ECHO_C='\c' ECHO_T= ;; +esac + +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi + +rm -f conf$$ conf$$.exe conf$$.file +echo >conf$$.file +if ln -s conf$$.file conf$$ 2>/dev/null; then + # We could just check for DJGPP; but this test a) works b) is more generic + # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). + if test -f conf$$.exe; then + # Don't use ln at all; we don't have any links + as_ln_s='cp -p' + else + as_ln_s='ln -s' + fi +elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln +else + as_ln_s='cp -p' +fi +rm -f conf$$ conf$$.exe conf$$.file + +if mkdir -p . 2>/dev/null; then + as_mkdir_p=: +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_executable_p="test -f" + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +# IFS +# We need space, tab and new line, in precisely that order. +as_nl=' +' +IFS=" $as_nl" + +# CDPATH. +$as_unset CDPATH + + +# Name of the host. +# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +exec 6>&1 + +# +# Initializations. +# ac_default_prefix=/usr/local -# Any additions from configure.in: -ac_help="$ac_help - --with-xemacs Use XEmacs to build" -ac_help="$ac_help - --with-emacs Use Emacs to build" -ac_help="$ac_help - --with-lispdir=DIR Where to install lisp files" -ac_help="$ac_help - --with-etcdir=DIR Where to install etc files" -ac_help="$ac_help - --with-url=DIR Specify where to find the url package" -ac_help="$ac_help - --with-w3=DIR Specify where to find the w3 package" -ac_help="$ac_help - --with-fonts Assume all fonts required are available" +ac_config_libobj_dir=. +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= +SHELL=${CONFIG_SHELL-/bin/sh} + +# Maximum number of lines to put in a shell here document. +# This variable seems obsolete. It should probably be removed, and +# only ac_max_sed_lines should be used. +: ${ac_max_here_lines=38} + +# Identity of this package. +PACKAGE_NAME= +PACKAGE_TARNAME= +PACKAGE_VERSION= +PACKAGE_STRING= +PACKAGE_BUGREPORT= + +ac_unique_file="lisp/gnus.el" +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA MAKEINFO EMACS XEMACS EMACS_FLAVOR lispdir etcdir info_dir HAVE_url URL HAVE_w3_forms W3 FLAGS LATEX WITH_FONTS_bembo WITHOUT_FONTS_bembo WITH_FONTS_pfu WITHOUT_FONTS_pfu WITH_FONTS_bcr WITHOUT_FONTS_bcr USE_FONTS LIBOBJS LTLIBOBJS' +ac_subst_files='' # Initialize some variables set by options. +ac_init_help= +ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. -build=NONE -cache_file=./config.cache +cache_file=/dev/null exec_prefix=NONE -host=NONE no_create= -nonopt=NONE no_recursion= prefix=NONE program_prefix=NONE @@ -43,10 +291,15 @@ program_transform_name=s,x,x, silent= site= srcdir= -target=NONE verbose= x_includes=NONE x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' @@ -60,17 +313,9 @@ oldincludedir='/usr/include' infodir='${prefix}/info' mandir='${prefix}/man' -# Initialize some other variables. -subdirs= -MFLAGS= MAKEFLAGS= -SHELL=${CONFIG_SHELL-/bin/sh} -# Maximum number of lines to put in a shell here document. -ac_max_here_lines=12 - ac_prev= for ac_option do - # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval "$ac_prev=\$ac_option" @@ -78,59 +323,59 @@ do continue fi - case "$ac_option" in - -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; - *) ac_optarg= ;; - esac + ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'` # Accept the important Cygnus configure options, so we can diagnose typos. - case "$ac_option" in + case $ac_option in -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir="$ac_optarg" ;; + bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) - ac_prev=build ;; + ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build="$ac_optarg" ;; + build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file="$ac_optarg" ;; + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad | --data | --dat | --da) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | --da=*) - datadir="$ac_optarg" ;; + datadir=$ac_optarg ;; -disable-* | --disable-*) - ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` + ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then - { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } - fi - ac_feature=`echo $ac_feature| sed 's/-/_/g'` - eval "enable_${ac_feature}=no" ;; + expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + { (exit 1); exit 1; }; } + ac_feature=`echo $ac_feature | sed 's/-/_/g'` + eval "enable_$ac_feature=no" ;; -enable-* | --enable-*) - ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` + ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then - { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } - fi - ac_feature=`echo $ac_feature| sed 's/-/_/g'` - case "$ac_option" in - *=*) ;; + expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + { (exit 1); exit 1; }; } + ac_feature=`echo $ac_feature | sed 's/-/_/g'` + case $ac_option in + *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac - eval "enable_${ac_feature}='$ac_optarg'" ;; + eval "enable_$ac_feature='$ac_optarg'" ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ @@ -139,95 +384,47 @@ do -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) - exec_prefix="$ac_optarg" ;; + exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; - -help | --help | --hel | --he) - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat << EOF -Usage: configure [options] [host] -Options: [defaults in brackets after descriptions] -Configuration: - --cache-file=FILE cache test results in FILE - --help print this message - --no-create do not create output files - --quiet, --silent do not print \`checking...' messages - --version print the version of autoconf that created configure -Directory and file names: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [same as prefix] - --bindir=DIR user executables in DIR [EPREFIX/bin] - --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] - --libexecdir=DIR program executables in DIR [EPREFIX/libexec] - --datadir=DIR read-only architecture-independent data in DIR - [PREFIX/share] - --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data in DIR - [PREFIX/com] - --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] - --libdir=DIR object code libraries in DIR [EPREFIX/lib] - --includedir=DIR C header files in DIR [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] - --infodir=DIR info documentation in DIR [PREFIX/info] - --mandir=DIR man documentation in DIR [PREFIX/man] - --srcdir=DIR find the sources in DIR [configure dir or ..] - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM - run sed PROGRAM on installed program names -EOF - cat << EOF -Host type: - --build=BUILD configure for building on BUILD [BUILD=HOST] - --host=HOST configure for HOST [guessed] - --target=TARGET configure for TARGET [TARGET=HOST] -Features and packages: - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --x-includes=DIR X include files are in DIR - --x-libraries=DIR X library files are in DIR -EOF - if test -n "$ac_help"; then - echo "--enable and --with options recognized:$ac_help" - fi - exit 0 ;; + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; -host | --host | --hos | --ho) - ac_prev=host ;; + ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) - host="$ac_optarg" ;; + host_alias=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir="$ac_optarg" ;; + includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir="$ac_optarg" ;; + infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir="$ac_optarg" ;; + libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) - libexecdir="$ac_optarg" ;; + libexecdir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst \ @@ -236,19 +433,19 @@ EOF -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) - localstatedir="$ac_optarg" ;; + localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir="$ac_optarg" ;; + mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c) + | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ @@ -262,26 +459,26 @@ EOF -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir="$ac_optarg" ;; + oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix="$ac_optarg" ;; + prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix="$ac_optarg" ;; + program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix="$ac_optarg" ;; + program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ @@ -298,7 +495,7 @@ EOF | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name="$ac_optarg" ;; + program_transform_name=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) @@ -308,7 +505,7 @@ EOF ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) - sbindir="$ac_optarg" ;; + sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ @@ -319,58 +516,57 @@ EOF | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) - sharedstatedir="$ac_optarg" ;; + sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) - site="$ac_optarg" ;; + site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir="$ac_optarg" ;; + srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir="$ac_optarg" ;; + sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target ;; + ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target="$ac_optarg" ;; + target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; - -version | --version | --versio | --versi | --vers) - echo "configure generated by autoconf version 2.13" - exit 0 ;; + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; -with-* | --with-*) - ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` + ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then - { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } - fi + expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid package name: $ac_package" >&2 + { (exit 1); exit 1; }; } ac_package=`echo $ac_package| sed 's/-/_/g'` - case "$ac_option" in - *=*) ;; + case $ac_option in + *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac - eval "with_${ac_package}='$ac_optarg'" ;; + eval "with_$ac_package='$ac_optarg'" ;; -without-* | --without-*) - ac_package=`echo $ac_option|sed -e 's/-*without-//'` + ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then - { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } - fi - ac_package=`echo $ac_package| sed 's/-/_/g'` - eval "with_${ac_package}=no" ;; + expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid package name: $ac_package" >&2 + { (exit 1); exit 1; }; } + ac_package=`echo $ac_package | sed 's/-/_/g'` + eval "with_$ac_package=no" ;; --x) # Obsolete; use --with-x. @@ -381,99 +577,110 @@ EOF ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes="$ac_optarg" ;; + x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries="$ac_optarg" ;; + x_libraries=$ac_optarg ;; - -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } + -*) { echo "$as_me: error: unrecognized option: $ac_option +Try \`$0 --help' for more information." >&2 + { (exit 1); exit 1; }; } ;; + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 + { (exit 1); exit 1; }; } + ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` + eval "$ac_envvar='$ac_optarg'" + export $ac_envvar ;; + *) - if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then - echo "configure: warning: $ac_option: invalid host type" 1>&2 - fi - if test "x$nonopt" != xNONE; then - { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } - fi - nonopt="$ac_option" + # FIXME: should be removed in autoconf 3.0. + echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then - { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + { echo "$as_me: error: missing argument to $ac_option" >&2 + { (exit 1); exit 1; }; } fi -trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 - -# File descriptor usage: -# 0 standard input -# 1 file creation -# 2 errors and warnings -# 3 some systems may open it to /dev/tty -# 4 used on the Kubota Titan -# 6 checking for... messages and results -# 5 compiler messages saved in config.log -if test "$silent" = yes; then - exec 6>/dev/null -else - exec 6>&1 -fi -exec 5>./config.log - -echo "\ -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. -" 1>&5 +# Be sure to have absolute paths. +for ac_var in exec_prefix prefix +do + eval ac_val=$`echo $ac_var` + case $ac_val in + [\\/$]* | ?:[\\/]* | NONE | '' ) ;; + *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 + { (exit 1); exit 1; }; };; + esac +done -# Strip out --no-create and --no-recursion so they do not pile up. -# Also quote any args containing shell metacharacters. -ac_configure_args= -for ac_arg +# Be sure to have absolute paths. +for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \ + localstatedir libdir includedir oldincludedir infodir mandir do - case "$ac_arg" in - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c) ;; - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; - *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) - ac_configure_args="$ac_configure_args '$ac_arg'" ;; - *) ac_configure_args="$ac_configure_args $ac_arg" ;; + eval ac_val=$`echo $ac_var` + case $ac_val in + [\\/$]* | ?:[\\/]* ) ;; + *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 + { (exit 1); exit 1; }; };; esac done -# NLS nuisances. -# Only set these to C if already set. These must not be set unconditionally -# because not all systems understand e.g. LANG=C (notably SCO). -# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! -# Non-C LC_CTYPE values break the ctype check. -if test "${LANG+set}" = set; then LANG=C; export LANG; fi -if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi -if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi -if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. + If a cross compiler is detected then cross compile mode will be used." >&2 + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -rf conftest* confdefs.h -# AIX cpp loses on an empty file, so make sure it contains at least a newline. -echo > confdefs.h +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null -# A filename unique to this package, relative to the directory that -# configure is in, which we can look for to find out if srcdir is correct. -ac_unique_file=lisp/gnus.el # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then its parent. - ac_prog=$0 - ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` - test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. + ac_confdir=`(dirname "$0") 2>/dev/null || +$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$0" : 'X\(//\)[^/]' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| \ + . : '\(.\)' 2>/dev/null || +echo X"$0" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } + /^X\(\/\/\)[^/].*/{ s//\1/; q; } + /^X\(\/\/\)$/{ s//\1/; q; } + /^X\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` srcdir=$ac_confdir if test ! -r $srcdir/$ac_unique_file; then srcdir=.. @@ -483,13 +690,433 @@ else fi if test ! -r $srcdir/$ac_unique_file; then if test "$ac_srcdir_defaulted" = yes; then - { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } + { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2 + { (exit 1); exit 1; }; } else - { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } + { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 + { (exit 1); exit 1; }; } fi fi -srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` +(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null || + { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2 + { (exit 1); exit 1; }; } +srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'` +ac_env_build_alias_set=${build_alias+set} +ac_env_build_alias_value=$build_alias +ac_cv_env_build_alias_set=${build_alias+set} +ac_cv_env_build_alias_value=$build_alias +ac_env_host_alias_set=${host_alias+set} +ac_env_host_alias_value=$host_alias +ac_cv_env_host_alias_set=${host_alias+set} +ac_cv_env_host_alias_value=$host_alias +ac_env_target_alias_set=${target_alias+set} +ac_env_target_alias_value=$target_alias +ac_cv_env_target_alias_set=${target_alias+set} +ac_cv_env_target_alias_value=$target_alias + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures this package to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +_ACEOF + + cat <<_ACEOF +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --datadir=DIR read-only architecture-independent data [PREFIX/share] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --infodir=DIR info documentation [PREFIX/info] + --mandir=DIR man documentation [PREFIX/man] +_ACEOF + + cat <<\_ACEOF +_ACEOF +fi + +if test -n "$ac_init_help"; then + + cat <<\_ACEOF + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-xemacs Use XEmacs to build + --with-emacs Use Emacs to build + --with-lispdir=DIR Where to install lisp files + --with-etcdir=DIR Where to install etc files + --with-url=DIR Specify where to find the url package + --with-w3=DIR Specify where to find the w3 package + --with-fonts Assume all fonts required are available + +_ACEOF +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + ac_popdir=`pwd` + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d $ac_dir || continue + ac_builddir=. + +if test "$ac_dir" != .; then + ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` + # A "../" for each directory in $ac_dir_suffix. + ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` +else + ac_dir_suffix= ac_top_builddir= +fi + +case $srcdir in + .) # No --srcdir option. We are building in place. + ac_srcdir=. + if test -z "$ac_top_builddir"; then + ac_top_srcdir=. + else + ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` + fi ;; + [\\/]* | ?:[\\/]* ) # Absolute path. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir ;; + *) # Relative path. + ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_builddir$srcdir ;; +esac + +# Do not use `cd foo && pwd` to compute absolute paths, because +# the directories may not exist. +case `pwd` in +.) ac_abs_builddir="$ac_dir";; +*) + case "$ac_dir" in + .) ac_abs_builddir=`pwd`;; + [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";; + *) ac_abs_builddir=`pwd`/"$ac_dir";; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_top_builddir=${ac_top_builddir}.;; +*) + case ${ac_top_builddir}. in + .) ac_abs_top_builddir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;; + *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_srcdir=$ac_srcdir;; +*) + case $ac_srcdir in + .) ac_abs_srcdir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;; + *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_top_srcdir=$ac_top_srcdir;; +*) + case $ac_top_srcdir in + .) ac_abs_top_srcdir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;; + *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;; + esac;; +esac + + cd $ac_dir + # Check for guested configure; otherwise get Cygnus style configure. + if test -f $ac_srcdir/configure.gnu; then + echo + $SHELL $ac_srcdir/configure.gnu --help=recursive + elif test -f $ac_srcdir/configure; then + echo + $SHELL $ac_srcdir/configure --help=recursive + elif test -f $ac_srcdir/configure.ac || + test -f $ac_srcdir/configure.in; then + echo + $ac_configure --help + else + echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi + cd $ac_popdir + done +fi + +test -n "$ac_init_help" && exit 0 +if $ac_init_version; then + cat <<\_ACEOF + +Copyright (C) 2003 Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit 0 +fi +exec 5>config.log +cat >&5 <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by $as_me, which was +generated by GNU Autoconf 2.59. Invocation command line was + + $ $0 $@ + +_ACEOF +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +hostinfo = `(hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + echo "PATH: $as_dir" +done + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Strip out --silent because we don't want to record it for future runs. +# Also quote any args containing shell meta-characters. +# Make two passes to allow for proper duplicate-argument suppression. +ac_configure_args= +ac_configure_args0= +ac_configure_args1= +ac_sep= +ac_must_keep_next=false +for ac_pass in 1 2 +do + for ac_arg + do + case $ac_arg in + -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + continue ;; + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) + ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case $ac_pass in + 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; + 2) + ac_configure_args1="$ac_configure_args1 '$ac_arg'" + if test $ac_must_keep_next = true; then + ac_must_keep_next=false # Got value, back to normal. + else + case $ac_arg in + *=* | --config-cache | -C | -disable-* | --disable-* \ + | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ + | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ + | -with-* | --with-* | -without-* | --without-* | --x) + case "$ac_configure_args0 " in + "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; + esac + ;; + -* ) ac_must_keep_next=true ;; + esac + fi + ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'" + # Get rid of the leading space. + ac_sep=" " + ;; + esac + done +done +$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } +$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Be sure not to use single quotes in there, as some shells, +# such as our DU 5.0 friend, will then `close' the trap. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + + cat <<\_ASBOX +## ---------------- ## +## Cache variables. ## +## ---------------- ## +_ASBOX + echo + # The following way of writing the cache mishandles newlines in values, +{ + (set) 2>&1 | + case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in + *ac_space=\ *) + sed -n \ + "s/'"'"'/'"'"'\\\\'"'"''"'"'/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p" + ;; + *) + sed -n \ + "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" + ;; + esac; +} + echo + + cat <<\_ASBOX +## ----------------- ## +## Output variables. ## +## ----------------- ## +_ASBOX + echo + for ac_var in $ac_subst_vars + do + eval ac_val=$`echo $ac_var` + echo "$ac_var='"'"'$ac_val'"'"'" + done | sort + echo + + if test -n "$ac_subst_files"; then + cat <<\_ASBOX +## ------------- ## +## Output files. ## +## ------------- ## +_ASBOX + echo + for ac_var in $ac_subst_files + do + eval ac_val=$`echo $ac_var` + echo "$ac_var='"'"'$ac_val'"'"'" + done | sort + echo + fi + + if test -s confdefs.h; then + cat <<\_ASBOX +## ----------- ## +## confdefs.h. ## +## ----------- ## +_ASBOX + echo + sed "/^$/d" confdefs.h | sort + echo + fi + test "$ac_signal" != 0 && + echo "$as_me: caught signal $ac_signal" + echo "$as_me: exit $exit_status" + } >&5 + rm -f core *.core && + rm -rf conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status + ' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -rf conftest* confdefs.h +# AIX cpp loses on an empty file, so make sure it contains at least a newline. +echo >confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -z "$CONFIG_SITE"; then if test "x$prefix" != xNONE; then @@ -500,65 +1127,131 @@ if test -z "$CONFIG_SITE"; then fi for ac_site_file in $CONFIG_SITE; do if test -r "$ac_site_file"; then - echo "loading site script $ac_site_file" + { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 +echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then - echo "loading cache $cache_file" - . $cache_file + # Some versions of bash will fail to source /dev/null (special + # files actually), so we avoid doing that. + if test -f "$cache_file"; then + { echo "$as_me:$LINENO: loading cache $cache_file" >&5 +echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . $cache_file;; + *) . ./$cache_file;; + esac + fi else - echo "creating cache $cache_file" - > $cache_file + { echo "$as_me:$LINENO: creating cache $cache_file" >&5 +echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in `(set) 2>&1 | + sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val="\$ac_cv_env_${ac_var}_value" + eval ac_new_val="\$ac_env_${ac_var}_value" + case $ac_old_set,$ac_new_set in + set,) + { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 +echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 +echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 +echo "$as_me: former value: $ac_old_val" >&2;} + { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 +echo "$as_me: current value: $ac_new_val" >&2;} + ac_cache_corrupted=: + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) + ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 +echo "$as_me: error: changes in the environment can compromise the build" >&2;} + { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 +echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} + { (exit 1); exit 1; }; } fi ac_ext=c -# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ac_cpp='$CPP $CPPFLAGS' -ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' -ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' -cross_compiling=$ac_cv_prog_cc_cross - -ac_exeext= -ac_objext=o -if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then - # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. - if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then - ac_n= ac_c=' -' ac_t=' ' - else - ac_n=-n ac_c= ac_t= - fi -else - ac_n= ac_c='\c' ac_t= -fi +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + -echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:540: checking whether ${MAKE-make} sets \${MAKE}" >&5 -set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 + + + + + + + + + + +echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6 +set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'` +if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat > conftestmake <<\EOF + cat >conftest.make <<\_ACEOF all: - @echo 'ac_maketemp="${MAKE}"' -EOF + @echo 'ac_maketemp="$(MAKE)"' +_ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. -eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` +eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` if test -n "$ac_maketemp"; then eval ac_cv_prog_make_${ac_make}_set=yes else eval ac_cv_prog_make_${ac_make}_set=no fi -rm -f conftestmake +rm -f conftest.make fi if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then - echo "$ac_t""yes" 1>&6 + echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6 SET_MAKE= else - echo "$ac_t""no" 1>&6 + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 SET_MAKE="MAKE=${MAKE-make}" fi @@ -572,14 +1265,20 @@ for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break + elif test -f $ac_dir/shtool; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break fi done if test -z "$ac_aux_dir"; then - { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } + { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 +echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} + { (exit 1); exit 1; }; } fi -ac_config_guess=$ac_aux_dir/config.guess -ac_config_sub=$ac_aux_dir/config.sub -ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. +ac_config_guess="$SHELL $ac_aux_dir/config.guess" +ac_config_sub="$SHELL $ac_aux_dir/config.sub" +ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or @@ -588,60 +1287,75 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install +# AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. -echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:597: checking for a BSD compatible install" >&5 +echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 +echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6 if test -z "$INSTALL"; then -if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${ac_cv_path_install+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" - for ac_dir in $PATH; do - # Account for people who put trailing slashes in PATH elements. - case "$ac_dir/" in - /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - if test -f $ac_dir/$ac_prog; then + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + # Account for people who put trailing slashes in PATH elements. +case $as_dir/ in + ./ | .// | /cC/* | \ + /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ + ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ + /usr/ucb/* ) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && - grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then + grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : + elif test $ac_prog = install && + grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # program-specific install script used by HP pwplus--don't use. + : else - ac_cv_path_install="$ac_dir/$ac_prog -c" - break 2 + ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + break 3 fi fi done - ;; - esac - done - IFS="$ac_save_IFS" + done + ;; +esac +done + fi if test "${ac_cv_path_install+set}" = set; then - INSTALL="$ac_cv_path_install" + INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. We don't cache a # path for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the path is relative. - INSTALL="$ac_install_sh" + INSTALL=$ac_install_sh fi fi -echo "$ac_t""$INSTALL" 1>&6 +echo "$as_me:$LINENO: result: $INSTALL" >&5 +echo "${ECHO_T}$INSTALL" >&6 # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' @@ -650,96 +1364,108 @@ if test "${EMACS}" = "t"; then EMACS="" fi + # Check whether --with-xemacs or --without-xemacs was given. if test "${with_xemacs+set}" = set; then withval="$with_xemacs" - if test "${withval}" = "yes"; then EMACS=xemacs; else EMACS=${withval}; fi -fi + if test "${withval}" = "yes"; then EMACS=xemacs; else EMACS=${withval}; fi +fi; # Check whether --with-emacs or --without-emacs was given. if test "${with_emacs+set}" = set; then withval="$with_emacs" - if test "${withval}" = "yes"; then EMACS=emacs; else EMACS=${withval}; fi -fi - + if test "${withval}" = "yes"; then EMACS=emacs; else EMACS=${withval}; fi +fi; # Extract the first word of "makeinfo", so it can be a program name with args. set dummy makeinfo; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:669: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_MAKEINFO+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$MAKEINFO"; then ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test. else - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_prog_MAKEINFO="makeinfo" - break - fi - done - IFS="$ac_save_ifs" +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MAKEINFO="makeinfo" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + test -z "$ac_cv_prog_MAKEINFO" && ac_cv_prog_MAKEINFO="no" fi fi -MAKEINFO="$ac_cv_prog_MAKEINFO" +MAKEINFO=$ac_cv_prog_MAKEINFO if test -n "$MAKEINFO"; then - echo "$ac_t""$MAKEINFO" 1>&6 + echo "$as_me:$LINENO: result: $MAKEINFO" >&5 +echo "${ECHO_T}$MAKEINFO" >&6 else - echo "$ac_t""no" 1>&6 + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 fi # Extract the first word of "emacs", so it can be a program name with args. set dummy emacs; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:700: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_prog_EMACS'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_EMACS+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$EMACS"; then ac_cv_prog_EMACS="$EMACS" # Let the user override the test. else - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_prog_EMACS="emacs" - break - fi - done - IFS="$ac_save_ifs" +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_EMACS="emacs" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + test -z "$ac_cv_prog_EMACS" && ac_cv_prog_EMACS="xemacs" fi fi -EMACS="$ac_cv_prog_EMACS" +EMACS=$ac_cv_prog_EMACS if test -n "$EMACS"; then - echo "$ac_t""$EMACS" 1>&6 + echo "$as_me:$LINENO: result: $EMACS" >&5 +echo "${ECHO_T}$EMACS" >&6 else - echo "$ac_t""no" 1>&6 + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 fi - - echo $ac_n "checking if $EMACS is really XEmacs""... $ac_c" 1>&6 -echo "configure:731: checking if $EMACS is really XEmacs" >&5 - + + echo "$as_me:$LINENO: checking if $EMACS is really XEmacs" >&5 +echo $ECHO_N "checking if $EMACS is really XEmacs... $ECHO_C" >&6 + elisp="(if (string-match \"XEmacs\" emacs-version) \"yes\" \"no\") " if test -z ""noecho""; then - echo $ac_n "checking for xemacsp""... $ac_c" 1>&6 -echo "configure:736: checking for xemacsp" >&5 + echo "$as_me:$LINENO: checking for xemacsp" >&5 +echo $ECHO_N "checking for xemacsp... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_xemacsp'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_xemacsp+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -750,7 +1476,8 @@ fi xemacsp=${EMACS_cv_SYS_xemacsp} if test -z ""noecho""; then - echo "$ac_t""$xemacsp" 1>&6 + echo "$as_me:$LINENO: result: $xemacsp" >&5 +echo "${ECHO_T}$xemacsp" >&6 fi XEMACS=${EMACS_cv_SYS_xemacsp} @@ -758,25 +1485,26 @@ fi if test "$XEMACS" = "yes"; then EMACS_FLAVOR=xemacs fi - echo "$ac_t""$XEMACS" 1>&6 - - + echo "$as_me:$LINENO: result: $XEMACS" >&5 +echo "${ECHO_T}$XEMACS" >&6 + + if test "$prefix" = "NONE"; then - echo $ac_n "checking prefix for your Emacs""... $ac_c" 1>&6 -echo "configure:768: checking prefix for your Emacs" >&5 - + echo "$as_me:$LINENO: checking prefix for your Emacs" >&5 +echo $ECHO_N "checking prefix for your Emacs... $ECHO_C" >&6 + elisp="(expand-file-name \"..\" invocation-directory)" if test -z ""noecho""; then - echo $ac_n "checking for prefix""... $ac_c" 1>&6 -echo "configure:773: checking for prefix" >&5 + echo "$as_me:$LINENO: checking for prefix" >&5 +echo $ECHO_N "checking for prefix... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_prefix'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_prefix+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -787,20 +1515,22 @@ fi prefix=${EMACS_cv_SYS_prefix} if test -z ""noecho""; then - echo "$ac_t""$prefix" 1>&6 + echo "$as_me:$LINENO: result: $prefix" >&5 +echo "${ECHO_T}$prefix" >&6 fi prefix=${EMACS_cv_SYS_prefix} - echo "$ac_t""$prefix" 1>&6 + echo "$as_me:$LINENO: result: $prefix" >&5 +echo "${ECHO_T}$prefix" >&6 fi - # Check whether --with-lispdir or --without-lispdir was given. + +# Check whether --with-lispdir or --without-lispdir was given. if test "${with_lispdir+set}" = set; then withval="$with_lispdir" lispdir=${withval} -fi - - echo $ac_n "checking where .elc files should go""... $ac_c" 1>&6 -echo "configure:804: checking where .elc files should go" >&5 +fi; + echo "$as_me:$LINENO: checking where .elc files should go" >&5 +echo $ECHO_N "checking where .elc files should go... $ECHO_C" >&6 if test -z "$lispdir"; then theprefix=$prefix if test "x$theprefix" = "xNONE"; then @@ -810,7 +1540,7 @@ echo "configure:804: checking where .elc files should go" >&5 datadir="\$(prefix)/lib" lispdir="\$(datadir)/${EMACS_FLAVOR}/site-packages/lisp/gnus" else - lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp" + lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp/gnus" fi for thedir in share lib; do potential= @@ -818,37 +1548,39 @@ echo "configure:804: checking where .elc files should go" >&5 if test "$EMACS_FLAVOR" = "xemacs"; then lispdir="\$(prefix)/${thedir}/${EMACS_FLAVOR}/site-packages/lisp/gnus" else - lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp" + lispdir="\$(datadir)/${EMACS_FLAVOR}/site-lisp/gnus" fi break fi done fi - echo "$ac_t""$lispdir" 1>&6 - + echo "$as_me:$LINENO: result: $lispdir" >&5 +echo "${ECHO_T}$lispdir" >&6 + + - # Check whether --with-etcdir or --without-etcdir was given. +# Check whether --with-etcdir or --without-etcdir was given. if test "${with_etcdir+set}" = set; then withval="$with_etcdir" etcdir=${withval} -fi - - echo $ac_n "checking where etc files should go""... $ac_c" 1>&6 -echo "configure:839: checking where etc files should go" >&5 +fi; + echo "$as_me:$LINENO: checking where etc files should go" >&5 +echo $ECHO_N "checking where etc files should go... $ECHO_C" >&6 if test -z "$etcdir"; then if test "$EMACS_FLAVOR" = "xemacs"; then etcdir="\$(lispdir)/../../etc" else - etcdir="\$(lispdir)/../etc" + etcdir="\$(lispdir)/../../etc" fi fi - echo "$ac_t""$etcdir" 1>&6 - + echo "$as_me:$LINENO: result: $etcdir" >&5 +echo "${ECHO_T}$etcdir" >&6 - echo $ac_n "checking where the TeXinfo docs should go""... $ac_c" 1>&6 -echo "configure:852: checking where the TeXinfo docs should go" >&5 + + echo "$as_me:$LINENO: checking where the TeXinfo docs should go" >&5 +echo $ECHO_N "checking where the TeXinfo docs should go... $ECHO_C" >&6 if test "$infodir" = "\${prefix}/info"; then if test "$EMACS_FLAVOR" = "xemacs"; then info_dir="\$(prefix)/${thedir}/${EMACS_FLAVOR}/site-packages/info" @@ -858,34 +1590,35 @@ echo "configure:852: checking where the TeXinfo docs should go" >&5 else info_dir=$infodir fi - echo "$ac_t""$info_dir" 1>&6 - + echo "$as_me:$LINENO: result: $info_dir" >&5 +echo "${ECHO_T}$info_dir" >&6 + -echo $ac_n "checking for acceptable URL version""... $ac_c" 1>&6 -echo "configure:867: checking for acceptable URL version" >&5 -if eval "test \"`echo '$''{'EMACS_cv_ACCEPTABLE_URL'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking for acceptable URL version" >&5 +echo $ECHO_N "checking for acceptable URL version... $ECHO_C" >&6 +if test "${EMACS_cv_ACCEPTABLE_URL+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + if test -z ""noecho""; then - echo $ac_n "checking for url-retrieve in url""... $ac_c" 1>&6 -echo "configure:875: checking for url-retrieve in url" >&5 + echo "$as_me:$LINENO: checking for url-retrieve in url" >&5 +echo $ECHO_N "checking for url-retrieve in url... $ECHO_C" >&6 fi library=`echo url | tr _ -` elisp="(progn (fmakunbound 'url-retrieve) (condition-case nil (progn (require '$library) (fboundp 'url-retrieve)) (error (prog1 nil (message \"$library not found\")))))" if test -z ""noecho""; then - echo $ac_n "checking for url""... $ac_c" 1>&6 -echo "configure:882: checking for url" >&5 + echo "$as_me:$LINENO: checking for url" >&5 +echo $ECHO_N "checking for url... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_url'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_url+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -896,7 +1629,8 @@ fi url=${EMACS_cv_SYS_url} if test -z ""noecho""; then - echo "$ac_t""$url" 1>&6 + echo "$as_me:$LINENO: result: $url" >&5 +echo "${ECHO_T}$url" >&6 fi if test "${EMACS_cv_SYS_url}" = "nil"; then @@ -908,7 +1642,8 @@ fi HAVE_url=${EMACS_cv_SYS_url} if test -z ""noecho""; then - echo "$ac_t""$HAVE_url" 1>&6 + echo "$as_me:$LINENO: result: $HAVE_url" >&5 +echo "${ECHO_T}$HAVE_url" >&6 fi if test "${HAVE_url}" = "yes"; then @@ -918,18 +1653,18 @@ else fi if test "${EMACS_cv_ACCEPTABLE_URL}" = "yes"; then - + elisp="(file-name-directory (locate-library \"url\"))" if test -z ""noecho""; then - echo $ac_n "checking for url_dir""... $ac_c" 1>&6 -echo "configure:926: checking for url_dir" >&5 + echo "$as_me:$LINENO: checking for url_dir" >&5 +echo $ECHO_N "checking for url_dir... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_url_dir'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_url_dir+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -940,7 +1675,8 @@ fi url_dir=${EMACS_cv_SYS_url_dir} if test -z ""noecho""; then - echo "$ac_t""$url_dir" 1>&6 + echo "$as_me:$LINENO: result: $url_dir" >&5 +echo "${ECHO_T}$url_dir" >&6 fi EMACS_cv_ACCEPTABLE_URL=$EMACS_cv_SYS_url_dir @@ -948,41 +1684,42 @@ fi fi - # Check whether --with-url or --without-url was given. + +# Check whether --with-url or --without-url was given. if test "${with_url+set}" = set; then withval="$with_url" - EMACS_cv_ACCEPTABLE_URL=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` -fi - + EMACS_cv_ACCEPTABLE_URL=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` +fi; URL=${EMACS_cv_ACCEPTABLE_URL} - - echo "$ac_t"""${URL}"" 1>&6 + echo "$as_me:$LINENO: result: \"${URL}\"" >&5 +echo "${ECHO_T}\"${URL}\"" >&6 -echo $ac_n "checking for acceptable W3 version""... $ac_c" 1>&6 -echo "configure:964: checking for acceptable W3 version" >&5 -if eval "test \"`echo '$''{'EMACS_cv_ACCEPTABLE_W3'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 + +echo "$as_me:$LINENO: checking for acceptable W3 version" >&5 +echo $ECHO_N "checking for acceptable W3 version... $ECHO_C" >&6 +if test "${EMACS_cv_ACCEPTABLE_W3+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + if test -z ""noecho""; then - echo $ac_n "checking for w3-form-encode-xwfu in w3_forms""... $ac_c" 1>&6 -echo "configure:972: checking for w3-form-encode-xwfu in w3_forms" >&5 + echo "$as_me:$LINENO: checking for w3-form-encode-xwfu in w3_forms" >&5 +echo $ECHO_N "checking for w3-form-encode-xwfu in w3_forms... $ECHO_C" >&6 fi library=`echo w3_forms | tr _ -` elisp="(progn (fmakunbound 'w3-form-encode-xwfu) (condition-case nil (progn (require '$library) (fboundp 'w3-form-encode-xwfu)) (error (prog1 nil (message \"$library not found\")))))" if test -z ""noecho""; then - echo $ac_n "checking for w3_forms""... $ac_c" 1>&6 -echo "configure:979: checking for w3_forms" >&5 + echo "$as_me:$LINENO: checking for w3_forms" >&5 +echo $ECHO_N "checking for w3_forms... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_w3_forms'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_w3_forms+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -993,7 +1730,8 @@ fi w3_forms=${EMACS_cv_SYS_w3_forms} if test -z ""noecho""; then - echo "$ac_t""$w3_forms" 1>&6 + echo "$as_me:$LINENO: result: $w3_forms" >&5 +echo "${ECHO_T}$w3_forms" >&6 fi if test "${EMACS_cv_SYS_w3_forms}" = "nil"; then @@ -1005,7 +1743,8 @@ fi HAVE_w3_forms=${EMACS_cv_SYS_w3_forms} if test -z ""noecho""; then - echo "$ac_t""$HAVE_w3_forms" 1>&6 + echo "$as_me:$LINENO: result: $HAVE_w3_forms" >&5 +echo "${ECHO_T}$HAVE_w3_forms" >&6 fi if test "${HAVE_w3_forms}" = "yes"; then @@ -1015,18 +1754,18 @@ else fi if test "${EMACS_cv_ACCEPTABLE_W3}" = "yes"; then - + elisp="(file-name-directory (locate-library \"w3-forms\"))" if test -z ""noecho""; then - echo $ac_n "checking for w3_dir""... $ac_c" 1>&6 -echo "configure:1023: checking for w3_dir" >&5 + echo "$as_me:$LINENO: checking for w3_dir" >&5 +echo $ECHO_N "checking for w3_dir... $ECHO_C" >&6 fi -if eval "test \"`echo '$''{'EMACS_cv_SYS_w3_dir'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "${EMACS_cv_SYS_w3_dir+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - + OUTPUT=./conftest-$$ - echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 retval=`cat ${OUTPUT}` echo "=> ${retval}" >& 5 2>&1 @@ -1037,7 +1776,8 @@ fi w3_dir=${EMACS_cv_SYS_w3_dir} if test -z ""noecho""; then - echo "$ac_t""$w3_dir" 1>&6 + echo "$as_me:$LINENO: result: $w3_dir" >&5 +echo "${ECHO_T}$w3_dir" >&6 fi EMACS_cv_ACCEPTABLE_W3=$EMACS_cv_SYS_w3_dir @@ -1045,19 +1785,20 @@ fi fi - # Check whether --with-w3 or --without-w3 was given. + +# Check whether --with-w3 or --without-w3 was given. if test "${with_w3+set}" = set; then withval="$with_w3" - EMACS_cv_ACCEPTABLE_W3=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` -fi - + EMACS_cv_ACCEPTABLE_W3=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` +fi; W3=${EMACS_cv_ACCEPTABLE_W3} - - echo "$ac_t"""${W3}"" 1>&6 + + echo "$as_me:$LINENO: result: \"${W3}\"" >&5 +echo "${ECHO_T}\"${W3}\"" >&6 - echo $ac_n "checking which options to pass on to (X)Emacs""... $ac_c" 1>&6 -echo "configure:1061: checking which options to pass on to (X)Emacs" >&5 + echo "$as_me:$LINENO: checking which options to pass on to (X)Emacs" >&5 +echo $ECHO_N "checking which options to pass on to (X)Emacs... $ECHO_C" >&6 if test "x$FLAGS" = "x"; then if test "$EMACS_FLAVOR" = "xemacs"; then FLAGS="-batch -no-autoloads -l \$(srcdir)/dgnushack.el" @@ -1067,60 +1808,65 @@ echo "configure:1061: checking which options to pass on to (X)Emacs" >&5 else FLAGS=$FLAGS fi - echo "$ac_t""$FLAGS" 1>&6 - + echo "$as_me:$LINENO: result: $FLAGS" >&5 +echo "${ECHO_T}$FLAGS" >&6 + test "$LATEX" = t && LATEX= test "$LATEX" || for ac_prog in latex do -# Extract the first word of "$ac_prog", so it can be a program name with args. + # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1081: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_LATEX'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_path_LATEX+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - case "$LATEX" in - /*) + case $LATEX in + [\\/]* | ?:[\\/]*) ac_cv_path_LATEX="$LATEX" # Let the user override the test with a path. ;; - ?:/*) - ac_cv_path_LATEX="$LATEX" # Let the user override the test with a dos path. - ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_LATEX="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_LATEX="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + ;; esac fi -LATEX="$ac_cv_path_LATEX" +LATEX=$ac_cv_path_LATEX + if test -n "$LATEX"; then - echo "$ac_t""$LATEX" 1>&6 + echo "$as_me:$LINENO: result: $LATEX" >&5 +echo "${ECHO_T}$LATEX" >&6 else - echo "$ac_t""no" 1>&6 + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 fi -test -n "$LATEX" && break + test -n "$LATEX" && break done test -n "$LATEX" || LATEX="no" -echo $ac_n "checking for available fonts""... $ac_c" 1>&6 -echo "configure:1118: checking for available fonts" >&5 +echo "$as_me:$LINENO: checking for available fonts" >&5 +echo $ECHO_N "checking for available fonts... $ECHO_C" >&6 + # Check whether --with-fonts or --without-fonts was given. if test "${with_fonts+set}" = set; then withval="$with_fonts" USE_FONTS="$withval" -fi - +fi; WITH_FONTS_bembo='%' WITHOUT_FONTS_bembo= WITH_FONTS_pfu='%' @@ -1133,7 +1879,7 @@ if test -z "${USE_FONTS}"; then else OUTPUT=./conftest-$$ echo '\nonstopmode\documentclass{article}\usepackage{bembo}\begin{document}\end{document}' > ${OUTPUT} - if ${LATEX} ${OUTPUT} & 5 2>&1 ; then + if ${LATEX} ${OUTPUT} & 5 2>&1 ; then if test -z "${USE_FONTS}"; then USE_FONTS="Adobe Bembo" else @@ -1144,7 +1890,7 @@ if test -z "${USE_FONTS}"; then fi echo '\nonstopmode\documentclass{article}\begin{document}{\fontfamily{pfu}\fontsize{10pt}{10}\selectfont test}\end{document}' > ${OUTPUT} if retval=`${LATEX} ${OUTPUT} & 5`; then - if echo "$retval" | grep 'Some font shapes were not available' >& 5 2>&1 ; then + if echo "$retval" | grep 'Some font shapes were not available' >& 5 2>&1 ; then : else if test -z "${USE_FONTS}"; then @@ -1158,7 +1904,7 @@ if test -z "${USE_FONTS}"; then fi echo '\nonstopmode\documentclass{article}\begin{document}{\fontfamily{bcr}\fontsize{10pt}{10}\selectfont test}\end{document}' > ${OUTPUT} if retval=`${LATEX} ${OUTPUT} & 5`; then - if echo "$retval" | grep 'Some font shapes were not available' >& 5 2>&1 ; then + if echo "$retval" | grep 'Some font shapes were not available' >& 5 2>&1 ; then : else if test -z "${USE_FONTS}"; then @@ -1190,7 +1936,8 @@ if test -z "${USE_FONTS}" ; then USE_FONTS=no fi USE_FONTS=`echo "${USE_FONTS}" | sed 's/,\([^,]*\)$/ and\1/'` -echo "$ac_t"""${USE_FONTS}"" 1>&6 +echo "$as_me:$LINENO: result: \"${USE_FONTS}\"" >&5 +echo "${ECHO_T}\"${USE_FONTS}\"" >&6 if test "${USE_FONTS}" = yes ; then USE_FONTS='Set in Adobe Bembo, Adobe Futura and Bitstream Courier.' elif test "${USE_FONTS}" = no ; then @@ -1201,285 +1948,939 @@ fi -trap '' 1 2 15 -cat > confcache <<\EOF + ac_config_files="$ac_config_files Makefile etc/Makefile lisp/Makefile texi/Makefile texi/gnusconfig.tex texi/ps/Makefile" +cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure -# scripts and configure runs. It is not useful on other systems. -# If it contains results you don't want to keep, you may remove or edit it. +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. # -# By default, configure uses ./config.cache as the cache file, -# creating it if it does not exist already. You can give configure -# the --cache-file=FILE option to use a different cache file; that is -# what configure does when it calls configure scripts in -# subdirectories, so they share the cache. -# Giving --cache-file=/dev/null disables caching, for debugging configure. -# config.status only pays attention to the cache file if you give it the -# --recheck option to rerun configure. +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. # -EOF +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, don't put newlines in cache variables' values. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. -(set) 2>&1 | - case `(ac_space=' '; set | grep ac_space) 2>&1` in - *ac_space=\ *) - # `set' does not quote correctly, so add quotes (double-quote substitution - # turns \\\\ into \\, and sed turns \\ into \). - sed -n \ - -e "s/'/'\\\\''/g" \ - -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" - ;; - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' - ;; - esac >> confcache -if cmp -s $cache_file confcache; then - : -else +{ + (set) 2>&1 | + case `(ac_space=' '; set | grep ac_space) 2>&1` in + *ac_space=\ *) + # `set' does not quote correctly, so add quotes (double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \). + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n \ + "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" + ;; + esac; +} | + sed ' + t clear + : clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + : end' >>confcache +if diff $cache_file confcache >/dev/null 2>&1; then :; else if test -w $cache_file; then - echo "updating cache $cache_file" - cat confcache > $cache_file + test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file" + cat confcache >$cache_file else echo "not updating unwritable cache $cache_file" fi fi rm -f confcache -trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 - test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' -# Any assignment to VPATH causes Sun make to only execute -# the first set of double-colon rules, so remove it if not needed. -# If there is a colon in the path, we need to keep it. +# VPATH may cause trouble with some makes, so we remove $(srcdir), +# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' + ac_vpsub='/^[ ]*VPATH[ ]*=/{ +s/:*\$(srcdir):*/:/; +s/:*\${srcdir}:*/:/; +s/:*@srcdir@:*/:/; +s/^\([^=]*=[ ]*\):*/\1/; +s/:*$//; +s/^[^=]*=[ ]*$//; +}' fi -trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 - # Transform confdefs.h into DEFS. # Protect against shell expansion while executing Makefile rules. # Protect against Makefile macro expansion. -cat > conftest.defs <<\EOF -s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g -s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g -s%\[%\\&%g -s%\]%\\&%g -s%\$%$$%g -EOF -DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '` -rm -f conftest.defs - - -# Without the "./", some shells look in PATH for config.status. -: ${CONFIG_STATUS=./config.status} +# +# If the first sed substitution is executed (which looks for macros that +# take arguments), then we branch to the quote section. Otherwise, +# look for a macro that doesn't take arguments. +cat >confdef2opt.sed <<\_ACEOF +t clear +: clear +s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\),-D\1=\2,g +t quote +s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\),-D\1=\2,g +t quote +d +: quote +s,[ `~#$^&*(){}\\|;'"<>?],\\&,g +s,\[,\\&,g +s,\],\\&,g +s,\$,$$,g +p +_ACEOF +# We use echo to avoid assuming a particular line-breaking character. +# The extra dot is to prevent the shell from consuming trailing +# line-breaks from the sub-command output. A line-break within +# single-quotes doesn't work because, if this script is created in a +# platform that uses two characters for line-breaks (e.g., DOS), tr +# would break. +ac_LF_and_DOT=`echo; echo .` +DEFS=`sed -n -f confdef2opt.sed confdefs.h | tr "$ac_LF_and_DOT" ' .'` +rm -f confdef2opt.sed + + +ac_libobjs= +ac_ltlibobjs= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_i=`echo "$ac_i" | + sed 's/\$U\././;s/\.o$//;s/\.obj$//'` + # 2. Add them. + ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext" + ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs -echo creating $CONFIG_STATUS -rm -f $CONFIG_STATUS -cat > $CONFIG_STATUS <&5 +echo "$as_me: creating $CONFIG_STATUS" >&6;} +cat >$CONFIG_STATUS <<_ACEOF +#! $SHELL +# Generated by $as_me. # Run this file to recreate the current configuration. -# This directory was configured as follows, -# on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# -# $0 $ac_configure_args -# # Compiler output produced by configure, useful for debugging -# configure, is in ./config.log if it exists. +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false +SHELL=\${CONFIG_SHELL-$SHELL} +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF +## --------------------- ## +## M4sh Initialization. ## +## --------------------- ## + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' +elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then + set -o posix +fi +DUALCASE=1; export DUALCASE # for MKS sh + +# Support unset when possible. +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + as_unset=unset +else + as_unset=false +fi -ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" -for ac_option + +# Work around bugs in pre-3.0 UWIN ksh. +$as_unset ENV MAIL MAILPATH +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +for as_var in \ + LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ + LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ + LC_TELEPHONE LC_TIME do - case "\$ac_option" in - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" - exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; - -version | --version | --versio | --versi | --vers | --ver | --ve | --v) - echo "$CONFIG_STATUS generated by autoconf version 2.13" - exit 0 ;; - -help | --help | --hel | --he | --h) - echo "\$ac_cs_usage"; exit 0 ;; - *) echo "\$ac_cs_usage"; exit 1 ;; - esac + if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then + eval $as_var=C; export $as_var + else + $as_unset $as_var + fi done -ac_given_srcdir=$srcdir -ac_given_INSTALL="$INSTALL" +# Required to use basename. +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi -trap 'rm -fr `echo "Makefile etc/Makefile lisp/Makefile texi/Makefile texi/gnusconfig.tex texi/ps/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 -EOF -cat >> $CONFIG_STATUS </dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + + +# Name of the executable. +as_me=`$as_basename "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)$' \| \ + . : '\(.\)' 2>/dev/null || +echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; } + /^X\/\(\/\/\)$/{ s//\1/; q; } + /^X\/\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` + + +# PATH needs CR, and LINENO needs CR and PATH. +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi -# Protect against being on the right side of a sed subst in config.status. -sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; - s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF -$ac_vpsub -$extrasub -s%@SHELL@%$SHELL%g -s%@CFLAGS@%$CFLAGS%g -s%@CPPFLAGS@%$CPPFLAGS%g -s%@CXXFLAGS@%$CXXFLAGS%g -s%@FFLAGS@%$FFLAGS%g -s%@DEFS@%$DEFS%g -s%@LDFLAGS@%$LDFLAGS%g -s%@LIBS@%$LIBS%g -s%@exec_prefix@%$exec_prefix%g -s%@prefix@%$prefix%g -s%@program_transform_name@%$program_transform_name%g -s%@bindir@%$bindir%g -s%@sbindir@%$sbindir%g -s%@libexecdir@%$libexecdir%g -s%@datadir@%$datadir%g -s%@sysconfdir@%$sysconfdir%g -s%@sharedstatedir@%$sharedstatedir%g -s%@localstatedir@%$localstatedir%g -s%@libdir@%$libdir%g -s%@includedir@%$includedir%g -s%@oldincludedir@%$oldincludedir%g -s%@infodir@%$infodir%g -s%@mandir@%$mandir%g -s%@SET_MAKE@%$SET_MAKE%g -s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g -s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g -s%@INSTALL_DATA@%$INSTALL_DATA%g -s%@MAKEINFO@%$MAKEINFO%g -s%@EMACS@%$EMACS%g -s%@XEMACS@%$XEMACS%g -s%@EMACS_FLAVOR@%$EMACS_FLAVOR%g -s%@lispdir@%$lispdir%g -s%@etcdir@%$etcdir%g -s%@info_dir@%$info_dir%g -s%@HAVE_url@%$HAVE_url%g -s%@URL@%$URL%g -s%@HAVE_w3_forms@%$HAVE_w3_forms%g -s%@W3@%$W3%g -s%@FLAGS@%$FLAGS%g -s%@LATEX@%$LATEX%g -s%@WITH_FONTS_bembo@%$WITH_FONTS_bembo%g -s%@WITHOUT_FONTS_bembo@%$WITHOUT_FONTS_bembo%g -s%@WITH_FONTS_pfu@%$WITH_FONTS_pfu%g -s%@WITHOUT_FONTS_pfu@%$WITHOUT_FONTS_pfu%g -s%@WITH_FONTS_bcr@%$WITH_FONTS_bcr%g -s%@WITHOUT_FONTS_bcr@%$WITHOUT_FONTS_bcr%g -s%@USE_FONTS@%$USE_FONTS%g -CEOF -EOF - -cat >> $CONFIG_STATUS <<\EOF - -# Split the substitutions into bite-sized pieces for seds with -# small command number limits, like on Digital OSF/1 and HP-UX. -ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. -ac_file=1 # Number of current file. -ac_beg=1 # First line for current file. -ac_end=$ac_max_sed_cmds # Line after last line for current file. -ac_more_lines=: -ac_sed_cmds="" -while $ac_more_lines; do - if test $ac_beg -gt 1; then - sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file - else - sed "${ac_end}q" conftest.subs > conftest.s$ac_file + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" || { + # Find who we are. Look in the path if we contain no path at all + # relative or not. + case $0 in + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break +done + + ;; + esac + # We did not find ourselves, most probably we were run as `sh COMMAND' + # in which case we are not to be found in the path. + if test "x$as_myself" = x; then + as_myself=$0 + fi + if test ! -f "$as_myself"; then + { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5 +echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;} + { (exit 1); exit 1; }; } fi - if test ! -s conftest.s$ac_file; then - ac_more_lines=false - rm -f conftest.s$ac_file + case $CONFIG_SHELL in + '') + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for as_base in sh bash ksh sh5; do + case $as_dir in + /*) + if ("$as_dir/$as_base" -c ' + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then + $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; } + $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; } + CONFIG_SHELL=$as_dir/$as_base + export CONFIG_SHELL + exec "$CONFIG_SHELL" "$0" ${1+"$@"} + fi;; + esac + done +done +;; + esac + + # Create $as_me.lineno as a copy of $as_myself, but with $LINENO + # uniformly replaced by the line number. The first 'sed' inserts a + # line-number line before each line; the second 'sed' does the real + # work. The second script uses 'N' to pair each line-number line + # with the numbered line, and appends trailing '-' during + # substitution so that $LINENO is not a special case at line end. + # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the + # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-) + sed '=' <$as_myself | + sed ' + N + s,$,-, + : loop + s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3, + t loop + s,-$,, + s,^['$as_cr_digits']*\n,, + ' >$as_me.lineno && + chmod +x $as_me.lineno || + { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5 +echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;} + { (exit 1); exit 1; }; } + + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensible to this). + . ./$as_me.lineno + # Exit status is that of the last command. + exit +} + + +case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in + *c*,-n*) ECHO_N= ECHO_C=' +' ECHO_T=' ' ;; + *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; + *) ECHO_N= ECHO_C='\c' ECHO_T= ;; +esac + +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi + +rm -f conf$$ conf$$.exe conf$$.file +echo >conf$$.file +if ln -s conf$$.file conf$$ 2>/dev/null; then + # We could just check for DJGPP; but this test a) works b) is more generic + # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). + if test -f conf$$.exe; then + # Don't use ln at all; we don't have any links + as_ln_s='cp -p' else - if test -z "$ac_sed_cmds"; then - ac_sed_cmds="sed -f conftest.s$ac_file" - else - ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" - fi - ac_file=`expr $ac_file + 1` - ac_beg=$ac_end - ac_end=`expr $ac_end + $ac_max_sed_cmds` + as_ln_s='ln -s' fi +elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln +else + as_ln_s='cp -p' +fi +rm -f conf$$ conf$$.exe conf$$.file + +if mkdir -p . 2>/dev/null; then + as_mkdir_p=: +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_executable_p="test -f" + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +# IFS +# We need space, tab and new line, in precisely that order. +as_nl=' +' +IFS=" $as_nl" + +# CDPATH. +$as_unset CDPATH + +exec 6>&1 + +# Open the log real soon, to keep \$[0] and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. Logging --version etc. is OK. +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX +} >&5 +cat >&5 <<_CSEOF + +This file was extended by $as_me, which was +generated by GNU Autoconf 2.59. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +_CSEOF +echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5 +echo >&5 +_ACEOF + +# Files that config.status was made for. +if test -n "$ac_config_files"; then + echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS +fi + +if test -n "$ac_config_headers"; then + echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS +fi + +if test -n "$ac_config_links"; then + echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS +fi + +if test -n "$ac_config_commands"; then + echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS +fi + +cat >>$CONFIG_STATUS <<\_ACEOF + +ac_cs_usage="\ +\`$as_me' instantiates files from templates according to the +current configuration. + +Usage: $0 [OPTIONS] [FILE]... + + -h, --help print this help, then exit + -V, --version print version number, then exit + -q, --quiet do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + +Configuration files: +$config_files + +Report bugs to ." +_ACEOF + +cat >>$CONFIG_STATUS <<_ACEOF +ac_cs_version="\\ +config.status +configured by $0, generated by GNU Autoconf 2.59, + with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" + +Copyright (C) 2003 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." +srcdir=$srcdir +INSTALL="$INSTALL" +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF +# If no file are specified by the user, then we need to provide default +# value. By we need to know if files were specified by the user. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=*) + ac_option=`expr "x$1" : 'x\([^=]*\)='` + ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'` + ac_shift=: + ;; + -*) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + *) # This is not an option, so the user has probably given explicit + # arguments. + ac_option=$1 + ac_need_defaults=false;; + esac + + case $ac_option in + # Handling of the options. +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --vers* | -V ) + echo "$ac_cs_version"; exit 0 ;; + --he | --h) + # Conflict between --help and --header + { { echo "$as_me:$LINENO: error: ambiguous option: $1 +Try \`$0 --help' for more information." >&5 +echo "$as_me: error: ambiguous option: $1 +Try \`$0 --help' for more information." >&2;} + { (exit 1); exit 1; }; };; + --help | --hel | -h ) + echo "$ac_cs_usage"; exit 0 ;; + --debug | --d* | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + CONFIG_FILES="$CONFIG_FILES $ac_optarg" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" + ac_need_defaults=false;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1 +Try \`$0 --help' for more information." >&5 +echo "$as_me: error: unrecognized option: $1 +Try \`$0 --help' for more information." >&2;} + { (exit 1); exit 1; }; } ;; + + *) ac_config_targets="$ac_config_targets $1" ;; + + esac + shift done -if test -z "$ac_sed_cmds"; then - ac_sed_cmds=cat + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" fi -EOF -cat >> $CONFIG_STATUS <>$CONFIG_STATUS <<_ACEOF +if \$ac_cs_recheck; then + echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 + exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion +fi -CONFIG_FILES=\${CONFIG_FILES-"Makefile etc/Makefile lisp/Makefile texi/Makefile texi/gnusconfig.tex texi/ps/Makefile"} -EOF -cat >> $CONFIG_STATUS <<\EOF -for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then - # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". - case "$ac_file" in - *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` - ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; - *) ac_file_in="${ac_file}.in" ;; +_ACEOF + + + + + +cat >>$CONFIG_STATUS <<\_ACEOF +for ac_config_target in $ac_config_targets +do + case "$ac_config_target" in + # Handling of arguments. + "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "etc/Makefile" ) CONFIG_FILES="$CONFIG_FILES etc/Makefile" ;; + "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;; + "texi/Makefile" ) CONFIG_FILES="$CONFIG_FILES texi/Makefile" ;; + "texi/gnusconfig.tex" ) CONFIG_FILES="$CONFIG_FILES texi/gnusconfig.tex" ;; + "texi/ps/Makefile" ) CONFIG_FILES="$CONFIG_FILES texi/ps/Makefile" ;; + *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 +echo "$as_me: error: invalid argument: $ac_config_target" >&2;} + { (exit 1); exit 1; }; };; esac +done - # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason to put it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Create a temporary directory, and hook for its removal unless debugging. +$debug || +{ + trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0 + trap '{ (exit 1); exit 1; }' 1 2 13 15 +} + +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` && + test -n "$tmp" && test -d "$tmp" +} || +{ + tmp=./confstat$$-$RANDOM + (umask 077 && mkdir $tmp) +} || +{ + echo "$me: cannot create a temporary directory in ." >&2 + { (exit 1); exit 1; } +} + +_ACEOF + +cat >>$CONFIG_STATUS <<_ACEOF - # Remove last slash and all that follows it. Not all systems have dirname. - ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` - if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then - # The file is in a subdirectory. - test ! -d "$ac_dir" && mkdir "$ac_dir" - ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" - # A "../" for each directory in $ac_dir_suffix. - ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` - else - ac_dir_suffix= ac_dots= +# +# CONFIG_FILES section. +# + +# No need to generate the scripts if there are no CONFIG_FILES. +# This happens for instance when ./config.status config.h +if test -n "\$CONFIG_FILES"; then + # Protect against being on the right side of a sed subst in config.status. + sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g; + s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF +s,@SHELL@,$SHELL,;t t +s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t +s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t +s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t +s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t +s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t +s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t +s,@exec_prefix@,$exec_prefix,;t t +s,@prefix@,$prefix,;t t +s,@program_transform_name@,$program_transform_name,;t t +s,@bindir@,$bindir,;t t +s,@sbindir@,$sbindir,;t t +s,@libexecdir@,$libexecdir,;t t +s,@datadir@,$datadir,;t t +s,@sysconfdir@,$sysconfdir,;t t +s,@sharedstatedir@,$sharedstatedir,;t t +s,@localstatedir@,$localstatedir,;t t +s,@libdir@,$libdir,;t t +s,@includedir@,$includedir,;t t +s,@oldincludedir@,$oldincludedir,;t t +s,@infodir@,$infodir,;t t +s,@mandir@,$mandir,;t t +s,@build_alias@,$build_alias,;t t +s,@host_alias@,$host_alias,;t t +s,@target_alias@,$target_alias,;t t +s,@DEFS@,$DEFS,;t t +s,@ECHO_C@,$ECHO_C,;t t +s,@ECHO_N@,$ECHO_N,;t t +s,@ECHO_T@,$ECHO_T,;t t +s,@LIBS@,$LIBS,;t t +s,@SET_MAKE@,$SET_MAKE,;t t +s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t +s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t +s,@INSTALL_DATA@,$INSTALL_DATA,;t t +s,@MAKEINFO@,$MAKEINFO,;t t +s,@EMACS@,$EMACS,;t t +s,@XEMACS@,$XEMACS,;t t +s,@EMACS_FLAVOR@,$EMACS_FLAVOR,;t t +s,@lispdir@,$lispdir,;t t +s,@etcdir@,$etcdir,;t t +s,@info_dir@,$info_dir,;t t +s,@HAVE_url@,$HAVE_url,;t t +s,@URL@,$URL,;t t +s,@HAVE_w3_forms@,$HAVE_w3_forms,;t t +s,@W3@,$W3,;t t +s,@FLAGS@,$FLAGS,;t t +s,@LATEX@,$LATEX,;t t +s,@WITH_FONTS_bembo@,$WITH_FONTS_bembo,;t t +s,@WITHOUT_FONTS_bembo@,$WITHOUT_FONTS_bembo,;t t +s,@WITH_FONTS_pfu@,$WITH_FONTS_pfu,;t t +s,@WITHOUT_FONTS_pfu@,$WITHOUT_FONTS_pfu,;t t +s,@WITH_FONTS_bcr@,$WITH_FONTS_bcr,;t t +s,@WITHOUT_FONTS_bcr@,$WITHOUT_FONTS_bcr,;t t +s,@USE_FONTS@,$USE_FONTS,;t t +s,@LIBOBJS@,$LIBOBJS,;t t +s,@LTLIBOBJS@,$LTLIBOBJS,;t t +CEOF + +_ACEOF + + cat >>$CONFIG_STATUS <<\_ACEOF + # Split the substitutions into bite-sized pieces for seds with + # small command number limits, like on Digital OSF/1 and HP-UX. + ac_max_sed_lines=48 + ac_sed_frag=1 # Number of current file. + ac_beg=1 # First line for current file. + ac_end=$ac_max_sed_lines # Line after last line for current file. + ac_more_lines=: + ac_sed_cmds= + while $ac_more_lines; do + if test $ac_beg -gt 1; then + sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag + else + sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag + fi + if test ! -s $tmp/subs.frag; then + ac_more_lines=false + else + # The purpose of the label and of the branching condition is to + # speed up the sed processing (if there are no `@' at all, there + # is no need to browse any of the substitutions). + # These are the two extra sed commands mentioned above. + (echo ':t + /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed + if test -z "$ac_sed_cmds"; then + ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed" + else + ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed" + fi + ac_sed_frag=`expr $ac_sed_frag + 1` + ac_beg=$ac_end + ac_end=`expr $ac_end + $ac_max_sed_lines` + fi + done + if test -z "$ac_sed_cmds"; then + ac_sed_cmds=cat fi +fi # test -n "$CONFIG_FILES" - case "$ac_given_srcdir" in - .) srcdir=. - if test -z "$ac_dots"; then top_srcdir=. - else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; - /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; - *) # Relative path. - srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" - top_srcdir="$ac_dots$ac_given_srcdir" ;; +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF +for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue + # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". + case $ac_file in + - | *:- | *:-:* ) # input from stdin + cat >$tmp/stdin + ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` + ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; + *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` + ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; + * ) ac_file_in=$ac_file.in ;; esac - case "$ac_given_INSTALL" in - [/$]*) INSTALL="$ac_given_INSTALL" ;; - *) INSTALL="$ac_dots$ac_given_INSTALL" ;; - esac + # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories. + ac_dir=`(dirname "$ac_file") 2>/dev/null || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| \ + . : '\(.\)' 2>/dev/null || +echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } + /^X\(\/\/\)[^/].*/{ s//\1/; q; } + /^X\(\/\/\)$/{ s//\1/; q; } + /^X\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` + { if $as_mkdir_p; then + mkdir -p "$ac_dir" + else + as_dir="$ac_dir" + as_dirs= + while test ! -d "$as_dir"; do + as_dirs="$as_dir $as_dirs" + as_dir=`(dirname "$as_dir") 2>/dev/null || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| \ + . : '\(.\)' 2>/dev/null || +echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } + /^X\(\/\/\)[^/].*/{ s//\1/; q; } + /^X\(\/\/\)$/{ s//\1/; q; } + /^X\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` + done + test ! -n "$as_dirs" || mkdir $as_dirs + fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5 +echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;} + { (exit 1); exit 1; }; }; } + + ac_builddir=. + +if test "$ac_dir" != .; then + ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` + # A "../" for each directory in $ac_dir_suffix. + ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` +else + ac_dir_suffix= ac_top_builddir= +fi + +case $srcdir in + .) # No --srcdir option. We are building in place. + ac_srcdir=. + if test -z "$ac_top_builddir"; then + ac_top_srcdir=. + else + ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` + fi ;; + [\\/]* | ?:[\\/]* ) # Absolute path. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir ;; + *) # Relative path. + ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_builddir$srcdir ;; +esac - echo creating "$ac_file" - rm -f "$ac_file" - configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." - case "$ac_file" in - *Makefile*) ac_comsub="1i\\ -# $configure_input" ;; - *) ac_comsub= ;; +# Do not use `cd foo && pwd` to compute absolute paths, because +# the directories may not exist. +case `pwd` in +.) ac_abs_builddir="$ac_dir";; +*) + case "$ac_dir" in + .) ac_abs_builddir=`pwd`;; + [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";; + *) ac_abs_builddir=`pwd`/"$ac_dir";; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_top_builddir=${ac_top_builddir}.;; +*) + case ${ac_top_builddir}. in + .) ac_abs_top_builddir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;; + *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_srcdir=$ac_srcdir;; +*) + case $ac_srcdir in + .) ac_abs_srcdir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;; + *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;; + esac;; +esac +case $ac_abs_builddir in +.) ac_abs_top_srcdir=$ac_top_srcdir;; +*) + case $ac_top_srcdir in + .) ac_abs_top_srcdir=$ac_abs_builddir;; + [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;; + *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;; + esac;; +esac + + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_builddir$INSTALL ;; esac - ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` - sed -e "$ac_comsub -s%@configure_input@%$configure_input%g -s%@srcdir@%$srcdir%g -s%@top_srcdir@%$top_srcdir%g -s%@INSTALL@%$INSTALL%g -" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file -fi; done -rm -f conftest.s* + if test x"$ac_file" != x-; then + { echo "$as_me:$LINENO: creating $ac_file" >&5 +echo "$as_me: creating $ac_file" >&6;} + rm -f "$ac_file" + fi + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + if test x"$ac_file" = x-; then + configure_input= + else + configure_input="$ac_file. " + fi + configure_input=$configure_input"Generated from `echo $ac_file_in | + sed 's,.*/,,'` by configure." + + # First look for the input files in the build tree, otherwise in the + # src tree. + ac_file_inputs=`IFS=: + for f in $ac_file_in; do + case $f in + -) echo $tmp/stdin ;; + [\\/$]*) + # Absolute (can't be DOS-style, as IFS=:) + test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 +echo "$as_me: error: cannot find input file: $f" >&2;} + { (exit 1); exit 1; }; } + echo "$f";; + *) # Relative + if test -f "$f"; then + # Build tree + echo "$f" + elif test -f "$srcdir/$f"; then + # Source tree + echo "$srcdir/$f" + else + # /dev/null tree + { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 +echo "$as_me: error: cannot find input file: $f" >&2;} + { (exit 1); exit 1; }; } + fi;; + esac + done` || { (exit 1); exit 1; } +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF + sed "$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s,@configure_input@,$configure_input,;t t +s,@srcdir@,$ac_srcdir,;t t +s,@abs_srcdir@,$ac_abs_srcdir,;t t +s,@top_srcdir@,$ac_top_srcdir,;t t +s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t +s,@builddir@,$ac_builddir,;t t +s,@abs_builddir@,$ac_abs_builddir,;t t +s,@top_builddir@,$ac_top_builddir,;t t +s,@abs_top_builddir@,$ac_abs_top_builddir,;t t +s,@INSTALL@,$ac_INSTALL,;t t +" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out + rm -f $tmp/stdin + if test x"$ac_file" != x-; then + mv $tmp/out $ac_file + else + cat $tmp/out + rm -f $tmp/out + fi -EOF -cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF +cat >>$CONFIG_STATUS <<\_ACEOF -exit 0 -EOF +{ (exit 0); exit 0; } +_ACEOF chmod +x $CONFIG_STATUS -rm -fr confdefs* $ac_clean_files -test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 +ac_clean_files=$ac_clean_files_save + + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || { (exit 1); exit 1; } +fi diff --git a/contrib/ChangeLog b/contrib/ChangeLog index 8f9b3d6..4e3d6ec 100644 --- a/contrib/ChangeLog +++ b/contrib/ChangeLog @@ -1,3 +1,26 @@ +2006-02-11 Miles Bader + + * sendmail.el, smtpmail.el: New files, from Emacs tree. + +2005-12-22 TSUCHIYA Masatoshi + + * gnus-namazu.el (gnus-namazu-remote-groups): Accept `t' as an + symbol that matches the method specified by `gnus-select-method'. + (gnus-namazu/make-directory-table): Follow the above change. + (gnus-namazu/call-namazu): Wrap a query string with quotes. + +2005-12-05 Adrian Aichner + + * nnir.el: New variable nnir-swish-e-index-files to support + multiple swish-e index files. + * nnir.el (nnir-swish-e-index-file): Make obsolete. + * nnir.el (nnir-swish-e-index-files): New. + * nnir.el (nnir-run-swish-e): Use nnir-swish-e-index-files. + +2005-05-17 Katsumi Yamaoka + + * nnir.el (nnir): Add :group. + 2005-01-26 Steve Youngs * gpg.el: Add timer/itimer compatibility. diff --git a/contrib/README b/contrib/README index 148ba57..d594125 100644 --- a/contrib/README +++ b/contrib/README @@ -40,8 +40,20 @@ nnir.el one-line-cookie.diff +sendmail.el +smtpmail.el + + Copies of the corresponding files from the Emacs lisp/mail/ + directory, to provide features (occasionally) needed by Gnus which + may not be provided by the versions of these files in older Emacs + distributions. + ssl.el + Obsolete interface to OpenSSL. Completely replaced by + lisp/tls.el, which supports both GnuTLS and OpenSSL. This + file will be removed eventually. + ucs-tables.el This file provides improved Unicode functionality. It defines @@ -65,5 +77,6 @@ vcard.el xml.el - This is used for parsing RSS feeds. Part of Emacs 21.3 and - later. + This is used for parsing RSS feeds. Part of Emacs 21.3 and later. + Note that the version of this file in the Gnus contrib/ directory is + out of date with respect to the version in the Emacs tree. diff --git a/contrib/compface.el b/contrib/compface.el index ac80578..942eb16 100644 --- a/contrib/compface.el +++ b/contrib/compface.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/contrib/gnus-namazu.el b/contrib/gnus-namazu.el index 40c35a1..bf23650 100644 --- a/contrib/gnus-namazu.el +++ b/contrib/gnus-namazu.el @@ -19,7 +19,7 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, you can either send email to this ;; program's maintainer or write to: The Free Software Foundation, -;; Inc.; 59 Temple Place, Suite 330; Boston, MA 02111-1307, USA. +;; Inc.; 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. ;;; Commentary: @@ -237,7 +237,8 @@ This means that the group \"nnimap+server:INBOX.group\" is placed in \"~/Maildir/.group\"." :group 'gnus-namazu :type '(repeat - (cons (regexp :tag "Regexp of group name") + (cons (choice (regexp :tag "Regexp of group name") + (const :tag "Groups served by `gnus-select-method'" t)) (string :tag "Base path of groups"))) :set (lambda (symbol value) (prog1 (set-default symbol value) @@ -336,7 +337,9 @@ This means that the group \"nnimap+server:INBOX.group\" is placed in "-a" ; show all matches "-l") ; use list format gnus-namazu-additional-arguments - (list query) + (list (if gnus-namazu-command-prefix + (concat "'" query "'") + query)) gnus-namazu-index-directories))) (apply 'call-process (car commands) nil t nil (cdr commands)))) @@ -367,10 +370,14 @@ This means that the group \"nnimap+server:INBOX.group\" is placed in (gnus-namazu/server-directory method)))) (push (cons dir group) alist))) (dolist (pair gnus-namazu-remote-groups) - (when (string-match (car pair) group) - (setq dir (nnmail-group-pathname - (substring group (match-end 0)) - "/")) + (when (setq dir + (or (and (eq t (car pair)) + (gnus-method-equal method gnus-select-method) + group) + (and (stringp (car pair)) + (string-match (car pair) group) + (substring group (match-end 0))))) + (setq dir (nnmail-group-pathname dir "/")) (push (cons (concat (cdr pair) ;; nnmail-group-pathname() on some ;; systems returns pathnames which diff --git a/contrib/gpg-ring.el b/contrib/gpg-ring.el index 10adec5..26bd40a 100644 --- a/contrib/gpg-ring.el +++ b/contrib/gpg-ring.el @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. diff --git a/contrib/gpg.el b/contrib/gpg.el index c83a4eb..f84a554 100644 --- a/contrib/gpg.el +++ b/contrib/gpg.el @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/contrib/nnir.el b/contrib/nnir.el index 331662d..0b88a8f 100644 --- a/contrib/nnir.el +++ b/contrib/nnir.el @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -376,7 +376,8 @@ Add an entry here when adding a new search engine.") ;;; User Customizable Variables: (defgroup nnir nil - "Search nnmh and nnml groups in Gnus with Glimpse, freeWAIS-sf, or EWS.") + "Search nnmh and nnml groups in Gnus with Glimpse, freeWAIS-sf, or EWS." + :group 'gnus) ;; Mail backend. @@ -531,18 +532,31 @@ that it is for swish++, not Glimpse." :type '(regexp) :group 'nnir) -;; Swish-E. Next three variables Copyright (C) 2000 Christoph Conrad -;; . +;; Swish-E. ;; URL: http://sunsite.berkeley.edu/SWISH-E/ ;; New version: http://www.boe.es/swish-e +;; Variables `nnir-swish-e-index-file', `nnir-swish-e-program' and +;; `nnir-swish-e-additional-switches' +;; Copyright (C) 2000 Christoph Conrad . +(make-obsolete-variable 'nnir-swish-e-index-file + 'nnir-swish-e-index-files) (defcustom nnir-swish-e-index-file (expand-file-name "~/Mail/index.swish-e") "*Index file for swish-e. -This could be a server parameter." +This could be a server parameter. +It is never consulted once `nnir-swish-e-index-files', which should be +used instead, has been customized." :type '(file) :group 'nnir) +(defcustom nnir-swish-e-index-files + (list nnir-swish-e-index-file) + "*List of index files for swish-e. +This could be a server parameter." + :type '(repeat (file)) + :group 'nnir) + (defcustom nnir-swish-e-program "swish-e" "*Name of swish-e search executable. This cannot be a server parameter." @@ -1195,10 +1209,10 @@ Tested with swish-e-2.0.1 on Windows NT 4.0." (erase-buffer) (message "Doing swish-e query %s..." query) - (let* ((index-file + (let* ((index-files (or (nnir-read-server-parm - 'nnir-swish-e-index-file server) - (error "Missing parameter `nnir-swish-e-index-file'"))) + 'nnir-swish-e-index-files server) + (error "Missing parameter `nnir-swish-e-index-files'"))) (additional-switches (nnir-read-server-parm 'nnir-swish-e-additional-switches server)) @@ -1206,7 +1220,7 @@ Tested with swish-e-2.0.1 on Windows NT 4.0." nil ; input from /dev/null t ; output nil ; don't redisplay - "-f" ,index-file + "-f" ,@index-files ,@additional-switches "-w" ,qstring ; the query, in swish-e format diff --git a/contrib/sendmail.el b/contrib/sendmail.el new file mode 100644 index 0000000..ee512b3 --- /dev/null +++ b/contrib/sendmail.el @@ -0,0 +1,1866 @@ +;;; sendmail.el --- mail sending commands for Emacs. -*- byte-compile-dynamic: t -*- + +;; Copyright (C) 1985, 1986, 1992, 1993, 1994, 1995, 1996, 1998, 2000, +;; 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. + +;; Maintainer: FSF +;; Keywords: mail + +;; 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 the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; This mode provides mail-sending facilities from within Emacs. It is +;; documented in the Emacs user's manual. + +;;; Code: +(eval-when-compile + ;; Necessary to avoid recursive `require's. + (provide 'sendmail) + (require 'rmail) + (require 'mailalias)) + +(autoload 'rfc2047-encode-string "rfc2047") + +(defgroup sendmail nil + "Mail sending commands for Emacs." + :prefix "mail-" + :group 'mail) + +(defcustom mail-setup-with-from t + "Non-nil means insert `From:' field when setting up the message." + :type 'boolean + :group 'sendmail + :version "22.1") + +;;;###autoload +(defcustom mail-from-style 'angles + "Specifies how \"From:\" fields look. + +If `nil', they contain just the return address like: + king@grassland.com +If `parens', they look like: + king@grassland.com (Elvis Parsley) +If `angles', they look like: + Elvis Parsley +If `system-default', allows the mailer to insert its default From field +derived from the envelope-from address. + +In old versions of Emacs, the `system-default' setting also caused +Emacs to pass the proper email address from `user-mail-address' +to the mailer to specify the envelope-from address. But that is now +controlled by a separate variable, `mail-specify-envelope-from'." + :type '(choice (const nil) (const parens) (const angles) + (const system-default)) + :version "20.3" + :group 'sendmail) + +;;;###autoload +(defcustom mail-specify-envelope-from nil + "If non-nil, specify the envelope-from address when sending mail. +The value used to specify it is whatever is found in +the variable `mail-envelope-from', with `user-mail-address' as fallback. + +On most systems, specifying the envelope-from address is a +privileged operation. This variable affects sendmail and +smtpmail -- if you use feedmail to send mail, see instead the +variable `feedmail-deduce-envelope-from'." + :version "21.1" + :type 'boolean + :group 'sendmail) + +(defcustom mail-envelope-from nil + "If non-nil, designate the envelope-from address when sending mail. +This only has an effect if `mail-specify-envelope-from' is non-nil. +The value should be either a string, or the symbol `header' (in +which case the contents of the \"From\" header of the message +being sent is used), or nil (in which case the value of +`user-mail-address' is used)." + :version "21.1" + :type '(choice (string :tag "From-name") + (const :tag "Use From: header from message" header) + (const :tag "Use `user-mail-address'" nil)) + :group 'sendmail) + +;;;###autoload +(defcustom mail-self-blind nil + "Non-nil means insert BCC to self in messages to be sent. +This is done when the message is initialized, +so you can remove or alter the BCC field to override the default." + :type 'boolean + :group 'sendmail) + +;;;###autoload +(defcustom mail-interactive nil + "Non-nil means when sending a message wait for and display errors. +nil means let mailer mail back a message to report errors." + :type 'boolean + :group 'sendmail) + +(defcustom mail-yank-ignored-headers + (concat "^" + (regexp-opt '("via" "mail-from" "origin" "status" "remailed" + "received" "message-id" "summary-line" "to" "subject" + "in-reply-to" "return-path" "mail-reply-to" + "mail-followup-to") "\\(?:") + ":") + "Delete these headers from old message when it's inserted in a reply." + :type 'regexp + :group 'sendmail) + +;; Prevent problems with `window-system' not having the correct value +;; when loaddefs.el is loaded. `custom-reevaluate-setting' needs the +;; standard value. +;;;###autoload +(put 'send-mail-function 'standard-value + '((if (and window-system (memq system-type '(darwin windows-nt))) + 'mailclient-send-it + 'sendmail-send-it))) + +;; Useful to set in site-init.el +;;;###autoload +(defcustom send-mail-function + (if (and window-system (memq system-type '(darwin windows-nt))) + 'mailclient-send-it + 'sendmail-send-it) + "Function to call to send the current buffer as mail. +The headers should be delimited by a line which is +not a valid RFC822 header or continuation line, +that matches the variable `mail-header-separator'. +This is used by the default mail-sending commands. See also +`message-send-mail-function' for use with the Message package." + :type '(radio (function-item sendmail-send-it :tag "Use Sendmail package") + (function-item smtpmail-send-it :tag "Use SMTPmail package") + (function-item feedmail-send-it :tag "Use Feedmail package") + (function-item mailclient-send-it :tag "Use Mailclient package") + function) + :group 'sendmail) + +;;;###autoload +(defcustom mail-header-separator "--text follows this line--" + "Line used to separate headers from text in messages being composed." + :type 'string + :group 'sendmail) + +;; Set up mail-header-separator for use as a category text property. +(put 'mail-header-separator 'rear-nonsticky '(category)) +;; This was a nice idea, for preventing accidental modification of +;; the separator. But I found it also prevented or obstructed +;; certain deliberate operations, such as copying the separator line +;; up to the top to send myself a copy of an already sent outgoing message +;; and other things. So I turned it off. --rms. +;;(put 'mail-header-separator 'read-only t) + +;;;###autoload +(defcustom mail-archive-file-name nil + "Name of file to write all outgoing messages in, or nil for none. +This can be an inbox file or an Rmail file." + :type '(choice file (const nil)) + :group 'sendmail) + +;;;###autoload +(defcustom mail-default-reply-to nil + "Address to insert as default Reply-to field of outgoing messages. +If nil, it will be initialized from the REPLYTO environment variable +when you first send mail." + :type '(choice (const nil) string) + :group 'sendmail) + +;;;###autoload +(defcustom mail-alias-file nil + "If non-nil, the name of a file to use instead of `/usr/lib/aliases'. +This file defines aliases to be expanded by the mailer; this is a different +feature from that of defining aliases in `.mailrc' to be expanded in Emacs. +This variable has no effect unless your system uses sendmail as its mailer." + :type '(choice (const nil) file) + :group 'sendmail) + +;;;###autoload +(defcustom mail-personal-alias-file "~/.mailrc" + "If non-nil, the name of the user's personal mail alias file. +This file typically should be in same format as the `.mailrc' file used by +the `Mail' or `mailx' program. +This file need not actually exist." + :type '(choice (const nil) file) + :group 'sendmail) + +;;;###autoload +(defcustom mail-setup-hook nil + "Normal hook, run each time a new outgoing mail message is initialized. +The function `mail-setup' runs this hook." + :type 'hook + :options '(fortune-to-signature spook mail-abbrevs-setup) + :group 'sendmail) + +;;;###autoload +(defvar mail-aliases t + "Alist of mail address aliases, +or t meaning should be initialized from your mail aliases file. +\(The file's name is normally `~/.mailrc', but `mail-personal-alias-file' +can specify a different file name.) +The alias definitions in the file have this form: + alias ALIAS MEANING") + +(defvar mail-alias-modtime nil + "The modification time of your mail alias file when it was last examined.") + +;;;###autoload +(defcustom mail-yank-prefix nil + "Prefix insert on lines of yanked message being replied to. +nil means use indentation." + :type '(choice (const nil) string) + :group 'sendmail) + +;;;###autoload +(defcustom mail-indentation-spaces 3 + "Number of spaces to insert at the beginning of each cited line. +Used by `mail-yank-original' via `mail-indent-citation'." + :type 'integer + :group 'sendmail) + +(defvar mail-yank-hooks nil + "Obsolete hook for modifying a citation just inserted in the mail buffer. +Each hook function can find the citation between (point) and (mark t). +And each hook function should leave point and mark around the citation +text as modified. + +This is a normal hook, misnamed for historical reasons. +It is semi-obsolete and mail agents should no longer use it.") + +;;;###autoload +(defcustom mail-citation-hook nil + "Hook for modifying a citation just inserted in the mail buffer. +Each hook function can find the citation between (point) and (mark t), +and should leave point and mark around the citation text as modified. +The hook functions can find the header of the cited message +in the variable `mail-citation-header', whether or not this is included +in the cited portion of the message. + +If this hook is entirely empty (nil), a default action is taken +instead of no action." + :type 'hook + :group 'sendmail) + +(defvar mail-citation-header nil + "While running `mail-citation-hook', this variable holds the message header. +This enables the hook functions to see the whole message header +regardless of what part of it (if any) is included in the cited text.") + +;;;###autoload +(defcustom mail-citation-prefix-regexp "[ \t]*[-a-z0-9A-Z]*>+[ \t]*\\|[ \t]*" + "Regular expression to match a citation prefix plus whitespace. +It should match whatever sort of citation prefixes you want to handle, +with whitespace before and after; it should also match just whitespace. +The default value matches citations like `foo-bar>' plus whitespace." + :type 'regexp + :group 'sendmail + :version "20.3") + +(defvar mail-abbrevs-loaded nil) +(defvar mail-mode-map + (let ((map (make-sparse-keymap))) + (define-key map "\M-\t" 'mail-complete) + (define-key map "\C-c?" 'describe-mode) + (define-key map "\C-c\C-f\C-t" 'mail-to) + (define-key map "\C-c\C-f\C-b" 'mail-bcc) + (define-key map "\C-c\C-f\C-f" 'mail-fcc) + (define-key map "\C-c\C-f\C-c" 'mail-cc) + (define-key map "\C-c\C-f\C-s" 'mail-subject) + (define-key map "\C-c\C-f\C-r" 'mail-reply-to) + (define-key map "\C-c\C-f\C-a" 'mail-mail-reply-to) ; author + (define-key map "\C-c\C-f\C-l" 'mail-mail-followup-to) ; list + (define-key map "\C-c\C-t" 'mail-text) + (define-key map "\C-c\C-y" 'mail-yank-original) + (define-key map "\C-c\C-r" 'mail-yank-region) + (define-key map [remap split-line] 'mail-split-line) + (define-key map "\C-c\C-q" 'mail-fill-yanked-message) + (define-key map "\C-c\C-w" 'mail-signature) + (define-key map "\C-c\C-v" 'mail-sent-via) + (define-key map "\C-c\C-c" 'mail-send-and-exit) + (define-key map "\C-c\C-s" 'mail-send) + (define-key map "\C-c\C-i" 'mail-attach-file) + + (define-key map [menu-bar mail] + (cons "Mail" (make-sparse-keymap "Mail"))) + + (define-key map [menu-bar mail fill] + '("Fill Citation" . mail-fill-yanked-message)) + + (define-key map [menu-bar mail yank] + '("Cite Original" . mail-yank-original)) + + (define-key map [menu-bar mail signature] + '("Insert Signature" . mail-signature)) + + (define-key map [menu-bar mail mail-sep] + '("--")) + + (define-key map [menu-bar mail cancel] + '("Cancel" . mail-dont-send)) + + (define-key map [menu-bar mail send-stay] + '("Send, Keep Editing" . mail-send)) + + (define-key map [menu-bar mail send] + '("Send Message" . mail-send-and-exit)) + + (define-key map [menu-bar headers] + (cons "Headers" (make-sparse-keymap "Move to Header"))) + + (define-key map [menu-bar headers text] + '("Text" . mail-text)) + + (define-key map [menu-bar headers expand-aliases] + '("Expand Aliases" . expand-mail-aliases)) + + (define-key map [menu-bar headers sent-via] + '("Sent Via" . mail-sent-via)) + + (define-key map [menu-bar headers mail-reply-to] + '("Mail Reply To" . mail-mail-reply-to)) + + (define-key map [menu-bar headers mail-followup-to] + '("Mail Followup To" . mail-mail-followup-to)) + + (define-key map [menu-bar headers reply-to] + '("Reply-To" . mail-reply-to)) + + (define-key map [menu-bar headers bcc] + '("Bcc" . mail-bcc)) + + (define-key map [menu-bar headers fcc] + '("Fcc" . mail-fcc)) + + (define-key map [menu-bar headers cc] + '("Cc" . mail-cc)) + + (define-key map [menu-bar headers subject] + '("Subject" . mail-subject)) + + (define-key map [menu-bar headers to] + '("To" . mail-to)) + + map)) + +(autoload 'build-mail-aliases "mailalias" + "Read mail aliases from user's personal aliases file and set `mail-aliases'." + nil) + +(autoload 'expand-mail-aliases "mailalias" + "Expand all mail aliases in suitable header fields found between BEG and END. +Suitable header fields are `To', `Cc' and `Bcc' and their `Resent-' variants. +Optional second arg EXCLUDE may be a regular expression defining text to be +removed from alias expansions." + nil) + +;;;###autoload +(defcustom mail-signature nil + "Text inserted at end of mail buffer when a message is initialized. +If t, it means to insert the contents of the file `mail-signature-file'. +If a string, that string is inserted. + (To make a proper signature, the string should begin with \\n\\n-- \\n, + which is the standard way to delimit a signature in a message.) +Otherwise, it should be an expression; it is evaluated +and should insert whatever you want to insert." + :type '(choice (const :tag "None" nil) + (const :tag "Use `.signature' file" t) + (string :tag "String to insert") + (sexp :tag "Expression to evaluate")) + :group 'sendmail) +(put 'mail-signature 'risky-local-variable t) + +;;;###autoload +(defcustom mail-signature-file "~/.signature" + "File containing the text inserted at end of mail buffer." + :type 'file + :group 'sendmail) + +;;;###autoload +(defcustom mail-default-directory "~/" + "Directory for mail buffers. +Value of `default-directory' for mail buffers. +This directory is used for auto-save files of mail buffers." + :type '(directory :tag "Directory") + :group 'sendmail + :version "22.1") + +(defvar mail-reply-action nil) +(defvar mail-send-actions nil + "A list of actions to be performed upon successful sending of a message.") +(put 'mail-reply-action 'permanent-local t) +(put 'mail-send-actions 'permanent-local t) + +;;;###autoload +(defcustom mail-default-headers nil + "A string containing header lines, to be inserted in outgoing messages. +It is inserted before you edit the message, +so you can edit or delete these lines." + :type '(choice (const nil) string) + :group 'sendmail) + +;;;###autoload +(defcustom mail-bury-selects-summary t + "If non-nil, try to show RMAIL summary buffer after returning from mail. +The functions \\[mail-send-on-exit] or \\[mail-dont-send] select +the RMAIL summary buffer before returning, if it exists and this variable +is non-nil." + :type 'boolean + :group 'sendmail) + +;;;###autoload +(defcustom mail-send-nonascii 'mime + "Specify whether to allow sending non-ASCII characters in mail. +If t, that means do allow it. nil means don't allow it. +`query' means ask the user each time. +`mime' means add an appropriate MIME header if none already present. +The default is `mime'. +Including non-ASCII characters in a mail message can be problematical +for the recipient, who may not know how to decode them properly." + :type '(choice (const t) (const nil) (const query) (const mime)) + :group 'sendmail) + +(defcustom mail-use-dsn nil + "Ask MTA for notification of failed, delayed or successful delivery. +Note that only some MTAs (currently only recent versions of Sendmail) +support Delivery Status Notification." + :group 'sendmail + :type '(repeat (radio (const :tag "Failure" failure) + (const :tag "Delay" delay) + (const :tag "Success" success))) + :version "22.1") + +;; Note: could use /usr/ucb/mail instead of sendmail; +;; options -t, and -v if not interactive. +(defvar mail-mailer-swallows-blank-line + (if (and (string-match "sparc-sun-sunos\\(\\'\\|[^5]\\)" system-configuration) + (file-readable-p "/etc/sendmail.cf") + (with-temp-buffer + (insert-file-contents "/etc/sendmail.cf") + (goto-char (point-min)) + (let ((case-fold-search nil)) + (re-search-forward "^OR\\>" nil t)))) + ;; According to RFC822, "The field-name must be composed of printable + ;; ASCII characters (i.e. characters that have decimal values between + ;; 33 and 126, except colon)", i.e. any chars except ctl chars, + ;; space, or colon. + '(looking-at "[ \t]\\|[][!\"#$%&'()*+,-./0-9;<=>?@A-Z\\\\^_`a-z{|}~]+:")) + "Set this non-nil if the system's mailer runs the header and body together. +\(This problem exists on Sunos 4 when sendmail is run in remote mode.) +The value should be an expression to test whether the problem will +actually occur.") + +(defvar mail-mode-syntax-table + (let ((st (make-syntax-table))) + ;; define-derived-mode will make it inherit from text-mode-syntax-table. + (modify-syntax-entry ?% ". " st) + st) + "Syntax table used while in `mail-mode'.") + +(defvar mail-font-lock-keywords + (eval-when-compile + (let* ((cite-chars "[>|}]") + (cite-prefix "[:alpha:]") + (cite-suffix (concat cite-prefix "0-9_.@-`'\""))) + (list '("^\\(To\\|Newsgroups\\):" . font-lock-function-name-face) + '("^\\(B?CC\\|Reply-to\\|Mail-\\(reply\\|followup\\)-to\\):" . font-lock-keyword-face) + '("^\\(Subject:\\)[ \t]*\\(.+\\)?" + (1 font-lock-comment-face) +;; (2 font-lock-type-face nil t) + ) + ;; Use EVAL to delay in case `mail-header-separator' gets changed. + '(eval . + (let ((separator (if (zerop (length mail-header-separator)) + " \\`\\' " + (regexp-quote mail-header-separator)))) + (cons (concat "^" separator "$") 'font-lock-warning-face))) + ;; Use MATCH-ANCHORED to effectively anchor the regexp left side. + `(,cite-chars + (,(concat "\\=[ \t]*" + "\\(\\(\\([" cite-prefix "]+[" cite-suffix "]*\\)?" + "\\(" cite-chars "[ \t]*\\)\\)+\\)" + "\\(.*\\)") + (beginning-of-line) (end-of-line) + (1 font-lock-comment-delimiter-face nil t) + (5 font-lock-comment-face nil t))) + '("^\\(X-[A-Za-z0-9-]+\\|In-reply-to\\):.*\\(\n[ \t]+.*\\)*$" + . font-lock-string-face)))) + "Additional expressions to highlight in Mail mode.") + + +(defun sendmail-sync-aliases () + (when mail-personal-alias-file + (let ((modtime (nth 5 (file-attributes mail-personal-alias-file)))) + (or (equal mail-alias-modtime modtime) + (setq mail-alias-modtime modtime + mail-aliases t))))) + +(defun mail-setup (to subject in-reply-to cc replybuffer actions) + (or mail-default-reply-to + (setq mail-default-reply-to (getenv "REPLYTO"))) + (sendmail-sync-aliases) + (if (eq mail-aliases t) + (progn + (setq mail-aliases nil) + (when mail-personal-alias-file + (if (file-exists-p mail-personal-alias-file) + (build-mail-aliases))))) + ;; Don't leave this around from a previous message. + (kill-local-variable 'buffer-file-coding-system) + ;; This doesn't work for enable-multibyte-characters. + ;; (kill-local-variable 'enable-multibyte-characters) + (set-buffer-multibyte default-enable-multibyte-characters) + (if current-input-method + (inactivate-input-method)) + (setq mail-send-actions actions) + (setq mail-reply-action replybuffer) + (goto-char (point-min)) + (if mail-setup-with-from + (mail-insert-from-field)) + (insert "To: ") + (save-excursion + (if to + ;; Here removed code to extract names from within <...> + ;; on the assumption that mail-strip-quoted-names + ;; has been called and has done so. + (let ((fill-prefix "\t") + (address-start (point))) + (insert to "\n") + (fill-region-as-paragraph address-start (point-max)) + (goto-char (point-max)) + (unless (bolp) + (newline))) + (newline)) + (if cc + (let ((fill-prefix "\t") + (address-start (progn (insert "CC: ") (point)))) + (insert cc "\n") + (fill-region-as-paragraph address-start (point-max)) + (goto-char (point-max)) + (unless (bolp) + (newline)))) + (if in-reply-to + (let ((fill-prefix "\t") + (fill-column 78) + (address-start (point))) + (insert "In-reply-to: " in-reply-to "\n") + (fill-region-as-paragraph address-start (point-max)) + (goto-char (point-max)) + (unless (bolp) + (newline)))) + (insert "Subject: " (or subject "") "\n") + (if mail-default-headers + (insert mail-default-headers)) + (if mail-default-reply-to + (insert "Reply-to: " mail-default-reply-to "\n")) + (if mail-self-blind + (insert "BCC: " user-mail-address "\n")) + (if mail-archive-file-name + (insert "FCC: " mail-archive-file-name "\n")) + (put-text-property (point) + (progn + (insert mail-header-separator "\n") + (1- (point))) + 'category 'mail-header-separator) + ;; Insert the signature. But remember the beginning of the message. + (if to (setq to (point))) + (cond ((eq mail-signature t) + (if (file-exists-p mail-signature-file) + (progn + (insert "\n\n-- \n") + (insert-file-contents mail-signature-file)))) + ((stringp mail-signature) + (insert mail-signature)) + (t + (eval mail-signature))) + (goto-char (point-max)) + (or (bolp) (newline))) + (if to (goto-char to)) + (or to subject in-reply-to + (set-buffer-modified-p nil)) + (run-hooks 'mail-setup-hook)) + +(defcustom mail-mode-hook nil + "Hook run by Mail mode." + :group 'sendmail + :type 'hook + :options '(footnote-mode)) + +(defvar mail-mode-abbrev-table text-mode-abbrev-table) +;;;###autoload +(define-derived-mode mail-mode text-mode "Mail" + "Major mode for editing mail to be sent. +Like Text Mode but with these additional commands: + +\\[mail-send] mail-send (send the message) +\\[mail-send-and-exit] mail-send-and-exit (send the message and exit) + +Here are commands that move to a header field (and create it if there isn't): + \\[mail-to] move to To: \\[mail-subject] move to Subject: + \\[mail-cc] move to CC: \\[mail-bcc] move to BCC: + \\[mail-fcc] move to FCC: \\[mail-reply-to] move to Reply-To: + \\[mail-mail-reply-to] move to Mail-Reply-To: + \\[mail-mail-followup-to] move to Mail-Followup-To: +\\[mail-text] mail-text (move to beginning of message text). +\\[mail-signature] mail-signature (insert `mail-signature-file' file). +\\[mail-yank-original] mail-yank-original (insert current message, in Rmail). +\\[mail-fill-yanked-message] mail-fill-yanked-message (fill what was yanked). +\\[mail-sent-via] mail-sent-via (add a Sent-via field for each To or CC). +Turning on Mail mode runs the normal hooks `text-mode-hook' and +`mail-mode-hook' (in that order)." + (make-local-variable 'mail-reply-action) + (make-local-variable 'mail-send-actions) + (setq buffer-offer-save t) + (make-local-variable 'font-lock-defaults) + (setq font-lock-defaults '(mail-font-lock-keywords t t)) + (make-local-variable 'paragraph-separate) + (make-local-variable 'normal-auto-fill-function) + (setq normal-auto-fill-function 'mail-mode-auto-fill) + (make-local-variable 'fill-paragraph-function) + (setq fill-paragraph-function 'mail-mode-fill-paragraph) + ;; Allow using comment commands to add/remove quoting (this only does + ;; anything if mail-yank-prefix is set to a non-nil value). + (set (make-local-variable 'comment-start) mail-yank-prefix) + (if mail-yank-prefix + (set (make-local-variable 'comment-start-skip) + (concat "^" (regexp-quote mail-yank-prefix) "[ \t]*"))) + (make-local-variable 'adaptive-fill-regexp) + (setq adaptive-fill-regexp + (concat "[ \t]*[-[:alnum:]]+>+[ \t]*\\|" + adaptive-fill-regexp)) + (make-local-variable 'adaptive-fill-first-line-regexp) + (setq adaptive-fill-first-line-regexp + (concat "[ \t]*[-[:alnum:]]*>+[ \t]*\\|" + adaptive-fill-first-line-regexp)) + ;; `-- ' precedes the signature. `-----' appears at the start of the + ;; lines that delimit forwarded messages. + ;; Lines containing just >= 3 dashes, perhaps after whitespace, + ;; are also sometimes used and should be separators. + (setq paragraph-separate (concat (regexp-quote mail-header-separator) + "$\\|\t*\\([-|#;>* ]\\|(?[0-9]+[.)]\\)+$" + "\\|[ \t]*[[:alnum:]]*>+[ \t]*$\\|[ \t]*$\\|" + "--\\( \\|-+\\)$\\|" + page-delimiter))) + + +(defun mail-header-end () + "Return the buffer location of the end of headers, as a number." + (save-restriction + (widen) + (save-excursion + (rfc822-goto-eoh) + (point)))) + +(defun mail-text-start () + "Return the buffer location of the start of text, as a number." + (save-restriction + (widen) + (save-excursion + (rfc822-goto-eoh) + (forward-line 1) + (point)))) + +(defun mail-sendmail-delimit-header () + "Set up whatever header delimiter convention sendmail will use. +Concretely: replace the first blank line in the header with the separator." + (rfc822-goto-eoh) + (insert mail-header-separator) + (point)) + +(defun mail-sendmail-undelimit-header () + "Remove header separator to put the message in correct form for sendmail. +Leave point at the start of the delimiter line." + (rfc822-goto-eoh) + (delete-region (point) (progn (end-of-line) (point)))) + +(defun mail-mode-auto-fill () + "Carry out Auto Fill for Mail mode. +If within the headers, this makes the new lines into continuation lines." + (if (< (point) (mail-header-end)) + (let ((old-line-start (save-excursion (beginning-of-line) (point)))) + (if (do-auto-fill) + (save-excursion + (beginning-of-line) + (while (not (eq (point) old-line-start)) + ;; Use insert-before-markers in case we're inserting + ;; before the saved value of point (which is common). + (insert-before-markers " ") + (forward-line -1)) + t))) + (do-auto-fill))) + +(defun mail-mode-fill-paragraph (arg) + ;; Do something special only if within the headers. + (if (< (point) (mail-header-end)) + (let (beg end fieldname) + (when (prog1 (re-search-backward "^[-a-zA-Z]+:" nil 'yes) + (setq beg (point))) + (setq fieldname + (downcase (buffer-substring beg (1- (match-end 0)))))) + (forward-line 1) + ;; Find continuation lines and get rid of their continuation markers. + (while (looking-at "[ \t]") + (delete-horizontal-space) + (forward-line 1)) + (setq end (point-marker)) + (goto-char beg) + ;; If this field contains addresses, + ;; make sure we can fill after each address. + (if (member fieldname + '("to" "cc" "bcc" "from" "reply-to" + "mail-reply-to" "mail-followup-to" + "resent-to" "resent-cc" "resent-bcc" + "resent-from" "resent-reply-to")) + (while (search-forward "," end t) + (or (looking-at "[ \t]") + (insert " ")))) + (fill-region-as-paragraph beg end arg) + ;; Mark all lines except the first as continuations. + (goto-char beg) + (forward-line 1) + (while (< (point) end) + (insert " ") + (forward-line 1)) + (move-marker end nil) + t))) + +;; User-level commands for sending. + +(defun mail-send-and-exit (&optional arg) + "Send message like `mail-send', then, if no errors, exit from mail buffer. +Prefix arg means don't delete this window." + (interactive "P") + (mail-send) + (mail-bury arg)) + +(defun mail-dont-send (&optional arg) + "Don't send the message you have been editing. +Prefix arg means don't delete this window." + (interactive "P") + (mail-bury arg)) + +(defun mail-bury (&optional arg) + "Bury this mail buffer." + (let ((newbuf (other-buffer (current-buffer)))) + (bury-buffer (current-buffer)) + (if (and (or (window-dedicated-p (frame-selected-window)) + (cdr (assq 'mail-dedicated-frame (frame-parameters)))) + (not (null (delq (selected-frame) (visible-frame-list))))) + (progn + (if (display-multi-frame-p) + (delete-frame (selected-frame)) + ;; The previous frame is where normally they have the + ;; RMAIL buffer displayed. + (other-frame -1))) + (let (rmail-flag summary-buffer) + (and (not arg) + (not (one-window-p)) + (with-current-buffer + (window-buffer (next-window (selected-window) 'not)) + (setq rmail-flag (eq major-mode 'rmail-mode)) + (setq summary-buffer + (and mail-bury-selects-summary + (boundp 'rmail-summary-buffer) + rmail-summary-buffer + (buffer-name rmail-summary-buffer) + (not (get-buffer-window rmail-summary-buffer)) + rmail-summary-buffer)))) + (if rmail-flag + ;; If the Rmail buffer has a summary, show that. + (if summary-buffer (switch-to-buffer summary-buffer) + (delete-window)) + (switch-to-buffer newbuf)))))) + +(defcustom mail-send-hook nil + "Hook run just before sending mail with `mail-send'." + :type 'hook + :options '(flyspell-mode-off) + :group 'sendmail) + +;;;###autoload +(defcustom mail-mailing-lists nil "\ +*List of mailing list addresses the user is subscribed to. + +The variable is used to trigger insertion of the \"Mail-Followup-To\" +header when sending a message to a mailing list." + :type '(repeat string) + :group 'sendmail) + + +(defun mail-send () + "Send the message in the current buffer. +If `mail-interactive' is non-nil, wait for success indication +or error messages, and inform user. +Otherwise any failure is reported in a message back to +the user from the mailer." + (interactive) + (if (if buffer-file-name + (y-or-n-p "Send buffer contents as mail message? ") + (or (buffer-modified-p) + (y-or-n-p "Message already sent; resend? "))) + (let ((inhibit-read-only t) + (opoint (point)) + (ml (when mail-mailing-lists + ;; The surrounding regexp assumes the use of + ;; `mail-strip-quoted-names' on addresses before matching + ;; Cannot deal with full RFC 822 freedom, but that is + ;; unlikely to be problematic. + (concat "\\(?:[[:space:];,]\\|\\`\\)" + (regexp-opt mail-mailing-lists t) + "\\(?:[[:space:];,]\\|\\'\\)")))) + ;; If there are mailing lists defined + (when ml + (save-excursion + (let* ((to (mail-fetch-field "to" nil t)) + (cc (mail-fetch-field "cc" nil t)) + (new-header-values ; To: and Cc: + (mail-strip-quoted-names + (concat to (when cc (concat ", " cc)))))) + ;; If message goes to known mailing list ... + (when (string-match ml new-header-values) + ;; Add Mail-Followup-To if none yet + (unless (mail-fetch-field "mail-followup-to") + (goto-char (mail-header-end)) + (insert "Mail-Followup-To: " + (let ((l)) + (mapc + ;; remove duplicates + '(lambda (e) + (unless (member e l) + (push e l))) + (split-string new-header-values + ",[[:space:]]+" t)) + (mapconcat 'identity l ", ")) + "\n")) + ;; Add Mail-Reply-To if none yet + (unless (mail-fetch-field "mail-reply-to") + (goto-char (mail-header-end)) + (insert "Mail-Reply-To: " + (or (mail-fetch-field "reply-to") + user-mail-address) + "\n")))))) + (unless (memq mail-send-nonascii '(t mime)) + (goto-char (point-min)) + (skip-chars-forward "\0-\177") + (or (= (point) (point-max)) + (if (eq mail-send-nonascii 'query) + (or (y-or-n-p "Message contains non-ASCII characters; send anyway? ") + (error "Aborted")) + (error "Message contains non-ASCII characters")))) + ;; Complain about any invalid line. + (goto-char (point-min)) + (while (< (point) (mail-header-end)) + (unless (looking-at "[ \t]\\|.*:\\|$") + (push-mark opoint) + (error "Invalid header line (maybe a continuation line lacks initial whitespace)")) + (forward-line 1)) + (goto-char opoint) + (run-hooks 'mail-send-hook) + (message "Sending...") + (funcall send-mail-function) + ;; Now perform actions on successful sending. + (while mail-send-actions + (condition-case nil + (apply (car (car mail-send-actions)) + (cdr (car mail-send-actions))) + (error)) + (setq mail-send-actions (cdr mail-send-actions))) + (message "Sending...done") + ;; If buffer has no file, mark it as unmodified and delete auto-save. + (if (not buffer-file-name) + (progn + (set-buffer-modified-p nil) + (delete-auto-save-file-if-necessary t)))))) + +(defun mail-envelope-from () + "Return the envelope mail address to use when sending mail. +This function uses `mail-envelope-from'." + (if (eq mail-envelope-from 'header) + (nth 1 (mail-extract-address-components + (mail-fetch-field "From"))) + mail-envelope-from)) + +;; This does the real work of sending a message via sendmail. +;; It is called via the variable send-mail-function. + +;;;###autoload +(defvar sendmail-coding-system nil + "*Coding system for encoding the outgoing mail. +This has higher priority than `default-buffer-file-coding-system' +and `default-sendmail-coding-system', +but lower priority than the local value of `buffer-file-coding-system'. +See also the function `select-message-coding-system'.") + +;;;###autoload +(defvar default-sendmail-coding-system 'iso-latin-1 + "Default coding system for encoding the outgoing mail. +This variable is used only when `sendmail-coding-system' is nil. + +This variable is set/changed by the command `set-language-environment'. +User should not set this variable manually, +instead use `sendmail-coding-system' to get a constant encoding +of outgoing mails regardless of the current language environment. +See also the function `select-message-coding-system'.") + +(defun mail-insert-from-field () + (let* ((login user-mail-address) + (fullname (user-full-name)) + (quote-fullname nil)) + (if (string-match "[^\0-\177]" fullname) + (setq fullname (rfc2047-encode-string fullname) + quote-fullname t)) + (cond ((eq mail-from-style 'angles) + (insert "From: " fullname) + (let ((fullname-start (+ (point-min) 6)) + (fullname-end (point-marker))) + (goto-char fullname-start) + ;; Look for a character that cannot appear unquoted + ;; according to RFC 822. + (if (or (re-search-forward "[^- !#-'*+/-9=?A-Z^-~]" + fullname-end 1) + quote-fullname) + (progn + ;; Quote fullname, escaping specials. + (goto-char fullname-start) + (insert "\"") + (while (re-search-forward "[\"\\]" + fullname-end 1) + (replace-match "\\\\\\&" t)) + (insert "\"")))) + (insert " <" login ">\n")) + ((eq mail-from-style 'parens) + (insert "From: " login " (") + (let ((fullname-start (point))) + (if quote-fullname + (insert "\"")) + (insert fullname) + (if quote-fullname + (insert "\"")) + (let ((fullname-end (point-marker))) + (goto-char fullname-start) + ;; RFC 822 says \ and nonmatching parentheses + ;; must be escaped in comments. + ;; Escape every instance of ()\ ... + (while (re-search-forward "[()\\]" fullname-end 1) + (replace-match "\\\\\\&" t)) + ;; ... then undo escaping of matching parentheses, + ;; including matching nested parentheses. + (goto-char fullname-start) + (while (re-search-forward + "\\(\\=\\|[^\\]\\(\\\\\\\\\\)*\\)\\\\(\\(\\([^\\]\\|\\\\\\\\\\)*\\)\\\\)" + fullname-end 1) + (replace-match "\\1(\\3)" t) + (goto-char fullname-start)))) + (insert ")\n")) + ((null mail-from-style) + (insert "From: " login "\n")) + ((eq mail-from-style 'system-default) + nil) + (t (error "Invalid value for `mail-from-style'"))))) + +(defun sendmail-send-it () + "Send the current mail buffer using the Sendmail package. +This is a suitable value for `send-mail-function'. It sends using the +external program defined by `sendmail-program'." + (require 'mail-utils) + (let ((errbuf (if mail-interactive + (generate-new-buffer " sendmail errors") + 0)) + (tembuf (generate-new-buffer " sendmail temp")) + (multibyte enable-multibyte-characters) + (case-fold-search nil) + (selected-coding (select-message-coding-system)) + resend-to-addresses + delimline + fcc-was-found + (mailbuf (current-buffer)) + (program (if (boundp 'sendmail-program) + sendmail-program + "/usr/lib/sendmail")) + ;; Examine these variables now, so that + ;; local binding in the mail buffer will take effect. + (envelope-from + (and mail-specify-envelope-from + (or (mail-envelope-from) user-mail-address)))) + (unwind-protect + (with-current-buffer tembuf + (erase-buffer) + (unless multibyte + (set-buffer-multibyte nil)) + (insert-buffer-substring mailbuf) + (goto-char (point-max)) + ;; require one newline at the end. + (or (= (preceding-char) ?\n) + (insert ?\n)) + ;; Change header-delimiter to be what sendmail expects. + (goto-char (mail-header-end)) + (delete-region (point) (progn (end-of-line) (point))) + (setq delimline (point-marker)) + (sendmail-sync-aliases) + (if mail-aliases + (expand-mail-aliases (point-min) delimline)) + (goto-char (point-min)) + ;; Ignore any blank lines in the header + (while (and (re-search-forward "\n\n\n*" delimline t) + (< (point) delimline)) + (replace-match "\n")) + (goto-char (point-min)) + ;; Look for Resent- headers. They require sending + ;; the message specially. + (let ((case-fold-search t)) + (goto-char (point-min)) + (while (re-search-forward "^Resent-\\(to\\|cc\\|bcc\\):" delimline t) + ;; Put a list of such addresses in resend-to-addresses. + (setq resend-to-addresses + (save-restriction + (narrow-to-region (point) + (save-excursion + (forward-line 1) + (while (looking-at "^[ \t]") + (forward-line 1)) + (point))) + (append (mail-parse-comma-list) + resend-to-addresses))) + ;; Delete Resent-BCC ourselves + (if (save-excursion (beginning-of-line) + (looking-at "resent-bcc")) + (delete-region (save-excursion (beginning-of-line) (point)) + (save-excursion (end-of-line) (1+ (point)))))) +;;; Apparently this causes a duplicate Sender. +;;; ;; If the From is different than current user, insert Sender. +;;; (goto-char (point-min)) +;;; (and (re-search-forward "^From:" delimline t) +;;; (progn +;;; (require 'mail-utils) +;;; (not (string-equal +;;; (mail-strip-quoted-names +;;; (save-restriction +;;; (narrow-to-region (point-min) delimline) +;;; (mail-fetch-field "From"))) +;;; (user-login-name)))) +;;; (progn +;;; (forward-line 1) +;;; (insert "Sender: " (user-login-name) "\n"))) + ;; Don't send out a blank subject line + (goto-char (point-min)) + (if (re-search-forward "^Subject:\\([ \t]*\n\\)+\\b" delimline t) + (replace-match "") + ;; This one matches a Subject just before the header delimiter. + (if (and (re-search-forward "^Subject:\\([ \t]*\n\\)+" delimline t) + (= (match-end 0) delimline)) + (replace-match ""))) + ;; Put the "From:" field in unless for some odd reason + ;; they put one in themselves. + (goto-char (point-min)) + (if (not (re-search-forward "^From:" delimline t)) + (mail-insert-from-field)) + ;; Possibly add a MIME header for the current coding system + (let (charset) + (goto-char (point-min)) + (and (eq mail-send-nonascii 'mime) + (not (re-search-forward "^MIME-version:" delimline t)) + (progn (skip-chars-forward "\0-\177") + (/= (point) (point-max))) + selected-coding + (setq charset + (coding-system-get selected-coding 'mime-charset)) + (goto-char delimline) + (insert "MIME-version: 1.0\n" + "Content-type: text/plain; charset=" + (symbol-name charset) + "\nContent-Transfer-Encoding: 8bit\n"))) + ;; Insert an extra newline if we need it to work around + ;; Sun's bug that swallows newlines. + (goto-char (1+ delimline)) + (if (eval mail-mailer-swallows-blank-line) + (newline)) + ;; Find and handle any FCC fields. + (goto-char (point-min)) + (if (re-search-forward "^FCC:" delimline t) + (progn + (setq fcc-was-found t) + (mail-do-fcc delimline))) + (if mail-interactive + (with-current-buffer errbuf + (erase-buffer)))) + (goto-char (point-min)) + (if (let ((case-fold-search t)) + (or resend-to-addresses + (re-search-forward "^To:\\|^cc:\\|^bcc:" + delimline t))) + (let* ((default-directory "/") + (coding-system-for-write selected-coding) + (args + (append (list (point-min) (point-max) + program + nil errbuf nil "-oi") + (and envelope-from + (list "-f" envelope-from)) +;;; ;; Don't say "from root" if running under su. +;;; (and (equal (user-real-login-name) "root") +;;; (list "-f" (user-login-name))) + (and mail-alias-file + (list (concat "-oA" mail-alias-file))) + (if mail-interactive + ;; These mean "report errors to terminal" + ;; and "deliver interactively" + '("-oep" "-odi") + ;; These mean "report errors by mail" + ;; and "deliver in background". + '("-oem" "-odb")) + ;; Get the addresses from the message + ;; unless this is a resend. + ;; We must not do that for a resend + ;; because we would find the original addresses. + ;; For a resend, include the specific addresses. + (or resend-to-addresses + '("-t") + ) + (if mail-use-dsn + (list "-N" (mapconcat 'symbol-name + mail-use-dsn ","))) + ) + ) + (exit-value (apply 'call-process-region args))) + (or (null exit-value) (eq 0 exit-value) + (error "Sending...failed with exit value %d" exit-value))) + (or fcc-was-found + (error "No recipients"))) + (if mail-interactive + (with-current-buffer errbuf + (goto-char (point-min)) + (while (re-search-forward "\n\n* *" nil t) + (replace-match "; ")) + (if (not (zerop (buffer-size))) + (error "Sending...failed to %s" + (buffer-substring (point-min) (point-max))))))) + (kill-buffer tembuf) + (if (bufferp errbuf) + (kill-buffer errbuf))))) + +(defun mail-do-fcc (header-end) + (unless (markerp header-end) + (error "Value of `header-end' must be a marker")) + (let (fcc-list + (rmailbuf (current-buffer)) + (time (current-time)) + (tembuf (generate-new-buffer " rmail output")) + (case-fold-search t)) + (save-excursion + (goto-char (point-min)) + (while (re-search-forward "^FCC:[ \t]*" header-end t) + (push (buffer-substring (point) + (progn + (end-of-line) + (skip-chars-backward " \t") + (point))) + fcc-list) + (delete-region (match-beginning 0) + (progn (forward-line 1) (point)))) + (set-buffer tembuf) + (erase-buffer) + ;; This initial newline is written out if the fcc file already exists. + (insert "\nFrom " (user-login-name) " " + (current-time-string time) "\n") + ;; Insert the time zone before the year. + (forward-char -1) + (forward-word -1) + (require 'mail-utils) + (insert (mail-rfc822-time-zone time) " ") + (goto-char (point-max)) + (insert-buffer-substring rmailbuf) + ;; Make sure messages are separated. + (goto-char (point-max)) + (insert ?\n) + (goto-char 2) + ;; ``Quote'' "^From " as ">From " + ;; (note that this isn't really quoting, as there is no requirement + ;; that "^[>]+From " be quoted in the same transparent way.) + (let ((case-fold-search nil)) + (while (search-forward "\nFrom " nil t) + (forward-char -5) + (insert ?>))) + (dolist (fcc fcc-list) + (let* ((buffer (find-buffer-visiting fcc)) + (curbuf (current-buffer)) + dont-write-the-file + buffer-matches-file + (beg (point-min)) (end (point-max)) + (beg2 (save-excursion (goto-char (point-min)) + (forward-line 2) (point)))) + (if buffer + ;; File is present in a buffer => append to that buffer. + (with-current-buffer buffer + (setq buffer-matches-file + (and (not (buffer-modified-p)) + (verify-visited-file-modtime buffer))) + ;; Keep the end of the accessible portion at the same place + ;; unless it is the end of the buffer. + (let ((max (if (/= (1+ (buffer-size)) (point-max)) + (point-max)))) + (unwind-protect + ;; Code below lifted from rmailout.el + ;; function rmail-output-to-rmail-file: + (let ((buffer-read-only nil) + (msg (and (boundp 'rmail-current-message) + rmail-current-message))) + ;; If MSG is non-nil, buffer is in RMAIL mode. + (if msg + (progn + ;; Append to an ordinary buffer as a + ;; Unix mail message. + (rmail-maybe-set-message-counters) + (widen) + (narrow-to-region (point-max) (point-max)) + (insert "\C-l\n0, unseen,,\n*** EOOH ***\n" + "Date: " (mail-rfc822-date) "\n") + (insert-buffer-substring curbuf beg2 end) + (insert "\n\C-_") + (goto-char (point-min)) + (widen) + (search-backward "\n\^_") + (narrow-to-region (point) (point-max)) + (rmail-count-new-messages t) + (rmail-show-message msg) + (setq max nil)) + ;; Output file not in rmail mode + ;; => just insert at the end. + (narrow-to-region (point-min) (1+ (buffer-size))) + (goto-char (point-max)) + (insert-buffer-substring curbuf beg end)) + (or buffer-matches-file + (progn + (if (y-or-n-p (format "Save file %s? " + fcc)) + (save-buffer)) + (setq dont-write-the-file t)))) + (if max (narrow-to-region (point-min) max)))))) + ;; Append to the file directly, + ;; unless we've already taken care of it. + (unless dont-write-the-file + (if (and (file-exists-p fcc) + ;; Check that the file isn't empty. We don't + ;; want to insert a newline at the start of an + ;; empty file. + (not (zerop (nth 7 (file-attributes fcc)))) + (mail-file-babyl-p fcc)) + ;; If the file is a Babyl file, + ;; convert the message to Babyl format. + (let ((coding-system-for-write + (or rmail-file-coding-system + 'emacs-mule))) + (with-current-buffer (get-buffer-create " mail-temp") + (setq buffer-read-only nil) + (erase-buffer) + (insert "\C-l\n0, unseen,,\n*** EOOH ***\nDate: " + (mail-rfc822-date) "\n") + (insert-buffer-substring curbuf beg2 end) + (insert "\n\C-_") + (write-region (point-min) (point-max) fcc t) + (erase-buffer))) + (write-region + (1+ (point-min)) (point-max) fcc t))) + (and buffer (not dont-write-the-file) + (with-current-buffer buffer + (set-visited-file-modtime)))))) + (kill-buffer tembuf))) + +(defun mail-sent-via () + "Make a Sent-via header line from each To or CC header line." + (interactive) + (save-excursion + ;; put a marker at the end of the header + (let ((end (copy-marker (mail-header-end))) + (case-fold-search t)) + (goto-char (point-min)) + ;; search for the To: lines and make Sent-via: lines from them + ;; search for the next To: line + (while (re-search-forward "^\\(to\\|cc\\):" end t) + ;; Grab this line plus all its continuations, sans the `to:'. + (let ((to-line + (buffer-substring (point) + (progn + (if (re-search-forward "^[^ \t\n]" end t) + (backward-char 1) + (goto-char end)) + (point))))) + ;; Insert a copy, with altered header field name. + (insert-before-markers "Sent-via:" to-line)))))) + +(defun mail-to () + "Move point to end of To-field." + (interactive) + (expand-abbrev) + (mail-position-on-field "To")) + +(defun mail-subject () + "Move point to end of Subject-field." + (interactive) + (expand-abbrev) + (mail-position-on-field "Subject")) + +(defun mail-cc () + "Move point to end of CC-field. Create a CC field if none." + (interactive) + (expand-abbrev) + (or (mail-position-on-field "cc" t) + (progn (mail-position-on-field "to") + (insert "\nCC: ")))) + +(defun mail-bcc () + "Move point to end of BCC-field. Create a BCC field if none." + (interactive) + (expand-abbrev) + (or (mail-position-on-field "bcc" t) + (progn (mail-position-on-field "to") + (insert "\nBCC: ")))) + +(defun mail-fcc (folder) + "Add a new FCC field, with file name completion." + (interactive "FFolder carbon copy: ") + (expand-abbrev) + (or (mail-position-on-field "fcc" t) ;Put new field after exiting FCC. + (mail-position-on-field "to")) + (insert "\nFCC: " folder)) + +(defun mail-reply-to () + "Move point to end of Reply-To-field. Create a Reply-To field if none." + (interactive) + (expand-abbrev) + (mail-position-on-field "Reply-To")) + +(defun mail-mail-reply-to () + "Move point to end of Mail-Reply-To field. +Create a Mail-Reply-To field if none." + (interactive) + (expand-abbrev) + (or (mail-position-on-field "mail-reply-to" t) + (progn (mail-position-on-field "to") + (insert "\nMail-Reply-To: ")))) + +(defun mail-mail-followup-to () + "Move point to end of Mail-Followup-To field. +Create a Mail-Followup-To field if none." + (interactive) + (expand-abbrev) + (or (mail-position-on-field "mail-followup-to" t) + (progn (mail-position-on-field "to") + (insert "\nMail-Followup-To: ")))) + +(defun mail-position-on-field (field &optional soft) + (let (end + (case-fold-search t)) + (setq end (mail-header-end)) + (goto-char (point-min)) + (if (re-search-forward (concat "^" (regexp-quote field) ":") end t) + (progn + (re-search-forward "^[^ \t]" nil 'move) + (beginning-of-line) + (skip-chars-backward "\n") + t) + (or soft + (progn (goto-char end) + (insert field ": \n") + (skip-chars-backward "\n"))) + nil))) + +(defun mail-text () + "Move point to beginning of message text." + (interactive) + (expand-abbrev) + (goto-char (mail-text-start))) + +(defun mail-signature (&optional atpoint) + "Sign letter with signature based on `mail-signature-file'. +Prefix arg means put contents at point." + (interactive "P") + (save-excursion + (or atpoint + (goto-char (point-max))) + (skip-chars-backward " \t\n") + (end-of-line) + (or atpoint + (delete-region (point) (point-max))) + (if (stringp mail-signature) + (insert mail-signature) + (insert "\n\n-- \n") + (insert-file-contents (expand-file-name mail-signature-file))))) + +(defun mail-fill-yanked-message (&optional justifyp) + "Fill the paragraphs of a message yanked into this one. +Numeric argument means justify as well." + (interactive "P") + (save-excursion + (goto-char (mail-text-start)) + (fill-individual-paragraphs (point) + (point-max) + justifyp + mail-citation-prefix-regexp))) + +(defun mail-indent-citation () + "Modify text just inserted from a message to be cited. +The inserted text should be the region. +When this function returns, the region is again around the modified text. + +Normally, indent each nonblank line `mail-indentation-spaces' spaces. +However, if `mail-yank-prefix' is non-nil, insert that prefix on each line." + (mail-yank-clear-headers (region-beginning) (region-end)) + (if (null mail-yank-prefix) + (indent-rigidly (region-beginning) (region-end) + mail-indentation-spaces) + (save-excursion + (let ((end (set-marker (make-marker) (region-end)))) + (goto-char (region-beginning)) + (while (< (point) end) + (insert mail-yank-prefix) + (forward-line 1)))))) + +(defun mail-yank-original (arg) + "Insert the message being replied to, if any (in rmail). +Puts point after the text and mark before. +Normally, indents each nonblank line ARG spaces (default 3). +However, if `mail-yank-prefix' is non-nil, insert that prefix on each line. + +Just \\[universal-argument] as argument means don't indent, insert no prefix, +and don't delete any header fields." + (interactive "P") + (if mail-reply-action + (let ((start (point)) + (original mail-reply-action)) + (and (consp original) (eq (car original) 'insert-buffer) + (setq original (nth 1 original))) + (if (consp original) + (apply (car original) (cdr original)) + ;; If the original message is in another window in the same frame, + ;; delete that window to save screen space. + ;; t means don't alter other frames. + (delete-windows-on original t) + (with-no-warnings + ;; We really want this to set mark. + (insert-buffer original)) + (set-text-properties (point) (mark t) nil)) + (if (consp arg) + nil + (goto-char start) + (let ((mail-indentation-spaces (if arg (prefix-numeric-value arg) + mail-indentation-spaces)) + ;; Avoid error in Transient Mark mode + ;; on account of mark's being inactive. + (mark-even-if-inactive t)) + (cond (mail-citation-hook + ;; Bind mail-citation-header to the inserted + ;; message's header. + (let ((mail-citation-header + (buffer-substring-no-properties + start + (save-excursion + (save-restriction + (narrow-to-region start (point-max)) + (goto-char start) + (rfc822-goto-eoh) + (point)))))) + (run-hooks 'mail-citation-hook))) + (mail-yank-hooks + (run-hooks 'mail-yank-hooks)) + (t + (mail-indent-citation))))) + ;; This is like exchange-point-and-mark, but doesn't activate the mark. + ;; It is cleaner to avoid activation, even though the command + ;; loop would deactivate the mark because we inserted text. + (goto-char (prog1 (mark t) + (set-marker (mark-marker) (point) (current-buffer)))) + (if (not (eolp)) (insert ?\n))))) + +(defun mail-yank-clear-headers (start end) + (if (< end start) + (let (temp) + (setq temp start start end end temp))) + (if mail-yank-ignored-headers + (save-excursion + (goto-char start) + (if (search-forward "\n\n" end t) + (save-restriction + (narrow-to-region start (point)) + (goto-char start) + (while (let ((case-fold-search t)) + (re-search-forward mail-yank-ignored-headers nil t)) + (beginning-of-line) + (delete-region (point) + (progn (re-search-forward "\n[^ \t]") + (forward-char -1) + (point))))))))) + +(defun mail-yank-region (arg) + "Insert the selected region from the message being replied to. +Puts point after the text and mark before. +Normally, indents each nonblank line ARG spaces (default 3). +However, if `mail-yank-prefix' is non-nil, insert that prefix on each line. + +Just \\[universal-argument] as argument means don't indent, insert no prefix, +and don't delete any header fields." + (interactive "P") + (and (consp mail-reply-action) + (eq (car mail-reply-action) 'insert-buffer) + (with-current-buffer (nth 1 mail-reply-action) + (or (mark t) + (error "No mark set: %S" (current-buffer)))) + (let ((buffer (nth 1 mail-reply-action)) + (start (point)) + ;; Avoid error in Transient Mark mode + ;; on account of mark's being inactive. + (mark-even-if-inactive t)) + ;; Insert the citation text. + (insert (with-current-buffer buffer + (buffer-substring-no-properties (point) (mark)))) + (push-mark start) + ;; Indent or otherwise annotate the citation text. + (if (consp arg) + nil + (let ((mail-indentation-spaces (if arg (prefix-numeric-value arg) + mail-indentation-spaces))) + (if mail-citation-hook + ;; Bind mail-citation-hook to the original message's header. + (let ((mail-citation-header + (with-current-buffer buffer + (buffer-substring-no-properties + (point-min) + (save-excursion + (goto-char (point-min)) + (rfc822-goto-eoh) + (point)))))) + (run-hooks 'mail-citation-hook)) + (if mail-yank-hooks + (run-hooks 'mail-yank-hooks) + (mail-indent-citation)))))))) + +(defun mail-split-line () + "Split current line, moving portion beyond point vertically down. +If the current line has `mail-yank-prefix', insert it on the new line." + (interactive "*") + (split-line mail-yank-prefix)) + + +(defun mail-attach-file (&optional file) + "Insert a file at the end of the buffer, with separator lines around it." + (interactive "fAttach file: ") + (save-excursion + (goto-char (point-max)) + (or (bolp) (newline)) + (newline) + (let ((start (point)) + middle) + (insert (format "===File %s===" file)) + (insert-char ?= (max 0 (- 60 (current-column)))) + (newline) + (setq middle (point)) + (insert "============================================================\n") + (push-mark) + (goto-char middle) + (insert-file-contents file) + (or (bolp) (newline)) + (goto-char start)))) + +;; Put these commands last, to reduce chance of lossage from quitting +;; in middle of loading the file. + +;;;###autoload (add-hook 'same-window-buffer-names "*mail*") + +;;;###autoload +(defun mail (&optional noerase to subject in-reply-to cc replybuffer actions) + "Edit a message to be sent. Prefix arg means resume editing (don't erase). +When this function returns, the buffer `*mail*' is selected. +The value is t if the message was newly initialized; otherwise, nil. + +Optionally, the signature file `mail-signature-file' can be inserted at the +end; see the variable `mail-signature'. + +\\ +While editing message, type \\[mail-send-and-exit] to send the message and exit. + +Various special commands starting with C-c are available in sendmail mode +to move to message header fields: +\\{mail-mode-map} + +If `mail-self-blind' is non-nil, a BCC to yourself is inserted +when the message is initialized. + +If `mail-default-reply-to' is non-nil, it should be an address (a string); +a Reply-to: field with that address is inserted. + +If `mail-archive-file-name' is non-nil, an FCC field with that file name +is inserted. + +The normal hook `mail-setup-hook' is run after the message is +initialized. It can add more default fields to the message. + +The first argument, NOERASE, determines what to do when there is +an existing modified `*mail*' buffer. If NOERASE is nil, the +existing mail buffer is used, and the user is prompted whether to +keep the old contents or to erase them. If NOERASE has the value +`new', a new mail buffer will be created instead of using the old +one. Any other non-nil value means to always select the old +buffer without erasing the contents. + +The second through fifth arguments, + TO, SUBJECT, IN-REPLY-TO and CC, specify if non-nil + the initial contents of those header fields. + These arguments should not have final newlines. +The sixth argument REPLYBUFFER is a buffer which contains an + original message being replied to, or else an action + of the form (FUNCTION . ARGS) which says how to insert the original. + Or it can be nil, if not replying to anything. +The seventh argument ACTIONS is a list of actions to take + if/when the message is sent. Each action looks like (FUNCTION . ARGS); + when the message is sent, we apply FUNCTION to ARGS. + This is how Rmail arranges to mark messages `answered'." + (interactive "P") +;;; This is commented out because I found it was confusing in practice. +;;; It is easy enough to rename *mail* by hand with rename-buffer +;;; if you want to have multiple mail buffers. +;;; And then you can control which messages to save. --rms. +;;; (let ((index 1) +;;; buffer) +;;; ;; If requested, look for a mail buffer that is modified and go to it. +;;; (if noerase +;;; (progn +;;; (while (and (setq buffer +;;; (get-buffer (if (= 1 index) "*mail*" +;;; (format "*mail*<%d>" index)))) +;;; (not (buffer-modified-p buffer))) +;;; (setq index (1+ index))) +;;; (if buffer (switch-to-buffer buffer) +;;; ;; If none exists, start a new message. +;;; ;; This will never re-use an existing unmodified mail buffer +;;; ;; (since index is not 1 anymore). Perhaps it should. +;;; (setq noerase nil)))) +;;; ;; Unless we found a modified message and are happy, start a new message. +;;; (if (not noerase) +;;; (progn +;;; ;; Look for existing unmodified mail buffer. +;;; (while (and (setq buffer +;;; (get-buffer (if (= 1 index) "*mail*" +;;; (format "*mail*<%d>" index)))) +;;; (buffer-modified-p buffer)) +;;; (setq index (1+ index))) +;;; ;; If none, make a new one. +;;; (or buffer +;;; (setq buffer (generate-new-buffer "*mail*"))) +;;; ;; Go there and initialize it. +;;; (switch-to-buffer buffer) +;;; (erase-buffer) +;;; (setq default-directory (expand-file-name "~/")) +;;; (auto-save-mode auto-save-default) +;;; (mail-mode) +;;; (mail-setup to subject in-reply-to cc replybuffer actions) +;;; (if (and buffer-auto-save-file-name +;;; (file-exists-p buffer-auto-save-file-name)) +;;; (message "Auto save file for draft message exists; consider M-x mail-recover")) +;;; t)) + + (if (eq noerase 'new) + (pop-to-buffer (generate-new-buffer "*mail*")) + (and noerase + (not (get-buffer "*mail*")) + (setq noerase nil)) + (pop-to-buffer "*mail*")) + + ;; Avoid danger that the auto-save file can't be written. + (let ((dir (expand-file-name + (file-name-as-directory mail-default-directory)))) + (if (file-exists-p dir) + (setq default-directory dir))) + ;; Only call auto-save-mode if necessary, to avoid changing auto-save file. + (if (or (and auto-save-default (not buffer-auto-save-file-name)) + (and (not auto-save-default) buffer-auto-save-file-name)) + (auto-save-mode auto-save-default)) + (mail-mode) + ;; Disconnect the buffer from its visited file + ;; (in case the user has actually visited a file *mail*). +;;; (set-visited-file-name nil) + (let (initialized) + (and (not (and noerase + (not (eq noerase 'new)))) + (if buffer-file-name + (if (buffer-modified-p) + (when (y-or-n-p "Buffer has unsaved changes; reinitialize it and discard them? ") + (if (y-or-n-p "Disconnect buffer from visited file? ") + (set-visited-file-name nil)) + t) + (when (y-or-n-p "Reinitialize buffer, and disconnect it from the visited file? ") + (set-visited-file-name nil) + t)) + ;; A non-file-visiting buffer. + (if (buffer-modified-p) + (y-or-n-p "Unsent message being composed; erase it? ") + t)) + (let ((inhibit-read-only t)) + (erase-buffer) + (mail-setup to subject in-reply-to cc replybuffer actions) + (setq initialized t))) + (if (and buffer-auto-save-file-name + (file-exists-p buffer-auto-save-file-name)) + (message "Auto save file for draft message exists; consider M-x mail-recover")) + initialized)) + +(defun mail-recover-1 () + "Pop up a list of auto-saved draft messages so you can recover one of them." + (interactive) + (let ((file-name (make-auto-save-file-name)) + (ls-lisp-support-shell-wildcards t) + non-random-len wildcard) + ;; Remove the random part from the auto-save-file-name, and + ;; create a wildcard which matches possible candidates. + ;; Note: this knows that make-auto-save-file-name appends + ;; "##" to the buffer name, where RANDOM-STUFF + ;; is the result of (make-temp-name ""). + (setq non-random-len + (- (length file-name) (length (make-temp-name "")) 1)) + (setq wildcard (concat (substring file-name 0 non-random-len) "*")) + (if (null (file-expand-wildcards wildcard)) + (message "There are no auto-saved drafts to recover") + ;; Bind dired-trivial-filenames to t because all auto-save file + ;; names are normally ``trivial'', so Dired will set point after + ;; all the files, at buffer bottom. We want it on the first + ;; file instead. + (let ((dired-trivial-filenames t)) + (dired-other-window wildcard (concat dired-listing-switches "t"))) + (rename-buffer "*Auto-saved Drafts*" t) + (save-excursion + (goto-char (point-min)) + (or (looking-at " Move to the draft file you want to recover,") + (let ((inhibit-read-only t)) + ;; Each line starts with a space so that Font Lock mode + ;; won't highlight the first character. + (insert "\ + Move to the draft file you want to recover, then type C-c C-c + to recover text of message whose composition was interrupted. + To browse text of a draft, type v on the draft file's line. + + You can also delete some of these files; + type d on a line to mark that file for deletion. + + List of possible auto-save files for recovery: + +")))) + (use-local-map + (let ((map (make-sparse-keymap))) + (set-keymap-parent map (current-local-map)) + map)) + (define-key (current-local-map) "v" + (lambda () + (interactive) + (let ((coding-system-for-read 'emacs-mule-unix)) + (dired-view-file)))) + (define-key (current-local-map) "\C-c\C-c" + (lambda () + (interactive) + (let ((fname (dired-get-filename)) + ;; Auto-saved files are written in the internal + ;; representation, so they should be read accordingly. + (coding-system-for-read 'emacs-mule-unix)) + (switch-to-buffer-other-window "*mail*") + (let ((buffer-read-only nil)) + (erase-buffer) + (insert-file-contents fname nil) + ;; insert-file-contents will set buffer-file-coding-system + ;; to emacs-mule, which is probably not what they want to + ;; use for sending the message. But we don't know what + ;; was its value before the buffer was killed or Emacs + ;; crashed. We therefore reset buffer-file-coding-system + ;; to the default value, so that either the default does + ;; TRT, or the user will get prompted for the right + ;; encoding when they send the message. + (setq buffer-file-coding-system + default-buffer-file-coding-system)))))))) + +(defun mail-recover () + "Recover interrupted mail composition from auto-save files. + +If the mail buffer has a current valid auto-save file, +the command recovers that file. Otherwise, it displays a +buffer showing the existing auto-saved draft messages; +you can move to one of them and type C-c C-c to recover that one." + (interactive) + ;; In case they invoke us from some random buffer... + (switch-to-buffer "*mail*") + ;; If *mail* didn't exist, set its directory, so that auto-saved + ;; drafts will be found. + (let ((dir (expand-file-name + (file-name-as-directory mail-default-directory)))) + (if (file-exists-p dir) + (setq default-directory dir))) + (or (eq major-mode 'mail-mode) + (mail-mode)) + (let ((file-name buffer-auto-save-file-name)) + (cond ((and file-name (file-exists-p file-name)) + (let ((dispbuf + ;; This used to invoke `ls' via call-process, but + ;; dired-noselect is more portable to systems where + ;; `ls' is not a standard program (it will use + ;; ls-lisp instead). + (dired-noselect file-name + (concat dired-listing-switches "t")))) + (save-selected-window + (select-window (display-buffer dispbuf t)) + (goto-char (point-min)) + (forward-line 2) + (dired-move-to-filename) + (setq dispbuf (rename-buffer "*Directory*" t))) + (if (not (yes-or-no-p + (format "Recover mail draft from auto save file %s? " + file-name))) + (error "mail-recover cancelled") + (let ((buffer-read-only nil) + (buffer-coding buffer-file-coding-system) + ;; Auto-save files are written in internal + ;; representation of non-ASCII characters. + (coding-system-for-read 'emacs-mule-unix)) + (erase-buffer) + (insert-file-contents file-name nil) + (setq buffer-file-coding-system buffer-coding))))) + (t (mail-recover-1))))) + +;;;###autoload +(defun mail-other-window (&optional noerase to subject in-reply-to cc replybuffer sendactions) + "Like `mail' command, but display mail buffer in another window." + (interactive "P") + (let ((pop-up-windows t) + (special-display-buffer-names nil) + (special-display-regexps nil) + (same-window-buffer-names nil) + (same-window-regexps nil)) + (pop-to-buffer "*mail*")) + (mail noerase to subject in-reply-to cc replybuffer sendactions)) + +;;;###autoload +(defun mail-other-frame (&optional noerase to subject in-reply-to cc replybuffer sendactions) + "Like `mail' command, but display mail buffer in another frame." + (interactive "P") + (let ((pop-up-frames t) + (special-display-buffer-names nil) + (special-display-regexps nil) + (same-window-buffer-names nil) + (same-window-regexps nil)) + (pop-to-buffer "*mail*")) + (mail noerase to subject in-reply-to cc replybuffer sendactions)) + +;; Do not add anything but external entries on this page. + +(provide 'sendmail) + +;; arch-tag: 48bc1025-d993-4d31-8d81-2a29491f0626 +;;; sendmail.el ends here diff --git a/contrib/smime-card.el b/contrib/smime-card.el new file mode 100644 index 0000000..d85f317 --- /dev/null +++ b/contrib/smime-card.el @@ -0,0 +1,197 @@ +;;; smime-card.el --- Make smime.el work with card readers + +;; Copyright (C) 2005 Brailcom, o.p.s. +;; Author: Milan Zamazal + +;; COPYRIGHT NOTICE +;; +;; This program 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 program 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 +;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +;;; Commentary: + +;; This is a simple wrapper around smime.el allowing to use private keys stored +;; on a smard card. +;; +;; To use it, just put (require 'smime-card) to you Emacs startup file and +;; customize the variable `smime-card-file-keys'. + +;;; Code: + +(require 'smime) + +;;; Configuration + +(defcustom smime-card-file-keys '() + "Alist of certificate files and their corresponding private key card ids. +Each element of the list is of the form (FILE . KEY-ID), where FILE is a +certificate file stored on a regular file system and KEY-ID is the identifier +of the corresponding private key stored on the card. +If FILE begins with the prefix `card:', the certificate is retrieved from the +card under the id following the `card:' prefix in FILE." + :type '(alist :key-type (file :tag "Certificate file") + :value-type (string :tag "Key identifier")) + :group 'smime) + +(defcustom smime-card-fetch-certificates nil + "If non-nil, fetch certificates from the card before verifying messages." + :type 'boolean + :group 'smime) + +;;; Internals + +(defvar smime-card-key nil) + +(defun smime-card-key (keyfile) + (cdr (assoc keyfile smime-card-file-keys))) + +(defvar smime-card-engine-command + "engine dynamic -pre SO_PATH:/usr/lib/opensc/engine_pkcs11.so -pre ID:pkcs11 -pre LIST_ADD:1 -pre LOAD\n") + +(defvar smime-card-process-output "") + +(defun smime-card-process-filter (process string) + (setq smime-card-process-output (concat smime-card-process-output string))) + +(defun smime-card-wait-for-prompt (process) + (while (not (string-match "\\(OpenSSL> \\|PIN: \\)$" + smime-card-process-output)) + (unless (accept-process-output process 5) + (message "OpenSSL: Timeout") + (throw 'error nil))) + (prog1 (if (string= (match-string 1 smime-card-process-output) "PIN: ") + 'pin + t) + (setq smime-card-process-output ""))) + +(defun smime-card-call-openssl-region (b e buf &rest args) + (let* ((infile (make-temp-file "smime-card-in")) + (outfile (make-temp-file "smime-card-out")) + (cert-on-card (and (string-match "^card:\\(.*\\)$" keyfile) + (match-string 1 keyfile))) + (certfile (and cert-on-card (make-temp-file "smime-card-cert"))) + (args (append args + (list "-engine" "pkcs11" + "-keyform" "engine" + "-inkey" smime-card-key + "-in" infile "-out" outfile))) + (process (start-process "openssl" " *openssl*" smime-openssl-program))) + (unwind-protect + (catch 'error + (when certfile + (unless (= (call-process "pkcs15-tool" nil nil nil + "-r" cert-on-card "-o" certfile) + 0) + (message "pkcs15: Error") + (throw 'error nil)) + (let ((args* args)) + (while (and args* (not (string= (car args*) "-signer"))) + (setq args* (cdr args*))) + (setq args* (cdr args*)) + (when args* + (setcar args* certfile)))) + (setq smime-card-process-output "") + (set-process-filter process 'smime-card-process-filter) + (unless (eq (smime-card-wait-for-prompt process) t) + (message "OpenSSL: Error on startup") + (throw 'error nil)) + (process-send-string process smime-card-engine-command) + (unless (eq (smime-card-wait-for-prompt process) t) + (message "OpenSSL: Error in pkcs11 loading") + (throw 'error nil)) + (write-region b e infile nil 0) + (process-send-string process + (concat (mapconcat 'identity args " ") "\n")) + (let ((answer (smime-card-wait-for-prompt process))) + (cond + ((eq answer 'pin) + (process-send-string process (concat (read-passwd "Smartcard PIN: ") "\n")) + (unless (eq (smime-card-wait-for-prompt process) t) + (message "OpenSSL: Error after passphrase") + (throw 'error nil))) + ((eq answer t) + nil) + (t + (message "OpenSSL: Error in processing") + (throw 'error nil)))) + (process-send-eof process) + (with-current-buffer (car buf) + (when (= (cadr (insert-file-contents outfile)) 0) + (message "OpenSSL: Empty output") + (throw 'error nil))) + t) + (delete-file infile) + (delete-file outfile) + (when certfile (delete-file certfile)) + (delete-process process) + (kill-buffer " *openssl*")))) + +;;; smime.el advices + +(defadvice smime-sign-region (around smime-card-sign-region activate) + (let ((smime-card-key (smime-card-key (ad-get-arg 2)))) + ad-do-it)) + +(defadvice smime-decrypt-region (around smime-card-decrypt-region activate) + (let ((smime-card-key (smime-card-key (ad-get-arg 2)))) + ad-do-it)) + +(defadvice smime-call-openssl-region (around smime-card-openssl activate) + (if smime-card-key + (setq ad-return-value + (apply 'smime-card-call-openssl-region (ad-get-args 0))) + ad-do-it)) + +(defadvice smime-verify-region (around smime-card-verify-region activate) + (if smime-card-fetch-certificates + (let ((cert-ids '())) + (with-temp-buffer + (unless (= (call-process + "pkcs15-tool" nil t nil "--list-certificates") + 0) + (error "pkcs15: Certificate listing")) + (goto-char (point-min)) + (while (re-search-forward "^[\t ]+ID[ ]+: \\([0-9]+\\) *$" nil t) + (setq cert-ids (cons (match-string 1) cert-ids)))) + (let ((certfile (make-temp-file "smime-card"))) + (unwind-protect + (progn + (with-temp-file certfile + (when smime-CA-file + (insert-file-contents smime-CA-file)) + (mapc (lambda (id) + (unless (= (call-process "pkcs15-tool" nil t nil + "-r" id) + 0) + (error "pkcs15: Certificat read"))) + cert-ids)) + (let ((smime-CA-file certfile)) + ad-do-it)) + (delete-file certfile)))) + ad-do-it)) + +(defadvice mml-smime-verify (around smime-card-mml-smime-verify activate) + ;; If both smime-CA-directory and smime-CA-file are unset, `mml-smime-verify' + ;; refuses to perform certificate verification. + (let ((smime-CA-file (if smime-card-fetch-certificates + (or smime-CA-file "/dev/null") + smime-CA-file))) + ad-do-it)) + +;;; Announce + +(provide 'smime-card) + +;; arch-tag: 51da9eb2-1ebe-4255-a429-9f5b04aea4bd +;;; smime-card.el ends here diff --git a/contrib/smtpmail.el b/contrib/smtpmail.el new file mode 100644 index 0000000..ff38cd2 --- /dev/null +++ b/contrib/smtpmail.el @@ -0,0 +1,981 @@ +;;; smtpmail.el --- simple SMTP protocol (RFC 821) for sending mail + +;; Copyright (C) 1995, 1996, 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. + +;; Author: Tomoji Kagatani +;; Maintainer: Simon Josefsson +;; w32 Maintainer: Brian D. Carlstrom +;; ESMTP support: Simon Leinen +;; Hacked by Mike Taylor, 11th October 1999 to add support for +;; automatically appending a domain to RCPT TO: addresses. +;; AUTH=LOGIN support: Stephen Cranefield +;; Keywords: mail + +;; 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 the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; Send Mail to smtp host from smtpmail temp buffer. + +;; Please add these lines in your .emacs(_emacs) or use customize. +;; +;;(setq send-mail-function 'smtpmail-send-it) ; if you use `mail' +;;(setq message-send-mail-function 'smtpmail-send-it) ; if you use message/Gnus +;;(setq smtpmail-default-smtp-server "YOUR SMTP HOST") +;;(setq smtpmail-local-domain "YOUR DOMAIN NAME") +;;(setq smtpmail-sendto-domain "YOUR DOMAIN NAME") +;;(setq smtpmail-debug-info t) ; only to debug problems +;;(setq smtpmail-auth-credentials ; or use ~/.authinfo +;; '(("YOUR SMTP HOST" 25 "username" "password"))) +;;(setq smtpmail-starttls-credentials +;; '(("YOUR SMTP HOST" 25 "~/.my_smtp_tls.key" "~/.my_smtp_tls.cert"))) +;; Where the 25 equals the value of `smtpmail-smtp-service', it can be an +;; integer or a string, just as long as they match (eq). + +;; To queue mail, set smtpmail-queue-mail to t and use +;; smtpmail-send-queued-mail to send. + +;; Modified by Stephen Cranefield , +;; 22/6/99, to support SMTP Authentication by the AUTH=LOGIN mechanism. +;; See http://help.netscape.com/products/server/messaging/3x/info/smtpauth.html +;; Rewritten by Simon Josefsson to use same credential variable as AUTH +;; support below. + +;; Modified by Simon Josefsson , 22/2/99, to support SMTP +;; Authentication by the AUTH mechanism. +;; See http://www.ietf.org/rfc/rfc2554.txt + +;; Modified by Simon Josefsson , 2000-10-07, to support +;; STARTTLS. Requires external program +;; ftp://ftp.opaopa.org/pub/elisp/starttls-*.tar.gz. +;; See http://www.ietf.org/rfc/rfc2246.txt, http://www.ietf.org/rfc/rfc2487.txt + +;;; Code: + +(require 'sendmail) +(autoload 'starttls-open-stream "starttls") +(autoload 'starttls-negotiate "starttls") +(autoload 'mail-strip-quoted-names "mail-utils") +(autoload 'message-make-date "message") +(autoload 'message-make-message-id "message") +(autoload 'rfc2104-hash "rfc2104") +(autoload 'netrc-parse "netrc") +(autoload 'netrc-machine "netrc") +(autoload 'netrc-get "netrc") + +;;; +(defgroup smtpmail nil + "SMTP protocol for sending mail." + :group 'mail) + + +(defcustom smtpmail-default-smtp-server nil + "*Specify default SMTP server. +This only has effect if you specify it before loading the smtpmail library." + :type '(choice (const nil) string) + :group 'smtpmail) + +(defcustom smtpmail-smtp-server + (or (getenv "SMTPSERVER") smtpmail-default-smtp-server) + "*The name of the host running SMTP server." + :type '(choice (const nil) string) + :group 'smtpmail) + +(defcustom smtpmail-smtp-service 25 + "*SMTP service port number. +The default value would be \"smtp\" or 25 ." + :type '(choice (integer :tag "Port") (string :tag "Service")) + :group 'smtpmail) + +(defcustom smtpmail-local-domain nil + "*Local domain name without a host name. +If the function (system-name) returns the full internet address, +don't define this value." + :type '(choice (const nil) string) + :group 'smtpmail) + +(defcustom smtpmail-sendto-domain nil + "*Local domain name without a host name. +This is appended (with an @-sign) to any specified recipients which do +not include an @-sign, so that each RCPT TO address is fully qualified. +\(Some configurations of sendmail require this.) + +Don't bother to set this unless you have get an error like: + Sending failed; SMTP protocol error +when sending mail, and the *trace of SMTP session to * +buffer includes an exchange like: + RCPT TO: + 501 : recipient address must contain a domain +" + :type '(choice (const nil) string) + :group 'smtpmail) + +(defcustom smtpmail-debug-info nil + "Whether to print info in buffer *trace of SMTP session to *. +See also `smtpmail-debug-verb' which determines if the SMTP protocol should +be verbose as well." + :type 'boolean + :group 'smtpmail) + +(defcustom smtpmail-debug-verb nil + "Whether this library sends the SMTP VERB command or not. +The commands enables verbose information from the SMTP server." + :type 'boolean + :group 'smtpmail) + +(defcustom smtpmail-code-conv-from nil ;; *junet* + "*smtpmail code convert from this code to *internal*..for tiny-mime.." + :type 'boolean + :group 'smtpmail) + +(defcustom smtpmail-queue-mail nil + "*Specify if mail is queued (if t) or sent immediately (if nil). +If queued, it is stored in the directory `smtpmail-queue-dir' +and sent with `smtpmail-send-queued-mail'." + :type 'boolean + :group 'smtpmail) + +(defcustom smtpmail-queue-dir "~/Mail/queued-mail/" + "*Directory where `smtpmail.el' stores queued mail." + :type 'directory + :group 'smtpmail) + +(defcustom smtpmail-auth-credentials "~/.authinfo" + "Specify username and password for servers, directly or via .netrc file. +This variable can either be a filename pointing to a file in netrc(5) +format, or list of four-element lists that contain, in order, +`servername' (a string), `port' (an integer), `user' (a string) and +`password' (a string, or nil to query the user when needed). If you +need to enter a `realm' too, add it to the user string, so that it +looks like `user@realm'." + :type '(choice file + (repeat (list (string :tag "Server") + (integer :tag "Port") + (string :tag "Username") + (choice (const :tag "Query when needed" nil) + (string :tag "Password"))))) + :version "22.1" + :group 'smtpmail) + +(defcustom smtpmail-starttls-credentials '(("" 25 "" "")) + "Specify STARTTLS keys and certificates for servers. +This is a list of four-element list with `servername' (a string), +`port' (an integer), `key' (a filename) and `certificate' (a filename)." + :type '(repeat (list (string :tag "Server") + (integer :tag "Port") + (file :tag "Key") + (file :tag "Certificate"))) + :version "21.1" + :group 'smtpmail) + +(defcustom smtpmail-warn-about-unknown-extensions nil + "*If set, print warnings about unknown SMTP extensions. +This is mainly useful for development purposes, to learn about +new SMTP extensions that might be useful to support." + :type 'boolean + :version "21.1" + :group 'smtpmail) + +(defvar smtpmail-queue-index-file "index" + "File name of queued mail index, +This is relative to `smtpmail-queue-dir'.") + +(defvar smtpmail-address-buffer) +(defvar smtpmail-recipient-address-list) + +(defvar smtpmail-queue-counter 0) + +;; Buffer-local variable. +(defvar smtpmail-read-point) + +(defvar smtpmail-queue-index (concat smtpmail-queue-dir + smtpmail-queue-index-file)) + +(defconst smtpmail-auth-supported '(cram-md5 plain login) + "List of supported SMTP AUTH mechanisms.") + +;;; +;;; +;;; + +(defvar smtpmail-mail-address nil + "Value to use for envelope-from address for mail from ambient buffer.") + +;;;###autoload +(defun smtpmail-send-it () + (let ((errbuf (if mail-interactive + (generate-new-buffer " smtpmail errors") + 0)) + (tembuf (generate-new-buffer " smtpmail temp")) + (case-fold-search nil) + delimline + (mailbuf (current-buffer)) + ;; Examine this variable now, so that + ;; local binding in the mail buffer will take effect. + (smtpmail-mail-address + (or (and mail-specify-envelope-from (mail-envelope-from)) + user-mail-address)) + (smtpmail-code-conv-from + (if enable-multibyte-characters + (let ((sendmail-coding-system smtpmail-code-conv-from)) + (select-message-coding-system))))) + (unwind-protect + (save-excursion + (set-buffer tembuf) + (erase-buffer) + (insert-buffer-substring mailbuf) + (goto-char (point-max)) + ;; require one newline at the end. + (or (= (preceding-char) ?\n) + (insert ?\n)) + ;; Change header-delimiter to be what sendmail expects. + (mail-sendmail-undelimit-header) + (setq delimline (point-marker)) +;; (sendmail-synch-aliases) + (if mail-aliases + (expand-mail-aliases (point-min) delimline)) + (goto-char (point-min)) + ;; ignore any blank lines in the header + (while (and (re-search-forward "\n\n\n*" delimline t) + (< (point) delimline)) + (replace-match "\n")) + (let ((case-fold-search t)) + ;; We used to process Resent-... headers here, + ;; but it was not done properly, and the job + ;; is done correctly in smtpmail-deduce-address-list. + ;; Don't send out a blank subject line + (goto-char (point-min)) + (if (re-search-forward "^Subject:\\([ \t]*\n\\)+\\b" delimline t) + (replace-match "") + ;; This one matches a Subject just before the header delimiter. + (if (and (re-search-forward "^Subject:\\([ \t]*\n\\)+" delimline t) + (= (match-end 0) delimline)) + (replace-match ""))) + ;; Put the "From:" field in unless for some odd reason + ;; they put one in themselves. + (goto-char (point-min)) + (if (not (re-search-forward "^From:" delimline t)) + (let* ((login smtpmail-mail-address) + (fullname (user-full-name))) + (cond ((eq mail-from-style 'angles) + (insert "From: " fullname) + (let ((fullname-start (+ (point-min) 6)) + (fullname-end (point-marker))) + (goto-char fullname-start) + ;; Look for a character that cannot appear unquoted + ;; according to RFC 822. + (if (re-search-forward "[^- !#-'*+/-9=?A-Z^-~]" + fullname-end 1) + (progn + ;; Quote fullname, escaping specials. + (goto-char fullname-start) + (insert "\"") + (while (re-search-forward "[\"\\]" + fullname-end 1) + (replace-match "\\\\\\&" t)) + (insert "\"")))) + (insert " <" login ">\n")) + ((eq mail-from-style 'parens) + (insert "From: " login " (") + (let ((fullname-start (point))) + (insert fullname) + (let ((fullname-end (point-marker))) + (goto-char fullname-start) + ;; RFC 822 says \ and nonmatching parentheses + ;; must be escaped in comments. + ;; Escape every instance of ()\ ... + (while (re-search-forward "[()\\]" fullname-end 1) + (replace-match "\\\\\\&" t)) + ;; ... then undo escaping of matching parentheses, + ;; including matching nested parentheses. + (goto-char fullname-start) + (while (re-search-forward + "\\(\\=\\|[^\\]\\(\\\\\\\\\\)*\\)\\\\(\\(\\([^\\]\\|\\\\\\\\\\)*\\)\\\\)" + fullname-end 1) + (replace-match "\\1(\\3)" t) + (goto-char fullname-start)))) + (insert ")\n")) + ((null mail-from-style) + (insert "From: " login "\n"))))) + ;; Insert a `Message-Id:' field if there isn't one yet. + (goto-char (point-min)) + (unless (re-search-forward "^Message-Id:" delimline t) + (insert "Message-Id: " (message-make-message-id) "\n")) + ;; Insert a `Date:' field if there isn't one yet. + (goto-char (point-min)) + (unless (re-search-forward "^Date:" delimline t) + (insert "Date: " (message-make-date) "\n")) + ;; Insert an extra newline if we need it to work around + ;; Sun's bug that swallows newlines. + (goto-char (1+ delimline)) + (if (eval mail-mailer-swallows-blank-line) + (newline)) + ;; Find and handle any FCC fields. + (goto-char (point-min)) + (if (re-search-forward "^FCC:" delimline t) + (mail-do-fcc delimline)) + (if mail-interactive + (with-current-buffer errbuf + (erase-buffer)))) + ;; + ;; + ;; + (setq smtpmail-address-buffer (generate-new-buffer "*smtp-mail*")) + (setq smtpmail-recipient-address-list + (smtpmail-deduce-address-list tembuf (point-min) delimline)) + (kill-buffer smtpmail-address-buffer) + + (smtpmail-do-bcc delimline) + ; Send or queue + (if (not smtpmail-queue-mail) + (if (not (null smtpmail-recipient-address-list)) + (if (not (smtpmail-via-smtp + smtpmail-recipient-address-list tembuf)) + (error "Sending failed; SMTP protocol error")) + (error "Sending failed; no recipients")) + (let* ((file-data + (expand-file-name + (format "%s_%i" + (format-time-string "%Y-%m-%d_%H:%M:%S") + (setq smtpmail-queue-counter + (1+ smtpmail-queue-counter))) + smtpmail-queue-dir)) + (file-data (convert-standard-filename file-data)) + (file-elisp (concat file-data ".el")) + (buffer-data (create-file-buffer file-data)) + (buffer-elisp (create-file-buffer file-elisp)) + (buffer-scratch "*queue-mail*")) + (unless (file-exists-p smtpmail-queue-dir) + (make-directory smtpmail-queue-dir t)) + (with-current-buffer buffer-data + (erase-buffer) + (insert-buffer-substring tembuf) + (write-file file-data) + (set-buffer buffer-elisp) + (erase-buffer) + (insert (concat + "(setq smtpmail-recipient-address-list '" + (prin1-to-string smtpmail-recipient-address-list) + ")\n")) + (write-file file-elisp) + (set-buffer (generate-new-buffer buffer-scratch)) + (insert (concat file-data "\n")) + (append-to-file (point-min) + (point-max) + smtpmail-queue-index) + ) + (kill-buffer buffer-scratch) + (kill-buffer buffer-data) + (kill-buffer buffer-elisp)))) + (kill-buffer tembuf) + (if (bufferp errbuf) + (kill-buffer errbuf))))) + +;;;###autoload +(defun smtpmail-send-queued-mail () + "Send mail that was queued as a result of setting `smtpmail-queue-mail'." + (interactive) + (with-temp-buffer + ;;; Get index, get first mail, send it, update index, get second + ;;; mail, send it, etc... + (let ((file-msg "")) + (insert-file-contents smtpmail-queue-index) + (goto-char (point-min)) + (while (not (eobp)) + (setq file-msg (buffer-substring (point) (line-end-position))) + (load file-msg) + ;; Insert the message literally: it is already encoded as per + ;; the MIME headers, and code conversions might guess the + ;; encoding wrongly. + (with-temp-buffer + (let ((coding-system-for-read 'no-conversion)) + (insert-file-contents file-msg)) + (let ((smtpmail-mail-address + (or (and mail-specify-envelope-from (mail-envelope-from)) + user-mail-address))) + (if (not (null smtpmail-recipient-address-list)) + (if (not (smtpmail-via-smtp smtpmail-recipient-address-list + (current-buffer))) + (error "Sending failed; SMTP protocol error")) + (error "Sending failed; no recipients")))) + (delete-file file-msg) + (delete-file (concat file-msg ".el")) + (delete-region (point-at-bol) (point-at-bol 2))) + (write-region (point-min) (point-max) smtpmail-queue-index)))) + +;(defun smtpmail-via-smtp (host,port,sender,destination,smtpmail-text-buffer) + +(defun smtpmail-fqdn () + (if smtpmail-local-domain + (concat (system-name) "." smtpmail-local-domain) + (system-name))) + +(defsubst smtpmail-cred-server (cred) + (nth 0 cred)) + +(defsubst smtpmail-cred-port (cred) + (nth 1 cred)) + +(defsubst smtpmail-cred-key (cred) + (nth 2 cred)) + +(defsubst smtpmail-cred-user (cred) + (nth 2 cred)) + +(defsubst smtpmail-cred-cert (cred) + (nth 3 cred)) + +(defsubst smtpmail-cred-passwd (cred) + (nth 3 cred)) + +(defun smtpmail-find-credentials (cred server port) + (catch 'done + (let ((l cred) el) + (while (setq el (pop l)) + (when (and (equal server (smtpmail-cred-server el)) + (equal port (smtpmail-cred-port el))) + (throw 'done el)))))) + +(defun smtpmail-maybe-append-domain (recipient) + (if (or (not smtpmail-sendto-domain) + (string-match "@" recipient)) + recipient + (concat recipient "@" smtpmail-sendto-domain))) + +(defun smtpmail-intersection (list1 list2) + (let ((result nil)) + (dolist (el2 list2) + (when (memq el2 list1) + (push el2 result))) + (nreverse result))) + +(defvar starttls-extra-args) +(defvar starttls-extra-arguments) + +(defun smtpmail-open-stream (process-buffer host port) + (let ((cred (smtpmail-find-credentials + smtpmail-starttls-credentials host port))) + (if (null (and cred (condition-case () + (with-no-warnings + (require 'starttls) + (call-process (if starttls-use-gnutls + starttls-gnutls-program + starttls-program))) + (error nil)))) + ;; The normal case. + (open-network-stream "SMTP" process-buffer host port) + (let* ((cred-key (smtpmail-cred-key cred)) + (cred-cert (smtpmail-cred-cert cred)) + (starttls-extra-args + (append + starttls-extra-args + (when (and (stringp cred-key) (stringp cred-cert) + (file-regular-p + (setq cred-key (expand-file-name cred-key))) + (file-regular-p + (setq cred-cert (expand-file-name cred-cert)))) + (list "--key-file" cred-key "--cert-file" cred-cert)))) + (starttls-extra-arguments + (append + starttls-extra-arguments + (when (and (stringp cred-key) (stringp cred-cert) + (file-regular-p + (setq cred-key (expand-file-name cred-key))) + (file-regular-p + (setq cred-cert (expand-file-name cred-cert)))) + (list "--x509keyfile" cred-key "--x509certfile" cred-cert))))) + (starttls-open-stream "SMTP" process-buffer host port))))) + +(defun smtpmail-try-auth-methods (process supported-extensions host port) + (let* ((mechs (cdr-safe (assoc 'auth supported-extensions))) + (mech (car (smtpmail-intersection smtpmail-auth-supported mechs))) + (cred (if (stringp smtpmail-auth-credentials) + (let* ((netrc (netrc-parse smtpmail-auth-credentials)) + (port-name (format "%s" (or port "smtp"))) + (hostentry (netrc-machine netrc host port-name + port-name))) + (when hostentry + (list host port + (netrc-get hostentry "login") + (netrc-get hostentry "password")))) + (smtpmail-find-credentials + smtpmail-auth-credentials host port))) + (passwd (when cred + (or (smtpmail-cred-passwd cred) + (read-passwd + (format "SMTP password for %s:%s: " + (smtpmail-cred-server cred) + (smtpmail-cred-port cred)))))) + ret) + (when (and cred mech) + (cond + ((eq mech 'cram-md5) + (smtpmail-send-command process (upcase (format "AUTH %s" mech))) + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (>= (car ret) 400)) + (throw 'done nil)) + (when (eq (car ret) 334) + (let* ((challenge (substring (cadr ret) 4)) + (decoded (base64-decode-string challenge)) + (hash (rfc2104-hash 'md5 64 16 passwd decoded)) + (response (concat (smtpmail-cred-user cred) " " hash)) + (encoded (base64-encode-string response))) + (smtpmail-send-command process (format "%s" encoded)) + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (>= (car ret) 400)) + (throw 'done nil))))) + ((eq mech 'login) + (smtpmail-send-command process "AUTH LOGIN") + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (>= (car ret) 400)) + (throw 'done nil)) + (smtpmail-send-command + process (base64-encode-string (smtpmail-cred-user cred))) + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (>= (car ret) 400)) + (throw 'done nil)) + (smtpmail-send-command process (base64-encode-string passwd)) + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (>= (car ret) 400)) + (throw 'done nil))) + ((eq mech 'plain) + ;; We used to send an empty initial request, and wait for an + ;; empty response, and then send the password, but this + ;; violate a SHOULD in RFC 2222 paragraph 5.1. Note that this + ;; is not sent if the server did not advertise AUTH PLAIN in + ;; the EHLO response. See RFC 2554 for more info. + (smtpmail-send-command process + (concat "AUTH PLAIN " + (base64-encode-string + (concat "\0" + (smtpmail-cred-user cred) + "\0" + passwd)))) + (if (or (null (car (setq ret (smtpmail-read-response process)))) + (not (integerp (car ret))) + (not (equal (car ret) 235))) + (throw 'done nil))) + + (t + (error "Mechanism %s not implemented" mech))) + ;; Remember the password. + (when (and (not (stringp smtpmail-auth-credentials)) + (null (smtpmail-cred-passwd cred))) + (setcar (cdr (cdr (cdr cred))) passwd))))) + +(defun smtpmail-via-smtp (recipient smtpmail-text-buffer) + (let ((process nil) + (host (or smtpmail-smtp-server + (error "`smtpmail-smtp-server' not defined"))) + (port smtpmail-smtp-service) + ;; smtpmail-mail-address should be set to the appropriate + ;; buffer-local value by the caller, but in case not: + (envelope-from (or smtpmail-mail-address + (and mail-specify-envelope-from + (mail-envelope-from)) + user-mail-address)) + response-code + greeting + process-buffer + (supported-extensions '())) + (unwind-protect + (catch 'done + ;; get or create the trace buffer + (setq process-buffer + (get-buffer-create (format "*trace of SMTP session to %s*" host))) + + ;; clear the trace buffer of old output + (with-current-buffer process-buffer + (setq buffer-undo-list t) + (erase-buffer)) + + ;; open the connection to the server + (setq process (smtpmail-open-stream process-buffer host port)) + (and (null process) (throw 'done nil)) + + ;; set the send-filter + (set-process-filter process 'smtpmail-process-filter) + + (with-current-buffer process-buffer + (set-buffer-process-coding-system 'raw-text-unix 'raw-text-unix) + (make-local-variable 'smtpmail-read-point) + (setq smtpmail-read-point (point-min)) + + + (if (or (null (car (setq greeting (smtpmail-read-response process)))) + (not (integerp (car greeting))) + (>= (car greeting) 400)) + (throw 'done nil) + ) + + (let ((do-ehlo t) + (do-starttls t)) + (while do-ehlo + ;; EHLO + (smtpmail-send-command process (format "EHLO %s" (smtpmail-fqdn))) + + (if (or (null (car (setq response-code + (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (progn + ;; HELO + (smtpmail-send-command + process (format "HELO %s" (smtpmail-fqdn))) + + (if (or (null (car (setq response-code + (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil))) + (dolist (line (cdr (cdr response-code))) + (let ((name (mapcar (lambda (s) (intern (downcase s))) + (split-string (substring line 4) "[ ]")))) + (and (eq (length name) 1) + (setq name (car name))) + (and name + (cond ((memq (if (consp name) (car name) name) + '(verb xvrb 8bitmime onex xone + expn size dsn etrn + enhancedstatuscodes + help xusr + auth=login auth starttls)) + (setq supported-extensions + (cons name supported-extensions))) + (smtpmail-warn-about-unknown-extensions + (message "Unknown extension %s" name))))))) + + (if (and do-starttls + (smtpmail-find-credentials smtpmail-starttls-credentials host port) + (member 'starttls supported-extensions) + (numberp (process-id process))) + (progn + (smtpmail-send-command process (format "STARTTLS")) + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil)) + (starttls-negotiate process) + (setq do-starttls nil)) + (setq do-ehlo nil)))) + + (smtpmail-try-auth-methods process supported-extensions host port) + + (if (or (member 'onex supported-extensions) + (member 'xone supported-extensions)) + (progn + (smtpmail-send-command process (format "ONEX")) + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil)))) + + (if (and smtpmail-debug-verb + (or (member 'verb supported-extensions) + (member 'xvrb supported-extensions))) + (progn + (smtpmail-send-command process (format "VERB")) + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil)))) + + (if (member 'xusr supported-extensions) + (progn + (smtpmail-send-command process (format "XUSR")) + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil)))) + + ;; MAIL FROM: + (let ((size-part + (if (or (member 'size supported-extensions) + (assoc 'size supported-extensions)) + (format " SIZE=%d" + (with-current-buffer smtpmail-text-buffer + ;; size estimate: + (+ (- (point-max) (point-min)) + ;; Add one byte for each change-of-line + ;; because of CR-LF representation: + (count-lines (point-min) (point-max))))) + "")) + (body-part + (if (member '8bitmime supported-extensions) + ;; FIXME: + ;; Code should be added here that transforms + ;; the contents of the message buffer into + ;; something the receiving SMTP can handle. + ;; For a receiver that supports 8BITMIME, this + ;; may mean converting BINARY to BASE64, or + ;; adding Content-Transfer-Encoding and the + ;; other MIME headers. The code should also + ;; return an indication of what encoding the + ;; message buffer is now, i.e. ASCII or + ;; 8BITMIME. + (if nil + " BODY=8BITMIME" + "") + ""))) +; (smtpmail-send-command process (format "MAIL FROM:%s@%s" (user-login-name) (smtpmail-fqdn))) + (smtpmail-send-command process (format "MAIL FROM:<%s>%s%s" + envelope-from + size-part + body-part)) + + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil) + )) + + ;; RCPT TO: + (let ((n 0)) + (while (not (null (nth n recipient))) + (smtpmail-send-command process (format "RCPT TO:<%s>" (smtpmail-maybe-append-domain (nth n recipient)))) + (setq n (1+ n)) + + (setq response-code (smtpmail-read-response process)) + (if (or (null (car response-code)) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil) + ) + )) + + ;; DATA + (smtpmail-send-command process "DATA") + + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil) + ) + + ;; Mail contents + (smtpmail-send-data process smtpmail-text-buffer) + + ;;DATA end "." + (smtpmail-send-command process ".") + + (if (or (null (car (setq response-code (smtpmail-read-response process)))) + (not (integerp (car response-code))) + (>= (car response-code) 400)) + (throw 'done nil) + ) + + ;;QUIT +; (smtpmail-send-command process "QUIT") +; (and (null (car (smtpmail-read-response process))) +; (throw 'done nil)) + t )) + (if process + (with-current-buffer (process-buffer process) + (smtpmail-send-command process "QUIT") + (smtpmail-read-response process) + +; (if (or (null (car (setq response-code (smtpmail-read-response process)))) +; (not (integerp (car response-code))) +; (>= (car response-code) 400)) +; (throw 'done nil) +; ) + (delete-process process) + (unless smtpmail-debug-info + (kill-buffer process-buffer))))))) + + +(defun smtpmail-process-filter (process output) + (with-current-buffer (process-buffer process) + (goto-char (point-max)) + (insert output))) + +(defun smtpmail-read-response (process) + (let ((case-fold-search nil) + (response-strings nil) + (response-continue t) + (return-value '(nil ())) + match-end) + (catch 'done + (while response-continue + (goto-char smtpmail-read-point) + (while (not (search-forward "\r\n" nil t)) + (unless (memq (process-status process) '(open run)) + (throw 'done nil)) + (accept-process-output process) + (goto-char smtpmail-read-point)) + + (setq match-end (point)) + (setq response-strings + (cons (buffer-substring smtpmail-read-point (- match-end 2)) + response-strings)) + + (goto-char smtpmail-read-point) + (if (looking-at "[0-9]+ ") + (let ((begin (match-beginning 0)) + (end (match-end 0))) + (if smtpmail-debug-info + (message "%s" (car response-strings))) + + (setq smtpmail-read-point match-end) + + ;; ignore lines that start with "0" + (if (looking-at "0[0-9]+ ") + nil + (setq response-continue nil) + (setq return-value + (cons (string-to-number + (buffer-substring begin end)) + (nreverse response-strings))))) + + (if (looking-at "[0-9]+-") + (progn (if smtpmail-debug-info + (message "%s" (car response-strings))) + (setq smtpmail-read-point match-end) + (setq response-continue t)) + (progn + (setq smtpmail-read-point match-end) + (setq response-continue nil) + (setq return-value + (cons nil (nreverse response-strings))))))) + (setq smtpmail-read-point match-end)) + return-value)) + + +(defun smtpmail-send-command (process command) + (goto-char (point-max)) + (if (= (aref command 0) ?P) + (insert "PASS \r\n") + (insert command "\r\n")) + (setq smtpmail-read-point (point)) + (process-send-string process command) + (process-send-string process "\r\n")) + +(defun smtpmail-send-data-1 (process data) + (goto-char (point-max)) + + (if (and (multibyte-string-p data) + smtpmail-code-conv-from) + (setq data (string-as-multibyte + (encode-coding-string data smtpmail-code-conv-from)))) + + (if smtpmail-debug-info + (insert data "\r\n")) + + (setq smtpmail-read-point (point)) + ;; Escape "." at start of a line + (if (eq (string-to-char data) ?.) + (process-send-string process ".")) + (process-send-string process data) + (process-send-string process "\r\n") + ) + +(defun smtpmail-send-data (process buffer) + (let ((data-continue t) sending-data) + (with-current-buffer buffer + (goto-char (point-min))) + (while data-continue + (with-current-buffer buffer + (setq sending-data (buffer-substring (point-at-bol) (point-at-eol))) + (end-of-line 2) + (setq data-continue (not (eobp)))) + (smtpmail-send-data-1 process sending-data)))) + +(defun smtpmail-deduce-address-list (smtpmail-text-buffer header-start header-end) + "Get address list suitable for smtp RCPT TO:
." + (unwind-protect + (with-current-buffer smtpmail-address-buffer + (erase-buffer) + (let + ((case-fold-search t) + (simple-address-list "") + this-line + this-line-end + addr-regexp) + (insert-buffer-substring smtpmail-text-buffer header-start header-end) + (goto-char (point-min)) + ;; RESENT-* fields should stop processing of regular fields. + (save-excursion + (setq addr-regexp + (if (re-search-forward "^Resent-\\(to\\|cc\\|bcc\\):" + header-end t) + "^Resent-\\(to\\|cc\\|bcc\\):" + "^\\(To:\\|Cc:\\|Bcc:\\)"))) + + (while (re-search-forward addr-regexp header-end t) + (replace-match "") + (setq this-line (match-beginning 0)) + (forward-line 1) + ;; get any continuation lines + (while (and (looking-at "^[ \t]+") (< (point) header-end)) + (forward-line 1)) + (setq this-line-end (point-marker)) + (setq simple-address-list + (concat simple-address-list " " + (mail-strip-quoted-names (buffer-substring this-line this-line-end)))) + ) + (erase-buffer) + (insert " " simple-address-list "\n") + (subst-char-in-region (point-min) (point-max) 10 ? t);; newline --> blank + (subst-char-in-region (point-min) (point-max) ?, ? t);; comma --> blank + (subst-char-in-region (point-min) (point-max) 9 ? t);; tab --> blank + + (goto-char (point-min)) + ;; tidyness in case hook is not robust when it looks at this + (while (re-search-forward "[ \t]+" header-end t) (replace-match " ")) + + (goto-char (point-min)) + (let (recipient-address-list) + (while (re-search-forward " \\([^ ]+\\) " (point-max) t) + (backward-char 1) + (setq recipient-address-list (cons (buffer-substring (match-beginning 1) (match-end 1)) + recipient-address-list)) + ) + (setq smtpmail-recipient-address-list recipient-address-list)) + + ) + ) + ) + ) + + +(defun smtpmail-do-bcc (header-end) + "Delete [Resent-]BCC: and their continuation lines from the header area. +There may be multiple BCC: lines, and each may have arbitrarily +many continuation lines." + (let ((case-fold-search t)) + (save-excursion + (goto-char (point-min)) + ;; iterate over all BCC: lines + (while (re-search-forward "^\\(RESENT-\\)?BCC:" header-end t) + (delete-region (match-beginning 0) + (progn (forward-line 1) (point))) + ;; get rid of any continuation lines + (while (and (looking-at "^[ \t].*\n") (< (point) header-end)) + (replace-match "")))))) + + +(provide 'smtpmail) + +;;; arch-tag: a76992df-6d71-43b7-9e72-4bacc6c05466 +;;; smtpmail.el ends here diff --git a/contrib/ssl.el b/contrib/ssl.el index 47da047..de69981 100644 --- a/contrib/ssl.el +++ b/contrib/ssl.el @@ -1,9 +1,11 @@ -;;; ssl.el --- ssl functions for emacsen without them builtin +;;; ssl.el,v --- ssl functions for Emacsen without them builtin +;; Author: William M. Perry +;; $Revision: 1.1.1.5 $ ;; Keywords: comm ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Copyright (c) 1995, 1996 by William M. Perry -;;; Copyright (c) 1996 - 1999 Free Software Foundation, Inc. +;;; Copyright (c) 1996, 97, 98, 99, 2001 Free Software Foundation, Inc. ;;; ;;; This file is part of GNU Emacs. ;;; @@ -25,25 +27,14 @@ (eval-when-compile (require 'cl)) (require 'base64) - -(eval-and-compile - (condition-case () - (require 'custom) - (error nil)) - (if (and (featurep 'custom) (fboundp 'custom-declare-variable)) - nil ;; We've got what we needed - ;; We have the old custom-library, hack around it! - (defmacro defgroup (&rest args) - nil) - (defmacro defcustom (var value doc &rest args) - (` (defvar (, var) (, value) (, doc)))))) +(require 'url) ; for `url-configuration-directory' (defgroup ssl nil "Support for `Secure Sockets Layer' encryption." :group 'comm) (defcustom ssl-certificate-directory "~/.w3/certs/" - "*Directory to store CA certificates in" + "*Directory in which to store CA certificates." :group 'ssl :type 'directory) @@ -63,7 +54,7 @@ Run with one argument, the directory name." The certificate is piped to it. Maybe a way of passing a file should be implemented" :group 'ssl - :type 'list) + :type '(repeat string)) (defcustom ssl-certificate-directory-style 'ssleay "*Style of cert database to use, the only valid value right now is `ssleay'. @@ -102,6 +93,19 @@ to." :group 'ssl :type 'list) +(defcustom ssl-view-certificate-program-name ssl-program-name + "*The program to run to provide a human-readable view of a certificate." + :group 'ssl + :type 'string) + +(defcustom ssl-view-certificate-program-arguments + '("x509" "-text" "-inform" "DER") + "*Arguments that should be passed to the certificate viewing program. +The certificate is piped to it. +Maybe a way of passing a file should be implemented." + :group 'ssl + :type 'list) + (defun ssl-certificate-information (der) "Return an assoc list of information about a certificate in DER format." (let ((certificate (concat "-----BEGIN CERTIFICATE-----\n" @@ -112,18 +116,19 @@ to." (set-buffer (get-buffer-create " *openssl*")) (erase-buffer) (insert certificate) - (setq exit-code (condition-case () - (call-process-region (point-min) (point-max) - ssl-program-name - t (list (current-buffer) nil) t - "x509" - "-subject" ; Print the subject DN - "-issuer" ; Print the issuer DN - "-dates" ; Both before and after dates - "-serial" ; print out serial number - "-noout" ; Don't spit out the certificate - ) - (error -1))) + (setq exit-code + (condition-case () + (call-process-region (point-min) (point-max) + ssl-program-name + t (list (current-buffer) nil) t + "x509" + "-subject" ; Print the subject DN + "-issuer" ; Print the issuer DN + "-dates" ; Both before and after dates + "-serial" ; print out serial number + "-noout" ; Don't spit out the certificate + ) + (error -1))) (if (/= exit-code 0) nil (let ((vals nil)) @@ -133,17 +138,17 @@ to." vals))))) (defun ssl-accept-ca-certificate () - "Ask if the user is willing to accept a new CA certificate. The buffer-name -should be the intended name of the certificate, and the buffer should probably -be in DER encoding" + "Ask if the user is willing to accept a new CA certificate. +The buffer name should be the intended name of the certificate, and +the buffer should probably be in DER encoding" ;; TODO, check if it is really new or if we already know it (let* ((process-connection-type nil) (tmpbuf (generate-new-buffer "X509 CA Certificate Information")) (response (save-excursion - (and (eq 0 + (and (eq 0 (apply 'call-process-region - (point-min) (point-max) - ssl-view-certificate-program-name + (point-min) (point-max) + ssl-view-certificate-program-name nil tmpbuf t ssl-view-certificate-program-arguments)) (switch-to-buffer tmpbuf) @@ -171,30 +176,46 @@ be in DER encoding" nil nil nil (expand-file-name ssl-certificate-directory)))))))) +(defvar ssl-exec-wrapper nil) + +(defun ssl-get-command () + (if (memq system-type '(ms-dos ms-windows axp-vms vax-vms)) + ;; Nothing to do on DOS, Windows, or VMS! + (cons ssl-program-name ssl-program-arguments) + (if (not ssl-exec-wrapper) + (let ((script + (expand-file-name "exec_ssl_quietly" url-configuration-directory))) + (if (not (file-executable-p script)) + ;; Need to create our handy-dandy utility script to shut OpenSSL + ;; up completely. + (progn + (write-region "#!/bin/sh\n\nexec \"$@\" 2> /dev/null\n" nil + script nil 5) + (set-file-modes script 493))) ; (rwxr-xr-x) + (setq ssl-exec-wrapper script))) + (cons ssl-exec-wrapper (cons ssl-program-name ssl-program-arguments)))) + (defun open-ssl-stream (name buffer host service) "Open a SSL connection for a service to a host. Returns a subprocess-object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. Args are NAME BUFFER HOST SERVICE. NAME is name for process. It is modified if necessary to make it unique. -BUFFER is the buffer (or buffer-name) to associate with the process. - Process output goes at end of that buffer, unless you specify - an output stream or filter function to handle the output. - BUFFER may be also nil, meaning that this process is not associated - with any buffer +BUFFER is the buffer (or buffer name) to associate with the process. +Process output goes at end of that buffer, unless you specify +an output stream or filter function to handle the output. +BUFFER may be also nil, meaning that this process is not associated +with any buffer. Third arg is name of the host to connect to, or its IP address. Fourth arg SERVICE is name of the service desired, or an integer specifying a port number to connect to." (if (integerp service) (setq service (int-to-string service))) (let* ((process-connection-type nil) (port service) - (proc (eval - (` - (start-process name buffer ssl-program-name - (,@ ssl-program-arguments)))))) + (proc (eval `(start-process name buffer ,@(ssl-get-command))))) (process-kill-without-query proc) proc)) (provide 'ssl) -;;; arch-tag: 659fae92-1c67-4055-939f-32153c2f5114 +;; arch-tag: 659fae92-1c67-4055-939f-32153c2f5114 diff --git a/contrib/ucs-tables.el b/contrib/ucs-tables.el index 43644bf..aceb8c7 100644 --- a/contrib/ucs-tables.el +++ b/contrib/ucs-tables.el @@ -18,9 +18,9 @@ ;; 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 -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -710,28 +710,28 @@ Translates from the iso8859 charsets and `mule-unicode-0100-24ff'.") ;; These are commented out since the current 8859-8 standard ;; does not yet define these codepoints, although there are ;; drafts which do). -; (?\,H@(B . ?\x05B0) ;; HEBREW POINT SHEVA -; (?\,HA(B . ?\x05B1) ;; HEBREW POINT HATAF SEGOL -; (?\,HB(B . ?\x05B2) ;; HEBREW POINT HATAF PATAH -; (?\,HC(B . ?\x05B3) ;; HEBREW POINT HATAF QAMATS -; (?\,HD(B . ?\x05B4) ;; HEBREW POINT HIRIQ -; (?\,HE(B . ?\x05B5) ;; HEBREW POINT TSERE -; (?\,HF(B . ?\x05B6) ;; HEBREW POINT SEGOL -; (?\,HG(B . ?\x05B7) ;; HEBREW POINT PATAH -; (?\,HH(B . ?\x05B8) ;; HEBREW POINT QAMATS -; (?\,HI(B . ?\x05B9) ;; HEBREW POINT HOLAM -; (?\,HK(B . ?\x05BB) ;; HEBREW POINT QUBUTS -; (?\,HL(B . ?\x05BC) ;; HEBREW POINT DAGESH -; (?\,HM(B . ?\x05BD) ;; HEBREW POINT METEG -; (?\,HN(B . ?\x05BE) ;; HEBREW POINT MAQAF -; (?\,HO(B . ?\x05BF) ;; HEBREW POINT RAFE -; (?\,HP(B . ?\x05C0) ;; HEBREW PUNCTUATION PASEQ -; (?\,HQ(B . ?\x05C1) ;; HEBREW POINT SHIN DOT -; (?\,HR(B . ?\x05C2) ;; HEBREW POINT SIN DOT -; (?\,HS(B . ?\x05C3) ;; HEBREW PUNCTUATION SOF PASUQ - (?\,H[(B . ?\x202D) ;; LEFT-TO-RIGHT OVERRIDE - (?\,H\(B . ?\x202E) ;; RIGHT-TO-LEFT OVERRIDE - (?\,H](B . ?\x202C) ;; POP DIRECTIONAL FORMATTING +; (?\@ . ?\x05B0) ;; HEBREW POINT SHEVA +; (?\A . ?\x05B1) ;; HEBREW POINT HATAF SEGOL +; (?\B . ?\x05B2) ;; HEBREW POINT HATAF PATAH +; (?\C . ?\x05B3) ;; HEBREW POINT HATAF QAMATS +; (?\D . ?\x05B4) ;; HEBREW POINT HIRIQ +; (?\E . ?\x05B5) ;; HEBREW POINT TSERE +; (?\F . ?\x05B6) ;; HEBREW POINT SEGOL +; (?\G . ?\x05B7) ;; HEBREW POINT PATAH +; (?\H . ?\x05B8) ;; HEBREW POINT QAMATS +; (?\I . ?\x05B9) ;; HEBREW POINT HOLAM +; (?\K . ?\x05BB) ;; HEBREW POINT QUBUTS +; (?\L . ?\x05BC) ;; HEBREW POINT DAGESH +; (?\M . ?\x05BD) ;; HEBREW POINT METEG +; (?\N . ?\x05BE) ;; HEBREW POINT MAQAF +; (?\O . ?\x05BF) ;; HEBREW POINT RAFE +; (?\P . ?\x05C0) ;; HEBREW PUNCTUATION PASEQ +; (?\Q . ?\x05C1) ;; HEBREW POINT SHIN DOT +; (?\R . ?\x05C2) ;; HEBREW POINT SIN DOT +; (?\S . ?\x05C3) ;; HEBREW PUNCTUATION SOF PASUQ + (?\[ . ?\x202D) ;; LEFT-TO-RIGHT OVERRIDE + (?\\ . ?\x202E) ;; RIGHT-TO-LEFT OVERRIDE + (?\] . ?\x202C) ;; POP DIRECTIONAL FORMATTING (?\,H_(B . ?\x2017) ;; DOUBLE LOW LINE (?\,H`(B . ?\x05D0) ;; HEBREW LETTER ALEF (?\,Ha(B . ?\x05D1) ;; HEBREW LETTER BET @@ -760,8 +760,8 @@ Translates from the iso8859 charsets and `mule-unicode-0100-24ff'.") (?\,Hx(B . ?\x05E8) ;; HEBREW LETTER RESH (?\,Hy(B . ?\x05E9) ;; HEBREW LETTER SHIN (?\,Hz(B . ?\x05EA) ;; HEBREW LETTER TAV - (?\,H{(B . ?\x202A) ;; LEFT-TO-RIGHT EMBEDDING - (?\,H|(B . ?\x202B) ;; RIGHT-TO-LEFT EMBEDDING + (?\{ . ?\x202A) ;; LEFT-TO-RIGHT EMBEDDING + (?\| . ?\x202B) ;; RIGHT-TO-LEFT EMBEDDING (?\,H}(B . ?\x200E) ;; LEFT-TO-RIGHT MARK (?\,H~(B . ?\x200F) ;; RIGHT-TO-LEFT MARK )) @@ -1749,12 +1749,12 @@ Interactively, prompts for a hex string giving the code." (?$(7#`(B . ?$,1GO(B))) (ipa - '((?,0 (B . ?i) + '((?i . ?i) (?,0!(B . ?$,1#j(B) - (?,0"(B . ?e) + (?e . ?e) (?,0#(B . ?$,1#[(B) (?,0$(B . ?,Af(B) - (?,0%(B . ?a) + (?a . ?a) (?,0&(B . ?$,1#h(B) (?,0'(B . ?$,1#Y(B) (?,0((B . ?$,1#P(B) @@ -1762,50 +1762,50 @@ Interactively, prompts for a hex string giving the code." (?,0*(B . ?$,1#d(B) (?,0+(B . ?$,1$,(B) (?,0,(B . ?$,1#Q(B) - (?,0-(B . ?y) + (?y . ?y) (?,0.(B . ?$,1$/(B) (?,0/(B . ?,Ax(B) (?,00(B . ?$,1 s(B) (?,01(B . ?$,1#v(B) (?,02(B . ?$,1$)(B) (?,03(B . ?$,1#u(B) - (?,04(B . ?u) + (?u . ?u) (?,05(B . ?$,1$*(B) - (?,06(B . ?o) + (?o . ?o) (?,07(B . ?$,1#T(B) (?,08(B . ?$,1#R(B) (?,0:(B . ?$,1#Z(B) - (?,0@(B . ?p) - (?,0A(B . ?b) - (?,0B(B . ?t) - (?,0C(B . ?d) - (?,0D(B . ?k) - (?,0E(B . ?g) - (?,0F(B . ?f) - (?,0G(B . ?v) + (?p . ?p) + (?b . ?b) + (?t . ?t) + (?d . ?d) + (?k . ?k) + (?g . ?g) + (?f . ?f) + (?v . ?v) (?,0H(B . ?$,1'8(B) (?,0I(B . ?,Ap(B) - (?,0J(B . ?s) - (?,0K(B . ?z) + (?s . ?s) + (?z . ?z) (?,0L(B . ?$,1$#(B) (?,0M(B . ?$,1$2(B) (?,0N(B . ?,Ag(B) - (?,0O(B . ?x) + (?x . ?x) (?,0P(B . ?$,1$!(B) - (?,0Q(B . ?h) - (?,0R(B . ?m) - (?,0S(B . ?n) + (?h . ?h) + (?m . ?m) + (?n . ?n) (?,0T(B . ?$,1#r(B) (?,0U(B . ?$,1 k(B) - (?,0V(B . ?r) + (?r . ?r) (?,0W(B . ?$,1$ (B) (?,0X(B . ?$,1#y(B) - (?,0Y(B . ?j) - (?,0Z(B . ?l) + (?j . ?j) + (?l . ?l) (?,0[(B . ?$,1$.(B) (?,0\(B . ?$,1$?(B) (?,0](B . ?$,1#e(B) - (?,0^(B . ?w) + (?w . ?w) (?,0_(B . ?$,1$-(B) (?,0p(B . ?$,1$h(B) (?,0q(B . ?$,1$l(B) diff --git a/contrib/vcard.el b/contrib/vcard.el index 39d6285..e52e0a5 100644 --- a/contrib/vcard.el +++ b/contrib/vcard.el @@ -20,7 +20,7 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, you can either send email to this ;; program's maintainer or write to: The Free Software Foundation, -;; Inc.; 59 Temple Place, Suite 330; Boston, MA 02111-1307, USA. +;; Inc.; 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/contrib/xml.el b/contrib/xml.el index 2357779..ccc8caf 100644 --- a/contrib/xml.el +++ b/contrib/xml.el @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/etc/Makefile.in b/etc/Makefile.in index 517bfad..ff9967f 100644 --- a/etc/Makefile.in +++ b/etc/Makefile.in @@ -13,16 +13,19 @@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ SHELL = /bin/sh -install: +install: $(SHELL) $(top_srcdir)/mkinstalldirs $(etcdir) cd $(srcdir) \ && for p in gnus-tut.txt; do \ echo " $(INSTALL_DATA) $$p $(etcdir)/$$p"; \ $(INSTALL_DATA) $$p $(etcdir)/$$p; \ done - $(SHELL) $(top_srcdir)/mkinstalldirs $(etcdir)/images/gnus + $(SHELL) $(top_srcdir)/mkinstalldirs $(etcdir)/images/gnus $(etcdir)/images/mail cd $(srcdir) \ - && for p in images/gnus/*.xpm images/gnus/*.pbm images/gnus/*.xbm images/gnus/x-splash; do \ + && for p in images/gnus/*.xpm images/gnus/*.pbm images/gnus/*.xbm \ + images/mail/*.xpm images/mail/*.pbm \ + images/*.xpm images/*.pbm \ + images/gnus/x-splash; do \ echo " $(INSTALL_DATA) $$p $(etcdir)/$$p"; \ $(INSTALL_DATA) $$p $(etcdir)/$$p; \ done @@ -33,10 +36,13 @@ install: $(INSTALL_DATA) $$p $(etcdir)/$$p; \ done -uninstall: +uninstall: rm -f $(etcdir)/gnus-tut.txt cd $(srcdir) \ - && for p in images/gnus/*.xpm images/gnus/*.pbm images/gnus/*.xbm images/gnus/x-splash; do \ + && for p in images/gnus/*.xpm images/gnus/*.pbm images/gnus/*.xbm \ + images/mail/*.xpm images/mail/*.pbm \ + images/*.xpm images/*.pbm \ + images/gnus/x-splash; do \ rm -f "$(etcdir)/$$p"; \ done rmdir $(etcdir)/images/gnus 2> /dev/null || true @@ -51,8 +57,11 @@ Makefile: $(srcdir)/Makefile.in ../config.status cd .. \ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status -distclean: - rm -f *~ Makefile +clean: + rm -f *~ + +distclean: clean + rm -f Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/etc/gnus-tut.txt b/etc/gnus-tut.txt index 4fcf56c..561ec99 100644 --- a/etc/gnus-tut.txt +++ b/etc/gnus-tut.txt @@ -25,7 +25,8 @@ Ingebrigtsen. If you have a WWW browser, you can investigate to your heart's delight at and . -;; Copyright (C) 1995 Free Software Foundation, Inc. +;; Copyright (C) 1995, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -44,8 +45,8 @@ heart's delight at and ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. From lars Thu Feb 23 23:20:38 1995 From: larsi@gnus.org (ding) diff --git a/etc/gnus/gnus-setup.ast b/etc/gnus/gnus-setup.ast index 4795a6f..2893c40 100644 --- a/etc/gnus/gnus-setup.ast +++ b/etc/gnus/gnus-setup.ast @@ -1,8 +1,10 @@ @title Configuring Gnus for the first time @node What do you want to do with Gnus? + @variable outbound (:radio ((item :tag "Send mail via sendmail" "sendmail") (item :tag "Send mail via SMTP" "smtp"))) "sendmail" -@variable backends (:set ((item :tag "Read news via NNTP" "nntp") (item :tag"Sacrifice a goat" "goat") (item :tag "Read mail, store it locally" "nnml") (item :tag "Read mail and store it on an IMAP server" "nnimap"))) (list "nnml") + +@variable backends (:set ((item :tag "Read news via NNTP" "nntp") (item :tag "Read mail, store it locally" "nnml") (item :tag "Read mail and store it on an IMAP server" "nnimap"))) (list "nnml") @result primary-mail-selections (list backends outbound) @text @@ -38,6 +40,12 @@ TODO: this will be a real link. Run M-x assistant and use the news-server.ast file as input. @end text + +@c Local variables: +@c mode: texinfo +@c End: + @ignore arch-tag: 6b7b200b-9169-4b44-8b32-b73773fa71af @end ignore + diff --git a/etc/gnus/news-server.ast b/etc/gnus/news-server.ast index d607be5..294f923 100644 --- a/etc/gnus/news-server.ast +++ b/etc/gnus/news-server.ast @@ -56,3 +56,9 @@ Password: @variable{user-name} @end text +@c Local variables: +@c mode: texinfo +@c End: + +@c arch tag is missing + diff --git a/etc/images/README b/etc/images/README new file mode 100644 index 0000000..a435456 --- /dev/null +++ b/etc/images/README @@ -0,0 +1,94 @@ +The following icons are from GNOME 2.6: + + attach.xpm (stock_attach) + connect.xpm (stock_connect) + contact.xpm (stock_contact) + delete.xpm (stock_delete) + describe.xpm (stock_properties) + disconnect.xpm (stock_disconnect) + exit.xpm (stock_exit) + lock-broken.xpm (stock_lock_broken) + lock-ok.xpm (stock_lock_ok) + lock.xpm (stock_lock) + next-page.xpm (stock_next-page) + refresh.xpm (stock_refresh) + sort-ascending.xpm (stock_sort-ascending) + sort-column-ascending.xpm (stock_sort-column-ascending) + sort-criteria.xpm (stock_sort-criteria) + sort-descending.xpm (stock_sort-descending) + sort-row-ascending.xpm (stock_sort-row-ascending) + + gnus/toggle-subscription.xpm (stock_task-recurring) + + mail/compose.xpm (stock_mail-compose) + mail/copy.xpm (stock_mail-copy) + mail/forward.xpm (stock_mail-forward) + mail/inbox.xpm (stock_inbox) + mail/move.xpm (stock_mail-move) + mail/not-spam.xpm (stock_not-spam) + mail/outbox.xpm (stock_outbox) + mail/reply-all.xpm (stock_mail-reply-to-all) + mail/reply.xpm (stock_mail-reply) + mail/save-draft.xpm (stock_mail-handling) + mail/send.xpm (stock_mail-send) + mail/spam.xpm (stock_spam) + + +The following icons were contributed by Adam Sjøgren : + + mail/preview.xpm (combining stock_mail and stock_zoom) + mail/save.xpm (combining stock_mail, stock_save and stock_convert) + + +The folling icon are duplicated from Emacs 22. They are either not present in +Emacs 21 or look different there. + + cancel.xpm + close.xpm + copy.xpm + cut.xpm + diropen.xpm + help.xpm + home.xpm + index.xpm + jump-to.xpm + left-arrow.xpm + new.xpm + next-node.xpm + open.xpm + paste.xpm + preferences.xpm + prev-node.xpm + print.xpm + redo.xpm + right-arrow.xpm + save.xpm + saveas.xpm + search.xpm + separator.xpm + spell.xpm + +You might want to use the following code to get Gnome icons in Emacs 21: + + ;; Only for Emacs 21: + (when (and (not (featurep 'xemacs)) + (not (boundp 'image-load-path)) + tool-bar-mode) + (push "/path/to/etc/images/" image-load-path) + (setq tool-bar-map (make-sparse-keymap)) + (clear-image-cache) + (tool-bar-setup)) + +The GNOME's stock_*.png files were converted to XPM using the following GIMP +script: + +;; -*- scheme -*- +;; Put this file in ~/.gimp-*/scripts/ +;; gimp -i -b '(rs-save-as-xpm "foo.png" "foo.xpm" 127)' '(gimp-quit 0)' +(define (rs-save-as-xpm filename filename2 threshold) + (let* ((image (car (gimp-file-load RUN-NONINTERACTIVE filename filename))) + (drawable (car (gimp-image-get-active-layer image)))) + (file-xpm-save RUN-NONINTERACTIVE image drawable + filename2 filename2 threshold) + (gimp-image-delete image))) +;; end diff --git a/etc/images/attach.xpm b/etc/images/attach.xpm new file mode 100644 index 0000000..e3298c9 --- /dev/null +++ b/etc/images/attach.xpm @@ -0,0 +1,126 @@ +/* XPM */ +static char * stock_attach_xpm[] = { +"24 24 99 2", +" c None", +". c #000000", +"+ c #010101", +"@ c #515151", +"# c #9A9A9A", +"$ c #CFCFCF", +"% c #6F6F6F", +"& c #464646", +"* c #A5A5A5", +"= c #E2E2E2", +"- c #FFFFFF", +"; c #F6F6F6", +"> c #8A8A8A", +", c #393939", +"' c #1C1C1C", +") c #8B8B8B", +"! c #E6E6E6", +"~ c #EEEEEE", +"{ c #E1E1E1", +"] c #F8F8F8", +"^ c #F7F7F7", +"/ c #CCCCCC", +"( c #565656", +"_ c #3E3E3E", +": c #818181", +"< c #D4D4D4", +"[ c #E7E7E7", +"} c #D7D7D7", +"| c #FAFAFA", +"1 c #F9F9F9", +"2 c #C2C2C2", +"3 c #CBCBCB", +"4 c #F5F5F5", +"5 c #D9D9D9", +"6 c #030303", +"7 c #545454", +"8 c #DEDEDE", +"9 c #B3B3B3", +"0 c #797979", +"a c #F4F4F4", +"b c #9D9D9D", +"c c #282828", +"d c #FBFBFB", +"e c #A6A6A6", +"f c #C5C5C5", +"g c #F0F0F0", +"h c #CACACA", +"i c #C7C7C7", +"j c #F2F2F2", +"k c #CECECE", +"l c #C4C4C4", +"m c #D5D5D5", +"n c #DADADA", +"o c #F3F3F3", +"p c #858585", +"q c #BEBEBE", +"r c #D3D3D3", +"s c #DCDCDC", +"t c #9C9C9C", +"u c #484848", +"v c #A7A7A7", +"w c #D6D6D6", +"x c #C8C8C8", +"y c #C6C6C6", +"z c #4C4C4C", +"A c #EAEAEA", +"B c #E5E5E5", +"C c #D8D8D8", +"D c #ADADAD", +"E c #BCBCBC", +"F c #E0E0E0", +"G c #F1F1F1", +"H c #909090", +"I c #686868", +"J c #A2A2A2", +"K c #C0C0C0", +"L c #C1C1C1", +"M c #787878", +"N c #AEAEAE", +"O c #151515", +"P c #D0D0D0", +"Q c #979797", +"R c #727272", +"S c #4A4A4A", +"T c #ECECEC", +"U c #ACACAC", +"V c #BABABA", +"W c #DDDDDD", +"X c #DBDBDB", +"Y c #B1B1B1", +"Z c #232323", +"` c #696969", +" . c #B7B7B7", +".. c #828282", +"+. c #404040", +"@. c #969696", +"#. c #323232", +"$. c #E8E8E8", +"%. c #121212", +" ", +" . . . . . ", +" . . . . ", +" . + @ # $ % . ", +" . . & * = - - ; > , ", +" . ' ) ! ~ { - ] ^ ; / ( ", +" . _ : < ' [ } | 1 ] 2 3 4 5 : . ", +" 6 7 ! - - - . } 8 9 0 . = ; 4 a b c ", +" . ; - - | | d . e f g ] . = 2 h a i ( ", +" . j ] 1 k l f . m 1 ] ] . 9 n a o o 0 . ", +" p - ] q 1 1 . r s 2 2 . = 4 a o j t c ", +" u - ^ ^ ] ] . v w ^ ; . = a l x j y z ", +" . A - ; q 2 . B C ; 4 . D E A F G A H . ", +" I - 4 ; ; J . K L . M w o j G G m N O ", +" , - a 4 4 n # . . 0 w j j G w P Q R S ", +" . T - a U V W o k X T } w Y : ( Z . ", +" ` - o o o o j j } ...+.Z . . ", +" c - o j j } q @.#.Z . ", +" . ! $./ # +.Z . . ", +" , .., %.. ", +" . . ", +" ", +" ", +" "}; diff --git a/etc/images/cancel.xpm b/etc/images/cancel.xpm new file mode 100644 index 0000000..1a9c80a --- /dev/null +++ b/etc/images/cancel.xpm @@ -0,0 +1,35 @@ +/* XPM */ +static char *magick[] = { +/* columns rows colors chars-per-pixel */ +"24 24 5 1", +" c #01c601c601c6", +". c Gray40", +"X c #a527a527a527", +"o c #da22da22da22", +"O c None", +/* pixels */ +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOO OOOOOOOOO", +"OOOOOO XXooXX. OOOOOOO", +"OOOOO XooooooooX. OOOOOO", +"OOOOO oooooooooo. OOOOOO", +"OOOO Xooo ooo XoX. OOOOO", +"OOOO Xoo o XXX OOOOO", +"OOOO oooo XoXX OOOOO", +"OOOO Xoooo ooXXX OOOOO", +"OOOO Xooo OXX. OOOOO", +"OOOO Xoo o XX. OOOOO", +"OOOO .Xoo ooX XX.. OOOOO", +"OOOOO XXOoXoXXX.. OOOOOO", +"OOOOO XXXXXXXXX.. OOOOOO", +"OOOOOO XXXX... OOOOOOO", +"OOOOOOOO OOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO", +"OOOOOOOOOOOOOOOOOOOOOOOO" +}; diff --git a/etc/images/close.xpm b/etc/images/close.xpm new file mode 100644 index 0000000..498843b --- /dev/null +++ b/etc/images/close.xpm @@ -0,0 +1,29 @@ +/* XPM */ +static char * close_xpm[] = { +"24 24 2 1", +" c None", +". c #000000", +" ", +" ", +" ", +" ", +" ", +" ", +" . . ", +" . ... ", +" .. .... ", +" .. ... ", +" ..... ", +" ... ", +" ..... ", +" ....... ", +" ... .... ", +" ... .... ", +" ... .. ", +" ", +" ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/connect.xpm b/etc/images/connect.xpm new file mode 100644 index 0000000..f58e8b3 --- /dev/null +++ b/etc/images/connect.xpm @@ -0,0 +1,85 @@ +/* XPM */ +static char * stock_connect_xpm[] = { +"24 24 58 1", +" c None", +". c #000000", +"+ c #989389", +"@ c #807D74", +"# c #C6C2BA", +"$ c #34332D", +"% c #B7B3AA", +"& c #C4C2BD", +"* c #EAE8E3", +"= c #9C978D", +"- c #BCB9B2", +"; c #363433", +"> c #E2E1DD", +", c #F0EFEC", +"' c #AAA7A0", +") c #F0EEEB", +"! c #B2B0AB", +"~ c #F9F9F8", +"{ c #C5C3BD", +"] c #0F0F0D", +"^ c #F2F0ED", +"/ c #EBEAE6", +"( c #8A857B", +"_ c #ECEBE8", +": c #EEECEA", +"< c #9F9C93", +"[ c #F3F2F0", +"} c #E8E7E4", +"| c #E3E1DD", +"1 c #78756B", +"2 c #BEBBB5", +"3 c #B3B1AA", +"4 c #7D786E", +"5 c #E1DFDB", +"6 c #D1D0CC", +"7 c #938E84", +"8 c #C8C5BF", +"9 c #A7A298", +"0 c #010101", +"a c #8C8981", +"b c #A6A29B", +"c c #726D63", +"d c #CECAC3", +"e c #A7A49E", +"f c #7E7A70", +"g c #A09D94", +"h c #817D73", +"i c #6C685E", +"j c #3C3933", +"k c #8B877E", +"l c #706C62", +"m c #B1ADA4", +"n c #97938A", +"o c #625E54", +"p c #6A655B", +"q c #37342D", +"r c #646056", +"s c #8B877D", +" ", +" ", +" ", +" ", +" ", +" ", +" .. .. ", +" ..+@.#@.. ", +" $%&*@.*@=-; ", +" .>,'*@.)@!~{] ", +"......@>,'*@.)@!~{@.....", +"*******^/(_@.:@<[}|*****", +"@@@@@1123451.6@789@@@@@@", +".....01abcd1.e@fghi.....", +" ]abcd1.e@fgh] ", +" ]jklmi.n@opq. ", +" ]]+r.s@.. ", +" ]] ]. ", +" ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/contact.xpm b/etc/images/contact.xpm new file mode 100644 index 0000000..b3cf61f --- /dev/null +++ b/etc/images/contact.xpm @@ -0,0 +1,129 @@ +/* XPM */ +static char * stock_contact_xpm[] = { +"24 24 102 2", +" c None", +". c #000000", +"+ c #E3E1DE", +"@ c #ECEBE7", +"# c #F0EEEB", +"$ c #D2CFC9", +"% c #81817F", +"& c #4C4C4A", +"* c #ECEAE6", +"= c #ECEAE5", +"- c #EBE9E5", +"; c #D2CEC8", +"> c #D9C7B8", +", c #D9C7B9", +"' c #D8C5B8", +") c #D1C0B3", +"! c #D6C5B7", +"~ c #EBEAE5", +"{ c #D3D0C9", +"] c #CDBCAC", +"^ c #AFA093", +"/ c #3A3531", +"( c #443F3A", +"_ c #AE9F93", +": c #CBBAAB", +"< c #4E4E4C", +"[ c #595957", +"} c #595857", +"| c #7D7C7A", +"1 c #D3D0CA", +"2 c #C6B5A4", +"3 c #3D3833", +"4 c #433D37", +"5 c #C2B0A2", +"6 c #D4D1CA", +"7 c #B0A08E", +"8 c #261F18", +"9 c #D37D1E", +"0 c #D68021", +"a c #B26616", +"b c #27241F", +"c c #9C8E7F", +"d c #EAE9E5", +"e c #A29281", +"f c #2E2012", +"g c #CC751A", +"h c #CC761A", +"i c #BF6C16", +"j c #24211C", +"k c #8E8170", +"l c #EAE8E3", +"m c #E9E8E3", +"n c #E9E7E3", +"o c #8E7F6C", +"p c #221E17", +"q c #C56D14", +"r c #7D450D", +"s c #AF5F11", +"t c #221E19", +"u c #7F7260", +"v c #E9E7E2", +"w c #E8E6E1", +"x c #E7E5E1", +"y c #E7E5E0", +"z c #D5D1CB", +"A c #3E372C", +"B c #1C1F1F", +"C c #301B06", +"D c #542D07", +"E c #291B0E", +"F c #151412", +"G c #473F33", +"H c #E8E6E2", +"I c #546371", +"J c #849CB4", +"K c #56687C", +"L c #343332", +"M c #495868", +"N c #566D85", +"O c #293643", +"P c #E6E4DF", +"Q c #E5E4DE", +"R c #EEEDE9", +"S c #7B95AF", +"T c #7B96B0", +"U c #68819B", +"V c #8999AA", +"W c #5A7088", +"X c #607A96", +"Y c #5B7691", +"Z c #E5E3DE", +"` c #4B4A48", +" . c #757471", +".. c #E6E3DE", +"+. c #3B3A39", +"@. c #747371", +"#. c #D3CFC8", +"$. c #E2E1DD", +"%. c #E7E4E0", +"&. c #D2CFC8", +"*. c #D1D0CA", +"=. c #C2C0B9", +" ", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . . ", +" . + @ # # # # # # # # # # # # # # # # # $ . ", +" . # % . . . . . . . & * = - - - - - - - ; . ", +" . # . > , ' ) ! > , . * * ~ ~ ~ ~ - - ~ { . ", +" . # . ] ^ / . ( _ : . * < [ ~ } } | - ~ 1 . ", +" . # . 2 3 . . . 4 5 . * * ~ ~ - - - - - 6 . ", +" . # . 7 8 9 0 a b c . * [ < | [ - } | d 6 . ", +" . # . e f g h i j k . * * l l m n n n n 6 . ", +" . # . o p q r s t u . v v w w w x y y y z . ", +" . # . A B C D E F G . H H y y y y y y y 6 . ", +" . # . I J K L M N O . y y P P P P P P Q { . ", +" . R . S T U V W X Y . y y P P P P Z Z Z { . ", +" . d ` . . . . . . . ` y y ...+.+.Z @.Z #.. ", +" . $.y y y y y y y y y %.P Z Z Z Z Z Z Z &.. ", +" . *.6 z 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 =.. ", +" . . . . . . . . . . . . . . . . . . . . . ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/copy.xpm b/etc/images/copy.xpm new file mode 100644 index 0000000..750aebb --- /dev/null +++ b/etc/images/copy.xpm @@ -0,0 +1,53 @@ +/* XPM */ +static char * copy_xpm[] = { +"24 24 26 1", +" c None", +". c #000000", +"+ c #B4B4B4", +"@ c #F8F8F8", +"# c #F6F6F6", +"$ c #C3C3C3", +"% c #E9E9E9", +"& c #989898", +"* c #828282", +"= c #8A8A8A", +"- c #E8E8E8", +"; c #636363", +"> c #5A5A5A", +", c #6B6B6B", +"' c #B3B3B3", +") c #FFFFFF", +"! c #D6D6D6", +"~ c #818181", +"{ c #A7A7A7", +"] c #8F8F8F", +"^ c #C6C6C6", +"/ c #808080", +"( c #E7E7E7", +"_ c #6D6D6D", +": c #767676", +"< c #F5F5F5", +" ", +" ", +" ", +"............. ", +".+@@@@@@@@@#$. ", +".@%%%%%%%%%%%. ", +".@&**=%+*%*+%. ", +".@%%%%%%%%---. ", +".@;>%,*+-............ ", +".@%%%%%%.'))))))))))!. ", +".@&**%*~.)))))))))))). ", +".@%%%%%-.){]]&)^])]^). ", +".@;>>%,/.)))))))))))). ", +".@%%%%%(.)_;):]^)^])). ", +".@&**%*~.)))))))))))). ", +".<%%%%%-.){]])]]^)&]). ", +".$%%%%%-.)))))))))))). ", +" ........)_;;):]^)^]). ", +" .)))))))))))). ", +" .){]])]]^)&]). ", +" .)))))))))))). ", +" .!))))))))))!. ", +" .............. ", +" "}; diff --git a/etc/images/cut.xpm b/etc/images/cut.xpm new file mode 100644 index 0000000..3f8e71d --- /dev/null +++ b/etc/images/cut.xpm @@ -0,0 +1,67 @@ +/* XPM */ +static char * cut_xpm[] = { +"24 24 40 1", +" c None", +". c #000000", +"+ c #C9C7C2", +"@ c #E6E4E0", +"# c #EFEEED", +"$ c #494946", +"% c #73726E", +"& c #F0EEED", +"* c #7F7D75", +"= c #F2F1EF", +"- c #D2CFC8", +"; c #E7E7E4", +"> c #BAB5AB", +", c #565653", +"' c #EDECE9", +") c #A4A097", +"! c #817F7E", +"~ c #4E4C48", +"{ c #F6F5F4", +"] c #474541", +"^ c #EFEEEC", +"/ c #8C8B8A", +"( c #F3F2F0", +"_ c #77746D", +": c #323232", +"< c #EBEBEA", +"[ c #605D58", +"} c #F5F4F3", +"| c #CECCC7", +"1 c #363634", +"2 c #6F6E6D", +"3 c #BEBDBB", +"4 c #EAE7E4", +"5 c #B8B5B1", +"6 c #474747", +"7 c #DAD8D4", +"8 c #9B9996", +"9 c #161615", +"0 c #6D6B6A", +"a c #3A3837", +" ", +" ", +" . . ", +" . . ", +" .+. .@. ", +" .#$ %@. ", +" .&*. .=-. ", +" .;>, %'). ", +" !#*. .=-~ ", +" .{>] ~^>. ", +" /(_.:<-[ ", +" .}|123>. ", +" .456>. ", +" .78.. ", +" .90a. ", +" ............. ", +" . ... ... ... ", +" .. .. .. .. ", +" . . . . ", +" .. .. .. .. ", +" .... .. . ", +" .... .... ", +" ", +" "}; diff --git a/etc/images/delete.xpm b/etc/images/delete.xpm new file mode 100644 index 0000000..e2d1d90 --- /dev/null +++ b/etc/images/delete.xpm @@ -0,0 +1,270 @@ +/* XPM */ +static char * stock_delete_xpm[] = { +"24 24 243 2", +" c None", +". c #000000", +"+ c #1C1C1C", +"@ c #767676", +"# c #E6E6E6", +"$ c #D3D3D3", +"% c #C3C3C3", +"& c #909090", +"* c #494949", +"= c #48473D", +"- c #BAB8A6", +"; c #E2E2DF", +"> c #F1F1F0", +", c #EAE9E6", +"' c #F2F2EE", +") c #EBEAE5", +"! c #C1C0B5", +"~ c #57564A", +"{ c #525146", +"] c #A8A68F", +"^ c #BDBBA1", +"/ c #C0BEA3", +"( c #A3A18A", +"_ c #6D6C5C", +": c #7C7C72", +"< c #4C4C49", +"[ c #45453F", +"} c #44433A", +"| c #6F6F67", +"1 c #C6C5B9", +"2 c #B6B59B", +"3 c #6D6C5D", +"4 c #B3B19B", +"5 c #A7A68E", +"6 c #908F7A", +"7 c #AAA993", +"8 c #CCCBB5", +"9 c #D0CEBA", +"0 c #D5D3C1", +"a c #AEADA3", +"b c #94938A", +"c c #454442", +"d c #232321", +"e c #353431", +"f c #292823", +"g c #1E1E1A", +"h c #535246", +"i c #ADAC93", +"j c #929189", +"k c #C2C1AF", +"l c #B1AF96", +"m c #ACAA92", +"n c #93927D", +"o c #080808", +"p c #D1D0C1", +"q c #D6D5C4", +"r c #DFDED1", +"s c #CECDC0", +"t c #ACACA6", +"u c #908F8A", +"v c #7E7D77", +"w c #5C5C55", +"x c #47463E", +"y c #656456", +"z c #777665", +"A c #807E6F", +"B c #BEBDA7", +"C c #B5B39A", +"D c #A19F88", +"E c #D9D8CC", +"F c #F6F5F2", +"G c #DBDAD1", +"H c #DAD9CE", +"I c #E5E4D9", +"J c #D0CFC3", +"K c #D3D3C9", +"L c #CAC9BC", +"M c #B7B6A6", +"N c #B8B6A1", +"O c #B0AF96", +"P c #B9B89D", +"Q c #B9B79D", +"R c #B8B69C", +"S c #C4C2A9", +"T c #AFAD97", +"U c #8B8976", +"V c #AAA998", +"W c #B6B6B2", +"X c #F9F9F7", +"Y c #FAFAF8", +"Z c #F4F4F0", +"` c #E2E1DA", +" . c #D9D9CE", +".. c #DBDACF", +"+. c #D3D1BE", +"@. c #C5C4AC", +"#. c #D6D5C3", +"$. c #CDCCBF", +"%. c #BBBAAD", +"&. c #7C7A69", +"*. c #717060", +"=. c #131313", +"-. c #999882", +";. c #AFAE9D", +">. c #C3C3BE", +",. c #DEDEDC", +"'. c #E9E9E8", +"). c #FBFBFA", +"!. c #FDFDFC", +"~. c #FDFDFD", +"{. c #FCFBFA", +"]. c #F2F2EF", +"^. c #EAE9E3", +"/. c #C0BFB1", +"(. c #959484", +"_. c #787766", +":. c #6E6D5D", +"<. c #5B5B4D", +"[. c #5D5C4F", +"}. c #A3A293", +"|. c #B8B7A6", +"1. c #D8D7D0", +"2. c #DBDBD4", +"3. c #D3D2CA", +"4. c #C8C8C3", +"5. c #C6C5BD", +"6. c #BDBCAD", +"7. c #BAB8A8", +"8. c #9F9E8B", +"9. c #8E8C78", +"0. c #8C8B77", +"a. c #7A7968", +"b. c #6C6B5D", +"c. c #4E4D45", +"d. c #424242", +"e. c #7B7B73", +"f. c #9F9F96", +"g. c #D2D1C7", +"h. c #DCDBD2", +"i. c #CCCBBE", +"j. c #D1D0C2", +"k. c #C4C3B6", +"l. c #9A9883", +"m. c #807F6D", +"n. c #7D7C6B", +"o. c #6A695E", +"p. c #40403E", +"q. c #37372D", +"r. c #0F0F0F", +"s. c #383734", +"t. c #787875", +"u. c #999893", +"v. c #8A897E", +"w. c #B3B2A4", +"x. c #AAAA9E", +"y. c #878673", +"z. c #8F8D79", +"A. c #626155", +"B. c #545451", +"C. c #31312E", +"D. c #2B2B23", +"E. c #71715D", +"F. c #57574B", +"G. c #42423A", +"H. c #262620", +"I. c #212121", +"J. c #1B1B1B", +"K. c #242424", +"L. c #161613", +"M. c #2A2A22", +"N. c #303027", +"O. c #3F3F34", +"P. c #7A7A65", +"Q. c #5B5B51", +"R. c #858576", +"S. c #76766B", +"T. c #98988E", +"U. c #75756B", +"V. c #515146", +"W. c #7F7F74", +"X. c #6A6A58", +"Y. c #404035", +"Z. c #626251", +"`. c #545445", +" + c #3E3E33", +".+ c #555546", +"++ c #34342B", +"@+ c #515143", +"#+ c #85856E", +"$+ c #5D5D54", +"%+ c #919182", +"&+ c #828278", +"*+ c #AAAAA3", +"=+ c #7A7A71", +"-+ c #4E4E45", +";+ c #8A8A80", +">+ c #7C7C6D", +",+ c #424237", +"'+ c #606052", +")+ c #5A5A4A", +"!+ c #3C3C32", +"~+ c #4E4E41", +"{+ c #35352C", +"]+ c #ACAC9C", +"^+ c #85857B", +"/+ c #BBBBB3", +"(+ c #A3A39A", +"_+ c #54544B", +":+ c #93938A", +"<+ c #919185", +"[+ c #686856", +"}+ c #414136", +"|+ c #434337", +"1+ c #A4A493", +"2+ c #C1C1B6", +"3+ c #B1B1A2", +"4+ c #6B6B5F", +"5+ c #9D9D8B", +"6+ c #848470", +"7+ c #71715E", +"8+ c #A5A594", +"9+ c #C2C2B7", +"0+ c #7B7B65", +"a+ c #5F5F4F", +"b+ c #666654", +"c+ c #49493C", +"d+ c #575748", +"e+ c #57574A", +"f+ c #7D7D6D", +"g+ c #767669", +"h+ c #B3B3A8", +"i+ c #A1A194", +"j+ c #6D6D61", +"k+ c #B3B3A5", +"l+ c #696957", +"m+ c #414135", +"n+ c #565647", +"o+ c #444438", +"p+ c #595951", +"q+ c #585849", +"r+ c #4E4E40", +"s+ c #747467", +"t+ c #616153", +" . . . . . . ", +" . + @ # $ % & * . . ", +" . . . = - ; > , ' ) ! ~ { . . . ", +" . ] ^ / ( _ : < [ } | 1 2 3 4 5 6 . ", +" . 7 8 9 0 a b c d e f g h i j k l m n . ", +" o p 8 q r s t u v w x y z A B C 2 C D . ", +" . E F G H I J K L M N O D P Q R S T U . ", +" . V W X Y Z ` ...0 +.S / @.#.$.%.&.*.. ", +" =.-.;.>.,.'.).!.~.{.X ].^.G /.(._.:.<.. ", +" . [.n }.|.1.2.3.4.5.6.7.8.9.0.9.a.b.c. ", +" . d.e.f.g.h.i.j.k.l l l l.m.n.o.p.. ", +" . q.r.s.t.u.v.w.x.( y.z.A.B.C.. D.. ", +" . E.F.G.H.I.J.. K.. . . . L.M.N.O.. ", +" . P.Q.R.S.T.U.V.W.X.Y.Z.`. +.+++@+. ", +" . #+$+%+&+*+=+-+;+>+,+'+)+!+~+{+`.. ", +" . #+Q.]+^+/+(+_+:+<+,+'+[+}+X.|+X.. ", +" . #+Q.1+^+2+3+4+3+5+`.6+7+|+X.|+X.. ", +" . #+Q.8+^+9+3+4+3+5+`.6+7+|+X.|+X.. ", +" . #+Q.5+^+2+3+4+3+5+`.6+7+|+X.|+X.. ", +" . 0+Q.1+^+2+3+4+3+5+`.6+7+|+X.|+a+. ", +" . b+Q.1+&+2+3+4+3+5+`.6+7+|+X.c+d+. ", +" . e+f+g+h+i+j+k+5+`.6+l+m+n+o+. . ", +" . . . p+q+r+s+t+~+c+c+. . . ", +" . . . . . . . . . . "}; diff --git a/etc/images/describe.xpm b/etc/images/describe.xpm new file mode 100644 index 0000000..38062d5 --- /dev/null +++ b/etc/images/describe.xpm @@ -0,0 +1,95 @@ +/* XPM */ +static char * stock_properties_xpm[] = { +"24 24 68 1", +" c None", +". c #000000", +"+ c #74716E", +"@ c #C9C4BD", +"# c #DFDAD2", +"$ c #F4EFE5", +"% c #F2ECE1", +"& c #FFFFFF", +"* c #4C4B48", +"= c #EEE5D4", +"- c #ECE2CF", +"; c #EADFC9", +"> c #F9F9F9", +", c #E2D2B1", +"' c #F4F4F4", +") c #EEEEEE", +"! c #959595", +"~ c #F5F5F5", +"{ c #F6F6F6", +"] c #D9D9D9", +"^ c #C7B99C", +"/ c #E9E9E9", +"( c #787878", +"_ c #E1E1E1", +": c #E2E2E2", +"< c #C8C8C8", +"[ c #877E69", +"} c #9A8F78", +"| c #DEDEDE", +"1 c #E3E3E3", +"2 c #929292", +"3 c #AFA389", +"4 c #ACACAC", +"5 c #A2A2A2", +"6 c #E4E4E4", +"7 c #BCBCBC", +"8 c #939393", +"9 c #EDEDED", +"0 c #EFEFEF", +"a c #F0F0F0", +"b c #E5E5E5", +"c c #E7E7E7", +"d c #E8E8E8", +"e c #EAEAEA", +"f c #EBEBEB", +"g c #BEBEBE", +"h c #F1F1F1", +"i c #DFDFDF", +"j c #F3F3F3", +"k c #E0E0E0", +"l c #ABABAB", +"m c #AEAEAE", +"n c #AFAFAF", +"o c #ADADAD", +"p c #B0B0B0", +"q c #B1B1B1", +"r c #F7F7F7", +"s c #B3B3B3", +"t c #F8F8F8", +"u c #B4B4B4", +"v c #B5B5B5", +"w c #B6B6B6", +"x c #FAFAFA", +"y c #FBFBFB", +"z c #DCDCDC", +"A c #DDDDDD", +"B c #E6E6E6", +"C c #969696", +" ", +" ", +" ", +" ......... ", +" .+@#$%.&&. ", +" *=---;.&>. ", +" .......;.,,,,.'). ", +" !~~{].;.^.,^^./(.. ", +" .~_:<.;.[.^.}..|].. ", +" .~:1.;.2.[.3.4...5. ", +" .{16..7/8.[.49)0a|. ", +" .{6bcd/ef8.g9)0ahi. ", +" .{bcd/ef9ef9)0ahjk. ", +" .{cllefmnomnppqj'_. ", +" .rd/ef9)09)0ahj'~:. ", +" .r/4o9)ppnppqss~{1. ", +" .tef9)0ah0ahj'~{rb. ", +" .>9npahssqssuvw>xc. ", +" .>)0ahj'~j'~{r>xyd. ", +" .nzA|ik_:k_:1bBcdC. ", +" ................. ", +" ", +" ", +" "}; diff --git a/etc/images/diropen.xpm b/etc/images/diropen.xpm new file mode 100644 index 0000000..6937b99 --- /dev/null +++ b/etc/images/diropen.xpm @@ -0,0 +1,44 @@ +/* XPM */ +static char * diropen_xpm[] = { +"19 24 17 1", +" c None", +". c #000100", +"+ c #C6C9A6", +"@ c #D0D3AF", +"# c #93997C", +"$ c #E6E7D0", +"% c #BEC19E", +"& c #B4B895", +"* c #A7AA88", +"= c #6B6D59", +"- c #4A4E40", +"; c #7C8166", +"> c #898E72", +", c #3C4032", +"' c #575845", +") c #34332C", +"! c #24231D", +" ............... ", +" .+@@@@@@@@@@@@@#. ", +".$@@@@@@@@@@@@@@@#.", +".++++%%%%%%%%%&&&*.", +".&&&&&&&&&&******#.", +".*%+++%%%%%%%%%&=#.", +".*+***********##-#.", +".*+****;===;####-#.", +".*+****=*****###-#.", +".*+****;*****###-#.", +".*+****########>-#.", +".*&######>>>>>>>,>.", +".*#-------------'>)", +".*&&&&&&&&&&&&&*#>)", +".*&************#'>)", +".*&***********##,>)", +".*&****====;###>,>)", +".#&****=**#**##>,;)", +".#&****>****###>,;)", +".#&****########>,;)", +".##''''''''''''',;)", +".#>==============;)", +".''''''''''''''''-!", +" ................. "}; diff --git a/etc/images/disconnect.xpm b/etc/images/disconnect.xpm new file mode 100644 index 0000000..e08b282 --- /dev/null +++ b/etc/images/disconnect.xpm @@ -0,0 +1,69 @@ +/* XPM */ +static char * stock_disconnect_xpm[] = { +"24 24 42 1", +" c None", +". c #000000", +"+ c #989389", +"@ c #807D74", +"# c #C6C2BA", +"$ c #43423C", +"% c #B7B3AA", +"& c #C4C2BD", +"* c #EAE8E3", +"= c #E2E1DD", +"- c #F0EFEC", +"; c #AAA7A0", +"> c #C5D2C8", +", c #E9EEEA", +"' c #F0EEEB", +") c #F2F0ED", +"! c #EBEAE6", +"~ c #8A857B", +"{ c #ECEBE8", +"] c #EEECEA", +"^ c #78756B", +"/ c #BEBBB5", +"( c #B3B1AA", +"_ c #7D786E", +": c #E1DFDB", +"< c #D1D0CC", +"[ c #010101", +"} c #8C8981", +"| c #A6A29B", +"1 c #726D63", +"2 c #CECAC3", +"3 c #A7A49E", +"4 c #0F0F0D", +"5 c #F0F3F1", +"6 c #272622", +"7 c #8B877E", +"8 c #706C62", +"9 c #B1ADA4", +"0 c #6C685E", +"a c #97938A", +"b c #646056", +"c c #8B877D", +" ", +" ", +" ", +" ", +" ", +" ", +" .. ..", +" ..+@. .#@", +" $%&*@.... .*@", +" .=-;*@.>>,. .'@", +".....@=-;*@.... .'@", +"******)!~{@. .]@", +"@@@@^^/(_:^. .<@", +"....[^}|12^.... .3@", +" 4}|12^.>>5. .3@", +" 67890.... .a@", +" 44+b. .c@", +" 44 4.", +" ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/exit.xpm b/etc/images/exit.xpm new file mode 100644 index 0000000..7f9daf1 --- /dev/null +++ b/etc/images/exit.xpm @@ -0,0 +1,167 @@ +/* XPM */ +static char * stock_exit_xpm[] = { +"24 24 140 2", +" c None", +". c #000000", +"+ c #D6D6D4", +"@ c #BDBDBC", +"# c #A8A8A4", +"$ c #92928F", +"% c #727370", +"& c #61615E", +"* c #20201F", +"= c #F1F1EF", +"- c #E6E6E4", +"; c #DADAD7", +"> c #CFCFCD", +", c #C4C4C1", +"' c #A8A8A5", +") c #767674", +"! c #777774", +"~ c #1E1E1D", +"{ c #B9B9B7", +"] c #AEAEAC", +"^ c #8F8F8D", +"/ c #262626", +"( c #414140", +"_ c #E9836C", +": c #DEDEDC", +"< c #C5C5C2", +"[ c #636362", +"} c #040504", +"| c #040604", +"1 c #050705", +"2 c #E87B62", +"3 c #E67056", +"4 c #D5D5D3", +"5 c #DBDBD8", +"6 c #D0D0CE", +"7 c #080A07", +"8 c #0A0C09", +"9 c #0A0D09", +"0 c #0B0E0A", +"a c #F0B0A1", +"b c #EB8D77", +"c c #DF421E", +"d c #E97E66", +"e c #CBCBC8", +"f c #0C0F0B", +"g c #0F130D", +"h c #10140E", +"i c #11150F", +"j c #EFA392", +"k c #BFBFBD", +"l c #5D5D5C", +"m c #10150F", +"n c #141912", +"o c #161C14", +"p c #171D15", +"q c #B7B7B4", +"r c #0C0C0C", +"s c #192017", +"t c #1C2319", +"u c #1D241A", +"v c #CD8484", +"w c #990000", +"x c #701616", +"y c #A6A6A5", +"z c #181E16", +"A c #1E261B", +"B c #212A1E", +"C c #222B1F", +"D c #4F0000", +"E c #AEAEAB", +"F c #1D261B", +"G c #242E21", +"H c #273224", +"I c #283325", +"J c #580000", +"K c #B5B5B3", +"L c #293426", +"M c #2D3929", +"N c #2E3A2A", +"O c #7C4343", +"P c #6A0000", +"Q c #720000", +"R c #BDBDBB", +"S c #232C20", +"T c #2A3526", +"U c #303C2B", +"V c #33402E", +"W c #C5C5C3", +"X c #1E261C", +"Y c #303D2C", +"Z c #374532", +"` c #394834", +" . c #500000", +".. c #CDCDCB", +"+. c #1B2319", +"@. c #253022", +"#. c #303E2D", +"$. c #394934", +"%. c #3D4E38", +"&. c #9D9D9B", +"*. c #565655", +"=. c #2C3828", +"-. c #40503A", +";. c #43553E", +">. c #BABAB7", +",. c #777776", +"'. c #323830", +"). c #232C1F", +"!. c #313E2D", +"~. c #3B4A36", +"{. c #43553D", +"]. c #485B42", +"^. c #4A5E44", +"/. c #F0F0EE", +"(. c #E5E5E3", +"_. c #C6C6C3", +":. c #ACACAB", +"<. c #8B8B8A", +"[. c #32392F", +"}. c #2C3728", +"|. c #3F503A", +"1. c #465840", +"2. c #4B5E44", +"3. c #4E6347", +"4. c #506549", +"5. c #DADAD8", +"6. c #7A7D78", +"7. c #333C30", +"8. c #475A41", +"9. c #4F6348", +"0. c #53694C", +"a. c #566C4E", +"b. c #576D4F", +"c. c #91968F", +"d. c #3B4736", +"e. c #42543C", +"f. c #51674A", +"g. c #586F50", +"h. c #5B7353", +"i. c #5C7454", +" ", +" . . . . . . . . . . . . . . . . ", +" . + @ # $ % & & & * . . . . . . ", +" . = - ; > , ' ) ! ~ . . . . . . ", +" . . = - ; > , { ] ^ / . . . . . . ", +" . . . = - ; > , { { { ( . . . . . . ", +" . _ . : - ; > < { { { [ } | 1 1 1 . ", +". . . . . . 2 3 . 4 5 6 < { { { [ 7 8 9 0 0 . ", +". a 2 2 2 2 b c d . e 6 < { { { [ f g h i i . ", +". j c c c c c c c 3 . k < { l { [ m n o p p . ", +". j c c c c c c c c 3 . q { l r [ n s t u u . ", +". v w w w w w w w w w x . y r { [ z A B C C . ", +". v w w w w w w w w D . E { { { [ F G H I I . ", +". v w w w w w w w J . K < { { { [ C L M N N . ", +". O P P P P Q w J . R 6 < { { { [ S T U V V . ", +". . . . . . Q J . W 5 6 < { { { [ X H Y Z ` . ", +" . .. ..- 5 6 < { { { [ +.@.#.$.%.. ", +" . . . = - 5 6 < { ] &.*.B =.Z -.;.. ", +" . . = - 5 6 >.&.,.'.).!.~.{.].^.. ", +" . /.(._.:.<.[.}.Z |.1.2.3.4.4.. ", +" . 5.k 6.7.Z -.8.9.0.a.a.b.b.b.. ", +" . c.d.e.^.f.g.h.i.i.i.i.i.i.i.. ", +" . . . . . . . . . . . . . . . . ", +" "}; diff --git a/etc/images/gnus/mail_send.xpm b/etc/images/gnus/mail_send.xpm new file mode 100644 index 0000000..f1d2282 --- /dev/null +++ b/etc/images/gnus/mail_send.xpm @@ -0,0 +1,39 @@ +/* XPM */ +static char *magick[] = { +/* columns rows colors chars-per-pixel */ +"24 24 9 1", +" c Gray0", +". c #675e6580613e", +"X c #8c8c7c7c6969", +"o c #9b458d377822", +"O c #a941a6459f3e", +"+ c #c8c8b2b29898", +"@ c #dadac2c2a5a5", +"# c #eb4dea2fe4ad", +"$ c None", +/* pixels */ +"$$$$$$$$$$$$$$$$$$$$$$$$", +"$$$$$$$$$$$$$$$$$$$$$$$$", +"$$$$$$$$$$$$$ $$$$$$$", +"$$$$$$$$ .@#+ $$$$$$", +"$$$ .+#####@O $$$$$$", +"$$ .+##########.+O $$$$$", +"$$ @..########O.+# $$$$$", +"$$ O@O..@#####.+## $$$$$", +"$$$ ###+O.O##...##O $$$$", +"$$$ @####@+..O#O.+# $$$$", +"$$$ O####.#######.O $$$$", +"$$$$ ###+O########.O $$$", +"$$$$ ###.########@O $$$", +"$$$$ +#+O#####@O $$$$$", +"$$$$$ #.###@O $$$$$$", +"$$$$$ .O@O $$ .. $$$$$", +"$$$$$ .. $$$$ .oo. $$$$", +"$$$$$$ $$$$$ oo $$$", +"$$$$$$$$$$$$$$$ Oo $$$$$", +"$$$$$$$$$$$$$$ oOOX $$$$", +"$$$$$$$$$$$$$$ ++++ $$$$", +"$$$$$$$$$$$$$ O@@@@O $$$", +"$$$$$$$$$$$$$ $$$", +"$$$$$$$$$$$$$$$$$$$$$$$$" +}; diff --git a/etc/images/gnus/toggle-subscription.xpm b/etc/images/gnus/toggle-subscription.xpm new file mode 100644 index 0000000..c067468 --- /dev/null +++ b/etc/images/gnus/toggle-subscription.xpm @@ -0,0 +1,58 @@ +/* XPM */ +static char * stock_task_recurring_xpm[] = { +"24 24 31 1", +" c None", +". c #000000", +"+ c #FFFFFF", +"@ c #F4E2BC", +"# c #F4D597", +"$ c #434343", +"% c #F0CC84", +"& c #EBB13D", +"* c #4B4B4B", +"= c #535353", +"- c #C8C8C8", +"; c #7D7D7D", +"> c #7C7C7C", +", c #858585", +"' c #5C5C5C", +") c #949494", +"! c #F2F2F2", +"~ c #B6B6B6", +"{ c #BDBDBD", +"] c #818181", +"^ c #878787", +"/ c #B2B2B2", +"( c #FDFDFD", +"_ c #DBDBDB", +": c #CCCCCC", +"< c #ECECEC", +"[ c #7F7F99", +"} c #333366", +"| c #8F8FA9", +"1 c #59597F", +"2 c #EEEEEE", +" ", +" . . . . . . . ", +" .+.+.+.+.+.+.+. ", +" .@.#.#.#.#.#.#. ", +" .$%$&*&*&=&=&$&*. ", +" .-*;*>*>*>*>=,'). ", +" .!>~>{]{]{]{]{^/. ", +" .(_:::::::::::_/. ", +" .+<<<<<<<<<<<< c #F2F0EC", +", c #E1DFDC", +"' c #AFADAA", +") c #272726", +"! c #020202", +"~ c #3F3E3E", +"{ c #36302D", +"] c #181818", +"^ c #FBF8F5", +"/ c #FEFCF8", +"( c #FAF8F5", +"_ c #F5F4F1", +": c #F2F1ED", +"< c #F1EFEB", +"[ c #F1EEEB", +"} c #EAE9E6", +"| c #DAD8D4", +"1 c #100E0E", +"2 c #1F100E", +"3 c #AF3A1E", +"4 c #FBAB93", +"5 c #FAE9E3", +"6 c #F0EFEB", +"7 c #E9E8E5", +"8 c #EAE8E6", +"9 c #ECEAE8", +"0 c #EDEBE9", +"a c #EDEBE8", +"b c #EACFC6", +"c c #D5340A", +"d c #751904", +"e c #100806", +"f c #34160D", +"g c #AF3C20", +"h c #FCCCBD", +"i c #F7BEAD", +"j c #E67554", +"k c #DFDDDB", +"l c #DBD9D6", +"m c #D8D7D3", +"n c #DBDAD6", +"o c #E3E2DE", +"p c #ECEBE8", +"q c #E5572D", +"r c #E33A0B", +"s c #D4340A", +"t c #691504", +"u c #100504", +"v c #582C22", +"w c #0F0F0F", +"x c #FDD4C8", +"y c #F7BFAF", +"z c #E87554", +"A c #D5512B", +"B c #C68270", +"C c #BEBDBA", +"D c #A5A3A0", +"E c #9C9A95", +"F c #B9B7B2", +"G c #D7D6D2", +"H c #E7E5E2", +"I c #E79A85", +"J c #E53C0B", +"K c #E43C0B", +"L c #E23A0B", +"M c #C93009", +"N c #010000", +"O c #040100", +"P c #FAB19C", +"Q c #FACCBE", +"R c #EB8264", +"S c #D8532D", +"T c #C0340F", +"U c #932006", +"V c #141412", +"W c #857974", +"X c #DA370B", +"Y c #EC7C5B", +"Z c #E95B32", +"` c #DE380B", +" . c #9D2306", +".. c #626261", +"+. c #FEF1ED", +"@. c #F09479", +"#. c #DC532B", +"$. c #C0350F", +"%. c #942006", +"&. c #621404", +"*. c #E2522B", +"=. c #F2A690", +"-. c #E74E21", +";. c #E23B0B", +">. c #C99181", +",. c #454342", +"'. c #E5E4E2", +"). c #FCFBFA", +"!. c #E2D8D3", +"~. c #C34C2A", +"{. c #B02B07", +"]. c #9E2D12", +"^. c #EF8D71", +"/. c #F09B83", +"(. c #EADDD7", +"_. c #272724", +":. c #F0EEEC", +"<. c #F3F2EF", +"[. c #D7D6D3", +"}. c #BFBEBB", +"|. c #9E6153", +"1. c #3F0D02", +"2. c #F0B9A9", +"3. c #F6F5F4", +"4. c #E8E7E4", +"5. c #DAD8D5", +"6. c #585652", +"7. c #F6F4F0", +"8. c #DAD8D6", +"9. c #C2C1BE", +"0. c #989691", +"a. c #0A0A08", +"b. c #F6F4F2", +"c. c #F4F3F1", +"d. c #E4E3E0", +"e. c #D3D2CE", +"f. c #63625D", +"g. c #DCDAD8", +"h. c #C7C6C2", +"i. c #ABAAA5", +"j. c #0A0A0A", +"k. c #FAF8F6", +"l. c #EFEDEA", +"m. c #DDDCD8", +"n. c #C6C4C2", +"o. c #3E3E39", +"p. c #1B1B19", +"q. c #F0EEEA", +"r. c #E0DFDD", +"s. c #CCCBC9", +"t. c #C0BFBB", +"u. c #131311", +"v. c #676663", +"w. c #FCFAF8", +"x. c #D6D4D2", +"y. c #BCBAB7", +"z. c #3C3C3A", +"A. c #DEDCD9", +"B. c #7E4B3E", +"C. c #232323", +"D. c #CC9385", +"E. c #FAFAF7", +"F. c #E6E6E2", +"G. c #CDCCCA", +"H. c #B0B0AC", +"I. c #EDE3DF", +"J. c #E78468", +"K. c #DF5D3A", +"L. c #631909", +"M. c #282828", +"N. c #B46E5E", +"O. c #FCC3B2", +"P. c #F1A691", +"Q. c #DCD2CC", +"R. c #C8C6C3", +"S. c #7E7C78", +"T. c #E8AD9C", +"U. c #E96139", +"V. c #EB7452", +"W. c #EF8E72", +"X. c #EA8063", +"Y. c #9E2E13", +"Z. c #3F1811", +"`. c #121212", +" + c #6B433B", +".+ c #E0A191", +"++ c #FDD3C7", +"@+ c #F4AD98", +"#+ c #DE532B", +"$+ c #C83409", +"%+ c #B48274", +"&+ c #383534", +"*+ c #D6340A", +"=+ c #E43D0F", +"-+ c #E8582E", +";+ c #ED7957", +">+ c #F4B6A4", +",+ c #F4B09D", +"'+ c #F0E5E0", +")+ c #F4F3EF", +"!+ c #FDF8F6", +"~+ c #FBCEC1", +"{+ c #F28B6E", +"]+ c #E44E23", +"^+ c #D3370A", +"/+ c #BF2F09", +"(+ c #260800", +"_+ c #190F0B", +":+ c #D5350A", +"<+ c #E43D0C", +"[+ c #E74C1F", +"}+ c #EFBBAB", +"|+ c #F5F4F3", +"1+ c #F5F3F1", +"2+ c #EAB1A0", +"3+ c #DE4316", +"4+ c #C5310A", +"5+ c #591202", +"6+ c #0E0504", +"7+ c #C83009", +"8+ c #E0532B", +"9+ c #E7E6E3", +"0+ c #E7E6E2", +"a+ c #DDDCD9", +"b+ c #CFCECA", +"c+ c #C14724", +"d+ c #AE2907", +"e+ c #290800", +"f+ c #0F0705", +"g+ c #9B2205", +"h+ c #C1A89F", +"i+ c #D1D0CC", +"j+ c #CFCDCA", +"k+ c #C7C6C3", +"l+ c #BBBAB7", +"m+ c #B5B4B1", +"n+ c #A7A6A2", +"o+ c #66564F", +"p+ c #0B0908", +"q+ c #010100", +"r+ c #222221", +"s+ c #51504B", +"t+ c #5D5C57", +"u+ c #3B3B37", +" . . + @ # # $ % ", +" . . . . & # * = - ; > , ' ) ! ~ . . . . ", +". . { ] ^ / ( _ : > < [ } | . 1 . . ", +" . 2 3 4 5 6 - 7 8 9 0 0 a b c d e . ", +" . f g h i j k l m n o } p a q r s t u . . ", +" v w x y z A B C D E F G H I J K L M . N ", +" O P Q R S T U . . . . V W X Y Z K ` .. ", +" ..+.@.#.$.%.. . . &.*.=.-.;.>.! . ", +",.'.).!.~.{.. . . ].^./.(.n _.. ", +"@ :.<.[.}.|.. 1.2.3.4.5.6.. ", +"# 7.6 8.9.0.. a.b.c.d.e.f.. ", +"# > < g.h.i.. j.k.l.m.n.o.. ", +"p., q.r.s.t.u. v.w.9 x.y.. . ", +"z.' [ 7 A.[.B.. C.D.E.F.G.H.. . ", +" ) } 0 I.J.K.L.. M.N.O.P.Q.R.S.. . ", +" ! | T.U.V.W.X.Y.Z.a.`. +.+++@+#+$+%+. . ", +" &+. *+=+-+;+>+,+'+)+k.!+~+{+]+^+/+(+. . ", +" . _+d :+L <+[+}+|+l.1+|+2+3+^+4+5+. . . ", +" . 6+t 7+` 8+9+0+o a+[.b+c+d+e+. . . ", +" . f+. g+h+i+j+k+l+m+n+o+. . . . ", +" . . . p+. q+r+s+t+u+. . . . . . . ", +" . . . . . . . . . . . . ", +" ", +" "}; diff --git a/etc/images/home.xpm b/etc/images/home.xpm new file mode 100644 index 0000000..57e8f9c --- /dev/null +++ b/etc/images/home.xpm @@ -0,0 +1,128 @@ +/* XPM */ +static char * home_xpm[] = { +"24 24 101 2", +" c None", +". c #000000", +"+ c #212121", +"@ c #2C2C2C", +"# c #C1665A", +"$ c #924B37", +"% c #2A2A2A", +"& c #333333", +"* c #343434", +"= c #242424", +"- c #944D3A", +"; c #A05443", +"> c #181818", +", c #474747", +"' c #555555", +") c #8D8D8D", +"! c #383838", +"~ c #191919", +"{ c #974F3C", +"] c #222222", +"^ c #313131", +"/ c #A1A1A1", +"( c #676767", +"_ c #ACACAC", +": c #BCBCBC", +"< c #585858", +"[ c #141414", +"} c #1C1C1C", +"| c #464646", +"1 c #666666", +"2 c #BABABA", +"3 c #7E7E7E", +"4 c #D2D2D2", +"5 c #FFFFFF", +"6 c #4F4F4F", +"7 c #262626", +"8 c #232323", +"9 c #505050", +"0 c #B2B2B2", +"a c #909090", +"b c #9A9A9A", +"c c #838383", +"d c #171717", +"e c #202020", +"f c #717171", +"g c #A6A6A6", +"h c #616161", +"i c #1D1D1D", +"j c #1F1F1F", +"k c #C4C4C4", +"l c #CACACA", +"m c #AEAEAE", +"n c #D1D1D1", +"o c #7C7C7C", +"p c #BFBFBF", +"q c #6C6C6C", +"r c #EEEEEE", +"s c #949494", +"t c #C7C7C7", +"u c #EBEBEB", +"v c #7D7D7D", +"w c #6E6E6E", +"x c #A9A9A9", +"y c #E99E8F", +"z c #DD806D", +"A c #9B5343", +"B c #CECECE", +"C c #626262", +"D c #858585", +"E c #ECA292", +"F c #D0533A", +"G c #934F3E", +"H c #6D6D6D", +"I c #ECA291", +"J c #CF543C", +"K c #371D16", +"L c #5D5D5D", +"M c #868686", +"N c #787878", +"O c #ECA696", +"P c #C95C49", +"Q c #E17C66", +"R c #924E3D", +"S c #888888", +"T c #A0A0A0", +"U c #3D1208", +"V c #D15137", +"W c #919191", +"X c #879981", +"Y c #82947C", +"Z c #8A9B85", +"` c #6E8467", +" . c #5D7555", +".. c #4C6042", +"+. c #3F4F37", +"@. c #303D2A", +"#. c #7F8F7A", +"$. c #64785E", +"%. c #44563E", +"&. c #657460", +"*. c #40503A", +" ", +" . . ", +" . . . . . + @ . ", +" . # $ . . % & * = . ", +" . - ; . > , ' ) ! ~ . ", +" . { . ] ^ / ( _ : < [ . ", +" . . } | 1 2 3 4 : 5 6 7 . ", +" . 8 9 0 a 4 b 5 : 5 : c d . ", +" . e f g 4 b 5 : 5 : 5 : 5 h i . ", +" . j k k l 5 m 5 2 5 2 5 : 5 n o } . ", +" . 8 m p p p p p p p p . . . . . a q = . ", +" . . . . r 5 5 5 5 5 5 5 . s t u . v . . . . ", +" . 4 5 . . . . . 5 . : 5 5 . w . ", +" . x 5 . y z A . 5 . B 5 5 . C . ", +" . D 5 . E F G . 5 . . . . . H . ", +" . . 5 . I J K . k s L L M N . . ", +" . . r . O P G . 5 5 5 5 5 2 . ", +" . 2 . Q # R . : : : : : S . ", +" . T U V # A . 5 5 5 5 5 W . ", +" . . . . . . . . . . . . . . . . . . . . . ", +" } X Y Z X ` ...+.@.. Y #.$.%.&.*.. ", +" . . . . . . . . . . . . . . . . . ", +" . . . ", +" "}; diff --git a/etc/images/index.xpm b/etc/images/index.xpm new file mode 100644 index 0000000..7e1de12 --- /dev/null +++ b/etc/images/index.xpm @@ -0,0 +1,201 @@ +/* XPM */ +static char * index_xpm[] = { +"24 24 174 2", +" c None", +". c #000000", +"+ c #FDFDFD", +"@ c #F5F5F5", +"# c #F6F6F6", +"$ c #D0D0D0", +"% c #C1C1C1", +"& c #C3C3C3", +"* c #C6C6C6", +"= c #C8C8C8", +"- c #8D8D8D", +"; c #CACACA", +"> c #919191", +", c #EFEFEF", +"' c #878787", +") c #8A8A8A", +"! c #5C5C5C", +"~ c #F8F8F8", +"{ c #EAEAEA", +"] c #CCCCCC", +"^ c #CECECE", +"/ c #979797", +"( c #CDCDCD", +"_ c #A1A1A1", +": c #090600", +"< c #A3A3A3", +"[ c #C5C5C5", +"} c #C4C4C4", +"| c #D1D1D1", +"1 c #D2D2D1", +"2 c #D2D2D2", +"3 c #9A9A9A", +"4 c #E8E8E8", +"5 c #949494", +"6 c #939393", +"7 c #574F4F", +"8 c #FDFDFC", +"9 c #777777", +"0 c #7E7E7E", +"a c #9D9D9D", +"b c #6B6B6B", +"c c #F1F1F1", +"d c #ECECEC", +"e c #CFCFCF", +"f c #575050", +"g c #FDFAF8", +"h c #A5A5A5", +"i c #B9B9B9", +"j c #EEEEEE", +"k c #EDEDED", +"l c #D5D5D5", +"m c #BABABA", +"n c #6D6767", +"o c #F9F1EA", +"p c #9E9E9E", +"q c #B5B5B5", +"r c #D9D9D9", +"s c #D7D7D7", +"t c #BCBCBC", +"u c #625C5B", +"v c #F9EEE4", +"w c #4F4D4A", +"x c #646464", +"y c #747474", +"z c #D6D6D5", +"A c #DFDFDF", +"B c #A0A0A0", +"C c #615C5B", +"D c #F9F0E4", +"E c #746C67", +"F c #FEFDFC", +"G c #FFFEFD", +"H c #131210", +"I c #636363", +"J c #7C7C7C", +"K c #F3F2F2", +"L c #98948F", +"M c #F9EFE3", +"N c #A09489", +"O c #FEFDFD", +"P c #766D68", +"Q c #736961", +"R c #A3A3A2", +"S c #A6A6A6", +"T c #DBDBDB", +"U c #C7C7C7", +"V c #E8E5E2", +"W c #97938E", +"X c #F6E9D8", +"Y c #84817A", +"Z c #FBF3EA", +"` c #908C86", +" . c #F1EDE7", +".. c #7B7975", +"+. c #878786", +"@. c #070000", +"#. c #FAFAFA", +"$. c #DDDDDD", +"%. c #E2DFDC", +"&. c #A8A199", +"*. c #F0E0CE", +"=. c #C8BFB4", +"-. c #D5CCBF", +";. c #DFD7CD", +">. c #DAD3C9", +",. c #DDCFC4", +"'. c #928C84", +"). c #A8A8A8", +"!. c #959595", +"~. c #040000", +"{. c #D9D5D2", +"]. c #D9CABB", +"^. c #D7C8B8", +"/. c #DECFBF", +"(. c #D8C9B9", +"_. c #E3D3C2", +":. c #C9BBAC", +"<. c #D9CEC2", +"[. c #7F766D", +"}. c #909090", +"|. c #D3D3D3", +"1. c #060100", +"2. c #C0BDBA", +"3. c #8C8782", +"4. c #C2B5A7", +"5. c #BFB4A6", +"6. c #B8AB9D", +"7. c #BAAD9E", +"8. c #BEB0A2", +"9. c #948A7F", +"0. c #716860", +"a. c #E2E2E2", +"b. c #A9A9A8", +"c. c #332C2B", +"d. c #5D5954", +"e. c #79736C", +"f. c #958C80", +"g. c #8D8379", +"h. c #988D82", +"i. c #706760", +"j. c #787878", +"k. c #E4E4E4", +"l. c #C2C2C2", +"m. c #201A1A", +"n. c #57514F", +"o. c #625C59", +"p. c #625A53", +"q. c #6B625A", +"r. c #585251", +"s. c #696764", +"t. c #080000", +"u. c #989898", +"v. c #B0B0B0", +"w. c #AFAFAF", +"x. c #999999", +"y. c #9D9897", +"z. c #050000", +"A. c #0C0303", +"B. c #080100", +"C. c #030000", +"D. c #282523", +"E. c #5A5A5A", +"F. c #868686", +"G. c #ECE4E2", +"H. c #DED7D5", +"I. c #D8D1D0", +"J. c #E0DBD7", +"K. c #E9E6E3", +"L. c #FCFBFA", +"M. c #030500", +"N. c #0B0505", +"O. c #14100F", +"P. c #090806", +"Q. c #000100", +" ", +" . . . . . . . . . . . . . . . . . . . . ", +" . + @ @ @ @ @ @ @ # # # # # # # # # $ . ", +" . @ % % % & & & & * * * * * = = = = - . ", +" . # & & & * * * * = = = = = ; ; ; ; > . ", +" . , ' ' ' ) ) ) ) - - - - - > > > > ! . ", +" . ~ { { { { { { { { { { { { { { { { ; . ", +" . # ; ; ; ] ] ] ] ] ^ ^ ^ ^ $ $ $ $ / . ", +" . # ] ] ] ( ^ ^ ^ _ : < [ } | 1 | 2 3 . ", +" . 4 5 5 5 / / / 6 7 8 . 9 0 - a a a b . ", +" . ~ c d d d d d e f g . h i $ j j k * . ", +" . ~ 2 2 2 2 l l m n o . > p q r r r < . ", +" . ~ l l l l s s t u v w . x . y p z < . ", +" . A B B B B < 9 . C D E F . G H . I J . ", +" . ~ @ , , , j . K L M N O P F Q R . S . ", +" . ~ T T T T U . V W X Y Z ` ...+.@.< . ", +" . #.$.$.$.$.& . %.&.*.=.-.;.>.,.'.@.p . ", +" . { ).).).).!.~.{.].^./.(._.:.<.[.@.}.. ", +" . #.@ c c c |.1.2.3.4.5.6.7.8.9.0.@.] . ", +" . #.a.a.a.a.l b.c.d.e.f.g.9.h.i.. j.q . ", +" . #.a.a.a.a.k.l.j.m.n.o.p.q.r.s.t.u.q . ", +" . a.v.v.v.v.v.w.x.y.z.A.t.B.C.D.E.F.m . ", +" . . . . . . . . . ~.G.H.I.J.K.L.M.. . . ", +" ~.N.z.O.C.P.. Q. "}; diff --git a/etc/images/jump-to.xpm b/etc/images/jump-to.xpm new file mode 100644 index 0000000..8f98979 --- /dev/null +++ b/etc/images/jump-to.xpm @@ -0,0 +1,171 @@ +/* XPM */ +static char * jump_to_xpm[] = { +"24 24 144 2", +" c None", +". c #000000", +"+ c #9ABC82", +"@ c #C1E3AA", +"# c #A0C487", +"$ c #8F6508", +"% c #AD671D", +"& c #D6AF41", +"* c #E1B744", +"= c #B86F20", +"- c #7E5907", +"; c #D8E7CD", +"> c #D9E7CF", +", c #DDEAD2", +"' c #E4EFDA", +") c #EBF6DF", +"! c #C8EBB0", +"~ c #A2C688", +"{ c #986F26", +"] c #E2B946", +"^ c #EFCD64", +"/ c #F4D268", +"( c #F6D469", +"_ c #E7C24A", +": c #D5B044", +"< c #BC8C31", +"[ c #1A0700", +"} c #D7E6CD", +"| c #B2D29C", +"1 c #B6D69F", +"2 c #BDDEA5", +"3 c #C4E7AC", +"4 c #CAEEB1", +"5 c #A1C387", +"6 c #CBB86E", +"7 c #EDD97E", +"8 c #FEE882", +"9 c #FEE77E", +"0 c #FDDF60", +"a c #FBD14F", +"b c #E4BF49", +"c c #BB8C31", +"d c #CFE2C3", +"e c #B2D19C", +"f c #B5D59F", +"g c #BBDBA4", +"h c #C1E3A9", +"i c #C6E9AE", +"j c #C3E6AB", +"k c #A9CE8D", +"l c #DCBA5C", +"m c #FBE46B", +"n c #FFEB64", +"o c #FFE054", +"p c #FED952", +"q c #F8CF4E", +"r c #C4A13E", +"s c #8BA27B", +"t c #618249", +"u c #628349", +"v c #64864B", +"w c #66894D", +"x c #688B4E", +"y c #678B4D", +"z c #6B9251", +"A c #719755", +"B c #55833A", +"C c #ECC75E", +"D c #FFED59", +"E c #FFE757", +"F c #FFDF54", +"G c #FBD44F", +"H c #E1BD48", +"I c #B36C1F", +"J c #608148", +"K c #628449", +"L c #63854A", +"M c #65894C", +"N c #6C9151", +"O c #527E39", +"P c #B39237", +"Q c #F0C248", +"R c #FFF25B", +"S c #FFEB58", +"T c #FFE155", +"U c #FBD450", +"V c #E3BD49", +"W c #BC983B", +"X c #618349", +"Y c #628549", +"Z c #65884B", +"` c #4D7735", +" . c #907934", +".. c #DCB444", +"+. c #FCDB52", +"@. c #FFEF5A", +"#. c #FFE957", +"$. c #FEDF54", +"%. c #F9D24F", +"&. c #E0BA48", +"*. c #B08F37", +"=. c #52743B", +"-. c #456A2F", +";. c #608248", +">. c #628448", +",. c #476F31", +"'. c #7F6B32", +"). c #D0AF4B", +"!. c #F5CF4E", +"~. c #FFE255", +"{. c #FEDA52", +"]. c #EAC54B", +"^. c #D0AC42", +"/. c #9C5D1A", +"(. c #5A7B42", +"_. c #456C2F", +":. c #6F5C23", +"<. c #A78833", +"[. c #F0C54A", +"}. c #FFDA52", +"|. c #FFDE53", +"1. c #C39032", +"2. c #886423", +"3. c #BC9D3B", +"4. c #F0C84E", +"5. c #FFD551", +"6. c #FED751", +"7. c #FDD550", +"8. c #EDC74C", +"9. c #E5BF49", +"0. c #CCA941", +"a. c #AB7727", +"b. c #B1822D", +"c. c #DCB746", +"d. c #DFBA47", +"e. c #EDC64C", +"f. c #E9C34B", +"g. c #D6B144", +"h. c #C19D3D", +"i. c #AB7C2B", +"j. c #BC7222", +"k. c #BB983B", +"l. c #B09638", +"m. c #A2621B", +" ", +" ", +" . ", +" . . ", +" . + . . . . . . . ", +" . . . . . . @ # . . $ % & * = - . . ", +" . ; > , ' ) ! ! ~ . { ] ^ / ( _ : < [ . ", +" . } | 1 2 3 4 4 3 5 . 6 7 8 9 0 a b c . ", +" . d e f g h i i h j k . l m n o p q r - . ", +" . s t u v w x x y z A B . C D E F G H I . ", +" . s J t K L v v M N O . P Q R S T U V W . ", +" . s J J t X u Y Z ` . ...+.@.#.$.%.&.*.. ", +" . =.-.-.-.-.;.>.,.. '.).!.E E ~.{.].^./.. ", +" . . . . . . (._.. :.<.[.}.|.|.{.%.V 1.$ . ", +" . -.. . 2.3.4.5.6.7.8.9.0.a.. ", +" . . . . b.c.d.e.f.g.h.i.. . ", +" . . $ j.k.l.m.$ . . ", +" . . . . . . ", +" ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/left-arrow.xpm b/etc/images/left-arrow.xpm new file mode 100644 index 0000000..586fe44 --- /dev/null +++ b/etc/images/left-arrow.xpm @@ -0,0 +1,70 @@ +/* XPM */ +static char * left_arrow_xpm[] = { +"24 24 43 1", +" c None", +". c #000000", +"+ c #B9D0B9", +"@ c #CDDECB", +"# c #B6C7B6", +"$ c #B1C9B0", +"% c #B3C4B3", +"& c #B4CBB2", +"* c #B5CEB5", +"= c #B7CCB5", +"- c #B9CEB7", +"; c #BAD1BA", +"> c #BBCFBA", +", c #BBD0B9", +"' c #B2C9B0", +") c #7EAB78", +"! c #AAC7A8", +"~ c #B3CAB1", +"{ c #B0C9B0", +"] c #B0C9AE", +"^ c #AEC7AC", +"/ c #AAC5A8", +"( c #A9C4A7", +"_ c #698267", +": c #2D2D2D", +"< c #CFDFCC", +"[ c #ADC8AB", +"} c #B0C7AE", +"| c #ADC6AB", +"1 c #678C63", +"2 c #9BAD9A", +"3 c #85AE81", +"4 c #87AF84", +"5 c #87B083", +"6 c #88AF84", +"7 c #88B085", +"8 c #86AF82", +"9 c #547150", +"0 c #3C5235", +"a c #5B7950", +"b c #4A6342", +"c c #3B5035", +"d c #415639", +" ", +" ", +" ", +" . ", +" .. ", +" .+. ", +" .@#. ", +" .@$%........ ", +" .@&*=-;->,'). ", +" .@!~{]^///^(_. ", +" :<[}||[!^^}^[1. ", +" .23444445645789. ", +" .0aaaaaaaaaaab. ", +" .0aaaaaaaaaab. ", +" .0aabccccccd. ", +" .0ab........ ", +" .0b. ", +" .b. ", +" .. ", +" . ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/lock-broken.xpm b/etc/images/lock-broken.xpm new file mode 100644 index 0000000..15676bd --- /dev/null +++ b/etc/images/lock-broken.xpm @@ -0,0 +1,231 @@ +/* XPM */ +static char * stock_lock_broken_xpm[] = { +"24 24 204 2", +" c None", +". c #0E0E0E", +"+ c #262626", +"@ c #464646", +"# c #3C3C3C", +"$ c #3B3B3B", +"% c #212121", +"& c #252525", +"* c #ADADAD", +"= c #F0F0F0", +"- c #EAEAEA", +"; c #1A1A1A", +"> c #000000", +", c #FAFAFA", +"' c #F4F4F4", +") c #4D4D4D", +"! c #303030", +"~ c #D8D8D8", +"{ c #E5E5E5", +"] c #B0B0B0", +"^ c #414141", +"/ c #484848", +"( c #030303", +"_ c #DADADA", +": c #E4E4E4", +"< c #353535", +"[ c #070707", +"} c #A6A6A6", +"| c #E6E6E6", +"1 c #686868", +"2 c #020202", +"3 c #3E3E3E", +"4 c #EFEFEF", +"5 c #9B9B9B", +"6 c #343434", +"7 c #F8F8F8", +"8 c #999999", +"9 c #F1F1F1", +"0 c #C4C4C4", +"a c #232323", +"b c #535353", +"c c #AEAEAE", +"d c #F3F3F3", +"e c #D3D3D3", +"f c #242424", +"g c #4E4E4E", +"h c #EEEEEE", +"i c #B5B5B5", +"j c #0F0601", +"k c #200E03", +"l c #765E49", +"m c #7D6A56", +"n c #38291D", +"o c #180A03", +"p c #D6CBC1", +"q c #A09E9D", +"r c #1D1109", +"s c #2A1E13", +"t c #3D2E21", +"u c #3F3123", +"v c #47423D", +"w c #DBB98E", +"x c #D6B183", +"y c #D3AC7E", +"z c #CFA573", +"A c #CD9E67", +"B c #C39056", +"C c #46270A", +"D c #281F14", +"E c #675643", +"F c #A48367", +"G c #D8AB7C", +"H c #BF9E7C", +"I c #DCBB93", +"J c #DCB786", +"K c #D1A872", +"L c #231B12", +"M c #7B6C58", +"N c #C69B63", +"O c #C39860", +"P c #C09257", +"Q c #BD8A4A", +"R c #B9803D", +"S c #AA6E28", +"T c #412409", +"U c #100B07", +"V c #CDB598", +"W c #E8CCA9", +"X c #DAB587", +"Y c #D4AC7D", +"Z c #D1A775", +"` c #C99F6A", +" . c #AF8B5B", +".. c #2E2517", +"+. c #1E1910", +"@. c #0B0805", +"#. c #594B39", +"$. c #2A2015", +"%. c #C2975E", +"&. c #BE8D50", +"*. c #BB823F", +"=. c #AE722C", +"-. c #422409", +";. c #0E0B07", +">. c #AB957E", +",. c #E9CEAC", +"'. c #DBB68A", +"). c #D5AD7E", +"!. c #D0A975", +"~. c #C9A26F", +"{. c #B99667", +"]. c #AA895F", +"^. c #31291C", +"/. c #322A1C", +"(. c #54493B", +"_. c #C69C64", +":. c #C2965E", +"<. c #BE8E50", +"[. c #C29156", +"}. c #9E692A", +"|. c #1A150D", +"1. c #887762", +"2. c #EAD1AF", +"3. c #DDB98E", +"4. c #D4AC7E", +"5. c #D2A876", +"6. c #C39E6D", +"7. c #927751", +"8. c #15110C", +"9. c #988468", +"0. c #C2945A", +"a. c #BE8F51", +"b. c #BC8544", +"c. c #BE8A4F", +"d. c #9A6526", +"e. c #70604D", +"f. c #EFD6B5", +"g. c #DEBD93", +"h. c #D4AC7C", +"i. c #D0A672", +"j. c #C9A069", +"k. c #9D7E53", +"l. c #140F09", +"m. c #1F1710", +"n. c #EFD8B9", +"o. c #E3C39C", +"p. c #D7B080", +"q. c #D4AC79", +"r. c #CDA46F", +"s. c #3A2C1B", +"t. c #FFFFFF", +"u. c #1C160D", +"v. c #B29E85", +"w. c #E6C8A3", +"x. c #D7B081", +"y. c #D1A874", +"z. c #CBA16A", +"A. c #BA905A", +"B. c #251C10", +"C. c #DF421E", +"D. c #F7F7F7", +"E. c #DFDFDF", +"F. c #2F2619", +"G. c #92806A", +"H. c #E6C7A2", +"I. c #D6AF7E", +"J. c #CCA26C", +"K. c #53422A", +"L. c #211910", +"M. c #2A2014", +"N. c #E1E1E1", +"O. c #6A5C4A", +"P. c #EAD0AD", +"Q. c #DAB68B", +"R. c #D2A978", +"S. c #CEA56E", +"T. c #C89D66", +"U. c #856740", +"V. c #534026", +"W. c #F9F9F9", +"X. c #FBFBFB", +"Y. c #E2E2E2", +"Z. c #42362B", +"`. c #D1BA9B", +" + c #DCBA8E", +".+ c #D1A773", +"++ c #C4975C", +"@+ c #BE8C4C", +"#+ c #B4813F", +"$+ c #281B0B", +"%+ c #E3E3E3", +"&+ c #372416", +"*+ c #74654F", +"=+ c #B68E5C", +"-+ c #926231", +";+ c #452B11", +">+ c #341E09", +",+ c #221205", +"'+ c #150802", +")+ c #FDFDFD", +"!+ c #030000", +"~+ c #050000", +"{+ c #010000", +"]+ c #C3C3C3", +" ", +" ", +" . + @ # $ % ", +" & * = - ; > , ' ) > ", +" ! ~ { ] ^ / ( $ _ : < ", +" [ } | 1 2 3 4 5 > ", +" 6 7 8 > > 9 0 a ", +" b 9 c > > d e f ", +" g h i > j k l m n o ", +" ^ p q r s t u > v w x y z A B C ", +" D E F G H I J K L > M N O P Q R S T ", +" U V W X Y Z ` ...+. @.#.$.%.&.*.=.-. ", +" ;.>.,.'.).!.~.{.].^./. (._.:.<.[.}.-. ", +" |.1.2.3.4.5.6.7.8. > 9.0.a.b.c.d.T ", +" e.f.g.h.i.j.k.l.> > > > > > > > > > ", +" m.n.o.p.q.r._.s. > t.t.t.t.t.t.t.> ", +" u.v.w.x.y.z.A.B.> > t.C.C.D.C.C.E.> ", +" F.G.H.I.i.J.K.L.M. > t.C.C.C.C.C.N.> ", +" O.P.Q.R.S.T.U.V. > t.W.C.C.C.X.Y.> ", +" Z.`. +.+z.++@+#+$+> > t.C.C.C.C.C.%+> ", +" &+*+=+-+;+>+,+'+ > t.C.C.)+C.C.{ > ", +" !+~+{+> > - %+%+: { { ]+> ", +" > > > > > > > > > ", +" "}; diff --git a/etc/images/lock-ok.xpm b/etc/images/lock-ok.xpm new file mode 100644 index 0000000..630d9b4 --- /dev/null +++ b/etc/images/lock-ok.xpm @@ -0,0 +1,215 @@ +/* XPM */ +static char * stock_lock_ok_xpm[] = { +"24 24 188 2", +" c None", +". c #000000", +"+ c #212121", +"@ c #9E9E9E", +"# c #E6E6E6", +"$ c #E7E7E7", +"% c #C8C8C8", +"& c #A0A0A0", +"* c #131313", +"= c #5F5F5F", +"- c #EDEDED", +"; c #D6D6D6", +"> c #D5D5D5", +", c #DDDDDD", +"' c #D8D8D8", +") c #A1A1A1", +"! c #3C3C3C", +"~ c #353535", +"{ c #EFEFEF", +"] c #CFCFCF", +"^ c #4C4C4C", +"/ c #141414", +"( c #6A6A6A", +"_ c #D0D0D0", +": c #B2B2B2", +"< c #454545", +"[ c #E2E2E2", +"} c #292929", +"| c #0F0F0F", +"1 c #949494", +"2 c #E9E9E9", +"3 c #C3C3C3", +"4 c #1C1C1C", +"5 c #E1E1E1", +"6 c #272727", +"7 c #DEDEDE", +"8 c #B6B6B6", +"9 c #B7B6B6", +"0 c #150902", +"a c #2E2419", +"b c #251D15", +"c c #616160", +"d c #5E5A56", +"e c #29211A", +"f c #15100C", +"g c #2F251B", +"h c #1D1710", +"i c #4A392B", +"j c #656361", +"k c #565352", +"l c #392B1D", +"m c #322110", +"n c #0C0500", +"o c #EFDBBF", +"p c #EDD9C0", +"q c #E9D5BE", +"r c #E7D2B9", +"s c #E5D0B3", +"t c #DCC09D", +"u c #D9BE99", +"v c #DABE99", +"w c #D7BB95", +"x c #D5B68E", +"y c #D2AF85", +"z c #CFA77C", +"A c #9A5E1B", +"B c #F0DABF", +"C c #E4C6A0", +"D c #D6AF80", +"E c #D3AC7B", +"F c #D0A570", +"G c #C99F68", +"H c #C69B64", +"I c #C69C64", +"J c #C89D66", +"K c #C79C65", +"L c #C39860", +"M c #C09256", +"N c #BC8645", +"O c #B67C36", +"P c #985E1A", +"Q c #EED8BC", +"R c #E3C39C", +"S c #D3AA7B", +"T c #CFA670", +"U c #CA9F68", +"V c #C89E66", +"W c #C89F68", +"X c #C49961", +"Y c #C09358", +"Z c #BC8746", +"` c #B77D39", +" . c #EED8BB", +".. c #E2C29B", +"+. c #D6AE7F", +"@. c #CA9E6D", +"#. c #C69861", +"$. c #BF925A", +"%. c #BB8E56", +"&. c #BD8E56", +"*. c #5C7354", +"=. c #EFDABE", +"-. c #E4C49D", +";. c #D7B080", +">. c #DAB685", +",. c #D4B07C", +"'. c #D0A971", +"). c #CEA46B", +"!. c #CDA46D", +"~. c #FFFFFF", +"{. c #DBE0D9", +"]. c #52684B", +"^. c #4E6346", +"/. c #52674A", +"(. c #EFD8BB", +"_. c #E0C199", +":. c #D3AA7A", +"<. c #C89B67", +"[. c #C3965F", +"}. c #BC8E56", +"|. c #BA8B52", +"1. c #BA8C54", +"2. c #F6F6F6", +"3. c #F7F7F7", +"4. c #F8F8F8", +"5. c #E6E9E5", +"6. c #6B8064", +"7. c #4B5F45", +"8. c #44553D", +"9. c #E3C29C", +"0. c #D9B484", +"a. c #D4AE77", +"b. c #CFA770", +"c. c #CCA46B", +"d. c #CBA36B", +"e. c #B6BEB3", +"f. c #4E6047", +"g. c #788274", +"h. c #CBD2C9", +"i. c #6A8063", +"j. c #384834", +"k. c #EDD6B8", +"l. c #E1BD94", +"m. c #D1A874", +"n. c #BD9058", +"o. c #B7874E", +"p. c #B48349", +"q. c #B5844C", +"r. c #8F9C8A", +"s. c #53684B", +"t. c #475841", +"u. c #657C5E", +"v. c #4A5D44", +"w. c #626E5D", +"x. c #EED8BA", +"y. c #E0C099", +"z. c #D8B37F", +"A. c #D2AD76", +"B. c #CEA66F", +"C. c #CCA46D", +"D. c #FAFAFA", +"E. c #6A7E63", +"F. c #63715E", +"G. c #E3E3E3", +"H. c #EED5B7", +"I. c #DFC096", +"J. c #D2A776", +"K. c #CEA46E", +"L. c #C89D65", +"M. c #C49960", +"N. c #C1955C", +"O. c #C2955C", +"P. c #FBFBFB", +"Q. c #FCFCFC", +"R. c #80937A", +"S. c #6D796A", +"T. c #FEFEFE", +"U. c #E5E5E5", +"V. c #AC8C65", +"W. c #CFA772", +"X. c #C49256", +"Y. c #C08D51", +"Z. c #BA8849", +"`. c #B78342", +" + c #B48240", +".+ c #B68241", +"++ c #EAEAEA", +"@+ c #E4E4E4", +" ", +" ", +" . . . . . ", +" . + @ # $ % & * ", +" . = - # ; > , ' ) ! . ", +" ~ { ] ^ . . / ( _ : < ", +" . [ ' } . | ( % 1 . ", +" * 2 3 . 4 5 @ . ", +" 6 7 8 . . $ 9 . ", +" 0 a b c d e f g b h b i j k l m n ", +" . o p q r s t u u v u w x y z A . ", +" . B C D E F G H I J K L M N O P . ", +" . Q R D S T U I V W V X Y Z ` A . ", +" . ...+.@.#.$.%.&.. . . . . . . . . *. ", +" . =.-.;.>.,.'.).!.. ~.~.~.~.~.~.{.].^./.", +" . (._.:.<.[.}.|.1.. ~.2.3.3.4.5.6.7.8. ", +" . Q 9.+.0.a.b.c.d.. ~.e.f.g.h.i.7.j. ", +" . k.l.m.#.n.o.p.q.. ~.r.s.t.u.v.w.. ", +" . x.y.S z.A.B.c.C.. ~.D.E.s./.F.G.. ", +" . H.I.J.K.L.M.N.O.. ~.P.Q.R.S.T.U.. ", +" . V.W.X.Y.Z.`. +.+. ++G.G.@+U.U.3 . ", +" . . . . . . . . . . . . . . . . . ", +" ", +" "}; diff --git a/etc/images/lock.xpm b/etc/images/lock.xpm new file mode 100644 index 0000000..c9aa18d --- /dev/null +++ b/etc/images/lock.xpm @@ -0,0 +1,227 @@ +/* XPM */ +static char * stock_lock_xpm[] = { +"24 24 200 2", +" c None", +". c #000000", +"+ c #212121", +"@ c #9E9E9E", +"# c #E6E6E6", +"$ c #E7E7E7", +"% c #C8C8C8", +"& c #A0A0A0", +"* c #131313", +"= c #5F5F5F", +"- c #EDEDED", +"; c #D6D6D6", +"> c #D5D5D5", +", c #DDDDDD", +"' c #D8D8D8", +") c #A1A1A1", +"! c #3C3C3C", +"~ c #353535", +"{ c #EFEFEF", +"] c #CFCFCF", +"^ c #4C4C4C", +"/ c #141414", +"( c #6A6A6A", +"_ c #D0D0D0", +": c #B2B2B2", +"< c #454545", +"[ c #E2E2E2", +"} c #292929", +"| c #0F0F0F", +"1 c #949494", +"2 c #E9E9E9", +"3 c #C3C3C3", +"4 c #1C1C1C", +"5 c #E1E1E1", +"6 c #272727", +"7 c #DEDEDE", +"8 c #B6B6B6", +"9 c #B7B6B6", +"0 c #150902", +"a c #2E2419", +"b c #251D15", +"c c #616160", +"d c #5E5A56", +"e c #29211A", +"f c #15100C", +"g c #2F251B", +"h c #1D1710", +"i c #4A392B", +"j c #656361", +"k c #565352", +"l c #392B1D", +"m c #322110", +"n c #0C0500", +"o c #EFDBBF", +"p c #EDD9C0", +"q c #E9D5BE", +"r c #E7D2B9", +"s c #E5D0B3", +"t c #DCC09D", +"u c #D9BE99", +"v c #DABE99", +"w c #D7BB95", +"x c #D5B68E", +"y c #D2AF85", +"z c #CFA77C", +"A c #9A5E1B", +"B c #F0DABF", +"C c #E4C6A0", +"D c #D6AF80", +"E c #D3AC7B", +"F c #D0A570", +"G c #C99F68", +"H c #C69B64", +"I c #C69C64", +"J c #C89D66", +"K c #C79C65", +"L c #C39860", +"M c #C09256", +"N c #BC8645", +"O c #B67C36", +"P c #985E1A", +"Q c #EED8BC", +"R c #E3C39C", +"S c #D3AA7B", +"T c #CFA670", +"U c #CA9F68", +"V c #C89E66", +"W c #C89F68", +"X c #C49961", +"Y c #C09358", +"Z c #BC8746", +"` c #B77D39", +" . c #EED8BB", +".. c #E2C29B", +"+. c #D6AE7F", +"@. c #CA9E6D", +"#. c #C69861", +"$. c #BF925A", +"%. c #BB8E56", +"&. c #BD8E56", +"*. c #BD9058", +"=. c #BC8F58", +"-. c #B9884E", +";. c #B48145", +">. c #BA8442", +",. c #B47834", +"'. c #975C1A", +"). c #EFDABE", +"!. c #E4C49D", +"~. c #D7B080", +"{. c #DAB685", +"]. c #D4B07C", +"^. c #D0A971", +"/. c #CEA46B", +"(. c #CDA46D", +"_. c #CCA66D", +":. c #CCA46B", +"<. c #CA9F63", +"[. c #C79858", +"}. c #B9813F", +"|. c #B37834", +"1. c #975D1A", +"2. c #EFD8BB", +"3. c #E0C199", +"4. c #D3AA7A", +"5. c #C89B67", +"6. c #C3965F", +"7. c #BC8E56", +"8. c #BA8B52", +"9. c #BA8C54", +"0. c #BB8D55", +"a. c #BA8C55", +"b. c #B6864C", +"c. c #B47F43", +"d. c #BA833F", +"e. c #B37934", +"f. c #9B601E", +"g. c #E3C29C", +"h. c #D9B484", +"i. c #D4AE77", +"j. c #CFA770", +"k. c #CBA36B", +"l. c #CCA46C", +"m. c #CA9D61", +"n. c #C69856", +"o. c #BA813E", +"p. c #B27733", +"q. c #A36B2F", +"r. c #EDD6B8", +"s. c #E1BD94", +"t. c #D1A874", +"u. c #B7874E", +"v. c #B48349", +"w. c #B5844C", +"x. c #B5884D", +"y. c #B48146", +"z. c #B27A3C", +"A. c #B67D3A", +"B. c #B07530", +"C. c #A67137", +"D. c #EED8BA", +"E. c #E0C099", +"F. c #D8B37F", +"G. c #D2AD76", +"H. c #CEA66F", +"I. c #CCA46D", +"J. c #CCA56D", +"K. c #C99D61", +"L. c #C69858", +"M. c #B9803D", +"N. c #B67D38", +"O. c #AB783F", +"P. c #EED5B7", +"Q. c #DFC096", +"R. c #D2A776", +"S. c #CEA46E", +"T. c #C89D65", +"U. c #C49960", +"V. c #C1955C", +"W. c #C2955C", +"X. c #C2965C", +"Y. c #C09155", +"Z. c #BC8A4B", +"`. c #BE8A4C", +" + c #A9773C", +".+ c #AC8C65", +"++ c #CFA772", +"@+ c #C49256", +"#+ c #C08D51", +"$+ c #BA8849", +"%+ c #B78342", +"&+ c #B48240", +"*+ c #B68241", +"=+ c #B88544", +"-+ c #BB8949", +";+ c #BC8748", +">+ c #BA874A", +",+ c #B98548", +"'+ c #B27B3B", +")+ c #6D4215", +" ", +" ", +" . . . . . ", +" . + @ # $ % & * ", +" . = - # ; > , ' ) ! . ", +" ~ { ] ^ . . / ( _ : < ", +" . [ ' } . | ( % 1 . ", +" * 2 3 . 4 5 @ . ", +" 6 7 8 . . $ 9 . ", +" 0 a b c d e f g b h b i j k l m n ", +" . o p q r s t u u v u w x y z A . ", +" . B C D E F G H I J K L M N O P . ", +" . Q R D S T U I V W V X Y Z ` A . ", +" . ...+.@.#.$.%.&.*.=.-.;.>.,.'.. ", +" . ).!.~.{.].^./.(._.:.<.[.}.|.1.. ", +" . 2.3.4.5.6.7.8.9.0.a.b.c.d.e.f.. ", +" . Q g.+.h.i.j.:.k.l.k.m.n.o.p.q.. ", +" . r.s.t.#.*.u.v.w.x.b.y.z.A.B.C.. ", +" . D.E.S F.G.H.:.I.J.l.K.L.M.N.O.. ", +" . P.Q.R.S.T.U.V.W.X.X.Y.Z.>.`. +. ", +" . .+++@+#+$+%+&+*+=+-+;+>+,+'+)+. ", +" . . . . . . . . . . . . . . . ", +" ", +" "}; diff --git a/etc/images/mail/compose.xpm b/etc/images/mail/compose.xpm new file mode 100644 index 0000000..2329b3d --- /dev/null +++ b/etc/images/mail/compose.xpm @@ -0,0 +1,225 @@ +/* XPM */ +static char * stock_mail_compose_xpm[] = { +"24 24 198 2", +" c None", +". c #000000", +"+ c #D1AF61", +"@ c #F1E3AC", +"# c #FBA90F", +"$ c #FFFFFF", +"% c #B5B5B5", +"& c #A06B09", +"* c #816000", +"= c #E0E0E0", +"- c #C1C1C1", +"; c #F4F4F4", +"> c #FDFDFD", +", c #E6C370", +"' c #F1D387", +") c #D58F0C", +"! c #B2B2B2", +"~ c #C3C3C3", +"{ c #FBFBFB", +"] c #A8A8A8", +"^ c #F6F6F6", +"/ c #B3B3B3", +"( c #FAFAFA", +"_ c #ADADAD", +": c #767676", +"< c #5D5D5D", +"[ c #404040", +"} c #F8F8F8", +"| c #F1D07E", +"1 c #ACACAC", +"2 c #F8F8F6", +"3 c #E2E2E2", +"4 c #858585", +"5 c #4B4B49", +"6 c #161616", +"7 c #FBFBFA", +"8 c #7D7D7D", +"9 c #F2F2F2", +"0 c #F0F0F0", +"a c #EFEFEF", +"b c #D5D5D5", +"c c #F9F9F9", +"d c #F6F6F3", +"e c #F3F3F3", +"f c #878786", +"g c #E5E5E5", +"h c #DFDFDF", +"i c #EBEBEB", +"j c #AEAEAE", +"k c #7B5307", +"l c #EDEDED", +"m c #EBEBE9", +"n c #E9E9E7", +"o c #E0E0DE", +"p c #BFBFBF", +"q c #F0F0ED", +"r c #F1D284", +"s c #CA870B", +"t c #9E9E9C", +"u c #DCDCD9", +"v c #D9D9D9", +"w c #D9D9D6", +"x c #D6D6D4", +"y c #E5E5E4", +"z c #D9D9D7", +"A c #BABABA", +"B c #AAAAAA", +"C c #E7E7E5", +"D c #E4E4E2", +"E c #E2E2E0", +"F c #EEEEEC", +"G c #979796", +"H c #D4D4D1", +"I c #DEDEDC", +"J c #DEDEDB", +"K c #BDBDBC", +"L c #E7E7E7", +"M c #EFEFED", +"N c #A6A6A5", +"O c #BA7C0A", +"P c #7A5B00", +"Q c #DBDBD9", +"R c #D5D5D3", +"S c #BCBCBC", +"T c #E3E3E3", +"U c #F2E6B6", +"V c #7B7B7B", +"W c #704B05", +"X c #676764", +"Y c #CBCBC7", +"Z c #C9C9C7", +"` c #DBDBD7", +" . c #D7D7D5", +".. c #D7D7D3", +"+. c #B4B4B4", +"@. c #E4E4E4", +"#. c #DBD5C1", +"$. c #7E6F57", +"%. c #755800", +"&. c #D9D9D5", +"*. c #D5D5D1", +"=. c #D0D0CE", +"-. c #BABAB8", +";. c #DDDDDB", +">. c #D1D1CF", +",. c #0E0E0E", +"'. c #535353", +"). c #8D8D8B", +"!. c #C4C4C1", +"~. c #C4C4BF", +"{. c #C1C1BC", +"]. c #D3D3D0", +"^. c #D1D1D0", +"/. c #DCDCDB", +"(. c #E0E0DC", +"_. c #898987", +":. c #C9C9C6", +"<. c #CDCDCA", +"[. c #D0D0CD", +"}. c #CECECB", +"|. c #CFCFCC", +"1. c #D0D0CC", +"2. c #B6B6B6", +"3. c #D4D4D0", +"4. c #C3C3C0", +"5. c #5B5B5B", +"6. c #91918D", +"7. c #91918F", +"8. c #9F9F9D", +"9. c #AFAFAC", +"0. c #B9B9B6", +"a. c #BEBEBB", +"b. c #C5C5C2", +"c. c #C8C8C5", +"d. c #CACAC7", +"e. c #CBCBC8", +"f. c #CCCCC9", +"g. c #CCCCC8", +"h. c #D2D2D0", +"i. c #D2D2CF", +"j. c #BFBFBD", +"k. c #9F9F9C", +"l. c #888886", +"m. c #878785", +"n. c #8C8C8A", +"o. c #959593", +"p. c #9C9C9A", +"q. c #A8A8A5", +"r. c #B1B1AE", +"s. c #B5B5B3", +"t. c #BBBBB8", +"u. c #BFBFBC", +"v. c #C2C2BE", +"w. c #D1D1CE", +"x. c #AEAEAB", +"y. c #9D9D9A", +"z. c #979794", +"A. c #949491", +"B. c #9A9A97", +"C. c #A3A3A0", +"D. c #AAAAA7", +"E. c #B0B0AC", +"F. c #B8B8B5", +"G. c #B0B0AE", +"H. c #CFCFCD", +"I. c #BEBEBC", +"J. c #B4B4B0", +"K. c #ACACA8", +"L. c #A4A4A2", +"M. c #A0A09C", +"N. c #A4A4A0", +"O. c #A8A8A6", +"P. c #ABABA7", +"Q. c #B2B2AE", +"R. c #A4A4A4", +"S. c #CECECC", +"T. c #CECECA", +"U. c #C6C6C2", +"V. c #BCBCB9", +"W. c #B3B3AF", +"X. c #ABABA9", +"Y. c #A6A6A3", +"Z. c #A0A09D", +"`. c #ACACA9", +" + c #A1A1A1", +".+ c #B1B1AF", +"++ c #B4B4B3", +"@+ c #B4B4B1", +"#+ c #B3B3B1", +"$+ c #AEAEAA", +"%+ c #A7A7A4", +"&+ c #A2A2A0", +"*+ c #A5A5A1", +"=+ c #999997", +"-+ c #929290", +";+ c #949490", +">+ c #9D9D9B", +",+ c #858583", +" . . . ", +" . . . . . . . . . . . . + @ # . . . ", +" . $ $ $ $ $ $ $ $ $ % & @ # * . = - . ", +" . $ ; $ $ $ $ $ > > . , ' ) . ! ~ { ] . ", +" . $ ^ $ $ $ > > > / & @ # * . ( _ : < [ . ", +" . $ ^ $ { { { { } . , | ) . 1 2 3 4 5 6 . ", +" . $ ; > > { { 7 8 & @ # * . ; 9 0 a b _ . ", +" . $ 9 c ^ ^ d e . , | ) . f g 3 h i 3 - . ", +" . $ 0 } } } 2 j k @ # * . l i m n n o p . ", +" . $ a e 0 q l . , r s . t u v w x y z A . ", +" . $ l ; ; 9 B & @ # * . C y y D o E z A . ", +" . $ i F C g . , r s . G H E o I J I z K . ", +" . $ L M i N O # # P . E o I J u Q Q R S . ", +" . $ g T v . U V W . X Y Z u ` z .z ..+.. ", +" . $ E y @.. #.$.%.. u Q ` &...R *...=.-.. ", +" . $ I ;.>.,.'.. . ).!.~.{.*.*.].^.].=.-.. ", +" . $ /.(.;.. . _.:.<.[.}.[.[.[.[.|.[.1.2.. ", +" . $ Q 3.4.5.6.7.8.9.0.a.4.b.c.d.e.f.g.! . ", +" . $ h.i.|.j.k.l.m.n.o.p.q.r.s.t.a.u.v.! . ", +" . $ w.1.f.|.4.x.y.z.z.A.B.k.C.q.D.E.F.G.. ", +" . $ i.w.w.w.H.e.I.J.K.L.M.M.N.L.O.P.Q.R.. ", +" . $ ^.w.=.S.T.T.g.U.V.W.J.X.Y.Z.Y.D.`. +. ", +" . $ .+++@+@+@+#+#+Q.$+%+&+*+*+=+-+;+>+,+. ", +" . . . . . . . . . . . . . . . . . . . . "}; diff --git a/etc/images/mail/copy.xpm b/etc/images/mail/copy.xpm new file mode 100644 index 0000000..25ccc17 --- /dev/null +++ b/etc/images/mail/copy.xpm @@ -0,0 +1,104 @@ +/* XPM */ +static char * stock_mail_copy_xpm[] = { +"24 24 77 1", +" c None", +". c #010101", +"+ c #2F2F2F", +"@ c #E3E2E1", +"# c #FCFCFC", +"$ c #B3B2B1", +"% c #95938E", +"& c #F7F7F7", +"* c #F5F4F2", +"= c #F8F8F8", +"- c #F7F6F6", +"; c #EAE9E5", +"> c #7B7976", +", c #D2CFCA", +"' c #E1E0DD", +") c #908E8B", +"! c #EBEAEA", +"~ c #F1F0EE", +"{ c #E2E0DD", +"] c #7C7B78", +"^ c #C6C3C0", +"/ c #E5E3DE", +"( c #DCDAD7", +"_ c #8F8C88", +": c #EBEBEA", +"< c #EFEDEA", +"[ c #DFDDDA", +"} c #787774", +"| c #C1BEBA", +"1 c #E6E3E0", +"2 c #EFEEEC", +"3 c #CBCAC6", +"4 c #ECECEC", +"5 c #F3F2F0", +"6 c #DCDCDC", +"7 c #7D7C79", +"8 c #B4B2AE", +"9 c #E7E5E1", +"0 c #F0EFEB", +"a c #E4E2DD", +"b c #7B7874", +"c c #AFACA6", +"d c #ABA8A3", +"e c #F9F8F6", +"f c #EAE9E8", +"g c #B0ADA7", +"h c #F5F3F0", +"i c #B9B8B6", +"j c #CBC9C4", +"k c #DEDBD5", +"l c #9D9994", +"m c #DBD9D6", +"n c #747370", +"o c #A09C97", +"p c #DAD8D5", +"q c #E7E6E3", +"r c #E8E6E1", +"s c #E0DED9", +"t c #F7F6F4", +"u c #D3D1CF", +"v c #868480", +"w c #C2BFBD", +"x c #DAD9D5", +"y c #F6F5F1", +"z c #D8D6D1", +"A c #F7F5F2", +"B c #92908B", +"C c #CCCAC5", +"D c #F7F6F2", +"E c #F5F4F0", +"F c #EAE8E3", +"G c #D2D0CB", +"H c #D9D7D2", +"I c #DAD8D3", +"J c #D5D3CE", +"K c #D6D4CF", +"L c #040404", +" ", +" ", +" ", +" .+........... ", +" .@###########$. ", +" .#%&*=*-*-*;>,. ", +" .#')!~-*-*{]^/. ", +" .#~(_:~<~[}|1/. ", +" .#~23]4567890a. ", +" .#22~b.+........... ", +" .#~2c.@###########$. ", +" .#2de.#%&*=*-*-*;>,. ", +" .fgeh.#')!~-*-*{]^/. ", +" .ijkk.#~(_:~<~[}|1/. ", +" .....#~23]4567890a. ", +" .#22~l]mnopqrs. ", +" .#~2ctuvwxoy0z. ", +" .#2deetptAABrC. ", +" .fgehDEAEAhFBG. ", +" .ijkkkHIJKGGGB. ", +" ............L ", +" ", +" ", +" "}; diff --git a/etc/images/mail/forward.xpm b/etc/images/mail/forward.xpm new file mode 100644 index 0000000..07af5fd --- /dev/null +++ b/etc/images/mail/forward.xpm @@ -0,0 +1,92 @@ +/* XPM */ +static char * stock_mail_forward_xpm[] = { +"24 24 65 1", +" c None", +". c #000000", +"+ c #535353", +"@ c #FFFFFF", +"# c #FEFEFE", +"$ c #FDFDFD", +"% c #FCFCFC", +"& c #FBFBFB", +"* c #F9F9F9", +"= c #F8F8F8", +"- c #F7F7F7", +"; c #F6F6F6", +"> c #F5F5F5", +", c #F4F4F4", +"' c #E3E3E3", +") c #EEEEEE", +"! c #4F4F4F", +"~ c #F3F3F3", +"{ c #F2F2F2", +"] c #F1F1F1", +"^ c #F0F0F0", +"/ c #EFEFEF", +"( c #EDEDED", +"_ c #AEAEAE", +": c #E4E4E4", +"< c #434343", +"[ c #ACACAC", +"} c #C8C8C8", +"| c #A0A0A0", +"1 c #D4D4D4", +"2 c #ECECEC", +"3 c #959595", +"4 c #3E3E3E", +"5 c #4D4D4D", +"6 c #818181", +"7 c #C6C6C6", +"8 c #6A6A6A", +"9 c #636363", +"0 c #B9B9B9", +"a c #737373", +"b c #7C7C7C", +"c c #5B88B2", +"d c #9EB8D1", +"e c #5080AD", +"f c #B5C9DC", +"g c #AFC5DA", +"h c #B2C7DB", +"i c #B6CADD", +"j c #A4BDD5", +"k c #9CB7D1", +"l c #080D11", +"m c #BCBCBC", +"n c #9BB6D0", +"o c #A0BAD3", +"p c #9AB5CF", +"q c #97B3CE", +"r c #5F8BB4", +"s c #91B0CC", +"t c #95B2CE", +"u c #4C79A3", +"v c #49749C", +"w c #3F6588", +"x c #2A435B", +"y c #456F96", +"z c #375978", +" ", +" ", +" ", +" ................. ", +" .+@@@@#$%&*=-;>,'+. ", +" .)!@>,~{{]^^/)('!_. ", +" .@:<$~{{]^/))('![}. ", +" .@>:!&]^^/)(('<|1}. ", +" .@&>:<=^/)(2'!31:}. ", +" .@>>>:4>)(2'567::}. ", +" .@&>>:8<~2'!877>.}. ", +" .@>>:9@0!^!37a7>... ", +" .@&:9@>:1![7::b:.c. ", +" .@:a@>>>>:.......de. ", +" .@b@::::::.fghiiijkel ", +" .ammmmmmmm.nokknpokqr. ", +" ..........sdppnkkkotu.", +" .vwwwwwwwwx. ", +" .yzzzzzwwx. ", +" .......wx. ", +" .x. ", +" .. ", +" . ", +" "}; diff --git a/etc/images/mail/inbox.xpm b/etc/images/mail/inbox.xpm new file mode 100644 index 0000000..5774e3a --- /dev/null +++ b/etc/images/mail/inbox.xpm @@ -0,0 +1,103 @@ +/* XPM */ +static char * stock_inbox_xpm[] = { +"24 24 76 1", +" c None", +". c #000000", +"+ c #B5CADD", +"@ c #BFD1E1", +"# c #C3D4E3", +"$ c #C7D7E5", +"% c #B0C6DA", +"& c #6B94BB", +"* c #131E29", +"= c #739ABF", +"- c #7EA2C4", +"; c #9AB6D0", +"> c #E4EBF2", +", c #DDE6EF", +"' c #8CACCA", +") c #5C8AB4", +"! c #090F15", +"~ c #B1C7DB", +"{ c #D0DDEA", +"] c #D9E3ED", +"^ c #88A9C8", +"/ c #4D7CA7", +"( c #030405", +"_ c #41688D", +": c #32506C", +"< c #C4D5E4", +"[ c #A5BED5", +"} c #456F97", +"| c #3B5F81", +"1 c #C8D8E6", +"2 c #9CB8D2", +"3 c #395B7B", +"4 c #C6D6E4", +"5 c #BBCEDF", +"6 c #3D6183", +"7 c #B6CBDE", +"8 c #426A90", +"9 c #E2C6A9", +"0 c #E5CDB4", +"a c #D5AA7F", +"b c #9D6733", +"c c #CB9967", +"d c #ADC4D9", +"e c #B99877", +"f c #CFBAA4", +"g c #9A7149", +"h c #CDA378", +"i c #D2A87E", +"j c #608DB6", +"k c #AA7B4B", +"l c #C2A588", +"m c #996633", +"n c #BB9978", +"o c #C3976B", +"p c #D2A980", +"q c #D1A77D", +"r c #E0C4A8", +"s c #C9B097", +"t c #D7B38E", +"u c #DAC2A9", +"v c #BD9063", +"w c #CEA57C", +"x c #E5CFBB", +"y c #393633", +"z c #E0C8B1", +"A c #C9A480", +"B c #D1A87E", +"C c #D0A67B", +"D c #E1CAB4", +"E c #52504D", +"F c #D8C6B5", +"G c #CBA988", +"H c #CCAF93", +"I c #D2B496", +"J c #A67D51", +"K c #E2CFBD", +" ...... ", +" .+@#$%&*. ", +" .=-;$>,')! ", +" ...=~{]^/( ", +" .=+#$_:. ", +" .<[@}|. ", +" .12@}3. ", +" ....425}6.... ", +" .=2527}8}:. ", +" ..9.=227}}:. ", +" ..0abb.=2~}:.. ", +" ..0abbbbc.=d:.ef.. ", +".0abbbbghii.j.kkklf.. ", +".mnabgopqqqi.iokkkkef. ", +".mmmnrooqiqqqiiiokkkks. ", +".mmmmmnrooqiqqqiiiokkl. ", +" ..mmmmmnrooqiqqiiituf. ", +" ..mmmmmnrvwiqqtxxy. ", +" ..mmmmmzABCDxE.. ", +" ...mmmFGHIE.. ", +" ...mJK... ", +" ..... ", +" ", +" "}; diff --git a/etc/images/mail/move.xpm b/etc/images/mail/move.xpm new file mode 100644 index 0000000..ed478eb --- /dev/null +++ b/etc/images/mail/move.xpm @@ -0,0 +1,103 @@ +/* XPM */ +static char * stock_mail_move_xpm[] = { +"24 24 76 1", +" c None", +". c #010101", +"+ c #2F2F2F", +"@ c #E3E2E1", +"# c #FCFCFC", +"$ c #B3B2B1", +"% c #95938E", +"& c #F7F7F7", +"* c #F5F4F2", +"= c #F8F8F8", +"- c #F7F6F6", +"; c #EAE9E5", +"> c #7B7976", +", c #D2CFCA", +"' c #E1E0DD", +") c #908E8B", +"! c #EBEAEA", +"~ c #F1F0EE", +"{ c #E2E0DD", +"] c #7C7B78", +"^ c #C6C3C0", +"/ c #E5E3DE", +"( c #DCDAD7", +"_ c #8F8C88", +": c #EBEBEA", +"< c #EFEDEA", +"[ c #DFDDDA", +"} c #787774", +"| c #C1BEBA", +"1 c #E6E3E0", +"2 c #EFEEEC", +"3 c #CBCAC6", +"4 c #ECECEC", +"5 c #F3F2F0", +"6 c #DCDCDC", +"7 c #7D7C79", +"8 c #B4B2AE", +"9 c #E7E5E1", +"0 c #F0EFEB", +"a c #E4E2DD", +"b c #9D9994", +"c c #DBD9D6", +"d c #747370", +"e c #A09C97", +"f c #DAD8D5", +"g c #E7E6E3", +"h c #E8E6E1", +"i c #E0DED9", +"j c #AFACA6", +"k c #F7F6F4", +"l c #D3D1CF", +"m c #868480", +"n c #C2BFBD", +"o c #DAD9D5", +"p c #F6F5F1", +"q c #D8D6D1", +"r c #ABA8A3", +"s c #F9F8F6", +"t c #F7F5F2", +"u c #92908B", +"v c #CCCAC5", +"w c #EAE9E8", +"x c #B0ADA7", +"y c #F5F3F0", +"z c #F7F6F2", +"A c #F5F4F0", +"B c #EAE8E3", +"C c #D2D0CB", +"D c #B9B8B6", +"E c #CBC9C4", +"F c #DEDBD5", +"G c #D9D7D2", +"H c #DAD8D3", +"I c #D5D3CE", +"J c #D6D4CF", +"K c #040404", +" ", +" ", +" ", +" . . . . . . . ", +" . . ", +" ", +" . . ", +" ", +" . . ", +" .+........... ", +" . .@###########$. ", +" .#%&*=*-*-*;>,. ", +" . .#')!~-*-*{]^/. ", +" .#~(_:~<~[}|1/. ", +" . . .#~23]4567890a. ", +" .#22~b]cdefghi. ", +" .#~2jklmnoep0q. ", +" .#2rsskfkttuhv. ", +" .wxsyzAtAtyBuC. ", +" .DEFFFGHIJCCCu. ", +" ............K ", +" ", +" ", +" "}; diff --git a/etc/images/mail/not-spam.xpm b/etc/images/mail/not-spam.xpm new file mode 100644 index 0000000..f8db326 --- /dev/null +++ b/etc/images/mail/not-spam.xpm @@ -0,0 +1,149 @@ +/* XPM */ +static char * stock_not_spam_xpm[] = { +"24 24 122 2", +" c None", +". c #1D1E1E", +"+ c #333839", +"@ c #393F40", +"# c #171819", +"$ c #B2B8B9", +"% c #D5E3E7", +"& c #AABABD", +"* c #64696A", +"= c #0C0D0D", +"- c #929C9E", +"; c #E7F0F3", +"> c #EDF0F1", +", c #E5EDEF", +"' c #C5D9DD", +") c #2E3132", +"! c #3F4343", +"~ c #1F2121", +"{ c #DFEBEE", +"] c #B7C4C8", +"^ c #D2D9DA", +"/ c #E1EFF2", +"( c #B6CBCF", +"_ c #3C4547", +": c #1E2223", +"< c #191E1F", +"[ c #2D2E2F", +"} c #191A1A", +"| c #252829", +"1 c #7E8E92", +"2 c #B7C2C3", +"3 c #C3D9DD", +"4 c #9CACB0", +"5 c #C3CDCE", +"6 c #C7E1E7", +"7 c #668F97", +"8 c #90ACB2", +"9 c #CDDDE1", +"0 c #485559", +"a c #88A6AC", +"b c #1F2223", +"c c #3F4545", +"d c #242728", +"e c #313B3E", +"f c #A8C2C8", +"g c #B2BDC0", +"h c #CFE5E9", +"i c #C2D9DE", +"j c #81989C", +"k c #A2C0C5", +"l c #85A9B1", +"m c #E5ECEE", +"n c #E7F2F4", +"o c #9BAEB3", +"p c #C8E1E7", +"q c #3A3E3F", +"r c #0C0E0E", +"s c #000000", +"t c #333737", +"u c #B3C2C5", +"v c #DDEDF0", +"w c #D8E4E6", +"x c #DAECEF", +"y c #D5E9ED", +"z c #D2E7EC", +"A c #95ADB2", +"B c #DBE2E2", +"C c #EDEFF0", +"D c #A2B1B3", +"E c #8FA4A8", +"F c #D7E2E5", +"G c #798F94", +"H c #151819", +"I c #F3B5A7", +"J c #865E55", +"K c #AFB9BB", +"L c #F1F8F9", +"M c #F7FBFB", +"N c #D9EBEF", +"O c #ECF4F6", +"P c #F3F7F7", +"Q c #E9F2F4", +"R c #EEF2F3", +"S c #E9EDEE", +"T c #C5C8C9", +"U c #C2C6C8", +"V c #E0E7E7", +"W c #DDEAED", +"X c #7A9DA5", +"Y c #EB8169", +"Z c #B83618", +"` c #924E3C", +" . c #9FA5A6", +".. c #E3EEF0", +"+. c #ECF5F7", +"@. c #D6EAED", +"#. c #CBE4E9", +"$. c #747C7D", +"%. c #B43518", +"&. c #E76A4D", +"*. c #B53F24", +"=. c #CB705A", +"-. c #C4D8DB", +";. c #D2E6E9", +">. c #CAE3E8", +",. c #A9C8CF", +"'. c #EC927D", +"). c #E66F54", +"!. c #D26951", +"~. c #F1A897", +"{. c #E76547", +"]. c #C58B7D", +"^. c #A8ABAC", +"/. c #70A1AB", +"(. c #DF421E", +"_. c #C43A1A", +":. c #E17055", +"<. c #DD8D7A", +"[. c #FFFFFF", +"}. c #030505", +"|. c #A2432E", +"1. c #AC3316", +" ", +" ", +" . + @ ", +" # $ % & * . ", +" = - ; > , ' ) ! ", +" ~ { ] ^ / ( _ : < [ } ", +" | 1 2 3 4 5 6 7 8 9 0 a b ", +" c d e f g h i j k l m n o p q r ", +" s t u v w / x y z A B C D E F G H ", +" s s I J K L M N O P Q R S T U V W X < ", +"s I Y Z ` ...+.@.#.$.s s s s s s s s s s s s ", +"s %.&.Y *.=.-.;.>.,.s '.).).).).).).).).).).!.s ", +"s %.%.%.&.~.{.].^./.s ).(.(.(.(.(.(.(.(.(.(._.s ", +"s %.%.%.%.%.&.~.:.<.s ).(.[.[.(.(.(.(.[.[.(._.s ", +" s s %.%.%.%.%.&.~.s ).(.[.[.[.(.(.[.[.[.(._.s ", +" s s %.%.%.%.%.s ).(.(.[.[.[.[.[.[.(.(._.s ", +" s s %.%.%.s ).(.(.(.[.[.[.[.(.(.(._.s ", +" }.s s |.s ).(.(.(.[.[.[.[.(.(.(._.s ", +" s s s ).(.(.[.[.[.[.[.[.(.(._.s ", +" s ).(.[.[.[.(.(.[.[.[.(._.s ", +" s ).(.[.[.(.(.(.(.[.[.(._.s ", +" s ).(.(.(.(.(.(.(.(.(.(._.s ", +" s !._._._._._._._._._._.1.s ", +" s s s s s s s s s s s s "}; diff --git a/etc/images/mail/outbox.xpm b/etc/images/mail/outbox.xpm new file mode 100644 index 0000000..58b5212 --- /dev/null +++ b/etc/images/mail/outbox.xpm @@ -0,0 +1,96 @@ +/* XPM */ +static char * stock_outbox_xpm[] = { +"24 24 69 1", +" c None", +". c #000000", +"+ c #E66040", +"@ c #EE937E", +"# c #E55E3F", +"$ c #E1431F", +"% c #EC8770", +"& c #F0A08E", +"* c #F3B7A9", +"= c #EF9985", +"- c #E76749", +"; c #ED8C75", +"> c #F5BEB1", +", c #F3B4A5", +"' c #F4B8AA", +") c #F1A593", +"! c #E55B3B", +"~ c #E45534", +"{ c #F4BDB0", +"] c #F4BAAC", +"^ c #EF9C89", +"/ c #E34E2B", +"( c #C0391A", +"_ c #8A2912", +": c #3E3E3C", +"< c #D4D3D2", +"[ c #DB411D", +"} c #F1A999", +"| c #D23E1C", +"1 c #812611", +"2 c #C7C7C5", +"3 c #ACABA8", +"4 c #6A6966", +"5 c #E9775D", +"6 c #CECDCC", +"7 c #A93217", +"8 c #9B9A97", +"9 c #494846", +"0 c #9A9996", +"a c #BBBBB9", +"b c #747370", +"c c #A5A4A1", +"d c #AAA9A6", +"e c #686765", +"f c #7D7C79", +"g c #686764", +"h c #9C9B98", +"i c #999895", +"j c #ABAAA7", +"k c #A9A8A5", +"l c #AF3417", +"m c #E55D3D", +"n c #C5C5C3", +"o c #8D8C89", +"p c #626260", +"q c #B2B1AE", +"r c #A7A6A3", +"s c #B4B4B2", +"t c #C3C3C1", +"u c #92918E", +"v c #D1D0CF", +"w c #373735", +"x c #CACAC8", +"y c #A8A7A4", +"z c #CCCCCA", +"A c #52514E", +"B c #C8C8C6", +"C c #B5B5B3", +"D c #7E7D7A", +" . ", +" .. ", +" .+. ", +" ....@#. ", +" .$%&*=@-. ", +" .;>,')@@@!. ", +" .~{]*^@@@@@-.", +" ...@>/((((((_. ", +" .:<.[}|((((((1. ", +" ..234.5+(_...(1. ", +" ..63444.@(7...._. ", +" ..6344448.@(.90a.. ", +".634444bcd.#$.eff.a.. ", +".gh34bijkk.lm.iffff0a. ", +".ggghniikdo..pddiffffq. ", +".ggggghniikdkkkdddiffr. ", +" ..ggggghniikdkkdddsta. ", +" ..ggggghnurdkksvvw. ", +" ..gggggxrdyzvA.. ", +" ...gggB3qCA.. ", +" ...gDv... ", +" ..... ", +" ", +" "}; diff --git a/etc/images/mail/preview.xpm b/etc/images/mail/preview.xpm new file mode 100644 index 0000000..563a267 --- /dev/null +++ b/etc/images/mail/preview.xpm @@ -0,0 +1,178 @@ +/* XPM */ +static char * mail_preview_xpm[] = { +"24 24 151 2", +" c None", +". c #343434", +"+ c #2D2D2D", +"@ c #292929", +"# c #262626", +"$ c #2E2E2E", +"% c #303030", +"& c #737373", +"* c #A1A1A1", +"= c #B4B4B4", +"- c #B2B2B2", +"; c #9D9D9D", +"> c #676767", +", c #202020", +"' c #1C1C1C", +") c #272727", +"! c #616161", +"~ c #CACACA", +"{ c #CFCFCF", +"] c #D0D0D0", +"^ c #CECECE", +"/ c #C9C9C9", +"( c #C1C1C1", +"_ c #A7A7A7", +": c #4C4C4C", +"< c #131313", +"[ c #222222", +"} c #757575", +"| c #D3D3D3", +"1 c #DBDBDB", +"2 c #E7E7E7", +"3 c #EFEFEF", +"4 c #F3F3F3", +"5 c #F1F1F1", +"6 c #E5E5E5", +"7 c #D2D2D2", +"8 c #BCBCBC", +"9 c #5E5E5E", +"0 c #101010", +"a c #212121", +"b c #5B5B5B", +"c c #CCCCCC", +"d c #D7D7D7", +"e c #F5F5F5", +"f c #FAFAFA", +"g c #FBFBFB", +"h c #F8F8F8", +"i c #F0F0F0", +"j c #E1E1E1", +"k c #C2C2C2", +"l c #434343", +"m c #0F0F0F", +"n c #1F1F1F", +"o c #B9B9B9", +"p c #D4D4D4", +"q c #F7F7F7", +"r c #F9F9F9", +"s c #F6F6F6", +"t c #EAEAEA", +"u c #E2E2E2", +"v c #ABABAB", +"w c #0E0E0E", +"x c #000000", +"y c #111111", +"z c #686868", +"A c #9C9C9C", +"B c #808080", +"C c #8E8E8E", +"D c #919191", +"E c #929292", +"F c #949494", +"G c #939393", +"H c #8B8B8B", +"I c #838383", +"J c #A3A3A3", +"K c #555555", +"L c #080808", +"M c #535353", +"N c #333333", +"O c #AFAFAF", +"P c #E6E6E6", +"Q c #FDFDFD", +"R c #FEFEFE", +"S c #FCFCFC", +"T c #A8A8A8", +"U c #8D8D8D", +"V c #050505", +"W c #EEEEEE", +"X c #A6A6A6", +"Y c #C8C8C8", +"Z c #FFFFFF", +"` c #B6B6B6", +" . c #F4F4F4", +".. c #F2F2F2", +"+. c #A9A9A9", +"@. c #040404", +"#. c #2A2A2A", +"$. c #AAAAAA", +"%. c #ECECEC", +"&. c #A5A5A5", +"*. c #C7C7C7", +"=. c #D8D8D8", +"-. c #CDCDCD", +";. c #858585", +">. c #010101", +",. c #606060", +"'. c #646464", +"). c #C3C3C3", +"!. c #DADADA", +"~. c #494949", +"{. c #ADADAD", +"]. c #0A0A0A", +"^. c #BABABA", +"/. c #DCDCDC", +"(. c #989898", +"_. c #E9E9E9", +":. c #EBEBEB", +"<. c #A4A4A4", +"[. c #B7B7B7", +"}. c #D1D1D1", +"|. c #414141", +"1. c #3D3D3D", +"2. c #969696", +"3. c #A0A0A0", +"4. c #BEBEBE", +"5. c #D9D9D9", +"6. c #C5C5C5", +"7. c #515151", +"8. c #C0C0C0", +"9. c #959595", +"0. c #DDDDDD", +"a. c #484848", +"b. c #030303", +"c. c #454545", +"d. c #060606", +"e. c #B5B5B5", +"f. c #C6C6C6", +"g. c #C4C4C4", +"h. c #A2A2A2", +"i. c #828282", +"j. c #1E1E1E", +"k. c #191919", +"l. c #7C7C7C", +"m. c #E4E4E4", +"n. c #9E9E9E", +"o. c #525252", +"p. c #B0B0B0", +"q. c #6C6C6C", +"r. c #565656", +"s. c #797979", +"t. c #3A3A3A", +" ", +" ", +" . + @ # # # ", +" $ % & * = - ; > , ' ", +" ) ! = ~ { ] ^ / ( _ : < ", +" [ } ~ | 1 2 3 4 5 6 7 8 9 0 ", +" a b c d 6 e f g f h e i j k l m ", +" n o p 6 q r g g f r s i t u v w ", +" x y z A B C D E F F G G D C H I J K L ", +"x M N O P e r g Q R R Q S f h e i T U V ", +"x W y ~ t 5 q q g r S r f q e i X Y _ V ", +"x Z y ` t 3 4 e s q q q s ...+.~ ] J @. ", +"x Z #.$.v %.i .. .e e e 4 5 &.*.=.-.;.>. ", +"x Z ,.'.1 ; %.3 i 5 5 i i T ).=.!./ ~.x ", +"x Z {.].^./.(._.:.%.%.%.<.[.}.!.p &.>. ", +"x Z /.|.1.7 +.2.6 6 6 3.$.4.=.5.).% x ", +"x Z e 6.L 7.8.( 9.0.(.= Y J ).( a.b.x ", +"x Z g d c.d.. 3.( F e.8.~ f.U + b.].x x ", +"x Z e & ^.g.1.b.a.I h.&.i.l x j.[.k.x x x ", +"x Z l.p m.m.Y n.o.j.b.b.j.o.n.p.q.O j.n x x ", +"x & 8 8 8 8 8 8 &.&.&.&.&.&.&.8 8 r.x > N x x ", +" x x x x x x x x x x x x x x x x x x x s.t.x x ", +" x z n x ", +" x x "}; diff --git a/etc/images/mail/reply-all.xpm b/etc/images/mail/reply-all.xpm new file mode 100644 index 0000000..dfd560d --- /dev/null +++ b/etc/images/mail/reply-all.xpm @@ -0,0 +1,176 @@ +/* XPM */ +static char * stock_mail_reply_to_all_xpm[] = { +"24 24 149 2", +" c None", +". c #000000", +"+ c #ADA99C", +"@ c #E6E1D0", +"# c #F0EAD9", +"$ c #A9A598", +"% c #141416", +"& c #161618", +"* c #080809", +"= c #DBD6C7", +"- c #1B1B1C", +"; c #050505", +"> c #5A5A5A", +", c #676767", +"' c #020202", +") c #807D76", +"! c #D49A3E", +"~ c #D2973B", +"{ c #040402", +"] c #6D6B6B", +"^ c #7A7979", +"/ c #030100", +"( c #040100", +"_ c #282724", +": c #DD9831", +"< c #DA962F", +"[ c #1A0E01", +"} c #BC6D1B", +"| c #BE6E13", +"1 c #BE6D13", +"2 c #BD6C13", +"3 c #3E3C36", +"4 c #D69029", +"5 c #D18D27", +"6 c #737067", +"7 c #110900", +"8 c #CF791C", +"9 c #CE791C", +"0 c #CD761A", +"a c #C47013", +"b c #4A4136", +"c c #A0731E", +"d c #96691A", +"e c #000100", +"f c #291703", +"g c #BA6613", +"h c #8C4E0D", +"i c #844A0D", +"j c #BF6D13", +"k c #1F2A0D", +"l c #306220", +"m c #4F7242", +"n c #448D44", +"o c #2E802E", +"p c #3A6F3A", +"q c #FFFFFF", +"r c #535353", +"s c #171009", +"t c #AC600C", +"u c #713F0A", +"v c #693A0A", +"w c #AA5F0A", +"x c #192B10", +"y c #275926", +"z c #68A769", +"A c #358A36", +"B c #2D812D", +"C c #FBFBFB", +"D c #F7F7F7", +"E c #FAFAFA", +"F c #F5F5F5", +"G c #4F4F4F", +"H c #AEAEAE", +"I c #141517", +"J c #6F767C", +"K c #534C46", +"L c #241609", +"M c #23180E", +"N c #484644", +"O c #354A4D", +"P c #050B07", +"Q c #4F7E4F", +"R c #399239", +"S c #2D852D", +"T c #297F29", +"U c #ACACAC", +"V c #C8C8C8", +"W c #151618", +"X c #6C7C8B", +"Y c #728EA9", +"Z c #5D6B78", +"` c #C8CBCD", +" . c #C3C7CD", +".. c #8090A2", +"+. c #5A728B", +"@. c #4E6479", +"#. c #111714", +"$. c #328732", +"%. c #2B7F2C", +"&. c #2B772C", +"*. c #434343", +"=. c #A0A0A0", +"-. c #D4D4D4", +";. c #25282A", +">. c #8A9EB4", +",. c #6A86A1", +"'. c #596A7C", +"). c #DDE1E4", +"!. c #DCE2E7", +"~. c #899CAC", +"{. c #687E96", +"]. c #546D87", +"^. c #10161D", +"/. c #8C8C8C", +"(. c #959595", +"_. c #E4E4E4", +":. c #23282D", +"<. c #8096AB", +"[. c #5D7996", +"}. c #53687D", +"|. c #CDD3D9", +"1. c #CBD2DC", +"2. c #899BAB", +"3. c #CCD4DC", +"4. c #5C748C", +"5. c #111820", +"6. c #4D4D4D", +"7. c #818181", +"8. c #C6C6C6", +"9. c #1F252B", +"0. c #6B8197", +"a. c #536D89", +"b. c #4A5D6F", +"c. c #81919F", +"d. c #8293A4", +"e. c #5A7087", +"f. c #496481", +"g. c #445D79", +"h. c #0E151B", +"i. c #6A6A6A", +"j. c #0E141A", +"k. c #0D1319", +"l. c #0E141B", +"m. c #0E131A", +"n. c #0F141A", +"o. c #636363", +"p. c #737373", +"q. c #7C7C7C", +"r. c #BCBCBC", +" ", +" . . ", +" + @ # $ . ", +" % & * = # # # . ", +" - ; > , ' ) ! ~ # . ", +" { ] ^ / ( _ : < # . ", +" [ } | 1 2 3 4 5 # 6 ", +" 7 8 9 0 a b c d # # . e . . . . . . ", +" f g h i j k l m n o p . q q q q q r . ", +" s t u v w x y z A o B . C D E F G H . ", +" I J K L M N O P Q R S T . F F F G U V . ", +" W X Y Z ` ...+.@.#.$.%.&.. F F *.=.-.V . ", +" ;.>.,.'.).!.~.{.].^.. . . /.F G (.-._.V . ", +" :.<.[.}.|.1.2.3.4.5.F F F F 6.7.8._._.V . ", +" 9.0.a.b.c.d.e.f.g.h.F F F G i.=._.F _.V . ", +" j.k.l.l.l.j.m.n.o.G F G (.8.p.8.F _.V . ", +" . q C F o.8.F _.-.G U 8._.F q._._.V . ", +" . q F p.-.F F F F _._.F F F F q._.V . ", +" . q q.-._._._._._._._._._._._._.q.V . ", +" . p.r.r.r.r.r.r.r.r.r.r.r.r.r.r.r.o.. ", +" . . . . . . . . . . . . . . . . . . ", +" ", +" ", +" "}; diff --git a/etc/images/mail/reply.xpm b/etc/images/mail/reply.xpm new file mode 100644 index 0000000..4925041 --- /dev/null +++ b/etc/images/mail/reply.xpm @@ -0,0 +1,94 @@ +/* XPM */ +static char * stock_mail_reply_xpm[] = { +"24 24 67 1", +" c None", +". c #000000", +"+ c #535353", +"@ c #FFFFFF", +"# c #FEFEFE", +"$ c #FDFDFD", +"% c #FCFCFC", +"& c #FBFBFB", +"* c #F9F9F9", +"= c #F8F8F8", +"- c #F7F7F7", +"; c #F6F6F6", +"> c #F5F5F5", +", c #F4F4F4", +"' c #E3E3E3", +") c #EEEEEE", +"! c #4F4F4F", +"~ c #F3F3F3", +"{ c #F2F2F2", +"] c #F1F1F1", +"^ c #F0F0F0", +"/ c #EFEFEF", +"( c #EDEDED", +"_ c #AEAEAE", +": c #E4E4E4", +"< c #434343", +"[ c #ACACAC", +"} c #C8C8C8", +"| c #A0A0A0", +"1 c #D4D4D4", +"2 c #ECECEC", +"3 c #959595", +"4 c #3E3E3E", +"5 c #4D4D4D", +"6 c #818181", +"7 c #C6C6C6", +"8 c #3D1A13", +"9 c #6A6A6A", +"0 c #636363", +"a c #B9B9B9", +"b c #737373", +"c c #EAC0BA", +"d c #7C7C7C", +"e c #DF9E95", +"f c #E0A198", +"g c #E1A59D", +"h c #E2A79E", +"i c #E3ABA3", +"j c #E3AAA2", +"k c #CC6253", +"l c #DD978D", +"m c #DF9F97", +"n c #DE9A90", +"o c #DD968C", +"p c #DD948A", +"q c #B14334", +"r c #BCBCBC", +"s c #431913", +"t c #EAC2BC", +"u c #DF9C92", +"v c #DD998F", +"w c #B54535", +"x c #65261D", +"y c #983A2C", +"z c #7C2F24", +"A c #63251D", +"B c #6C291F", +" ", +" ", +" ", +" ................. ", +" .+@@@@#$%&*=-;>,'+. ", +" .)!@>,~{{]^^/)('!_. ", +" .@:<$~{{]^/))('![}. ", +" .@>:!&]^^/)(('<|1}. ", +" .@&>:<=^/)(2'!31:}. ", +" .@>>>:4>)(2'567::}. ", +" .@&8>:9<~2'!977>:}. ", +" .@..:0@a!^!37b7>:}. ", +" ..c.0@>:1![7::d::}. ", +" .ce.......:>>>:d:}. ", +" .cfghihjek.::::::d}. ", +" .clmenoonpq.rrrrrrr0. ", +"stnuvvlnnnnw.......... ", +" .xyyyyyyyyz. ", +" .xyyAAAAAB. ", +" .xy....... ", +" .x. ", +" .. ", +" . ", +" "}; diff --git a/etc/images/mail/save-draft.xpm b/etc/images/mail/save-draft.xpm new file mode 100644 index 0000000..9b37491 --- /dev/null +++ b/etc/images/mail/save-draft.xpm @@ -0,0 +1,99 @@ +/* XPM */ +static char * stock_mail_handling_xpm[] = { +"24 24 72 1", +" c None", +". c #000000", +"+ c #BCBCBC", +"@ c #FFFFFF", +"# c #535353", +"$ c #EEEEEE", +"% c #4F4F4F", +"& c #F5F5F5", +"* c #FBFBFB", +"= c #F7F7F7", +"- c #FAFAFA", +"; c #AEAEAE", +"> c #E4E4E4", +", c #434343", +"' c #ACACAC", +") c #C8C8C8", +"! c #A0A0A0", +"~ c #D4D4D4", +"{ c #959595", +"] c #3E3E3E", +"^ c #4D4D4D", +"/ c #818181", +"( c #C6C6C6", +"_ c #6A6A6A", +": c #636363", +"< c #B9B9B9", +"[ c #737373", +"} c #010101", +"| c #AAAAAA", +"1 c #0B0B0B", +"2 c #0C0C0C", +"3 c #060606", +"4 c #E4E3E1", +"5 c #050505", +"6 c #B3B3B1", +"7 c #484641", +"8 c #9F9D96", +"9 c #888781", +"0 c #7C7C7C", +"a c #B0AFAD", +"b c #A8A7A1", +"c c #908E86", +"d c #97958E", +"e c #807D74", +"f c #969696", +"g c #090909", +"h c #595854", +"i c #605E57", +"j c #898883", +"k c #76746B", +"l c #43423F", +"m c #282724", +"n c #363430", +"o c #6D6B63", +"p c #E2E2E1", +"q c #B6B5AF", +"r c #21201E", +"s c #0A0908", +"t c #181816", +"u c #E6E6E4", +"v c #65635C", +"w c #161614", +"x c #8C8B89", +"y c #DFDEDC", +"z c #B0AFA9", +"A c #D5D4D1", +"B c #93918B", +"C c #D6D5D2", +"D c #ABA9A3", +"E c #5D5C55", +"F c #494943", +"G c #42413C", +" ", +" ................. ", +" .+@@@@@@@@@@@@@@@#. ", +" .$%&*&*=*&*&*=-&%;. ", +" .@>,&&&&&&&&&&&%'). ", +" .@&>%&&&&&&&&&,!~). ", +" .@*&>,&&&&&&&%{~>). ", +" .@&&&>]&&&&&^/(>>). ", +" .@*&&&_,&&&%_!>&>). ", +" .@&&&:<<%&%{([(}}}. ", +" .@*&:(&>~%'|12:345... ", +" .@&[~&&&&>>2>62787.9.. ", +" .@0~>>>>>>>1ab888cde7. ", +" .[+++++++++fg88hijek. ", +" ...........78ilmn8o7..", +" .pq8hrstuevi.", +" ..78jnwxyv7..", +" .zequABv. ", +" .CD8eekkE7. ", +" ..h.7k7.F.. ", +" .. .G. .. ", +" ... ", +" ", +" "}; diff --git a/etc/images/mail/save.xpm b/etc/images/mail/save.xpm new file mode 100644 index 0000000..0001716 --- /dev/null +++ b/etc/images/mail/save.xpm @@ -0,0 +1,291 @@ +/* XPM */ +static char * mail_save_xpm[] = { +"24 24 264 2", +" c None", +". c #000000", +"+ c #141414", +"@ c #262626", +"# c #212121", +"$ c #1F1F1F", +"% c #1E1E1E", +"& c #1D1D1D", +"* c #202020", +"= c #232323", +"- c #292929", +"; c #171717", +"> c #121212", +", c #B8B8B8", +"' c #FFFFFF", +") c #A8A8A8", +"! c #0E0E0E", +"~ c #595959", +"{ c #444444", +"] c #4F4F4F", +"^ c #050505", +"/ c #222222", +"( c #3D3D3D", +"_ c #FEFEFE", +": c #FCFCFC", +"< c #FDFDFD", +"[ c #CACACA", +"} c #191919", +"| c #B3B1B0", +"1 c #EEECEB", +"2 c #F0DCAA", +"3 c #E5C470", +"4 c #DFB84F", +"5 c #8A681F", +"6 c #100E09", +"7 c #FBFBFB", +"8 c #515151", +"9 c #F0F0F0", +"0 c #D6D6D6", +"a c #EEECE9", +"b c #E6D498", +"c c #EED682", +"d c #EED680", +"e c #E3C15E", +"f c #D29815", +"g c #976E15", +"h c #7F5B0A", +"i c #1C190F", +"j c #D9D9D9", +"k c #424242", +"l c #F1F1F1", +"m c #F3F3F3", +"n c #EBE9E5", +"o c #CBB771", +"p c #735817", +"q c #C6A546", +"r c #E3C05D", +"s c #BC8710", +"t c #AD7C10", +"u c #6B6B6B", +"v c #A0A0A0", +"w c #535353", +"x c #505050", +"y c #AE9C5C", +"z c #292928", +"A c #CECDCA", +"B c #CAC9C7", +"C c #1A1917", +"D c #9C7E2B", +"E c #AB7C12", +"F c #242012", +"G c #555555", +"H c #DEDEDE", +"I c #E8E8E8", +"J c #3B3B3B", +"K c #D7D6D6", +"L c #656462", +"M c #DAD9D7", +"N c #E1E0DF", +"O c #1A1A19", +"P c #3D351F", +"Q c #A37819", +"R c #231F13", +"S c #282828", +"T c #898989", +"U c #EFEFEF", +"V c #FAFAFA", +"W c #E8E7E6", +"X c #8B8B8A", +"Y c #0B0B06", +"Z c #A97C1A", +"` c #1B1B1B", +" . c #C9C9C9", +".. c #DFDFDF", +"+. c #EBEBEB", +"@. c #ECECEC", +"#. c #E1E1E1", +"$. c #221E11", +"%. c #EAE8E3", +"&. c #C58F13", +"*. c #B68411", +"=. c #826321", +"-. c #302C19", +";. c #131313", +">. c #1A1A1A", +",. c #161616", +"'. c #151515", +"). c #181818", +"!. c #1B1B1A", +"~. c #141413", +"{. c #363220", +"]. c #916F25", +"^. c #322F1E", +"/. c #98B4C8", +"(. c #25313B", +"_. c #A9CCE0", +":. c #545A68", +"<. c #BC6A60", +"[. c #AD5A51", +"}. c #A4574D", +"|. c #2B2719", +"1. c #353120", +"2. c #5A4D51", +"3. c #6E8DA2", +"4. c #0C1820", +"5. c #BAE5FF", +"6. c #696E6F", +"7. c #F9F9F9", +"8. c #EBEBEA", +"9. c #937025", +"0. c #CDCAC1", +"a. c #73726E", +"b. c #7496AF", +"c. c #0A131A", +"d. c #BAE0FD", +"e. c #6A6E71", +"f. c #ECEDEC", +"g. c #DEDFDF", +"h. c #DBDDDD", +"i. c #D8DBDB", +"j. c #CDCFCF", +"k. c #312E1B", +"l. c #2F2C19", +"m. c #B2B3B0", +"n. c #C0C0BE", +"o. c #6F6D6B", +"p. c #7C9FBB", +"q. c #050F15", +"r. c #B7DDFC", +"s. c #54575A", +"t. c #F4F4F3", +"u. c #ECECEB", +"v. c #F3F3F2", +"w. c #7F7D7A", +"x. c #7EA0BB", +"y. c #020A10", +"z. c #B1D7F7", +"A. c #FDFCFB", +"B. c #EFEFEE", +"C. c #EDEDEC", +"D. c #EBECEB", +"E. c #EBECEC", +"F. c #F7F7F6", +"G. c #7D7977", +"H. c #7F9FB9", +"I. c #050B0E", +"J. c #B3DDF7", +"K. c #685050", +"L. c #847F7C", +"M. c #7E9DB7", +"N. c #0A0B0C", +"O. c #A9D3F0", +"P. c #7B99AB", +"Q. c #6B6E70", +"R. c #63696C", +"S. c #60666B", +"T. c #5E6569", +"U. c #555E67", +"V. c #5D6267", +"W. c #61676B", +"X. c #64696D", +"Y. c #62666A", +"Z. c #6B747E", +"`. c #7D9CB4", +" + c #000508", +".+ c #A8CBED", +"++ c #7498B7", +"@+ c #6F92B0", +"#+ c #3F5160", +"$+ c #4A5E70", +"%+ c #566E82", +"&+ c #4D6779", +"*+ c #52697C", +"=+ c #52697A", +"-+ c #54687A", +";+ c #455E70", +">+ c #7697B4", +",+ c #92A9BC", +"'+ c #000205", +")+ c #A8CEEB", +"!+ c #7196B3", +"~+ c #4D5152", +"{+ c #D7D2CB", +"]+ c #F1EEEA", +"^+ c #FAF8F5", +"/+ c #F9F8F5", +"(+ c #E8E4DF", +"_+ c #D8D4CD", +":+ c #9D968B", +"<+ c #425563", +"[+ c #446783", +"}+ c #A7C4DA", +"|+ c #000101", +"1+ c #A5CDEA", +"2+ c #7196B1", +"3+ c #57595C", +"4+ c #534F46", +"5+ c #2E281F", +"6+ c #CAC7C2", +"7+ c #C9C4BD", +"8+ c #C2BBB1", +"9+ c #E3E0DC", +"0+ c #314353", +"a+ c #40647C", +"b+ c #B6C9DA", +"c+ c #A3CDEB", +"d+ c #7695B1", +"e+ c #525455", +"f+ c #474239", +"g+ c #3B372D", +"h+ c #C0BCB5", +"i+ c #C7C2BA", +"j+ c #E2DFD9", +"k+ c #F8F6F3", +"l+ c #344652", +"m+ c #406479", +"n+ c #A6C3DA", +"o+ c #010000", +"p+ c #708798", +"q+ c #6A8DA7", +"r+ c #4F5052", +"s+ c #F7F2EC", +"t+ c #59534B", +"u+ c #57524A", +"v+ c #C1BCB4", +"w+ c #EBE9E4", +"x+ c #FFFFFD", +"y+ c #30414E", +"z+ c #415C6F", +"A+ c #A2C4DC", +"B+ c #020000", +"C+ c #030406", +"D+ c #141A1F", +"E+ c #151718", +"F+ c #35332F", +"G+ c #393634", +"H+ c #41403E", +"I+ c #3F3E3D", +"J+ c #454344", +"K+ c #434241", +"L+ c #312F2C", +"M+ c #02070A", +"N+ c #070E12", +"O+ c #465A69", +". + @ # $ % & & & % * = - ; . ", +"> , ' ' ' ' ' ' ' ' ' ' ' ) ! ", +"@ ' ~ ' ' ' ' ' ' ' ' ' { ] ^ . . . ", +"/ ' ' ( ' _ : < < ' [ } | 1 2 3 4 5 . 6 ", +"* ' ' 7 8 9 < 7 _ 0 @ a b c d d e f g h i ", +"$ ' ' ' j k l : m $ n o . . . p q r s t i ", +"* ' ' ' u v w ' x . y z A B C D d f E F ", +"/ ' ' G H 7 I J , K > L M N O P d f Q R ", +"S ' T U ' ' ' _ V ' < W X Y . . . d f Z . . . ", +"` ...U +.+.+.@.@.+.@.+.#.$.%.d d d f &.*.=.-.. ", +". ;.>.; ,.'.'.'.'.'.,.).!.~.{.%.d d f f ].^./.(.", +" . _.:.<.[.}.|.%.d f ].1.2.3.4.", +" . 5.6.' ' 7.8.-.%.9.^.0.a.b.c.", +" . d.e.f.g.h.i.j.k.l.m.n.o.p.q.", +" . r.s.' ' ' ' ' ' t.u.v.w.x.y.", +" . z.6.A.B.C.D.+.E.C.U F.G.H.I.", +" . J.K.' ' ' ' ' ' ' ' ' L.M.N.", +" . O.P.Q.R.S.T.U.V.W.X.Y.Z.`. +", +" . .+++@+#+$+%+&+*+=+-+;+>+,+'+", +" . )+!+~+{+]+^+/+(+_+:+<+[+}+|+", +" . 1+2+3+' 4+5+6+7+8+9+0+a+b+. ", +" . c+d+e+' f+g+h+i+j+k+l+m+n+o+", +" . p+q+r+s+t+u+v+w+x+]+y+z+A+B+", +" C+D+E+F+G+H+I+J+K+L+M+N+O+. "}; diff --git a/etc/images/mail/send.xpm b/etc/images/mail/send.xpm new file mode 100644 index 0000000..44ee493 --- /dev/null +++ b/etc/images/mail/send.xpm @@ -0,0 +1,85 @@ +/* XPM */ +static char * stock_mail_send_xpm[] = { +"24 24 58 1", +" c None", +". c #4F3F0A", +"+ c #000000", +"@ c #F4E6B5", +"# c #F4E5B3", +"$ c #EDD684", +"% c #755F10", +"& c #EDD580", +"* c #EED685", +"= c #AF8D18", +"- c #EFD98C", +"; c #EED88B", +"> c #EDD582", +", c #EED889", +"' c #EFDA92", +") c #F0DB93", +"! c #735D10", +"~ c #535353", +"{ c #FFFFFF", +"] c #F0DC97", +"^ c #F6F6F6", +"/ c #F5F5F5", +"( c #F4F4F4", +"_ c #E3E3E3", +": c #EEEEEE", +"< c #4F4F4F", +"[ c #EDD37C", +"} c #EDEDED", +"| c #AEAEAE", +"1 c #E4E4E4", +"2 c #434343", +"3 c #FDFDFD", +"4 c #F3F3F3", +"5 c #E4BF3D", +"6 c #CBA41C", +"7 c #D1A81C", +"8 c #907413", +"9 c #7C6411", +"0 c #ACACAC", +"a c #C8C8C8", +"b c #FBFBFB", +"c c #A0A0A0", +"d c #D4D4D4", +"e c #F8F8F8", +"f c #F0F0F0", +"g c #EFEFEF", +"h c #ECECEC", +"i c #959595", +"j c #3E3E3E", +"k c #4D4D4D", +"l c #818181", +"m c #C6C6C6", +"n c #6A6A6A", +"o c #636363", +"p c #B9B9B9", +"q c #737373", +"r c #7C7C7C", +"s c #BCBCBC", +" ", +" . ", +" +@+ ", +" +#$%+ ", +" +#&*=%+ ", +" +#-;>==%+ ", +" +#,',>===%+ ", +" ++++++)$&=!++++++ ", +" +~{{{{+]$$=!+^/(_~+ ", +" +:<{/(+,[$=!+:}_<|+ ", +" +{1234+56789+}_<0a+ ", +" +{/1 c #EDF0F1", +", c #E5EDEF", +"' c #C5D9DD", +") c #2E3132", +"! c #3F4343", +"~ c #1F2121", +"{ c #DFEBEE", +"] c #B7C4C8", +"^ c #D2D9DA", +"/ c #E1EFF2", +"( c #B6CBCF", +"_ c #3C4547", +": c #1E2223", +"< c #191E1F", +"[ c #2D2E2F", +"} c #191A1A", +"| c #252829", +"1 c #7E8E92", +"2 c #B7C2C3", +"3 c #C3D9DD", +"4 c #9CACB0", +"5 c #C3CDCE", +"6 c #C7E1E7", +"7 c #668F97", +"8 c #90ACB2", +"9 c #CDDDE1", +"0 c #485559", +"a c #88A6AC", +"b c #1F2223", +"c c #3F4545", +"d c #242728", +"e c #313B3E", +"f c #A8C2C8", +"g c #B2BDC0", +"h c #CFE5E9", +"i c #C2D9DE", +"j c #81989C", +"k c #A2C0C5", +"l c #85A9B1", +"m c #E5ECEE", +"n c #E7F2F4", +"o c #9BAEB3", +"p c #C8E1E7", +"q c #3A3E3F", +"r c #0C0E0E", +"s c #000000", +"t c #333737", +"u c #B3C2C5", +"v c #DDEDF0", +"w c #D8E4E6", +"x c #DAECEF", +"y c #D5E9ED", +"z c #D2E7EC", +"A c #95ADB2", +"B c #DBE2E2", +"C c #EDEFF0", +"D c #A2B1B3", +"E c #8FA4A8", +"F c #D7E2E5", +"G c #798F94", +"H c #151819", +"I c #F3B5A7", +"J c #865E55", +"K c #AFB9BB", +"L c #F1F8F9", +"M c #F7FBFB", +"N c #D9EBEF", +"O c #ECF4F6", +"P c #F3F7F7", +"Q c #E9F2F4", +"R c #EEF2F3", +"S c #E9EDEE", +"T c #C5C8C9", +"U c #C2C6C8", +"V c #E0E7E7", +"W c #DDEAED", +"X c #7A9DA5", +"Y c #EB8169", +"Z c #B83618", +"` c #924E3C", +" . c #9FA5A6", +".. c #E3EEF0", +"+. c #ECF5F7", +"@. c #D6EAED", +"#. c #CBE4E9", +"$. c #D9E7E9", +"%. c #E1EBED", +"&. c #B8CBD0", +"*. c #BDCBCF", +"=. c #ABB3B5", +"-. c #E3E5E5", +";. c #DCEBEF", +">. c #6A979F", +",. c #131819", +"'. c #B43518", +"). c #E76A4D", +"!. c #B53F24", +"~. c #CB705A", +"{. c #C4D8DB", +"]. c #D2E6E9", +"^. c #CAE3E8", +"/. c #A9C8CF", +"(. c #7FA4AA", +"_. c #82B4BE", +":. c #E2EFF0", +"<. c #D3E7EA", +"[. c #AFD5DE", +"}. c #C7E2E7", +"|. c #E7F1F2", +"1. c #97C3CB", +"2. c #637F86", +"3. c #191311", +"4. c #EF9985", +"5. c #F1A897", +"6. c #E76547", +"7. c #C58B7D", +"8. c #A8ABAC", +"9. c #70A1AB", +"0. c #88B5BE", +"a. c #95C7D1", +"b. c #ADD4DC", +"c. c #DCEAEF", +"d. c #B5D8E0", +"e. c #CAE4E9", +"f. c #95BEC6", +"g. c #6696A0", +"h. c #585857", +"i. c #51190C", +"j. c #D9401D", +"k. c #EC8A74", +"l. c #E17055", +"m. c #DD8D7A", +"n. c #D8E7EA", +"o. c #D8E9ED", +"p. c #D6EAEE", +"q. c #D9EBEE", +"r. c #E4F0F3", +"s. c #CFE3E8", +"t. c #5B94A0", +"u. c #5C7E85", +"v. c #3D221D", +"w. c #782310", +"x. c #EA7A60", +"y. c #E5A293", +"z. c #EBD9D5", +"A. c #C6D3D6", +"B. c #799FA8", +"C. c #558C98", +"D. c #45686E", +"E. c #27201F", +"F. c #5D3228", +"G. c #B86F5D", +"H. c #F1A593", +"I. c #E58D78", +"J. c #C0C0C1", +"K. c #32464B", +"L. c #4A6E75", +"M. c #282121", +"N. c #4A2E27", +"O. c #C6968B", +"P. c #DDA89B", +"Q. c #5F1C0D", +"R. c #F2AFA0", +"S. c #A36F63", +"T. c #341C17", +"U. c #301A15", +"V. c #674C45", +"W. c #E4AEA1", +"X. c #8D2A13", +"Y. c #030505", +"Z. c #A2432E", +"`. c #E4A799", +" + c #D97C67", +".+ c #B66A59", +"++ c #B26C5C", +"@+ c #882812", +"#+ c #DB411D", +"$+ c #F4BAAC", +" ", +" ", +" ", +" ", +" . + @ ", +" # $ % & * . ", +" = - ; > , ' ) ! ", +" ~ { ] ^ / ( _ : < [ } ", +" | 1 2 3 4 5 6 7 8 9 0 a b ", +" c d e f g h i j k l m n o p q r ", +" s t u v w / x y z A B C D E F G H ", +" s s I J K L M N O P Q R S T U V W X < ", +"s I Y Z ` ...+.@.#.$.%.h &.*.=.-.;.>.,.s ", +"s '.).Y !.~.{.].^./.(._.:.<.[.}.|.1.2.3.4.s ", +"s '.'.'.).5.6.7.8.9.0.a.b.c.d.e.f.g.h.i.j.k.s ", +"s '.'.'.'.'.).5.l.m.n.o.p.q.r.s.t.u.v.w.j.x.s ", +" s s '.'.'.'.'.).5.6.y.z.A.B.C.D.E.F.G.H.4.s ", +" s s '.'.'.'.'.).5.I.J.K.L.M.N.O.P.Q.s ", +" s s '.'.'.'.'.R.S.T.U.V.W.X.s s ", +" Y.s s Z.'.'.`. +.+++@+s s ", +" s s s '.#+$+s s s ", +" s s s s s ", +" ", +" "}; diff --git a/etc/images/new.xpm b/etc/images/new.xpm new file mode 100644 index 0000000..2d4690e --- /dev/null +++ b/etc/images/new.xpm @@ -0,0 +1,154 @@ +/* XPM */ +static char * new_xpm[] = { +"24 24 127 2", +" c None", +". c #000000", +"+ c #D3D3D3", +"@ c #F6F6F6", +"# c #FFFFFF", +"$ c #F9F9F9", +"% c #DADADA", +"& c #585858", +"* c #C7C7C7", +"= c #D1D1D1", +"- c #D6D6D6", +"; c #FEFEFE", +"> c #FDFDFD", +", c #C0C0C0", +"' c #E1E1E1", +") c #F0F0F0", +"! c #9B9B9B", +"~ c #FCFCFB", +"{ c #FBFBFB", +"] c #AFAFAE", +"^ c #E9E9E9", +"/ c #DFDFDF", +"( c #8F8F8F", +"_ c #FAFAF9", +": c #F9F9F8", +"< c #A4A4A3", +"[ c #F4F4F4", +"} c #CFCFCF", +"| c #A2A2A2", +"1 c #F8F8F7", +"2 c #F8F7F6", +"3 c #9E9E9E", +"4 c #F7F6F5", +"5 c #F6F6F4", +"6 c #F4F3F2", +"7 c #DEDDDC", +"8 c #D3D2D0", +"9 c #B7B7B5", +"0 c #9F9E9D", +"a c #706F6F", +"b c #65625A", +"c c #F5F4F3", +"d c #F2F2F0", +"e c #E4E4E2", +"f c #DAD9D7", +"g c #D8D8D6", +"h c #CDCCCA", +"i c #AFAEAC", +"j c #88847B", +"k c #F3F3F1", +"l c #EFEFED", +"m c #EEEDEB", +"n c #EDECEA", +"o c #E9E8E6", +"p c #D5D4D3", +"q c #C4C3C2", +"r c #8F8A81", +"s c #F6F5F4", +"t c #F5F5F3", +"u c #F1F1EF", +"v c #F1F0EE", +"w c #ECEBE9", +"x c #EAE9E7", +"y c #E5E4E2", +"z c #E4E3E0", +"A c #D2D1CE", +"B c #8D887E", +"C c #F3F2F1", +"D c #F0F0EE", +"E c #F0EFED", +"F c #EFEEEC", +"G c #E8E7E5", +"H c #E5E4E1", +"I c #E2E1DE", +"J c #E1DFDC", +"K c #979288", +"L c #A49E93", +"M c #E8E7E4", +"N c #E7E6E3", +"O c #E3E2DF", +"P c #E2E0DD", +"Q c #E1E0DC", +"R c #E0DFDB", +"S c #A19C90", +"T c #EDEDEB", +"U c #EBEAE8", +"V c #E9E8E5", +"W c #E6E4E1", +"X c #E3E2DE", +"Y c #DFDEDA", +"Z c #DEDDD9", +"` c #DDDCD8", +" . c #A19B90", +".. c #E7E5E2", +"+. c #E4E3DF", +"@. c #DCDBD7", +"#. c #E6E5E2", +"$. c #E5E4E0", +"%. c #E2E1DD", +"&. c #DBD9D5", +"*. c #D9D7D3", +"=. c #9F998D", +"-. c #E4E2DF", +";. c #DDDBD7", +">. c #DCDAD6", +",. c #D8D6D2", +"'. c #9E988D", +"). c #EDEDED", +"!. c #E1E0DD", +"~. c #E0DEDA", +"{. c #D8D6D1", +"]. c #D7D5D1", +"^. c #9D978B", +"/. c #E1DFDB", +"(. c #DEDCD8", +"_. c #D7D6D1", +":. c #D5D3CE", +"<. c #9B958A", +"[. c #999891", +"}. c #A39E92", +"|. c #A39D92", +"1. c #A39D91", +"2. c #A29C90", +"3. c #A19B8F", +"4. c #9D978C", +"5. c #9B968A", +"6. c #676359", +" ", +" . . . . . . . . . . . . . ", +" . + @ # # # # # # # # $ % & . ", +" . @ # # # # # # # # # # * = - . ", +" . # # # # # # # ; # ; > , ' ) ! . ", +" . # # # # # ; > ~ > ~ { ] ^ # / ( . ", +" . # # # ; > ~ { _ { _ : < ) # [ } | . ", +" . # ; > ~ { _ : 1 : 1 2 3 . . . . . . . ", +" . # ~ { _ : 1 2 4 2 4 5 6 7 8 9 0 a b . ", +" . # _ : 1 2 4 5 c 5 c 6 d e f g h i j . ", +" . # 1 2 4 5 c 6 k 6 k d l m n o p q r . ", +" . # s t 6 6 k d u d u v m w x y z A B . ", +" . # 6 C d D l v E v E F w G H z I J K . ", +" . # 6 C d D l v E v E F w G H z I J L . ", +" . # D l l F m n n n n w M N O P Q R S . ", +" . # T n w w w U V U V V H W X Y Z ` .. ", +" . # U o o G M M N M N ..+.X R Z ` @. .. ", +" . # N #.#.#.H W $.W $.+.%.R Z @.&.*.=.. ", +" . $ z O X -.+.%.X %.X Q Q Z ;.>.*.,.'.. ", +" . ).!.J Q R %.R Q R Q Y ~.;.>.*.{.].^.. ", +" . = /.~.Y Z R Z ~.Z ~.(.(.>.>.,._.:.<.. ", +" . [.}.L |.1.|.S 2.S 2.3. .=.=.4.4.5.6.. ", +" . . . . . . . . . . . . . . . . . . ", +" "}; diff --git a/etc/images/next-node.xpm b/etc/images/next-node.xpm new file mode 100644 index 0000000..385766e --- /dev/null +++ b/etc/images/next-node.xpm @@ -0,0 +1,45 @@ +/* XPM */ +static char * next_node2_xpm[] = { +"24 24 18 1", +" c None", +". c #000000", +"+ c #FFFFFF", +"@ c #DADAD6", +"# c #BCBCB8", +"$ c #506B46", +"% c #778E6F", +"& c #0F1308", +"* c #77A16E", +"= c #C2D7BE", +"- c #6B9060", +"; c #A9C7A6", +"> c #C1D6BD", +", c #BDD3B8", +"' c #B0CAAD", +") c #A4C3A2", +"! c #445B2C", +"~ c #8CA782", +" .................. ", +" .+++++++++++++++@#. ", +" .+++++++++++++++#+#. ", +" .+++$#++++++++++#%$&. ", +" .+++..#@++++++++@%$&. ", +" .+++.*.#@@+@++++++@#. ", +" .+@@.=-.#@@++@@@@@@#. ", +".......=;-.#@@@+@@@@@#. ", +".=>>>>>,;;-.#@@@@@@@@#. ", +".=;;;;';;;;-.##@@@@@@#. ", +".@>,,,>,,,,;-.#@@@@@@#. ", +".)----------!.%#@@@@@#. ", +".~---------!.%##@@@@##. ", +".*--------!.$%##@@@@@#. ", +".......--!.%####@@@@@#. ", +" .##%.-!.$%####@@@@##. ", +" .@##.!.%####@####@##. ", +" .+##..%%#####@@@@@@#. ", +" .+@#.#####@@@####@@#. ", +" .+@@#####@@@@####@##. ", +" .+##################. ", +" ..................... ", +" ", +" "}; diff --git a/etc/images/next-page.xpm b/etc/images/next-page.xpm new file mode 100644 index 0000000..75236fe --- /dev/null +++ b/etc/images/next-page.xpm @@ -0,0 +1,119 @@ +/* XPM */ +static char * stock_next_page_xpm[] = { +"24 24 92 2", +" c None", +". c #000000", +"+ c #5B7289", +"@ c #FFFFFF", +"# c #F2F2F2", +"$ c #E5E5E5", +"% c #D8D8D8", +"& c #CCCCCC", +"* c #B0B0B0", +"= c #8B8B8B", +"- c #6A6A6A", +"; c #494949", +"> c #888888", +", c #C9C9C9", +"' c #E3E3E3", +") c #EEEEEE", +"! c #E6E6E6", +"~ c #DEDEDE", +"{ c #D6D6D6", +"] c #ADADAD", +"^ c #556D85", +"/ c #47617B", +"( c #BFBFBF", +"_ c #B2B2B2", +": c #ACACAC", +"< c #A6A6A6", +"[ c #F6F6F6", +"} c #384F66", +"| c #3A5067", +"1 c #DADADA", +"2 c #3A5168", +"3 c #D3D3D3", +"4 c #3B5269", +"5 c #47617C", +"6 c #3D526A", +"7 c #48627D", +"8 c #B6B6B6", +"9 c #959595", +"0 c #7C7C7C", +"a c #616161", +"b c #464646", +"c c #262626", +"d c #C5C5C5", +"e c #3E546A", +"f c #49637D", +"g c #3F556B", +"h c #4B647E", +"i c #40566C", +"j c #4C647F", +"k c #41576D", +"l c #4C657F", +"m c #42586E", +"n c #4E6780", +"o c #44586F", +"p c #4F6881", +"q c #B5B5B5", +"r c #45596F", +"s c #506982", +"t c #77838F", +"u c #9C9FA1", +"v c #91969C", +"w c #91979C", +"x c #92979C", +"y c #92979D", +"z c #A2A3A4", +"A c #9D9FA2", +"B c #8F9296", +"C c #8F9396", +"D c #8F9397", +"E c #909397", +"F c #868788", +"G c #465B70", +"H c #526A83", +"I c #3E5975", +"J c #3F5A76", +"K c #415B77", +"L c #425C78", +"M c #435E79", +"N c #445F7A", +"O c #46607B", +"P c #68727D", +"Q c #7D8185", +"R c #616A73", +"S c #3B4F63", +"T c #3C5064", +"U c #3C5065", +"V c #3E5166", +"W c #3F5266", +"X c #405367", +"Y c #405468", +"Z c #344353", +"` c #2F4050", +" ", +" ", +" . . . . . . . . . . . . . . . . ", +" . + @ # $ % & * = - ; > , ' ) ! ~ { ] ^ . ", +" . / @ # $ % & ( _ : < @ @ [ ) ! ~ { _ } . ", +" . / @ # $ % & ( _ : < @ ' [ ) ! ~ { _ | . ", +" . / @ # $ % & ( _ : < @ . 1 ) ! ~ { * 2 . ", +" . / @ # $ % & ( _ : < @ . . 3 ! ~ { * 4 . ", +" . 5 @ # $ % & ( _ : < @ . . . & ~ { * 6 . ", +" . 7 @ # $ 8 9 0 a b c . . . . . d { * e . ", +" . f @ # $ % & ( _ : < @ . . . & ~ { * g . ", +" . h @ # $ % & ( _ : < @ . . 3 ! ~ { * i . ", +" . j @ # $ % & ( _ : < @ . 1 ) ! ~ { * k . ", +" . l @ # $ % & ( _ : < @ ' [ ) ! ~ { * m . ", +" . n @ # $ % & ( _ : < @ @ [ ) ! ~ { * o . ", +" . p @ # $ % & ( _ : < @ @ [ ) ! ~ { q r . ", +" . s t u v w x y y z < A B C C D D E F G . ", +" . H I J K L M N O P Q R S T U V W X Y Z . ", +" . . . . . . . . . ` . . . . . . . . . . ", +" . . . ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/open.xpm b/etc/images/open.xpm new file mode 100644 index 0000000..6b95c7e --- /dev/null +++ b/etc/images/open.xpm @@ -0,0 +1,200 @@ +/* XPM */ +static char * open_xpm[] = { +"24 24 173 2", +" c None", +". c #000000", +"+ c #010100", +"@ c #B5B8A5", +"# c #E4E7D2", +"$ c #878A76", +"% c #33342B", +"& c #0B0B0B", +"* c #E2E5CF", +"= c #CFD4AF", +"- c #CED3AE", +"; c #B2B696", +"> c #2D2D25", +", c #23241D", +"' c #9D9F90", +") c #C6CAA6", +"! c #C4C9A5", +"~ c #C6CBA7", +"{ c #C7CCA8", +"] c #C9CEA9", +"^ c #555847", +"/ c #1A1B15", +"( c #20201A", +"_ c #D4D6C2", +": c #BEC2A0", +"< c #B3B896", +"[ c #B0B595", +"} c #B3B797", +"| c #B6BB99", +"1 c #BBC09E", +"2 c #BCC19F", +"3 c #81856C", +"4 c #3E3F32", +"5 c #010101", +"6 c #DADDC8", +"7 c #AFB494", +"8 c #AAAF8F", +"9 c #A3A789", +"0 c #A6AA8B", +"a c #A9AD8E", +"b c #A7AB8D", +"c c #A4A88A", +"d c #A1A588", +"e c #AAAD96", +"f c #B3B5A5", +"g c #B8BBAA", +"h c #BABCAB", +"i c #C1C3B2", +"j c #C7CAB7", +"k c #CACDBB", +"l c #BABDA8", +"m c #0C0C09", +"n c #DDDFCB", +"o c #969B7E", +"p c #9DA286", +"q c #95987C", +"r c #96997E", +"s c #9A9D81", +"t c #999D80", +"u c #9DA184", +"v c #A5AA8B", +"w c #A4A98A", +"x c #A3A889", +"y c #A2A588", +"z c #A2A587", +"A c #9FA386", +"B c #9B9E83", +"C c #898D74", +"D c #D8DBC9", +"E c #84866E", +"F c #7D8169", +"G c #151612", +"H c #D7DAC9", +"I c #797D67", +"J c #3D3F34", +"K c #E0E0D9", +"L c #EBEDDD", +"M c #E8EBD9", +"N c #E7EAD8", +"O c #E3E6D4", +"P c #DEE1D0", +"Q c #DADCCC", +"R c #DADCD1", +"S c #2B2C28", +"T c #D7DAC6", +"U c #6F735E", +"V c #0D0D0D", +"W c #F4F4EC", +"X c #CACFAB", +"Y c #C6CBA8", +"Z c #C2C6A4", +"` c #ABB091", +" . c #23251E", +".. c #494B3D", +"+. c #DCDCD4", +"@. c #EAECDD", +"#. c #CDD2AD", +"$. c #CCD1AC", +"%. c #CACFAA", +"&. c #BABF9D", +"*. c #B5B999", +"=. c #81836C", +"-. c #070806", +";. c #D5D8C4", +">. c #161616", +",. c #F2F2EA", +"'. c #C9CEAA", +"). c #C8CDA9", +"!. c #C4C9A6", +"~. c #C1C5A3", +"{. c #BCC09F", +"]. c #B6BB9A", +"^. c #B0B494", +"/. c #9DA185", +"(. c #535445", +"_. c #B6B8A7", +":. c #747470", +"<. c #ECECE2", +"[. c #C3C8A5", +"}. c #C2C7A4", +"|. c #C0C5A2", +"1. c #BFC4A1", +"2. c #BDC2A0", +"3. c #B9BD9C", +"4. c #B9BE9D", +"5. c #A9AD8F", +"6. c #A3A78A", +"7. c #80836D", +"8. c #020201", +"9. c #A6A998", +"0. c #B8BC9B", +"a. c #AFB394", +"b. c #ACB091", +"c. c #A8AC8E", +"d. c #A6AA8C", +"e. c #9FA286", +"f. c #9B9F83", +"g. c #9A9D82", +"h. c #8A8D75", +"i. c #4F5243", +"j. c #070705", +"k. c #9E9F91", +"l. c #E5E6DA", +"m. c #ADB192", +"n. c #A5A98C", +"o. c #9FA387", +"p. c #999D81", +"q. c #95987E", +"r. c #92957B", +"s. c #8C8F76", +"t. c #8A8D74", +"u. c #71735F", +"v. c #080908", +"w. c #E3E5D9", +"x. c #C0C3AF", +"y. c #94987C", +"z. c #8F9379", +"A. c #8B8F75", +"B. c #8A8E74", +"C. c #888C73", +"D. c #858970", +"E. c #868971", +"F. c #82866E", +"G. c #80836C", +"H. c #7D8069", +"I. c #797C66", +"J. c #727560", +"K. c #717460", +"L. c #71745F", +"M. c #6A6D59", +"N. c #434538", +"O. c #080907", +"P. c #050504", +" ", +" ", +" ", +" . . . . . . . ", +" + @ # # # # # $ % ", +" & * = = = - - ; > ", +", ' * ) ! ~ { ] ] ^ / ", +"( _ : < [ } | 1 2 3 4 5 . . . . . . . ", +", 6 7 8 9 0 8 a b c d e f g h i j k l . ", +"m n o p q r s t r u v w x y 9 z A B C . ", +". D E F G . . . . . . . . . . . . . . . 5 5 ", +". H I J K L M M M M M M M M M M M N O P Q R S ", +". T U V W = = = = = = = = = - - - X Y Z 1 ` . ", +". T ..+.@.#.- - #.- #.#.#.#.#.$.%.Y Z &.*.=.-. ", +". ;.>.,.X %.X %.'.%.'.{ ).).Y !.~.{.].^./.(.m ", +". _.:.<.[.}.}.Z |.Z 1.2.|.2.3.4.} [ 5.6.7.8. ", +". 9.+.0.0.*.} } [ [ a.a.a.b.c.d.e.f.g.h.i.j. ", +". k.l.m.5.d.n.6.6.d o.e.f.p.q.r.s.t.t.u.v. ", +". w.x.y.z.A.B.C.C.D.E.F.G.H.I.J.K.L.M.N.O. ", +" . . . . . . . . . . . . . . . . . . P. ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/paste.xpm b/etc/images/paste.xpm new file mode 100644 index 0000000..cdd8636 --- /dev/null +++ b/etc/images/paste.xpm @@ -0,0 +1,116 @@ +/* XPM */ +static char * paste_xpm[] = { +"24 24 89 1", +" c None", +". c #000000", +"+ c #B9B9B9", +"@ c #FEFEFE", +"# c #F9F9F9", +"$ c #757575", +"% c #F5F5E8", +"& c #565651", +"* c #FFFFFF", +"= c #A0A0A0", +"- c #939393", +"; c #7C7C7C", +"> c #C5C5BB", +", c #CFC6A0", +"' c #D7CEAA", +") c #ADA689", +"! c #4B483C", +"~ c #6D6D6D", +"{ c #6C6C6C", +"] c #A9A9A9", +"^ c #3D3A30", +"/ c #979178", +"( c #C1B898", +"_ c #8A793D", +": c #C3BB9A", +"< c #AFA78A", +"[ c #444236", +"} c #FAFAFA", +"| c #EFEFEF", +"1 c #C7C7C7", +"2 c #D8D8D8", +"3 c #D2D2D2", +"4 c #7B7B7B", +"5 c #302E26", +"6 c #89846C", +"7 c #C4BC9A", +"8 c #847235", +"9 c #C5C5C5", +"0 c #A7A7A7", +"a c #ADADAD", +"b c #9A9A9A", +"c c #9B9B9B", +"d c #868686", +"e c #424242", +"f c #847033", +"g c #C9C09E", +"h c #464337", +"i c #35332A", +"j c #2D2B23", +"k c #C6BE9D", +"l c #826F33", +"m c #7F7964", +"n c #4C493C", +"o c #171612", +"p c #13120F", +"q c #3E3B31", +"r c #282210", +"s c #474438", +"t c #B3B3B3", +"u c #D6D6D6", +"v c #B7AE90", +"w c #B1AA8C", +"x c #37352B", +"y c #151410", +"z c #8F8F8F", +"A c #989898", +"B c #C6C6C6", +"C c #B9B293", +"D c #11100D", +"E c #434035", +"F c #636363", +"G c #767676", +"H c #AAA48B", +"I c #A5A086", +"J c #A19A7F", +"K c #312F26", +"L c #AFA88C", +"M c #050403", +"N c #12110E", +"O c #A9A489", +"P c #A39E85", +"Q c #EBE7D0", +"R c #D2C9A5", +"S c #A29053", +"T c #8E7C3D", +"U c #88793B", +"V c #806C2F", +"W c #78652B", +"X c #251F0C", +" .... ", +" ......+@#$...... ", +".%%%%%&*=-;&>%%%,. ", +".%''')!*~{]^/(''_. ", +".%::<[}|123456<78. ", +".%''!900abcde!)'f. ", +".%g:6hijjjjj56 c #CCCCCC", +", c #AFAFAF", +"' c #D3D1CB", +") c #C1C0BF", +"! c #F0EFED", +"~ c #797772", +"{ c #DCDCDC", +"] c #A5A19C", +"^ c #EAE9E5", +"/ c #F3F1F0", +"( c #EDEDED", +"_ c #A19D96", +": c #C1BDB4", +"< c #DBD8D3", +"[ c #D9D6D1", +"} c #89857E", +"| c #FCFCFC", +"1 c #EAE9E6", +"2 c #F5F4F3", +"3 c #C6C2BA", +"4 c #F0EFEE", +"5 c #F4F4F3", +"6 c #CBC7C0", +"7 c #ECECEB", +"8 c #676560", +"9 c #54524D", +"0 c #777676", +"a c #797978", +"b c #85827E", +"c c #79756F", +"d c #7590AE", +"e c #A4BAD0", +"f c #90A6BE", +"g c #9F9F9E", +"h c #BEBDBC", +"i c #B8B4AD", +"j c #87837C", +"k c #D3DFEA", +"l c #A2AEBC", +"m c #9DB6CE", +"n c #637B95", +"o c #E2E2E2", +"p c #EEEEED", +"q c #849CB6", +"r c #D7E2ED", +"s c #8D98A5", +"t c #9DB8D2", +"u c #607791", +"v c #EDEDEC", +"w c #99ADC3", +"x c #DFE7F0", +"y c #8193A9", +"z c #586D84", +"A c #5B7189", +"B c #F1F1F1", +"C c #EEEDEB", +"D c #A7A6A5", +"E c #726F6A", +"F c #A1B4C8", +"G c #EEF3F6", +"H c #60768F", +"I c #DEDDDC", +"J c #787776", +"K c #4E4E4D", +"L c #91A6BE", +"M c #F0F4F7", +"N c #97A5B6", +"O c #BFBEBD", +"P c #AAAAA9", +"Q c #ACACAB", +"R c #B0C6DB", +"S c #EDF2F6", +"T c #818A95", +"U c #6C85A1", +"V c #C0D1E2", +" .. ", +" .+@#. ", +" .$%+. .. ", +" .&$. .*=. ", +" .. -;$. .*>,. ", +" .' ..)!+~. .{,. ", +" .]%%^/+++. .(.. ", +" ._:%$<[+}. .|. ", +" .....123}..>. ", +" .456.,. ", +" .7.,.. ", +" .,.89. ", +" ....,.0abc. ", +" .def.. .ghij. ", +" .dklmn. .op6}. ", +" .qrsntu. .v/$}. ", +" .wxyztdA. .BCDE..", +" .FGyHtdA. .IJK,.", +" .LMNHtdA. .OPQ.", +" .RSTtdA.. ... ", +" .UtVLA.. ", +" .UUn.. ", +" ... ", +" "}; diff --git a/etc/images/prev-node.xpm b/etc/images/prev-node.xpm new file mode 100644 index 0000000..586bf9c --- /dev/null +++ b/etc/images/prev-node.xpm @@ -0,0 +1,44 @@ +/* XPM */ +static char * prev_node3_xpm[] = { +"24 24 17 1", +" c None", +". c #000000", +"+ c #0F1308", +"@ c #FFFFFF", +"# c #BCBCB8", +"$ c #DADAD6", +"% c #778E6F", +"& c #C2D7BE", +"* c #A6BFA0", +"= c #A9C7A6", +"- c #BDD3B8", +"; c #B0CAAD", +"> c #C1D6BD", +", c #8CA782", +"' c #5B7950", +") c #6B9060", +"! c #445B2C", +" .................. ", +" +@#@@@@@@@@@@@@@@$. ", +" +@@%$@@@@@@@@@@@@@$. ", +" .$#%%$@@@@@@@@@$.$$$. ", +" .%$##$@@@@@@@@#..$$$. ", +" .#@@@@@@@@@$$#.&.#$$. ", +" .$@@@@@@@@@@#.$*.##$. ", +" .@@@@@@@@$$#.$=*.......", +" .@@@@@@@$$#.$==-&&&&&*.", +" .@@@@@@@$#.@====;====%.", +" .@$@$$$$#.$>>>>>>>>>>,.", +" .@$@$$$$#.'))))))))))!.", +" .@$$$$$$##.')))))))))!.", +" .@$$$$$$##%.')))'!!!!!.", +" .@$$$$$##$#%.')!.......", +" .@$$$$$$$###%.'!.%%%. ", +" .@$$#####$$##%.!.%##. ", +" .@$$$$$$$#####%..###. ", +" .@$$#####$$$###%.###. ", +" .@$$$$$$$$$$$#######. ", +" .@##################. ", +" ..................... ", +" ", +" "}; diff --git a/etc/images/print.xpm b/etc/images/print.xpm new file mode 100644 index 0000000..95f2f40 --- /dev/null +++ b/etc/images/print.xpm @@ -0,0 +1,202 @@ +/* XPM */ +static char * print_xpm[] = { +"24 24 175 2", +" c None", +". c #000000", +"+ c #C7C7C7", +"@ c #FAFAFA", +"# c #FCFCFC", +"$ c #FBFBFB", +"% c #F8F8F8", +"& c #AFAFAF", +"* c #F9F9F9", +"= c #E5E5E5", +"- c #E3E3E3", +"; c #E2E2E2", +"> c #E0E0E0", +", c #DFDFDF", +"' c #DCDCDC", +") c #DBDBDB", +"! c #B6B6B6", +"~ c #6B6B6B", +"{ c #676767", +"] c #818181", +"^ c #E7E7E7", +"/ c #606060", +"( c #A0A0A0", +"_ c #DADADA", +": c #E1E1E1", +"< c #B7B7B7", +"[ c #FDFDFD", +"} c #EFEFEF", +"| c #EEEEEE", +"1 c #EDEDED", +"2 c #ECECEC", +"3 c #EBEBEB", +"4 c #E9E9E9", +"5 c #E8E8E8", +"6 c #BFBFBF", +"7 c #8A8A8A", +"8 c #6A6A6A", +"9 c #9E9E9E", +"0 c #F6F6F6", +"a c #909090", +"b c #A2A2A2", +"c c #AAAAAA", +"d c #F4F4F4", +"e c #CECECE", +"f c #ADADAD", +"g c #AEAEAE", +"h c #BEBEBE", +"i c #A6A6A6", +"j c #CDCDCD", +"k c #F5F5F5", +"l c #DEDEDE", +"m c #DDDDDD", +"n c #C9C9C9", +"o c #878787", +"p c #888888", +"q c #D0D0D0", +"r c #6E6E6E", +"s c #797979", +"t c #D1D1D1", +"u c #A1A1A1", +"v c #B3B3B3", +"w c #FFFFFF", +"x c #CACACA", +"y c #A7A7A7", +"z c #A5A5A5", +"A c #A4A4A4", +"B c #A3A3A3", +"C c #87847C", +"D c #EAE8E3", +"E c #8D8982", +"F c #53524C", +"G c #807D74", +"H c #AAA9A5", +"I c #BAB5AB", +"J c #F3F3F3", +"K c #C3C1BD", +"L c #8B8B89", +"M c #E6E5E1", +"N c #F9F9F8", +"O c #FAFAF9", +"P c #F9F9F7", +"Q c #F7F6F5", +"R c #F7F7F4", +"S c #F6F5F4", +"T c #F2F1EE", +"U c #F0EFEC", +"V c #E5E5E4", +"W c #9F9F9F", +"X c #DFDED9", +"Y c #A4A3A1", +"Z c #6C6B6A", +"` c #F5F4F3", +" . c #D5D5D5", +".. c #D3D3D3", +"+. c #D4D4D3", +"@. c #D4D4D4", +"#. c #A9A9A9", +"$. c #B5B5B5", +"%. c #CDCDCB", +"&. c #B5B5B4", +"*. c #DCDAD3", +"=. c #6B6B6A", +"-. c #999896", +";. c #918F87", +">. c #999895", +",. c #E6E4E1", +"'. c #F0EEEC", +"). c #FAF9F9", +"!. c #F9F8F7", +"~. c #F8F7F6", +"{. c #F8F8F7", +"]. c #F4F3F1", +"^. c #F2F1EF", +"/. c #565655", +"(. c #858482", +"_. c #9C9B99", +":. c #6B6A68", +"<. c #585858", +"[. c #5E5C57", +"}. c #524F4B", +"|. c #4A4845", +"1. c #4B4A46", +"2. c #4B4946", +"3. c #4A4844", +"4. c #494743", +"5. c #484642", +"6. c #474541", +"7. c #464440", +"8. c #514F4B", +"9. c #53514E", +"0. c #7B7A77", +"a. c #797771", +"b. c #949391", +"c. c #989694", +"d. c #868480", +"e. c #6E6C66", +"f. c #706D67", +"g. c #5C5955", +"h. c #67645F", +"i. c #5B5954", +"j. c #585651", +"k. c #5D5B56", +"l. c #595652", +"m. c #53504C", +"n. c #575450", +"o. c #595752", +"p. c #5C5956", +"q. c #5B5956", +"r. c #61615E", +"s. c #696861", +"t. c #77756F", +"u. c #7E7B77", +"v. c #979690", +"w. c #96938D", +"x. c #807E77", +"y. c #7D7A74", +"z. c #787770", +"A. c #716F6A", +"B. c #6E6C67", +"C. c #595753", +"D. c #63615C", +"E. c #686661", +"F. c #6F6E68", +"G. c #6D6C66", +"H. c #72716B", +"I. c #76746F", +"J. c #6A6963", +"K. c #8B8880", +"L. c #B2AFA8", +"M. c #B6B3AD", +"N. c #BFBDB6", +"O. c #BDBBB4", +"P. c #B0AEA6", +"Q. c #ABA8A2", +"R. c #9C9991", +" ", +" . . . . . . . . . . . . ", +" . + @ # # # # # # # $ % & . ", +" . * = - - - ; > , , ' ) ! . ", +" . # ~ { ] ^ / ( _ : > > < . ", +" . [ } | 1 1 | 2 2 3 4 5 6 . ", +" . [ 7 8 9 0 a b 4 c a d + . ", +" . [ # # # # $ $ # # $ $ e . ", +" . [ f g = h % h i j 3 # j . ", +" . k l l l m l l , l 5 : n . ", +" . . @ o ~ p q r s t p u q v . . ", +" . w . x y z A z z i B b u u 9 . C . ", +" . w D E F . . . . . . . . . . G C H I . ", +" . w w J w w w w w w w w w w w w w w w w D . ", +" . K L M N O N P Q R O O S T T U V D W X I . ", +" . Y Z ` h .! ..! +.< @.#...$.%.&.*.=.-.;.. ", +" . >.=.,.'.Q N @ ).N !.~.{.{.].].].^./.(.;.. ", +" . _.:.<.[.}.|.1.2.2.2.3.4.5.6.4.7.8.9.0.a.. ", +" . b.c.d.e.f.g.h.i.j.i.k.l.m.n.o.p.q.r.s.t.. ", +" . u.v.w.;.x.y.z.t.A.t.A.B.C.D.E.F.G.H.I.J.. ", +" . . . . . . . . . . . . . . . . . . . . ", +" . K.L.M.N.N.N.N.N.O.P.L.Q.P.R.R.R.G G . ", +" . . . . . . . . . . . . . . . . . . ", +" "}; diff --git a/etc/images/redo.xpm b/etc/images/redo.xpm new file mode 100644 index 0000000..273aec5 --- /dev/null +++ b/etc/images/redo.xpm @@ -0,0 +1,69 @@ +/* XPM */ +static char * stock_redo_xpm[] = { +"24 24 42 1", +" c None", +". c #000000", +"+ c #939A8D", +"@ c #BAD09D", +"# c #92998C", +"$ c #818F71", +"% c #ADBDA0", +"& c #C2D5AA", +"* c #D1DFBE", +"= c #BED2A3", +"- c #99A28F", +"; c #A8BCA6", +"> c #D5E1C6", +", c #CDDCBC", +"' c #D2E0BF", +") c #C5D7AE", +"! c #919889", +"~ c #8C9A7F", +"{ c #D4E0C5", +"] c #D3E0C1", +"^ c #BFD3A6", +"/ c #9BAA87", +"( c #B5C3A9", +"_ c #92AD62", +": c #7C9B40", +"< c #59702D", +"[ c #7F8E6B", +"} c #C8D9B2", +"| c #85A24D", +"1 c #53692A", +"2 c #A4B690", +"3 c #9BB572", +"4 c #6D8839", +"5 c #95A77E", +"6 c #8BA859", +"7 c #657255", +"8 c #98AF74", +"9 c #AFC394", +"0 c #6D7A5B", +"a c #9CAF84", +"b c #748261", +"c c #879772", +" ", +" ", +" ", +" . ", +" .. ", +" .+. ", +" ....@#. ", +" .$%&*=@-. ", +" .;>,')@@@!. ", +" .~{]*^@@@@@/. ", +" .(>_::::::<. ", +" .[}|::::::1. ", +" .23:<...:1. ", +" .@:4. .<. ", +" .@:.. .. ", +" .56. . ", +" .78. ", +" .9. ", +" .0a. ", +" .bc. ", +" ... ", +" ", +" ", +" "}; diff --git a/etc/images/refresh.xpm b/etc/images/refresh.xpm new file mode 100644 index 0000000..fbf4ce8 --- /dev/null +++ b/etc/images/refresh.xpm @@ -0,0 +1,113 @@ +/* XPM */ +static char * stock_refresh_xpm[] = { +"24 24 86 1", +" c None", +". c #000000", +"+ c #F3F6F8", +"@ c #C8D4DF", +"# c #F7F9FA", +"$ c #0D110C", +"% c #6286A5", +"& c #A0B6C9", +"* c #C9D5E0", +"= c #F2F5F7", +"- c #172116", +"; c #819EB6", +"> c #CAD6E1", +", c #CCD7E1", +"' c #CED9E3", +") c #F6F8F9", +"! c #7192AE", +"~ c #587B99", +"{ c #CDD8E2", +"] c #CFDAE4", +"^ c #D3DDE6", +"/ c #D5DEE6", +"( c #ADC0D0", +"_ c #90A9BF", +": c #537490", +"< c #23323E", +"[ c #85A1B8", +"} c #5E83A3", +"| c #6084A3", +"1 c #6689A7", +"2 c #678AA8", +"3 c #48657D", +"4 c #A8BCCD", +"5 c #7393AE", +"6 c #6B8DAA", +"7 c #5C81A1", +"8 c #5D82A2", +"9 c #6588A6", +"0 c #435F76", +"a c #B1C3D2", +"b c #50718D", +"c c #9FB5C8", +"d c #94ACC1", +"e c #425D73", +"f c #435E74", +"g c #B4C5D3", +"h c #6C8EAB", +"i c #C4D2DD", +"j c #5B80A0", +"k c #456178", +"l c #7595B0", +"m c #BFCEDA", +"n c #597D9C", +"o c #A3B8CA", +"p c #B0C2D1", +"q c #86A2B9", +"r c #6E8FAB", +"s c #E1E8EE", +"t c #B9C9D6", +"u c #6387A6", +"v c #4C6B85", +"w c #7F9DB6", +"x c #BCCCD9", +"y c #DDE5EC", +"z c #E4EAEF", +"A c #D8E1E9", +"B c #D1DBE4", +"C c #C7D3DE", +"D c #B7C8D6", +"E c #7091AD", +"F c #537592", +"G c #9DB3C6", +"H c #8CA7BD", +"I c #304353", +"J c #4E6E89", +"K c #829FB7", +"L c #92ABC0", +"M c #C5D3DE", +"N c #7C9AB3", +"O c #5A7E9D", +"P c #47647C", +"Q c #6185A4", +"R c #5B7F9E", +"S c #4F6F8A", +"T c #405A71", +"U c #283926", +" . ", +" .. ", +" .+. ", +" ....@#. ", +" $%&@@**=. .. ", +" -;@@**>,'). .!~. ", +" .%@**>,{]^/(. ._:. ", +" <&@[}}|%123. .4. ", +".5@678|%920. .ab. ", +".cd7e...1f. . .gh. ", +".ijb. .k. .. .al. ", +".mn. .. .'. .op5. ", +".qr. . .*s...at4u. ", +".vw. .xyzyABCDEF. ", +" .G. .p'B,@ixaH2I. ", +" .JK. .LM@,>>MmNOP. ", +" .F9. .9|%Q|}7RS.. ", +" .. .|R~~nJT.. ", +" .j~.... ", +" UO. ", +" .. ", +" . ", +" ", +" "}; diff --git a/etc/images/right-arrow.xpm b/etc/images/right-arrow.xpm new file mode 100644 index 0000000..da81568 --- /dev/null +++ b/etc/images/right-arrow.xpm @@ -0,0 +1,68 @@ +/* XPM */ +static char * right_arrow_xpm[] = { +"24 24 41 1", +" c None", +". c #000000", +"+ c #8CA782", +"@ c #B1CDAE", +"# c #77A16E", +"$ c #B4CEB1", +"% c #ACC8A9", +"& c #709867", +"* c #C1D6BD", +"= c #BDD3B8", +"- c #BFD4BB", +"; c #C2D7BE", +"> c #B0CAAD", +", c #B2CBB0", +"' c #AAC7A8", +") c #0F1308", +"! c #AEC5A8", +"~ c #AEC8AD", +"{ c #ABC7A8", +"] c #AAC6A7", +"^ c #A8C6A5", +"/ c #ADC8AD", +"( c #A8C7A8", +"_ c #A5C4A3", +": c #7F9F76", +"< c #A6BFA0", +"[ c #ABC7AA", +"} c #A7C5A4", +"| c #A9C7A6", +"1 c #AFC8AD", +"2 c #A4C3A2", +"3 c #6B9060", +"4 c #778E6F", +"5 c #698D60", +"6 c #6B9063", +"7 c #445B2C", +"8 c #6B8661", +"9 c #5B7950", +"0 c #6C8562", +"a c #65815C", +"b c #506B46", +" ", +" ", +" ", +" . ", +" .. ", +" .+. ", +" .@#. ", +" ........$%&. ", +" .*=-;;;;>,'&) ", +" .!~{{{]^'/(_:. ", +" .<[^}^|{%'{123. ", +" .45666666666657. ", +" .8999999999997. ", +" .099999999997. ", +" .abbbbbb9997. ", +" ........b97. ", +" .b7. ", +" .7. ", +" .. ", +" . ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/save.xpm b/etc/images/save.xpm new file mode 100644 index 0000000..6507e37 --- /dev/null +++ b/etc/images/save.xpm @@ -0,0 +1,247 @@ +/* XPM */ +static char * save_xpm[] = { +"24 24 220 2", +" c None", +". c #000000", +"+ c #C3D7F4", +"@ c #A9CDE5", +"# c #75757A", +"$ c #EFC5BB", +"% c #F1C8BE", +"& c #F0C6BC", +"* c #EEBCB2", +"= c #EEBEB5", +"- c #EEC1B8", +"; c #EDBFB6", +"> c #E9B7AD", +", c #E9B8AF", +"' c #E9B9B1", +") c #E5BFBA", +"! c #737277", +"~ c #B3CDE3", +"{ c #A1BED6", +"] c #BBD6E8", +"^ c #8AAAC5", +"/ c #605F68", +"( c #E08D7E", +"_ c #E0826E", +": c #E0806E", +"< c #DC7A68", +"[ c #DC8171", +"} c #DA7868", +"| c #D48173", +"1 c #D47D6E", +"2 c #CE7265", +"3 c #CF7264", +"4 c #CE7567", +"5 c #C4675B", +"6 c #C36558", +"7 c #626169", +"8 c #87A3B7", +"9 c #567187", +"0 c #BAD5E9", +"a c #88A7C3", +"b c #686670", +"c c #C8817B", +"d c #CB7C74", +"e c #CB7A73", +"f c #CB7B73", +"g c #CC7C72", +"h c #CB7D73", +"i c #BF6B64", +"j c #CC7A70", +"k c #C16A62", +"l c #CC7C73", +"m c #C2655B", +"n c #C36459", +"o c #BA6C6A", +"p c #819EB6", +"q c #547086", +"r c #B6D3E7", +"s c #87ABC1", +"t c #737373", +"u c #FFFFFF", +"v c #83A0B8", +"w c #526C80", +"x c #B9D3E7", +"y c #85A4BF", +"z c #4F697C", +"A c #B9D3E6", +"B c #84A3BF", +"C c #CECECE", +"D c #CDCDCD", +"E c #BFBFBF", +"F c #88A4BB", +"G c #486276", +"H c #B7D2E7", +"I c #82A0BB", +"J c #636363", +"K c #465E70", +"L c #B5CAE5", +"M c #7FA2B9", +"N c #87A3BA", +"O c #455C6D", +"P c #AECCE5", +"Q c #7DA0B6", +"R c #C5C5C5", +"S c #546069", +"T c #B0D1E4", +"U c #83A1B6", +"V c #735B5B", +"W c #515C64", +"X c #AACEE3", +"Y c #7B9BB2", +"Z c #7A8E9A", +"` c #7A7A7A", +" . c #6B6F72", +".. c #6F6F6F", +"+. c #696969", +"@. c #6F777E", +"#. c #86A2B9", +"$. c #3A515D", +"%. c #A9C9E2", +"&. c #7494AF", +"*. c #829FB7", +"=. c #7F9DB6", +"-. c #7E9CB5", +";. c #7998B2", +">. c #85A1B8", +",. c #8CA7BD", +"'. c #8AA5BB", +"). c #364A59", +"!. c #ABC4E2", +"~. c #7294AD", +"{. c #6F90AC", +"]. c #7192AE", +"^. c #414A4E", +"/. c #424A51", +"(. c #525B63", +"_. c #626F79", +":. c #5F6C76", +"<. c #5C6971", +"[. c #5A666F", +"}. c #58636B", +"|. c #57636A", +"1. c #3B5360", +"2. c #39424B", +"3. c #7897B3", +"4. c #A4B9CB", +"5. c #364853", +"6. c #AAC9E2", +"7. c #7091AA", +"8. c #6F8FA7", +"9. c #4A5359", +"0. c #97938C", +"a. c #DFDDDA", +"b. c #E3E1DE", +"c. c #EBEAE8", +"d. c #EAE9E7", +"e. c #CFCEC9", +"f. c #C9C6C0", +"g. c #9B968E", +"h. c #566168", +"i. c #4B657A", +"j. c #54738C", +"k. c #AAC6DD", +"l. c #34464E", +"m. c #AAC9E1", +"n. c #6C8EA6", +"o. c #6C8CA4", +"p. c #40474D", +"q. c #DAD8D3", +"r. c #E7E6E2", +"s. c #67655E", +"t. c #524F47", +"u. c #D9D7D4", +"v. c #C7C5BF", +"w. c #C0BCB5", +"x. c #B8B3AB", +"y. c #434C54", +"z. c #4D697F", +"A. c #4F6F84", +"B. c #B3CADC", +"C. c #313E49", +"D. c #A8C8E1", +"E. c #6B8DA6", +"F. c #728FA4", +"G. c #E2E1DD", +"H. c #F0EFEC", +"I. c #CDCAC6", +"J. c #C2BFB9", +"K. c #CAC6C0", +"L. c #DCDAD7", +"M. c #4B555D", +"N. c #4E697F", +"O. c #BACCDC", +"P. c #A4C4DE", +"Q. c #698BA3", +"R. c #708AA1", +"S. c #383E43", +"T. c #E0DEDA", +"U. c #514E46", +"V. c #4F4C44", +"W. c #C7C4BE", +"X. c #CBC8C2", +"Y. c #E1E0DC", +"Z. c #E9E8E6", +"`. c #475158", +" + c #4E6879", +".+ c #4D6C80", +"++ c #A3C3DB", +"@+ c #383F43", +"#+ c #778999", +"$+ c #6E899E", +"%+ c #65859C", +"&+ c #33383C", +"*+ c #D7D4D0", +"=+ c #D6D4D0", +"-+ c #4E4A43", +";+ c #4D4942", +">+ c #D1CEC9", +",+ c #E6E5E2", +"'+ c #EDECEA", +")+ c #454F55", +"!+ c #486173", +"~+ c #4D6678", +"{+ c #A1C1DA", +"]+ c #373C40", +"^+ c #0C0D0F", +"/+ c #4E5E6A", +"(+ c #5B6E7C", +"_+ c #4F5B62", +":+ c #A4A099", +"<+ c #CCC9C3", +"[+ c #D7D5D1", +"}+ c #E4E2E0", +"|+ c #DDDBD7", +"1+ c #B8B5B0", +"2+ c #3E474D", +"3+ c #4A6176", +"4+ c #4A6070", +"5+ c #9BC3D8", +"6+ c #363C41", +"7+ c #28323E", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . ", +" . + @ # $ % & * = - ; > , > , ' ) ! ~ { . ", +" . ] ^ / ( _ : < [ } | 1 2 3 4 5 6 7 8 9 . ", +" . 0 a b c d e f g h i j k l m n o b p q . ", +" . r s t u u u u u u u u u u u u u t v w . ", +" . x y t u u u u u u u u u u u u u t v z . ", +" . A B t C D D D D D D D D D D D E t F G . ", +" . H I J u u u u u u u u u u u u u t F K . ", +" . L M t u u u u u u u u u u u u u t N O . ", +" . P Q t C D D D D D D D D D D D R t N S . ", +" . T U V u u u u u u u u u u u u u t v W . ", +" . X Y Z ` t t t t t ...t t t t +.@.#.$.. ", +" . %.&.p v #.*.=.-.*.;.#.>.>.N *.,.v '.).. ", +" . !.~.{.].^./.(._.:.<.[.}.|.(.1.2.3.4.5.. ", +" . 6.7.8.9.0.a.b.c.c.d.a.e.f.g.h.i.j.k.l.. ", +" . m.n.o.p.q.r.s.t.t.u.v.w.x.e.y.z.A.B.C.. ", +" . D.E.F.p.G.H.s.t.t.I.J.w.K.L.M.N.A.O.C.. ", +" . P.Q.R.S.T.c.U.V.V.W.w.X.Y.Z.`. +.+++@+. ", +" . #+$+%+&+*+=+-+;+;+w.>+,+'+,+)+!+~+{+]+. ", +" ^+/+(+_+:+w.x.<+<+[+}+d.|+1+2+3+4+5+6+. ", +" . . . . . . . . . . . . . . . . 7+. ", +" "}; diff --git a/etc/images/saveas.xpm b/etc/images/saveas.xpm new file mode 100644 index 0000000..2830b06 --- /dev/null +++ b/etc/images/saveas.xpm @@ -0,0 +1,289 @@ +/* XPM */ +static char * saveas_xpm[] = { +"24 24 262 2", +" c None", +". c #000000", +"+ c #FBE73B", +"@ c #F2B64D", +"# c #FCEB3D", +"$ c #F7B544", +"% c #5D502C", +"& c #C3D7F4", +"* c #A9CDE5", +"= c #75757A", +"- c #EFC5BB", +"; c #F1C8BE", +"> c #F0C6BC", +", c #EEBCB2", +"' c #EEBEB5", +") c #EEC1B8", +"! c #EDBFB6", +"~ c #E8B6AC", +"{ c #FCE93B", +"] c #F7B545", +"^ c #6C5F34", +"/ c #434345", +"( c #92A7B9", +"_ c #96B1C7", +": c #BBD6E8", +"< c #8AAAC5", +"[ c #605F68", +"} c #E08D7E", +"| c #E0826E", +"1 c #E0806E", +"2 c #DC7A68", +"3 c #DC8171", +"4 c #DA7868", +"5 c #D38072", +"6 c #FAE43A", +"7 c #F4B244", +"8 c #615030", +"9 c #783E35", +"0 c #4D4C52", +"a c #7790A2", +"b c #526D82", +"c c #BAD5E9", +"d c #88A7C3", +"e c #686670", +"f c #C8817B", +"g c #CB7C74", +"h c #CB7A73", +"i c #CB7B73", +"j c #CC7C72", +"k c #CA7C72", +"l c #F9DF39", +"m c #F3AF42", +"n c #614F2F", +"o c #8F4941", +"p c #945554", +"q c #5B5A62", +"r c #7B97AE", +"s c #536F84", +"t c #B6D3E7", +"u c #87ABC1", +"v c #737373", +"w c #FFFFFF", +"x c #FEFEFE", +"y c #F9DC38", +"z c #EFB44D", +"A c #665A32", +"B c #BBBBBB", +"C c #CDCDCD", +"D c #E4E4E4", +"E c #6E6E6E", +"F c #819EB6", +"G c #526C80", +"H c #B9D3E7", +"I c #85A4BF", +"J c #F8D837", +"K c #F0A93F", +"L c #655930", +"M c #BABABA", +"N c #CCCCCC", +"O c #E5E5E5", +"P c #F7F7F7", +"Q c #727272", +"R c #83A0B8", +"S c #4F697C", +"T c #B9D3E6", +"U c #84A3BF", +"V c #CECECE", +"W c #F6D236", +"X c #EDA43E", +"Y c #5C5130", +"Z c #949494", +"` c #A3A3A3", +" . c #B7B7B7", +".. c #C6C6C6", +"+. c #BDBDBD", +"@. c #88A4BB", +"#. c #486276", +"$. c #B7D2E7", +"%. c #82A0BB", +"&. c #636363", +"*. c #FDFDFD", +"=. c #D7AE74", +"-. c #61562F", +";. c #465E70", +">. c #B5CAE5", +",. c #7FA2B9", +"'. c #4F4115", +"). c #87A3BA", +"!. c #455C6D", +"~. c #AECCE5", +"{. c #7DA0B6", +"]. c #CBCBCB", +"^. c #9B9B9B", +"/. c #9C9C9C", +"(. c #A7A7A7", +"_. c #B8B8B8", +":. c #C5C5C5", +"<. c #546069", +"[. c #B0D1E4", +"}. c #83A1B6", +"|. c #735B5B", +"1. c #F0F0F0", +"2. c #D9D9D9", +"3. c #D3D3D3", +"4. c #E1E1E1", +"5. c #EDEDED", +"6. c #F8F8F8", +"7. c #515C64", +"8. c #AACEE3", +"9. c #7B9BB2", +"0. c #7A8E9A", +"a. c #7A7A7A", +"b. c #707070", +"c. c #6C6C6C", +"d. c #6F6F6F", +"e. c #6A6E71", +"f. c #696969", +"g. c #6F777E", +"h. c #86A2B9", +"i. c #3A515D", +"j. c #A9C9E2", +"k. c #7494AF", +"l. c #7E9BB4", +"m. c #7D9AB3", +"n. c #7998B2", +"o. c #85A1B8", +"p. c #829FB7", +"q. c #8CA7BD", +"r. c #8AA5BB", +"s. c #364A59", +"t. c #ABC4E2", +"u. c #7294AD", +"v. c #6F90AC", +"w. c #7192AE", +"x. c #414A4E", +"y. c #424A51", +"z. c #525B63", +"A. c #626F79", +"B. c #5F6C76", +"C. c #5C6971", +"D. c #5A666F", +"E. c #58636B", +"F. c #57636A", +"G. c #3B5360", +"H. c #39424B", +"I. c #7897B3", +"J. c #A4B9CB", +"K. c #364853", +"L. c #AAC9E2", +"M. c #7091AA", +"N. c #6F8FA7", +"O. c #4A5359", +"P. c #97938C", +"Q. c #DFDDDA", +"R. c #E3E1DE", +"S. c #EBEAE8", +"T. c #EAE9E7", +"U. c #CFCEC9", +"V. c #C9C6C0", +"W. c #9B968E", +"X. c #566168", +"Y. c #4B657A", +"Z. c #54738C", +"`. c #AAC6DD", +" + c #34464E", +".+ c #AAC9E1", +"++ c #6C8EA6", +"@+ c #6C8CA4", +"#+ c #40474D", +"$+ c #DAD8D3", +"%+ c #E7E6E2", +"&+ c #67655E", +"*+ c #524F47", +"=+ c #D9D7D4", +"-+ c #C7C5BF", +";+ c #C0BCB5", +">+ c #B8B3AB", +",+ c #434C54", +"'+ c #4D697F", +")+ c #4F6F84", +"!+ c #B3CADC", +"~+ c #313E49", +"{+ c #A8C8E1", +"]+ c #6B8DA6", +"^+ c #728FA4", +"/+ c #E2E1DD", +"(+ c #F0EFEC", +"_+ c #CDCAC6", +":+ c #C2BFB9", +"<+ c #CAC6C0", +"[+ c #DCDAD7", +"}+ c #4B555D", +"|+ c #4E697F", +"1+ c #BACCDC", +"2+ c #A4C4DE", +"3+ c #698BA3", +"4+ c #708AA1", +"5+ c #383E43", +"6+ c #E0DEDA", +"7+ c #514E46", +"8+ c #4F4C44", +"9+ c #C7C4BE", +"0+ c #CBC8C2", +"a+ c #E1E0DC", +"b+ c #E9E8E6", +"c+ c #475158", +"d+ c #4E6879", +"e+ c #4D6C80", +"f+ c #A3C3DB", +"g+ c #383F43", +"h+ c #778999", +"i+ c #6E899E", +"j+ c #65859C", +"k+ c #33383C", +"l+ c #D7D4D0", +"m+ c #D6D4D0", +"n+ c #4E4A43", +"o+ c #4D4942", +"p+ c #D1CEC9", +"q+ c #E6E5E2", +"r+ c #EDECEA", +"s+ c #454F55", +"t+ c #486173", +"u+ c #4D6678", +"v+ c #A1C1DA", +"w+ c #373C40", +"x+ c #0C0D0F", +"y+ c #4E5E6A", +"z+ c #5B6E7C", +"A+ c #4F5B62", +"B+ c #A4A099", +"C+ c #CCC9C3", +"D+ c #D7D5D1", +"E+ c #E4E2E0", +"F+ c #DDDBD7", +"G+ c #B8B5B0", +"H+ c #3E474D", +"I+ c #4A6176", +"J+ c #4A6070", +"K+ c #9BC3D8", +"L+ c #363C41", +"M+ c #28323E", +" . . ", +" . + @ . ", +" . . . . . . . . . . . . . # $ % . . . ", +" . & * = - ; > , ' ) ! ~ . { ] ^ . / ( _ . ", +" . : < [ } | 1 2 3 4 5 . 6 7 8 . 9 0 a b . ", +" . c d e f g h i j k . l m n . o p q r s . ", +" . t u v w w w w x . y z A . B C D E F G . ", +" . H I v w w w x . J K L . M N O P Q R S . ", +" . T U v V C N . W X Y . Z ` ...+.v @.#.. ", +" . $.%.&.w w *.. =.-.. M N D P *.w v @.;.. ", +" . >.,.v w x . '.. . M N D P *.w w v ).!.. ", +" . ~.{.v V ].. . ^./.(._...].C C :.v ).<.. ", +" . [.}.|.w *.1.2.3.4.5.6.x w w w w v R 7.. ", +" . 8.9.0.a.Q b.c.c.d.e.E v v v v f.g.h.i.. ", +" . j.k.F R h.F l.m.F n.h.o.o.).p.q.R r.s.. ", +" . t.u.v.w.x.y.z.A.B.C.D.E.F.z.G.H.I.J.K.. ", +" . L.M.N.O.P.Q.R.S.S.T.Q.U.V.W.X.Y.Z.`. +. ", +" . .+++@+#+$+%+&+*+*+=+-+;+>+U.,+'+)+!+~+. ", +" . {+]+^+#+/+(+&+*+*+_+:+;+<+[+}+|+)+1+~+. ", +" . 2+3+4+5+6+S.7+8+8+9+;+0+a+b+c+d+e+f+g+. ", +" . h+i+j+k+l+m+n+o+o+;+p+q+r+q+s+t+u+v+w+. ", +" x+y+z+A+B+;+>+C+C+D+E+T.F+G+H+I+J+K+L+. ", +" . . . . . . . . . . . . . . . . M+. ", +" "}; diff --git a/etc/images/search.xpm b/etc/images/search.xpm new file mode 100644 index 0000000..ad63005 --- /dev/null +++ b/etc/images/search.xpm @@ -0,0 +1,234 @@ +/* XPM */ +static char * search_xpm[] = { +"24 24 207 2", +" c None", +". c #000000", +"+ c #D3D3D3", +"@ c #F6F6F6", +"# c #FFFFFF", +"$ c #F9F9F9", +"% c #DADADA", +"& c #585858", +"* c #C7C7C7", +"= c #D1D1D1", +"- c #D6D6D6", +"; c #FEFEFE", +"> c #FDFDFD", +", c #C0C0C0", +"' c #E1E1E1", +") c #F0F0F0", +"! c #9B9B9B", +"~ c #FCFCFB", +"{ c #FBFBFB", +"] c #AFAFAE", +"^ c #E9E9E9", +"/ c #DFDFDF", +"( c #8F8F8F", +"_ c #FAFAF9", +": c #F9F9F8", +"< c #A4A4A3", +"[ c #F4F4F4", +"} c #CFCFCF", +"| c #A2A2A2", +"1 c #B8B8B8", +"2 c #47473F", +"3 c #0A0A09", +"4 c #4B4B43", +"5 c #B4B4B3", +"6 c #F7F6F5", +"7 c #9E9E9E", +"8 c #A9A9A8", +"9 c #34342E", +"0 c #9D9D8D", +"a c #CFCFB9", +"b c #C4C4AF", +"c c #8D8D7F", +"d c #353530", +"e c #ACACAA", +"f c #F1F0EF", +"g c #DEDDDC", +"h c #D3D2D0", +"i c #B7B7B5", +"j c #9F9E9D", +"k c #706F6F", +"l c #65625A", +"m c #46463F", +"n c #9C9C8C", +"o c #E2E2D0", +"p c #EDEDE7", +"q c #C0C0AC", +"r c #B2B29F", +"s c #828274", +"t c #4C4C44", +"u c #E4E4E2", +"v c #E1E1DF", +"w c #DAD9D7", +"x c #D8D8D6", +"y c #CDCCCA", +"z c #AFAEAC", +"A c #88847B", +"B c #F8F8F7", +"C c #090908", +"D c #D5D5BF", +"E c #FBFBFA", +"F c #C3C3AE", +"G c #B5B5A2", +"H c #A6A695", +"I c #9C9C8F", +"J c #080807", +"K c #CFCFCD", +"L c #E3E2E0", +"M c #ECEBE9", +"N c #E9E8E6", +"O c #D5D4D3", +"P c #C4C3C2", +"Q c #8F8A81", +"R c #F6F5F4", +"S c #F3F3F1", +"T c #090909", +"U c #CACAB5", +"V c #DDDDD0", +"W c #B7B7A4", +"X c #AAAA98", +"Y c #9B9B8B", +"Z c #AEAEA3", +"` c #BBBAB9", +" . c #E8E7E5", +".. c #E5E4E2", +"+. c #E4E3E0", +"@. c #D2D1CE", +"#. c #8D887E", +"$. c #F4F3F2", +"%. c #F0EFEE", +"&. c #474740", +"*. c #929283", +"=. c #BABAA7", +"-. c #ADAD9B", +";. c #9F9F8E", +">. c #ACACA1", +",. c #CFCFCB", +"'. c #4C4C45", +"). c #B3B2B1", +"!. c #E2E1DE", +"~. c #E1DFDC", +"{. c #979288", +"]. c #949493", +"^. c #34342F", +"/. c #878779", +"(. c #A0A090", +"_. c #AEAEA2", +":. c #C3C3BE", +"<. c #010101", +"[. c #B1B0AF", +"}. c #D2D1CF", +"|. c #A49E93", +"1. c #F0F0EE", +"2. c #EDEDEB", +"3. c #DDDDDB", +"4. c #898988", +"5. c #414141", +"6. c #737271", +"7. c #A4A3A1", +"8. c #DFDEDB", +"9. c #E2E0DD", +"0. c #E1E0DC", +"a. c #E0DFDB", +"b. c #A19C90", +"c. c #E1E0DE", +"d. c #CBCAC9", +"e. c #B2B1B0", +"f. c #A3A2A1", +"g. c #9D9C9A", +"h. c #9E9D9C", +"i. c #9F9F9D", +"j. c #ABAAA7", +"k. c #DCDBD7", +"l. c #DEDDD9", +"m. c #DDDCD8", +"n. c #A19B90", +"o. c #EBEAE8", +"p. c #E6E5E3", +"q. c #C8C7C4", +"r. c #B6B6B3", +"s. c #B0AFAD", +"t. c #B3B2B0", +"u. c #747371", +"v. c #9D9C99", +"w. c #DAD9D5", +"x. c #E7E6E3", +"y. c #E6E5E2", +"z. c #E3E2DF", +"A. c #DBDAD7", +"B. c #D4D3D0", +"C. c #D0CFCB", +"D. c #D1CFCC", +"E. c #D1D0CC", +"F. c #C9C8C4", +"G. c #6B6B69", +"H. c #CECDC9", +"I. c #D6D4D0", +"J. c #9F998D", +"K. c #E3E2DE", +"L. c #E4E2DF", +"M. c #DFDEDA", +"N. c #D5D4D0", +"O. c #C0BFBC", +"P. c #7B7A78", +"Q. c #BCBAB6", +"R. c #CECCC8", +"S. c #9D978C", +"T. c #EDEDED", +"U. c #E1E0DD", +"V. c #E2E1DD", +"W. c #DBDAD6", +"X. c #BBB9B6", +"Y. c #A6A4A1", +"Z. c #9E9C99", +"`. c #ACABA7", +" + c #C7C5C2", +".+ c #9B9589", +"++ c #E1DFDB", +"@+ c #E0DEDA", +"#+ c #DEDCD8", +"$+ c #DAD8D4", +"%+ c #BDBCB8", +"&+ c #ACABA8", +"*+ c #B2B1AD", +"=+ c #C6C4C0", +"-+ c #999388", +";+ c #999891", +">+ c #A39E92", +",+ c #A39D92", +"'+ c #A39D91", +")+ c #A29C90", +"!+ c #A19B8F", +"~+ c #9D978B", +"{+ c #989286", +"]+ c #918C82", +"^+ c #938D83", +"/+ c #979286", +"(+ c #666258", +" ", +" . . . . . . . . . . . . . ", +" . + @ # # # # # # # # $ % & . ", +" . @ # # # # # # # # # # * = - . ", +" . # # # # # # # ; # ; > , ' ) ! . ", +" . # # # # # ; > ~ > ~ { ] ^ # / ( . ", +" . # # # ; > ~ { _ { _ : < ) # [ } | . ", +" . # ; > ~ 1 2 3 3 4 5 6 7 . . . . . . . ", +" . # ~ { 8 9 0 a b c d e f g h i j k l . ", +" . # _ : m n o p q r s t u v w x y z A . ", +" . # B 6 C D E F G H I J K L M N O P Q . ", +" . # R S T U V W X Y Z 3 ` w ...+.@.#.. ", +" . # $.%.&.*.=.-.;.>.,.'.).h !.+.!.~.{.. ", +" . # $.%.].^./.(._.:.<.<.[.}.!.+.!.~.|.. ", +" . # 1.2.3.4.4 3 3 5.6.<.<.7.8.9.0.a.b.. ", +" . # 2.M c.d.e.f.g.h.i.<.<.<.j.k.l.m.n.. ", +" . # o.N p.w q.r.z s.t.u.. <.<.v.w.k.n.. ", +" . # x.y.y.z.A.B.C.D.E.F.G.<.<.<.H.I.J.. ", +" . $ +.z.K.L.K.a.a.M.M.N.O.P.<.<.Q.R.S.. ", +" . T.U.~.0.a.V.a.0.a.0.W.E.X.Y.Z.`. +.+. ", +" . = ++@+M.l.a.l.@+l.@+#+$+R.%+&+*+=+-+. ", +" . ;+>+|.,+'+,+b.)+b.)+!+n.~+{+]+^+/+(+. ", +" . . . . . . . . . . . . . . . . . . ", +" "}; diff --git a/etc/images/separator.xpm b/etc/images/separator.xpm new file mode 100644 index 0000000..0c518fa --- /dev/null +++ b/etc/images/separator.xpm @@ -0,0 +1,30 @@ +/* XPM */ +static char * separator_xpm[] = { +"2 24 3 1", +" c None", +". c #DBD3CB", +"+ c #FCFBFA", +" ", +" ", +" ", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +".+", +" ", +" ", +" "}; diff --git a/etc/images/sort-ascending.xpm b/etc/images/sort-ascending.xpm new file mode 100644 index 0000000..5a47e5c --- /dev/null +++ b/etc/images/sort-ascending.xpm @@ -0,0 +1,33 @@ +/* XPM */ +static char * stock_sort_ascending_xpm[] = { +"23 23 7 1", +" c None", +". c #314E6C", +"+ c #000000", +"@ c #D1DECF", +"# c #7DA377", +"$ c #E4ECE3", +"% c #B3C9AF", +" ", +" .... ", +" .. .. ", +" .. .. ", +" ...... ", +" .. .. ", +" .. .. ", +" ", +" + ", +" ", +" + ", +" ", +" + + ", +" +@+ + ", +" +@##+ ++ ++++++ ", +" +###+$+ +++ ", +" +##%#+ +++ ", +" +%##+ +++ ", +" +$###+ +++ ", +" +++++++ ++++++ ", +" ", +" ", +" "}; diff --git a/etc/images/sort-column-ascending.xpm b/etc/images/sort-column-ascending.xpm new file mode 100644 index 0000000..76d7f93 --- /dev/null +++ b/etc/images/sort-column-ascending.xpm @@ -0,0 +1,29 @@ +/* XPM */ +static char * stock_sort_column_ascending_xpm[] = { +"24 24 2 1", +" c None", +". c #000000", +" ", +" ", +" ... ", +" . .. ", +" .. ", +" .. ", +" .. ", +" .. ", +" .. ", +" ..... . ", +" ", +" . ", +" ", +" . ", +" .... ", +" .. .. ", +" .. .. ", +" .. .. ", +" ..... ", +" .. ", +" . ... ", +" ..... ", +" ", +" "}; diff --git a/etc/images/sort-criteria.xpm b/etc/images/sort-criteria.xpm new file mode 100644 index 0000000..d1c83b8 --- /dev/null +++ b/etc/images/sort-criteria.xpm @@ -0,0 +1,55 @@ +/* XPM */ +static char * stock_sort_criteria_xpm[] = { +"24 24 28 1", +" c None", +". c #000000", +"+ c #FFFFFF", +"@ c #D3D3D3", +"# c #F2ECE1", +"$ c #F4EFE5", +"% c #DFDAD2", +"& c #C9C4BD", +"* c #74716E", +"= c #FAFAFA", +"- c #EADFC9", +"; c #ECE2CF", +"> c #EEE5D4", +", c #4C4B48", +"' c #F5F5F5", +") c #C9C9C9", +"! c #E2D2B1", +"~ c #CFC4B1", +"{ c #BFBFBF", +"] c #C0C0C0", +"^ c #C7B99C", +"/ c #F0F0F0", +"( c #B7B7B7", +"_ c #9A8F78", +": c #877E69", +"< c #AFA389", +"[ c #A09889", +"} c #314E6C", +" ", +" ", +" ...... ", +" ... ", +" ... ", +" ... ", +" ......... ... ", +" .+@.#$%&*. ...... ", +" .=@.-;;;>, ", +" .').!!!!.~. ", +" .{].^^!.^.~. ", +" ./(.._.^.:.~. ", +" .....<.:...[. ", +" .:.. .. ", +" .. ", +" ", +" }}}} ", +" }} }} ", +" }} }} ", +" }}}}}} ", +" }} }} ", +" }} }} ", +" ", +" "}; diff --git a/etc/images/sort-descending.xpm b/etc/images/sort-descending.xpm new file mode 100644 index 0000000..90127ac --- /dev/null +++ b/etc/images/sort-descending.xpm @@ -0,0 +1,33 @@ +/* XPM */ +static char * stock_sort_descending_xpm[] = { +"24 23 7 1", +" c None", +". c #000000", +"+ c #D1DECF", +"@ c #7DA377", +"# c #314E6C", +"$ c #E4ECE3", +"% c #B3C9AF", +" ", +" ", +" ...... ", +" ... ", +" ... ", +" ... ", +" ... ", +" ...... ", +" . ", +" ", +" . ", +" ", +" . . ", +" .+. . ", +" .+@@. .. #### ", +" .@@@.$. ## ## ", +" .@@%@. ## ## ", +" .%@@. ###### ", +" .$@@@. ## ## ", +" ....... ## ## ", +" ", +" ", +" "}; diff --git a/etc/images/sort-row-ascending.xpm b/etc/images/sort-row-ascending.xpm new file mode 100644 index 0000000..5200b97 --- /dev/null +++ b/etc/images/sort-row-ascending.xpm @@ -0,0 +1,22 @@ +/* XPM */ +static char * stock_sort_row_ascending_xpm[] = { +"21 17 2 1", +" c None", +". c #000000", +" ", +" ", +" ", +" ", +" ... .... ", +" . .. .. .. ", +" .. .. .. ", +" .. .. .. ", +" .. ..... ", +" .. .. ", +" .. . .. ", +" ..... . . . ..... ", +" ", +" ", +" ", +" ", +" "}; diff --git a/etc/images/spell.xpm b/etc/images/spell.xpm new file mode 100644 index 0000000..b53f451 --- /dev/null +++ b/etc/images/spell.xpm @@ -0,0 +1,64 @@ +/* XPM */ +static char * spell_xpm[] = { +"24 24 37 1", +" c None", +". c #000000", +"+ c #8BBB8C", +"@ c #ABD0AC", +"# c #1A3B1A", +"$ c #8ABA88", +"% c #B4D5B4", +"& c #70A770", +"* c #132C13", +"= c #77A676", +"- c #2D2D2D", +"; c #CBDFCB", +"> c #6FAE6E", +", c #A8CBA6", +"' c #6D9D6C", +") c #D0E4D0", +"! c #6FAF6F", +"~ c #587055", +"{ c #B8D6B8", +"] c #5B9159", +"^ c #D4E4D4", +"/ c #67AF67", +"( c #5D905B", +"_ c #9FC59D", +": c #93BE92", +"< c #B5D1B5", +"[ c #67AF68", +"} c #63A261", +"| c #BBD6BA", +"1 c #82B881", +"2 c #75AF74", +"3 c #6B8868", +"4 c #9DC39D", +"5 c #7DB17B", +"6 c #6BA368", +"7 c #485C46", +"8 c #89BA88", +" ", +" ", +" ", +" ", +" ... .... ... ", +" .. . .. . .. . ", +" .. . .... .. ", +" ..... .. . .. ", +" .. . .. . .. . . ", +" .. . .... ... ... ", +" .+. ", +" .. .@# ", +" .$. .%&. ", +" *=. -;>. ", +" .,'. .)!~. ", +" .{].^/(. ", +" ._:<[}~. ", +" .|123. ", +" .4567. ", +" .83. ", +" .37. ", +" .. ", +" ", +" "}; diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 84ae2b2..7fec43c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,3039 @@ +2006-04-11 Reiner Steib + + * gnus.el: No Gnus v0.4 is released. + +2006-04-11 Lars Magne Ingebrigtsen + + * nnslashdot.el (nnslashdot-retrieve-headers-1): Fix up to new + layout. + + * rfc2047.el (rfc2047-decode-encoded-words): Don't message about + unknown charset. + + * message.el (message-header-synonyms): Add Original-To to the + default. + + * gnus-sum.el (gnus-get-newsgroup-headers-xover): group is an + optional parameter. + +2006-04-06 Reiner Steib + + * gnus-fun.el (gnus): Require it for gnus-directory. + +2006-04-06 Katsumi Yamaoka + + * gnus-fun.el (gnus-face-properties-alist): Add :version. + +2006-04-05 Daiki Ueno + + * pgg-gpg.el (pgg-gpg-process-filter): Fix. + +2006-04-05 Simon Josefsson + + * password.el (password-reset): New function. + +2006-04-05 Daiki Ueno + + * pgg-gpg.el (pgg-gpg-encrypt-region, pgg-gpg-sign-region): Wait + for BEGIN_SIGNING too, new in GnuPG 1.4.3. + +2006-04-04 Andreas Seltenreich + + * nnweb.el (nnweb-google-create-mapping): Update regexp. Some + whitespace was matched into the url, which broke browsing hits + > 100 when mm-url-use-external was nil. + +2006-04-04 Reiner Steib + + * gnus-sum.el (gnus-summary-from-or-to-or-newsgroups): Check + gnus-extra-headers for 'Newsgroups. + + * message.el (message-tool-bar-gnome): Check if `flyspell-mode' is + bound. + +2006-04-04 Daiki Ueno + + * pgg-gpg.el: Clean up process buffers every time gpg processes + complete. + +2006-04-03 Reiner Steib + + * gnus-fun.el (gnus-convert-image-to-face-command): Fix typo in + doc string. + +2006-04-03 Daiki Ueno + + * pgg-gpg.el (pgg-gpg-process-filter) + (pgg-gpg-wait-for-completion): Check if buffer is alive. + + * pgg-gpg.el (pgg-gpg-process-sentinel): Don't remove GNUPG: + lines, temporary fix. + +2006-03-31 Reiner Steib + + * gnus-group.el (gnus-group-update-tool-bar): Add :initialize and + :set. + +2006-03-29 Daiki Ueno + + * pgg-gpg.el (pgg-gpg-start-process): Don't bind + default-enable-multibyte-characters. This reverts the change from + revision 6.17 which is no longer necessary because the passphrase + is sent separately now. GnuPG messages are unreadable under + multibyte locales with default-enable-multibyte-characters set to + nil. + +2006-03-28 Reiner Steib + + * message.el (message-tool-bar-gnome): Move "spell". + +2006-03-27 Reiner Steib + + * gnus-sum.el (gnus-summary-from-or-to-or-newsgroups): Don't use + XEmacs-only `replace-in-string'. Use `gnus-group-real-name' + instead. + +2006-03-27 Karl Kleinpaste + + * gnus-sum.el (gnus-summary-from-or-to-or-newsgroups): Improve + newsgroups handling for NNTP overviews which don't include + Newsgroups. + +2006-03-26 Andreas Seltenreich + + * message.el (message-resend): Bind message-generate-hashcash to + to nil. + +2006-03-26 Andreas Seltenreich + + * hashcash.el (hashcash-already-paid-p): Bind case-fold-search + when searching for already-paid recipients. + +2006-03-27 Daiki Ueno + + * pgg-gpg.el: Invoke gpg asynchronous, to avoid querying for + passphrases when it is not needed. + (pgg-gpg-use-agent): Add, to hard code that pgg shouldn't wait for + passphrase stuff from gpg, should only be necessary when you use + gpg with a smartcard. + +2006-03-23 Katsumi Yamaoka + + * mml.el (mml-insert-mime): Ignore cached contents of + message/external-body part. + + * mm-decode.el (mm-get-part): Add optional 'no-cache' argument. + (mm-insert-part): Ditto. + +2006-03-23 Simon Josefsson + + * pgg-gpg.el (pgg-gpg-update-agent): Add again, with fixes from + Reiner. + (pgg-gpg-use-agent-p): Use it again. + +2006-03-23 Simon Josefsson + + * pgg-gpg.el (pgg-gpg-update-agent): Remove, doesn't work with + older emacsen. + (pgg-gpg-use-agent-p): Don't use it. + +2006-03-23 Reiner Steib + + * pgg-gpg.el (pgg-gpg-update-agent): Only use make-network-process + if we can. + +2006-03-22 Sascha Wilde + + * pgg-gpg.el (pgg-gpg-use-agent): Disable by default. + (pgg-gpg-update-agent): New function. + (pgg-gpg-use-agent-p): New function. + (pgg-gpg-process-region, pgg-gpg-encrypt-region) + (pgg-gpg-encrypt-symmetric-region, pgg-gpg-decrypt-region) + (pgg-gpg-sign-region): Use it. + +2006-03-22 Katsumi Yamaoka + + * gnus-sum.el (gnus-map-articles): Don't funcall symbol macro. + Reported by Ralf Wachinger . + +2006-03-21 Simon Josefsson + + * pgg-gpg.el: Ideas below based on patch from Sascha Wilde + . + (pgg-gpg-use-agent): New variable. + (pgg-gpg-process-region): Use it. + (pgg-gpg-encrypt-region): Likewise. + (pgg-gpg-encrypt-symmetric-region): Likewise. + (pgg-gpg-decrypt-region): Likewise. + (pgg-gpg-sign-region): Likewise. + (pgg-gpg-possibly-cache-passphrase): Don't cache a nil password. + +2006-03-21 Reiner Steib + + * gnus-agent.el (gnus-agent-queue-mail): Fix custom tag for `t'. + + * spam.el (spam-mark-new-messages-in-spam-group-as-spam): Add + comment on version. + +2006-03-20 Reiner Steib + + * smiley.el: Add missing test smiley. + +2006-03-17 Katsumi Yamaoka + + * mm-decode.el (mm-with-part): New macro. + (mm-get-part): Use it; work with message/external-body as well. + (mm-save-part): Treat name and filename equally. + + * mm-extern.el (mm-extern-cache-contents): New function. + (mm-inline-external-body): Use it; force the part to be displayed; + move undisplayer added to the cached handle to the parent. + + * gnus-art.el (gnus-mime-save-part-and-strip): Add name parameter. + (gnus-mime-view-part-as-type): Work with message/external-body. + + * gnus-util.el (gnus-tool-bar-update): Bind tool-bar-mode. + +2006-03-16 Reiner Steib + + * gmm-utils.el (gmm-image-load-path-for-library): Prefer user's + images in image-load-path. [Sync with image.el, revision 1.60, in + Emacs.] + +2006-03-15 Reiner Steib + + * gmm-utils.el (gmm-image-load-path-for-library): Pass value of + path rather than symbol. Always return list of directories. + Guarantee that image directory comes first. [Sync with image.el, + revision 1.59, in Emacs.] + + * message.el (message-make-tool-bar): Adjust to new API of + `gmm-image-load-path-for-library'. + + * gnus-sum.el (gnus-summary-make-tool-bar): Ditto. + + * gnus-group.el (gnus-group-make-tool-bar): Ditto. + +2006-03-15 Andreas Seltenreich + + * gnus-art.el (gnus-article-only-boring-p): Bind + inhibit-point-motion-hooks to avoid infinite loop when entering + intangible text. Reported by Ralf Wachinger + . + +2006-03-14 Reiner Steib + + * gmm-utils.el (gmm-image-load-path-for-library): Fix typo. Use + `defun' instead of `gmm-defun-compat'. + +2006-03-14 Simon Josefsson + + * message.el (message-unique-id): Don't use message-number-base36 + if (user-uid) is a float. Reported by Bjorn Solberg + . + +2006-03-13 Katsumi Yamaoka + + * mm-uu.el (mm-uu-dissect): Dissect all parts correctly. + + * gnus-art.el (gnus-mime-display-single): Make sure there is an + empty line between a part and a message part. + +2006-03-10 Reiner Steib + + * smiley.el: Add more test smileys. + (smiley-data-directory, smiley-regexp-alist) + (gnus-smiley-file-types): Fix doc strings. + (smiley-update-cache): Clear smiley-cached-regexp-alist before + adding new elements. + (smiley-mouse-map): Unused code. Make it a comment. + +2006-03-10 Katsumi Yamaoka + + * gnus-nocem.el (gnus-nocem-scan-groups): Add autoload cookie; + scan latest NoCeM messages instead of old ones. + (gnus-nocem-check-article): Fix regexps so as to match to PGP + delimiters that are recently used. + (gnus-nocem-load-cache): Add autoload cookie. + + * gnus.el (gnus-use-nocem): Enable it to be set to also a number. + + * gnus-start.el (gnus-setup-news): Scan NoCeM messages if a group + level which is larger than gnus-use-nocem is specified. + + * gnus-group.el (gnus-group-get-new-news): Ditto. + +2006-03-08 Reiner Steib + + * gnus-util.el (gnus-tool-bar-update): New function. + + * gnus-group.el (gnus-group-update-tool-bar): New variable. + (gnus-group-insert-group-line): Add gnus-tool-bar-update. + + * gnus-topic.el (gnus-topic-prepare-topic): Add gnus-tool-bar-update. + + * gnus-group.el (gnus-group-redraw-when-idle) + (gnus-group-redraw-check): Remove. + (gnus-group-make-tool-bar): Remove gnus-group-redraw-check. + +2006-03-08 Katsumi Yamaoka + + * nnmail.el (nnmail-split-it): Invert match-partial-words behavior + if optional last element is specified in splits (FIELD VALUE...). + +2006-03-07 Reiner Steib + + * message.el (message-make-tool-bar): Rename gmm-image-load-path + to gmm-image-load-path-for-library. Call with no-error argument. + (message-tool-bar-gnome): Rename "mail/attach" to "attach". + + * gnus-sum.el (gnus-summary-make-tool-bar): Ditto. + + * gnus-group.el (gnus-group-make-tool-bar): Ditto. + + * gmm-utils.el (gmm-image-load-path): Remove alias. + +2006-03-06 Reiner Steib + + * gmm-utils.el (gmm-image-load-path): Add alias. + + * nnml.el (nnml-generate-nov-databases-directory): Rename from + nnml-generate-nov-databases-1. + (nnml-generate-nov-databases): Use it. + (nnml-generate-nov-databases-directory): Document no-active + argument. + + * gmm-utils.el (gmm-image-load-path-for-library): Return single + directory if path is t. Add no-error. + + * gnus-group.el (gnus-group-make-tool-bar): Use add-hook. + Suggested by Stefan Monnier . + + * gnus-art.el (gnus-article-browse-delete-temp-files): Simplify + resetting gnus-article-browse-html-temp-list. + + * gmm-utils.el (gmm-image-load-path-for-library): Sync with + mh-compat.el revision 1.9 in Emacs. Rename `gmm-image-load-path'. + Add example to docstring. Rename local variables. Move error + checks to default case in cond and simplify. + +2006-03-06 Katsumi Yamaoka + + * mm-view.el (mm-w3m-cid-retrieve-1): Check carefully whether + handle is multipart when calling it recursively. + (mm-w3m-cid-retrieve): Display warning if retrieving fails. + +2006-03-03 Daniel Pittman + + * nnimap.el (nnimap-request-update-info-internal): Optimize. + Don't `gnus-uncompress-range' to avoid excessive memory usage. + +2006-03-03 Katsumi Yamaoka + + * gnus-group.el (gnus-group-tool-bar-gnome): Check if gnus-topic.el + is loaded. + + * gnus-sum.el (gnus-summary-tool-bar-gnome): Check if spam.el is + loaded. + +2006-03-03 Reiner Steib + + * mm-util.el (mm-with-unibyte-current-buffer): Change "Emacs 23" + to "Emacs 23 (unicode)" in doc string. + + * gnus-sum.el (gnus-summary-set-display-table): Change "Emacs 23" to + "Emacs 23 (unicode)" in comment. + +2006-03-03 Katsumi Yamaoka + + * mm-decode.el (mm-get-part): Don't use + mm-with-unibyte-current-buffer. + + * gnus-sum.el (gnus-summary-set-display-table): Don't nix out + characters 160 through 255 in Emacs 23. + +2006-03-02 Reiner Steib + + * gnus-art.el (gnus-article-browse-html-temp-list): Rename from + gnus-article-browse-html-temp. + (gnus-article-browse-delete-temp): Make it customizable. Add + `file'. Adjust doc string. + (gnus-article-browse-delete-temp-files): Add argument. Allow + query for each file. Adjust doc string. + (gnus-article-browse-html-parts): Add + `gnus-article-browse-delete-temp-files' to + `gnus-summary-prepare-exit-hook' and `gnus-exit-gnus-hook'. + +2006-03-02 Hynek Schlawack + + * gnus-art.el (gnus-article-browse-html-temp) + (gnus-article-browse-delete-temp): New variables. + (gnus-article-browse-delete-temp-files): New function. + (gnus-article-browse-html-parts): Use it. + +2006-03-02 Reiner Steib + + * gnus-group.el (gnus-group-redraw-check): Remove redundant tests. + + * gmm-utils.el (gmm-image-load-path): Mention ../etc search in doc + string. + + * gnus-sum.el (gnus-summary-tool-bar-gnome): Don't use + gnus-summary-insert-new-articles when unplugged. Remove + gnus-summary-search-article-forward. + + * gmm-utils.el (gmm-tool-bar-style): Test tool-bar-mode and + display-visual-class instead of display-color-cells. + +2006-03-02 Katsumi Yamaoka + + * dgnushack.el: Autoload customize-group for XEmacs. + + * mml.el (mml-generate-mime-1): Encode parts other than text/* or + message/* containing non-ASCII text properly. + +2006-03-01 Reiner Steib + + * message.el: Require gmm-utils, remove autoloads. + (message-tool-bar): Set default based on + gmm-tool-bar-style. + (message-tool-bar-gnome): Add gmm-customize-mode. + + * gnus-sum.el (gnus-summary-tool-bar): Set default based on + gmm-tool-bar-style. + (gnus-summary-tool-bar-gnome): Add gmm-customize-mode. + + * gnus-group.el (gnus-group-tool-bar): Set default based on + gmm-tool-bar-style. + (gnus-group-tool-bar-gnome): Add gmm-customize-mode. + + * gmm-utils.el (gmm-image-directory): Rename variable from + gmm-image-load-path. + (gmm-image-load-path): Use gmm-image-directory. + (gmm-customize-mode): New function. + (gmm-tool-bar-style): New variable. + + * gnus-group.el (gnus-group-redraw-when-idle): Rename from + gnus-group-redraw-line-number. + (gnus-group-redraw-check): Simplify. + (gnus-group-tool-bar-update): Remove redraw check. + (gnus-group-make-tool-bar): Add redraw check. + +2006-03-01 Michael Piotrowski (tiny change) + + * gnus-art.el (gnus-button): Add missing parentheses. + +2006-03-01 Katsumi Yamaoka + + * lpath.el: Fbind line-number-at-pos. + +2006-02-28 Katsumi Yamaoka + + * mm-util.el (mm-with-unibyte-current-buffer): Add note. + +2006-02-28 Reiner Steib + + * gnus-art.el (gnus-button): New face. + (gnus-article-button-face): Use it. + + * gnus-sum.el (gnus-summary-tool-bar-gnome): Add + gnus-summary-next-page. Re-order. + + * gnus-group.el (gnus-group-tool-bar-gnome): prev-node and + next-node are now included. + (gnus-group-redraw-line-number): New internal variable. + (gnus-group-redraw-check): Helper function for updating the tool + bar. + (gnus-group-tool-bar-update): Add gnus-group-redraw-check. + + * gmm-utils.el (gmm-tool-bar-item): Add TODO about modifiers. + + * spam.el (spam-spamassassin-score-regexp): New internal variable. + (spam-extra-header-to-number, spam-check-spamassassin-headers): + Use it to match format of Spamassassin 3.0 and later. Reported by + IRIE Tetsuya . + (spam-check-bogofilter) + (spam-bogofilter-register-with-bogofilter): Fix args of + `gnus-error' calls. + +2006-02-28 Reiner Steib + + * gnus-draft.el (gnus-draft-send): Bind message-signature to avoid + unnecessary interaction when sending queued mails. Reported by + TAKAHASHI Yoshio . + +2006-02-27 Reiner Steib + + * gnus-sum.el (gnus-sequence-of-unread-articles): Return nil if + first or last are nil. + +2006-02-24 Andreas Seltenreich + + * nnweb.el (nnweb-gmane-create-mapping): Don't choke on ^M. + +2006-02-24 Lars Magne Ingebrigtsen + + * gnus-int.el (gnus-open-server): Respect gnus-batch-mode. + +2006-02-24 Lars Magne Ingebrigtsen + + * dns.el (query-dns): Protect more against buggy tcp output. + +2006-02-24 Reiner Steib + + * nnweb.el (nnweb-type-definition, nnweb-gmane-search): Use new + nov.php. + +2006-02-24 Andreas Seltenreich + + * nnweb.el (nnweb-type-definition, nnweb-gmane-create-mapping) + (nnweb-gmane-wash-article, nnweb-gmane-search): Fix Gmane web + groups. Kudos to Olly Betts for providing NOV + output on the server side. + (nnweb-google-create-mapping): Update regexps and add some + progress indication. + +2006-02-23 Reiner Steib + + * gnus-group.el (gnus-group-tool-bar-gnome): Fix + gnus-agent-toggle-plugged. Re-order icons. + (gnus-group-tool-bar-gnome): Add + gnus-group-{prev,next}-unread-group. + (gnus-group-tool-bar-gnome): Re-order icons. + + * gnus-sum.el (gnus-summary-tool-bar-gnome): Move + gnus-summary-insert-new-articles. + + * message.el (message-tool-bar-gnome, message-tool-bar-retro): Fix + comments. + + * utf7.el (utf7-utf-16-coding-system): Fix comment. utf-16-be is + also available in Emacs 21.3. + + * message.el (message-fix-before-sending): Change "Emacs 22" to + "Emacs 23 (unicode)" in comment. + + * qp.el (quoted-printable-encode-region): Change "Emacs 22" to + "Emacs 23 (unicode)" in comment. + + * mm-util.el: Change "Emacs 22" to "Emacs 23 (unicode)" in + comment. + (mm-coding-system-p): Add comment about no-MULE XEmacs. + + * mm-view.el (mm-fill-flowed): Add :version. + +2006-02-23 Katsumi Yamaoka + + * gmm-utils.el (gmm-image-load-path): Don't modify image-load-path + and load-path. + +2006-02-22 Reiner Steib + + * message.el: Autoload gmm-image-load-path. + (message-tool-bar-retro): Prepend "gnus/" subdirectory to some + icon file names. Use old Emacs 21 "mail_send.xpm" icon for + consitency. + + * gmm-utils.el (gmm-image-load-path): Also search in + "../etc/images". Don't set gmm-image-load-path if we don't find + the image. + +2006-02-22 Katsumi Yamaoka + + * gmm-utils.el (gmm-image-load-path): Don't make + `gmm-image-load-path' include subdirectories which the second arg + `image' might specify. + + * gnus-group.el (gnus-group-tool-bar-retro): Prepend the "gnus/" + subdirectory to icon file names. + + * gnus-sum.el (gnus-summary-tool-bar-retro): Ditto. + +2006-02-21 Reiner Steib + + * gnus-group.el (gnus-group-make-tool-bar): Add IMAGE argument to + gmm-image-load-path calls. + + * gnus-sum.el (gnus-summary-make-tool-bar): Ditto. + + * message.el (message-make-tool-bar): Ditto. + + * mml.el (mml-preview): Added comment concerning tool bar icons. + + * gnus-group.el (gnus-group-tool-bar-gnome): Use new icon names. + (gnus-group-make-tool-bar): Use `gmm-image-load-path'. + + * gnus-sum.el (gnus-summary-tool-bar-gnome): Use new icon names. + (gnus-summary-make-tool-bar): Use `gmm-image-load-path'. + + * message.el (message-tool-bar-gnome): Use new icon names. + (message-make-tool-bar): Use `gmm-image-load-path'. + + * gmm-utils.el (gmm-defun-compat, gmm-image-search-load-path): New + functions from MH-E. + (gmm-image-load-path): New variable from MH-E. + (gmm-image-load-path): New function from MH-E. Added arguments + LIBRARY, IMAGE and PATH. Don't modify paths. Don't use + *-image-load-path-called-flag. + +2006-02-21 Milan Zamazal + + * mm-view.el (mm-view-pkcs7-verify): Implement using smime.el. + +2006-02-21 Wolfram Fenske + (tiny change) + + * nnimap.el (nnimap-request-move-article): Change folder back to + source group before deleting. + +2006-02-20 Reiner Steib + + * mm-util.el (mm-charset-override-alist): Fix type in doc string. + + * gnus-art.el (mm-url-insert-file-contents-external): Autoload + mm-url. + + * mm-uu.el (mm-uu-type-alist): Improve `LaTeX'. + +2006-02-20 Katsumi Yamaoka + + * rfc2047.el (rfc2047-charset-to-coding-system): Don't check the + coding system which mm-charset-to-coding-system returns for a + given charset is valid. + +2006-02-16 Juanma Barranquero + + * html2text.el (html2text-remove-tag-list): + * spam-stat.el (spam-stat-buffer-words): Fix typo in docstring. + +2006-02-14 Chong Yidong + + * gnus-cus.el: Revert 2005-10-17 change. + +2006-02-17 Katsumi Yamaoka + + * gnus-art.el (article-strip-banner): Call + article-really-strip-banner only when the regexp match is made. + +2006-02-16 Katsumi Yamaoka + + * gnus-art.el (article-strip-banner): Use + gnus-extract-address-components instead of + mail-header-parse-addresses to make it work with non-ASCII text; + remove mail-encode-encoded-word-string. + + * rfc2231.el (rfc2231-parse-string): Attempt to parse parameter + values which are surrounded with \"...\"; make it never cause a + Lisp error; give up parsing of parameters if it failed in + extracting type. + +2006-02-14 Arne J,Ax(Brgensen + + * smime.el (smime-cert-by-ldap-1): Fix bug where + `smime-ldap-search' returns results without userCertificates. + +2006-02-15 Katsumi Yamaoka + + * mm-util.el (mm-make-temp-file): Don't catch file-error in Emacs. + +2006-02-14 Reiner Steib + + * spam.el (spam-check-spamassassin-headers): Adapt format for + Spamassassin 3.0 or later. Reported by ARISAWA Akihiro + . + (spam-list-of-processors): Add spam-use-gmane. + +2006-02-14 Katsumi Yamaoka + + * mm-util.el (mm-make-temp-file): Import the Emacs 22 version of + make-temp-file; make it work with XEmacs as well. + + * gnus-art.el (gnus-article-browse-html-parts): Use the 3rd arg of + mm-make-temp-file. + + * mm-decode.el (mm-display-external): Use the 3rd arg of + mm-make-temp-file. + (mm-create-image-xemacs): Ditto. + +2006-02-14 Katsumi Yamaoka + + * gnus-draft.el (gnus-draft-send): Replace message-narrow-to-head + with message-narrow-to-headers. + (gnus-draft-setup): Narrow to header to run message-fetch-field. + (gnus-draft-check-draft-articles): New function. + (gnus-draft-edit-message, gnus-draft-send-message): Use it. + +2006-02-13 Reiner Steib + + * gnus-art.el (gnus-article-browse-html-parts): + `hs-show-html-list' should read `gnus-article-browse-html-parts'. + Don't use suffix argument for mm-make-temp-file for Emacs 21 + compatibility. Remove useless `format'. + +2006-02-13 Andreas Seltenreich + + * nnweb.el (nnweb-google-wash-article): Update regexps. + (nnweb-group-alist): Use defvoo instead of defvar. + +2006-02-13 Katsumi Yamaoka + + * nnoo.el (nnoo-declare): Don't generate duplicate entries when + re-loading nn* modules. + +2006-02-10 Reiner Steib + + * gnus-group.el (gnus-group-make-tool-bar): Remove duplicate check + for `tool-bar-mode' and don't check it's default-value. + + * gnus-sum.el (gnus-summary-make-tool-bar): Ditto. + + * message.el (message-make-tool-bar): Ditto. + + * gnus-art.el (gnus-article-browse-html-parts): Remove useless + `substring'. Shorten tmp-file name. + + * gnus.el: Remove bogus comment. + +2006-02-10 Hynek Schlawack + + * gnus-art.el (gnus-article-browse-html-parts): New function. + (gnus-article-browse-html-article): New function for viewing html + articles with a browser. + +2006-02-09 Daiki Ueno + + * pgg-gpg.el (pgg-gpg-encrypt-region): Don't convert line-endings + in elisp. + (pgg-gpg-encrypt-symmetric-region): Ditto. + (pgg-gpg-sign-region): Ditto. + + * pgg-def.el (pgg-text-mode): New variable. + + * mml2015.el (mml2015-pgg-sign): Enable pgg-text-mode. + (mml2015-pgg-encrypt): Ditto. + + * mml1991.el (mml1991-pgg-sign): Enable pgg-text-mode. + (mml1991-pgg-encrypt): Ditto. + +2006-02-08 Katsumi Yamaoka + + * nnfolder.el (nnfolder-insert-newsgroup-line): Use + message-make-date instead of current-time-string. + + * mm-view.el (mm-inline-message): Don't set gnus-newsgroup-charset + to gnus-decoded which mm-uu might set. + +2006-02-08 Katsumi Yamaoka + + * rfc2231.el (rfc2231-parse-string): Sort segmented parameters; + don't decode quoted parameters; remove misimported Emacs code. + Suggested by ARISAWA Akihiro . + (rfc2231-decode-encoded-string): Don't use split-string which + behaves differently according to Emacs version; use + mm-decode-coding-region to convert charset to coding-system. + Suggested by ARISAWA Akihiro . + (rfc2231-encode-string): Remove misimported Emacs code. + +2006-02-07 Katsumi Yamaoka + + * gnus-art.el (article-decode-charset): Don't use ignore-errors + when calling mail-header-parse-content-type. + (article-de-quoted-unreadable): Ditto. + (article-de-base64-unreadable): Ditto. + (article-wash-html): Ditto. + + * mm-decode.el (mm-dissect-buffer): Don't use ignore-errors when + calling mail-header-parse-content-type and + mail-header-parse-content-disposition. + (mm-find-raw-part-by-type): Don't use ignore-errors when calling + mail-header-parse-content-type. + + * mml.el (mml-insert-mime-headers): Use mml-insert-parameter to + insert charset and format parameters; encode description after + inserting it to buffer. + (mml-insert-parameter): Fold lines properly even if a parameter is + segmented into two or more lines; change the max column to 76. + + * rfc1843.el (rfc1843-decode-article-body): Don't use + ignore-errors when calling mail-header-parse-content-type. + + * rfc2231.el (rfc2231-parse-string): Return at least type if + possible; don't cause an error even if it fails in parsing of + parameters. Suggested by ARISAWA Akihiro . + (rfc2231-encode-string): Don't break lines at the beginning, leave + it to mml-insert-parameter. + + * webmail.el (webmail-yahoo-article): Don't use ignore-errors when + calling mail-header-parse-content-type. + +2006-02-06 Reiner Steib + + * spam-report.el (spam-report-gmane-use-article-number): Improve + doc string. + (spam-report-gmane-internal): Check if a suitable header was found + in the article. + +2006-02-04 Katsumi Yamaoka + + * rfc2231.el (rfc2231-parse-string): Revert 2006-02-03 change. + (rfc2231-encode-string): Make param*=value always begin with LWSP. + +2006-02-05 Romain Francoise + + Update copyright notices of all files in the gnus directory. + +2006-02-03 Andreas Seltenreich + + * nnweb.el (nnweb-request-group): Avoid growing overview files. + +2006-02-03 Katsumi Yamaoka + + * rfc2231.el (rfc2231-parse-string): Add missing semicolons to + segmented lines of parameter value to cope with Thunderbird 1.5 + bug (cf. https://bugzilla.mozilla.org/show_bug.cgi?id=323318). + Suggested by ARISAWA Akihiro . + (rfc2231-encode-string): Don't make lines exceeding 76 column. + +2006-02-01 Max Froumentin (tiny change) + + * mml.el (mml-generate-mime-1): Correct the order of inline signed + parts. + +2006-01-31 Andreas Seltenreich + + * nnweb.el (nnweb-group-alist): Use defvar instead of defvoo, + there's only one active file for all servers. + (nnweb-request-scan): Make sure nnweb-articles is initialized on + solid groups. Gnus might have used a FAST request to select the + group. + (nnweb-request-group, nnweb-google-parse-1): Don't keep nnweb-type + and nnweb-search redundantly in the active file. + (nnweb-request-list): Don't list bogus groups. There can only be + one. + (nnweb-request-create-group): Don't use ARGS. + (nnweb-possibly-change-server, nnweb-request-group): Remove some + initialisations. Let nnoo do the work. + +2006-01-31 Katsumi Yamaoka + + * mm-uu.el (mm-uu-emacs-sources-extract): Say the part has been + decoded. + (mm-uu-diff-extract): Ditto. + + * mm-view.el (mm-display-inline-fontify): Get decoded part rightly. + +2006-01-31 Kevin Ryde + + * mailcap.el (mailcap-viewer-passes-test): Don't put "(nil t)" into + mailcap-viewer-test-cache when there's no 'test clause, since that + will invert the meaning of a "nil" test previously determined by + mailcap-mailcap-entry-passes-test. + +2006-01-30 Katsumi Yamaoka + + * gnus-group.el: Bind tool-bar-mode instead of tool-bar-map when + compiling. + + * gnus-sum.el: Ditto. + + * message.el: Don't bind tool-bar-map when compiling. + +2006-01-30 Reiner Steib + + * nnweb.el (nnweb-google-parse-1): Clarify some comments. + +2006-01-30 Andreas Seltenreich + + * nnweb.el (nnweb-type-definition, nnweb-google-parse-1) + (nnweb-google-create-mapping, nnweb-google-search): Adapt to + current Google Groups. + +2006-01-26 Reiner Steib + + * gnus-sum.el (gnus-summary-make-tool-bar): Add checks for XEmacs + and tool-bar-mode. + + * gnus-group.el (gnus-group-make-tool-bar): Add checks for XEmacs + and tool-bar-mode. + + * message.el (message-tool-bar-update): Simplify. + (message-make-tool-bar): Add checks for XEmacs and tool-bar-mode. + + * gnus-sum.el (gnus-summary-tool-bar-update): Check for + gnus-summary-buffer. + (gnus-summary-tool-bar-gnome): Use "reply-author" icon for + gnus-summary-reply. + + * gmm-utils.el (gmm): Add :version. + +2006-01-26 Katsumi Yamaoka + + * Makefile.in (clean): New rule. + (distclean): Use it. + +2006-01-26 Steve Youngs + + * gmm-utils.el (gmm-tool-bar-item, gmm-tool-bar-zap-list): Don't + autoload. + +2006-01-26 Katsumi Yamaoka + + * gmm-utils.el (gmm-verbose): Add :group. + +2006-01-25 Reiner Steib + + * message.el: Change some comments WRT tool-bars. + + * gnus-sum.el (gnus-summary-tool-bar) + (gnus-summary-tool-bar-gnome, gnus-summary-tool-bar-retro) + (gnus-summary-tool-bar-zap-list): New variables. + (gnus-summary-make-tool-bar): Complete rewrite using + `gmm-tool-bar-from-list'. + + * gnus-group.el (gnus-group-tool-bar, gnus-group-tool-bar-gnome) + (gnus-group-tool-bar-retro, gnus-group-tool-bar-zap-list): New + variables. + (gnus-group-make-tool-bar): Complete rewrite using + `gmm-tool-bar-from-list'. + (gnus-group-tool-bar-update): New function. + + * message.el (message-mode-field-menu): Add "Show hidden Headers". + +2006-01-25 Katsumi Yamaoka + + * mm-uu.el (mm-uu-dissect-text-parts): Ignore it if a given part + is dissected into a single part of which the type is the same as + the given one; decode charset. + +2006-01-21 Kevin Ryde + + * mailcap.el (mailcap-parse-mailcap-extras): "test" key must go + into alists as symbol not string, since that's what + mailcap-viewer-passes-test and mailcap-mailcap-entry-passes-test + look for. + +2006-01-24 Reiner Steib + + * gmm-utils.el (gmm-tool-bar-item): Add "Separator". + (gmm-tool-bar-from-list): Suppress tooltip for `gmm-ignore'. + + * message.el (message-tool-bar-gnome): Use gmm-ignore. + +2006-01-24 Katsumi Yamaoka + + * gnus-xmas.el (gnus-mime-security-button-menu): New alias. + (gnus-xmas-mime-security-button-menu): New function. + + * gnus-art.el (gnus-mime-security-button-commands): New variable. + (gnus-mime-security-button-menu): New definition. + (gnus-mime-security-button-map): Use them. + (gnus-mime-security-button-menu): New function. + (gnus-insert-mime-security-button): Addition to help echo. + (gnus-mime-security-run-function, gnus-mime-security-save-part) + (gnus-mime-security-pipe-part): New functions. + + * mm-uu.el (mm-uu-buttonize-original-text-parts): Remove. + (mm-uu-dissect-text-parts): Revert a part of 2006-01-23 change. + + * mm-decode.el (mm-handle-set-disposition): Remove. + (mm-handle-set-description): Remove. + +2006-01-24 Katsumi Yamaoka + + * mm-view.el (mm-w3m-standalone-supports-m17n-p): New variable. + (mm-w3m-standalone-supports-m17n-p): New function. + (mm-inline-text-html-render-with-w3m-standalone): Use it to alter + w3m usage. + + * gnus-art.el (gnus-article-wash-html-with-w3m-standalone): Use + mm-w3m-standalone-supports-m17n-p to alter w3m usage. + +2006-01-23 Reiner Steib + + * message.el (message-tool-bar-zap-list): Use + gmm-tool-bar-zap-list as custom type. + (message-tool-bar-update): New function. + (message-tool-bar, message-tool-bar-gnome) + (message-tool-bar-retro): Add message-tool-bar-update. + (message-tool-bar-gnome): Add flyspell-buffer. + + * gnus-util.el (gnus-error): Describe `args'. + + * gmm-utils.el (gmm-error): Describe `args'. + (gmm-tool-bar-zap-list): New widget. + (gmm-tool-bar-from-list): Improve description of `zap-list'. + +2006-01-23 Katsumi Yamaoka + + * mm-uu.el (mm-uu-buttonize-original-text-parts): New variable. + (mm-uu-dissect-text-parts): Buttonize original text parts; reduce + the number of recursive calls. + + * mm-decode.el (mm-handle-set-disposition): New macro. + (mm-handle-set-description): New macro. + +2006-01-23 Katsumi Yamaoka + + * mm-uu.el (mm-uu-dissect-text-parts): Decode content transfer + encoding. + +2006-01-20 Reiner Steib + + * message.el (message-tool-bar-zap-list, message-tool-bar) + (message-tool-bar-gnome, message-tool-bar-retro): New variables. + (message-tool-bar-local-item-from-menu): Remove. + (message-tool-bar-map): Replace by `message-make-tool-bar'. + (message-make-tool-bar): New function. + (message-mode): Use `message-make-tool-bar'. + + * gmm-utils.el: New file. + (gmm-verbose, gmm-message, gmm-error): From gnus-utils.el. + (gmm-lazy): New widget copied from `nnmail.el'. + (gmm-tool-bar-from-list): New function for creating customizable + tool bars. + (gmm-tool-bar-from-list): Fix typos in doc string. Remove debug + output. + (gmm): Add :prefix to defgroup. + +2006-01-20 Per Abrahamsen + + * gmm-utils.el (gmm-widget-p): New function. + +2006-01-20 Reiner Steib + + * mml.el (mml-attach-file): Describe `description' in doc string. + (mml-menu): Add Emacs MIME manual and PGG manual. + +2006-01-20 Richard M. Stallman + + * mm-url.el (mm-url-load-url): Require url-parse and url-vars. + +2006-01-20 Kevin Greiner + + * nntp.el (nntp-end-of-line): Doc fix. + +2006-01-20 Chong Yidong + + * imap.el (imap-open): Handle case where buffer is a buffer + object. + +2005-01-20 Stefan Monnier + + * gnus-delay.el (gnus-delay): Don't autoload. + It's useless and could trigger a bug in cus-dep.el causing ldefs-boot + to be re-loaded when customizing the `gnus-delay' group. + +2005-01-20 Chong Yidong + + * message.el (message-insert-citation-line): Use newlines. + +2006-01-19 Ken Manheimer + + * pgg-pgp.el (pgg-pgp-encrypt-region, pgg-pgp-decrypt-region) + (pgg-pgp-sign-region): Add optional 'passphrase' argument to all + these routines, so the passphrase can be managed externally and + passed in to the system. + (pgg-pgp-decrypt-region, pgg-pgp-sign-region): Use new name for + pgg-add-passphrase-to-cache function. + + * pgg-pgp5.el (pgg-pgp5-encrypt-region, pgg-pgp5-decrypt-region) + (pgg-pgp5-sign-region): Add optional 'passphrase' argument to all + these routines, so the passphrase can be managed externally and + passed in to the system. + (pgg-pgp5-sign-region): Use new name of + pgg-add-passphrase-to-cache function. + +2006-01-19 Ken Manheimer + + * pgg-gpg.el (pgg-gpg-select-matching-key): Fix: look at the right + part of the decoded armor to find the key-identifier. + (pgg-gpg-lookup-key-owner): New function to return the + human-readable identifier of a key owner. + (pgg-gpg-key-id-from-key-owner): Make it easy to identify the key + itself. + (pgg-gpg-decrypt-region): Prompt with the key owner (rather than + the key value) if we have a key and can match it against a secret + key. Also, added a note pointing out fact that the prompt only + indicates the first matching key. + + * pgg.el (pgg-decrypt): Passing along 'passphrase' in call to + pgg-decrypt-region. + (pgg-add-passphrase-to-cache): Rename from + `pgg-add-passphrase-cache' to reduce confusion (all callers + changed). + (pgg-remove-passphrase-from-cache): Rename from + `pgg-remove-passphrase-cache' to reduce confusion (all callers + changed). + (pgg-read-passphrase, pgg-add-passphrase-cache) + (pgg-remove-passphrase-cache): Add informative docstrings. + (pgg-decrypt): Convey provided passphrase in subordinate call to + pgg-decrypt-region. + +2006-01-19 Ken Manheimer + + * pgg.el (pgg-encrypt-region, pgg-encrypt-symmetric-region) + (pgg-encrypt-symmetric, pgg-encrypt, pgg-decrypt-region) + (pgg-decrypt, pgg-sign-region, pgg-sign): Add optional + 'passphrase' argument, so the passphrase can be managed externally + and then passed in to the system. + + * pgg.el (pgg-read-passphrase, pgg-add-passphrase-cache) + (pgg-remove-passphrase-cache): Add optional 'notruncate' argument, + so the passphrase cache can be used reliably with identifiers + besides a pgp packet's key id. + + * pgg-gpg.el (pgg-gpg-encrypt-region) + (pgg-gpg-encrypt-symmetric-region, pgg-gpg-decrypt-region) + (pgg-gpg-sign-region): Add optional 'passphrase' argument to all + these routines, so the passphrase can be managed externally and + passed in to the system. + + * pgg-gpg.el (pgg-gpg-possibly-cache-passphrase): Add optional + 'notruncate' argument, so the passphrase cache can be used + reliably with identifiers besides a pgp packet's key id. + +2006-01-19 Sascha Wilde + + * pgg-gpg.el (pgg-gpg-encrypt-symmetric-region): New function for + symmetric encryption. + (pgg-gpg-symmetric-key-p): New function to check for an symmetric + encrypted session key. + (pgg-gpg-decrypt-region): When decrypting a symmetric encrypted + message ask for the passphrase in a proper way. + + * pgg.el (pgg-encrypt-symmetric, pgg-encrypt-symmetric-region): + New user commands for symmetric encryption. + +2006-01-19 Katsumi Yamaoka + + * mm-bodies.el (mm-decode-body): Don't decode decoded body. + + * mm-uu.el (mm-uu-dissect-text-parts): Dissect dissected parts. + +2006-01-19 Mark D. Baushke + + * pgg-gpg.el (pgg-gpg-encrypt-region): Add --textmode to gpg args. + +2006-01-17 Katsumi Yamaoka + + * mm-decode.el (mm-inlined-types): Add application/pgp. + (mm-automatic-display): Ditto. + + * mm-uu.el (mm-uu-dissect-text-parts): Recognize application/pgp + part as text. + +2006-01-16 Katsumi Yamaoka + + * nnrss.el: Update copyright. + (nnrss-opml-import): Query whether to subscribe to each entry. + + * gnus-art.el: + * gnus-sum.el: + * gnus-xmas.el: + * messagexmas.el: + * mm-uu.el: + * mm-view.el: Update copyright. + +2006-01-16 Reiner Steib + + * message.el (message-info): New function. + (message-mode-menu): Add it. + Update copyright. + + * ChangeLog: Fix and update copyright. + +2006-01-13 Romain Francoise + + * message.el (message-forward-subject-name-subject): Prefer the + address to 'nowhere' if the sender has no name. + Fix typo. Update copyright year. + +2006-01-13 Katsumi Yamaoka + + * gnus-art.el (article-wash-html): Use + gnus-summary-show-article-charset-alist if a numeric arg is given. + (gnus-article-wash-html-with-w3m-standalone): New function. + + * mm-view.el (mm-text-html-renderer-alist): Map w3m-standalone to + mm-inline-text-html-render-with-w3m-standalone. + (mm-text-html-washer-alist): Map w3m-standalone to + gnus-article-wash-html-with-w3m-standalone. + (mm-inline-text-html-render-with-w3m-standalone): New function. + +2006-01-12 Reiner Steib + + * mm-uu.el (mm-uu-type-alist): Fix previous message-marks commit. + Improve LaTeX. + +2006-01-10 Katsumi Yamaoka + + * nnrss.el (nnrss-wash-html-in-text-plain-parts): New variable. + (nnrss-request-article): Render text/plain parts as HTML. + + * gnus-art.el (gnus-article-wash-html-with-w3m): No need to narrow + the buffer. + +2006-01-08 Reiner Steib + + * gnus-cus.el (gnus-group-parameters): Sync posting-style with + custom definition of `gnus-posting-styles'. + + * gnus-start.el (gnus-gnus-to-quick-newsrc-format): Bind + print-circle. Suggested by Kalle Olavi Niemitalo . + +2006-01-05 Reiner Steib + + * gnus-group.el (gnus-useful-groups): Use Gmane for ding. + Use nntp for bug archive. + +2006-01-05 Katsumi Yamaoka + + * nnrss.el (nnrss-request-article): Fix the way to fill text/plain + parts. + (nnrss-normalize-date): New function converts ISO 8601 date into + RFC822 style. Suggested by Mark Plaksin . + (nnrss-check-group): Use it. + +2006-01-01 Katsumi Yamaoka + + * gnus-sum.el (gnus-summary-work-articles): Remove useless `min'. + + * nnrss.el (nnrss-fetch): Make it fail gracefully when it can't + fetch a feed. Suggested by Mark Plaksin . + (nnrss-insert-w3): Ditto. + +2005-12-22 Katsumi Yamaoka + + * gnus-uu.el (gnus-uu-digest-mail-forward): Reverse the order of + the articles to be forwarded including the case where neither a + number of articles nor a region is specified. + +2005-12-21 Katsumi Yamaoka + + * nnrss.el (nnrss-request-article): Fix last change; fill + text/plain parts. + +2005-12-20 Katsumi Yamaoka + + * nnrss.el (nnrss-request-article): Replace
s with newlines + in text/plain part. + (nnrss-check-group): Don't add excessive newline to dc:subject. + +2005-12-19 Mark Plaksin (tiny change) + + * nnrss.el (nnrss-check-group): Put the RSS dc:subject in the + article. + +2005-12-18 Reiner Steib + + * nnml.el: Don't require gnus-bcklg. Autoload it. + (nnml-use-compressed-files, nnml-save-mail): Support other + comression programs such as bzip2. + +2005-12-17 Lars Magne Ingebrigtsen + + * dns.el (query-dns): Make sure we check the buffer size before + removing tcp headers. + +2005-12-16 Katsumi Yamaoka + + * gnus-art.el (gnus-article-delete-text-of-type): Enable it to + remove MIME buttons associated with multipart/alternative parts. + (gnus-mime-display-alternative): Tag buttons using `article-type' + text property. + + * gnus-msg.el (gnus-copy-article-buffer): Remove MIME buttons + associated with multipart/alternative parts. + + * gnus-art.el (gnus-signature-separator): Fix custom type. + + * mm-decode.el (mm-inlined-types): Fix custom type. + (mm-keep-viewer-alive-types): Ditto. + (mm-automatic-display): Ditto. + (mm-attachment-override-types): Ditto. + (mm-inline-override-types): Ditto. + (mm-automatic-external-display): Ditto. + +2005-12-15 Reiner Steib + + * spam-report.el (spam-report-user-mail-address) + (spam-report-user-agent): New variables. + (spam-report-url-ping-plain): Use spam-report-user-agent. + +2005-12-14 Ralf Angeli + + * gnus-art.el (gnus-button-handle-custom): Do not just use + `customize-apropos' for any "M-x customize-*" button but the + function called for. Accept both the function name and its + argument in order to achieve this. + (gnus-button-alist): Remove support for "custom:" URL's. Pass + function name to `gnus-button-handle-custom' in case of "M-x + customize-*" buttons. + +2005-12-12 Katsumi Yamaoka + + * gnus-art.el (gnus-buttonized-mime-types): Mention addition of + multipart/alternative and add xref to mm-discouraged-alternatives + in doc string. + + * mm-decode.el (mm-discouraged-alternatives): Add xref to + gnus-buttonized-mime-types in doc string. + +2005-12-08 Reiner Steib + + * mm-decode.el (mm-discouraged-alternatives): Fix custom type. + Suggest image/.* in the doc string. + +2005-12-12 Reiner Steib + + * mm-uu.el (mm-uu-type-alist): Don't depend on message.el for + message-marks (Debian bug #342521). + +2005-12-12 Simon Josefsson + + * password.el (password-read-from-cache): Add. + (password-read): Use it. + +2005-12-12 Katsumi Yamaoka + + * rfc2047.el (rfc2047-charset-to-coding-system): Recognize + us-ascii as a MIME charset. + + * mm-bodies.el (mm-decode-content-transfer-encoding): Protect + against the case where the 2nd arg TYPE is nil. + +2005-12-09 Reiner Steib + + * pop3.el (pop3-stream-type): Fix custom version. + + * mm-uu.el (mm-uu-type-alist): Simplify uu regexp. + +2005-12-09 ARISAWA Akihiro (tiny change) + + * mm-decode.el (mm-display-external): Add missing cdr. + +2005-12-07 Katsumi Yamaoka + + * mm-decode.el (mm-display-external): Use nametemplate (defined in + RFC1524) if it is in mailcap or add a suffix according to + mailcap-mime-extensions when generating a temp filename; postpone + deleting a temp file for 2 seconds for some wrappers, shell + scripts, and so on, which might exit right after having started a + viewer command as a background job. + +2005-12-06 Reiner Steib + + * nntp.el (nntp-marks-directory): Fix custom group. + + * gnus-fun.el (gnus-face-from-file): Decrease quant in smaller + steps when < 10. + + * gnus-start.el (gnus-no-server-1): Mention + `gnus-level-default-subscribed' in doc string. + +2005-12-02 ARISAWA Akihiro (tiny change) + + * mm-view.el (mm-inline-text-html-render-with-w3m): Fix misplaced + parens. + +2005-12-01 Katsumi Yamaoka + + * gnus-xmas.el (gnus-use-toolbar): Revert. + (gnus-xmas-setup-toolbar): Use global default-toolbar if + gnus-use-toolbar is default. + + * messagexmas.el (message-use-toolbar): Revert. + (message-setup-toolbar): Use global default-toolbar if + message-use-toolbar is default. + +2005-11-30 Katsumi Yamaoka + + * gnus-xmas.el (gnus-use-toolbar): Determine the default value + according to default-toolbar-visible-p. + + * messagexmas.el (message-use-toolbar): Ditto. + +2005-11-26 Dave Love + + * tls.el (open-tls-stream): Rename arg SERVICE to PORT. + (tls-program, tls-success): Provide openssl alternative. + + * starttls.el: Doc fixes. + (starttls-open-stream-gnutls, starttls-open-stream): Rename arg + SERVICE to PORT. + + * pop3.el (pop3-open-server) : Clarify a loop. Deal with + port null or service name. + (starttls-negotiate): Autoload. + +2005-11-25 Katsumi Yamaoka + + * message.el (message-kill-to-signature): Fix interactive spec. + +2005-11-24 Katsumi Yamaoka + + * pop3.el (pop3-open-server): Recognize a string as a service name. + +2005-11-24 Pascal Rigaux (tiny change) + + * rfc2231.el (rfc2231-parse-string): Support non-ascii chars. + +2005-11-23 Dave Love + + Add pop3s, pop3/starttls. + + * pop3.el (pop3-authentication-scheme): Clarify doc. + (open-tls-stream, starttls-open-stream): Autoload. + (pop3-stream-type): New. + (pop3-open-server): Use it. + + * mail-source.el (mail-sources): Fix some :types. Add stream type + for POP. + (mail-source-keyword-map): Add :stream for POP. + (mail-source-fetch-pop): Use pop3-stream-type. + +2005-11-22 Katsumi Yamaoka + + * nnmail.el (nnmail-fancy-expiry-target): Use current-time instead + of current-time-string. + +2005-11-20 Stefan Schimanski (tiny change) + + * nnmail.el (nnmail-fancy-expiry-target): Protect against invalid + date header. + +2005-11-19 Kevin Greiner + + * gnus-sum.el (gnus-fetch-old-headers): Updated docs to warn that + it can seriously impact performance as it bypasses the agent's + local caches. + +2005-11-19 Kevin Greiner + + * gnus-agent.el (gnus-agent-possibly-synchronize-flags): A server + must be explicitly online rather than "not explicitly offline" for + its flags to be synchronized. + + * gnus-sum.el (gnus-summary-remove-process-mark): Always return t so + that gnus-uu-unmark-thread will function correctly. + + * gnus-group.el (gnus-total-fetched-for): Reduced cutoff so that + 1024K is instead displayed as 1M. + +2005-11-17 Lars Magne Ingebrigtsen + + * flow-fill.el (fill-flowed): Bind adaptive-fill-mode to nil. + +2005-11-16 Boris Samorodov (tiny patch) + + * imap.el (imap-kerberos4-open): Ignore SSL stuff. + +2005-11-13 Kevin Greiner + + * gnus-agent.el (gnus-agent-read-local): Trivial fix to format of + error message to display actual error condition. + (gnus-agent-save-local): Avoid saving symbols that are bound to + nil as they simply result in a warning message in + gnus-agent-read-local. + +2005-11-13 Katsumi Yamaoka + + * gnus-start.el (gnus-dribble-read-file): Use make-local-variable + rather than make-variable-buffer-local for file-precious-flag. + +2005-11-12 Kevin Greiner + + * gnus-agent.el (gnus-agent-braid-nov): Now tests new nov entries + for duplicates which are removed. The invalid sort check then + triggers a rescan after the sort as sorting may have moved + duplicate entries such that they can be cheaply detected. + +2005-11-13 Katsumi Yamaoka + + * gnus-start.el (gnus-dribble-read-file): Quote file-precious-flag. + +2005-11-12 Kevin Greiner + + * gnus-agent.el (gnus-agent-article-alist-save-format): Changed + internal variable to a custom variable. Changed default value + from compressed(2) to uncompressed(1). + (gnus-agent-read-agentview): Reversed revision 7.8 to restore + support for uncompressed agentview files. Taken together, reading + the agentview file should now be 6-7 times faster. + +2005-11-11 Jan Nieuwenhuizen + + * gnus-start.el (gnus-dribble-read-file): Set file-precious-flag, + as a buffer-local variable. This avoids creating truncated + dribble files as a result of a hang up, eg. + +2006-01-03 Rodrigo Ventura (tiny change) + + * gnus-xmas.el (gnus-xmas-group-startup-message): Typo + gnus-splash-face -> gnus-splash. Fixes starting from a TTY in + XEmacs. + +2005-12-09 Reiner Steib + + * gnus-start.el (gnus-start-draft-setup): Enforce + `gnus-draft-mode' for nndraft:drafts at startup. + + * gnus.el (gnus-splash): Change custom group. + (gnus-group-get-parameter, gnus-group-parameter-value): Describe + allow-list argument. + + * gnus-agent.el (gnus-agent-article-alist-save-format): Format doc + string. + +2005-12-06 Reiner Steib + + * gnus-art.el (gnus-default-article-saver): Add user-defined + `function' to custom type. + +2005-10-30 Chong Yidong + + * imap.el (imap-open): Handle case where buffer is a buffer + object. + +2005-11-29 Reiner Steib + + * gnus-cache.el (gnus-cache-rename-group): Wrap doc strings and + long lines. + (gnus-cache-delete-group): Wrap doc strings. + + * gnus-agent.el (gnus-agent-rename-group) + (gnus-agent-delete-group): Wrap doc strings. + + +2005-11-10 Katsumi Yamaoka + + * messagexmas.el (message-use-toolbar): Change the valid values + into default, top, bottom, left, and right. + (message-toolbar-thickness): New variable. + (message-xmas-setup-toolbar): Locate gnus-xmas-glyph-directory as + well. + (message-setup-toolbar): Make it work. + + * gnus-xmas.el (gnus-xmas-update-toolbars): New function. + (gnus-use-toolbar): Change the valid values into default, top, + bottom, left, and right. + (gnus-toolbar-thickness): New variable. + (gnus-xmas-setup-toolbar): New function. + (gnus-xmas-setup-group-toolbar): Use it. + (gnus-xmas-setup-summary-toolbar): Use it. + +2005-11-10 Lars Magne Ingebrigtsen + + * gnus-start.el (gnus-1): Add "native" to + gnus-predefined-server-alist. + + * gnus.el (gnus-method-to-server): Don't add "native" to the + lists here, because that leads to problems when + gnus-select-method is bound. + +2005-11-09 Simon Josefsson + + * gnus-sum.el (gnus-article-sort-by-date-reverse): Remove, + use (not sort-by-date) instead. + +2005-11-30 Stefan Monnier + + * gnus-delay.el (gnus-delay-group): Don't autoload. + It's useless and could trigger a bug in cus-dep.el causing ldefs-boot + to be re-loaded when customizing the `gnus-delay' group. + +2005-11-19 Chong Yidong + + * message.el: Revert last changes. + (message-insert-citation-line): Use newlines. + +2005-11-17 Chong Yidong + + * message.el (message-courtesy-message) + (message-mark-insert-begin, message-mark-insert-end) + (message-elide-ellipsis, message-cancel-message) + (message-add-header, message-change-subject) + (message-cross-post-followup-to-header) + (message-cross-post-insert-note, message-reduce-to-to-cc) + (message-widen-reply, message-delete-not-region) + (message-kill-to-signature, message-insert-signature) + (message-insert-importance-high, message-insert-importance-low) + (message-insert-or-toggle-importance) + (message-insert-disposition-notification-to) + (message-indent-citation, message-yank-original) + (message-cite-original-without-signature, message-cite-original) + (message-insert-citation-line, message-position-on-field) + (message-fix-before-sending, message-send-mail-partially) + (message-send-mail, message-send-mail-with-sendmail) + (message-send-mail-with-qmail, message-send-news) + (message-check-news-header-syntax, message-generate-headers) + (message-insert-courtesy-copy, message-fill-address) + (message-fill-header, message-shorten-references) + (message-setup-1, message-cancel-news) + (message-forward-make-body-plain, message-forward-make-body-mime) + (message-forward-make-body-mml, message-encode-message-body) + (message-forward-make-body-digest-plain) + (message-forward-make-body-digest-mime) + (message-use-alternative-email-as-from): Insert `hard-newline' + instead of ordinary newlines. + +2005-11-09 Katsumi Yamaoka + + * message.el (message-generate-headers): Downcase the argument + given to message-check-element. + +2005-11-08 Kevin Greiner + + * nntp.el (nntp-authinfo-rejected): New error condition. + (nntp-wait-for): Use new error condition to signal authentication + error. + (nntp-retrieve-data): Rethrow new error condition to break out of + recursive call to nntp-send-authinfo. + +2005-11-08 Romain Francoise + + * gnus-sum.el (gnus-summary-catchup-and-goto-prev-group): New function. + (gnus-summary-exit-map): Bind to `Z p'. + (gnus-summary-make-menu-bar): Add menu item. + +2005-11-02 Reiner Steib + + * gnus-art.el (gnus-article-treat-custom): Add `first'. + (gnus-treat-*): Add `first' in all doc strings. + + * gnus-group.el (gnus-group-compact-group): Fix typo. + +2005-11-01 Katsumi Yamaoka + + * gnus.el (gnus-parameters-case-fold-search): New variable. + (gnus-parameters-get-parameter): Use it. + + * gnus-score.el (gnus-home-score-file): Doc fix. + +2005-11-01 Xavier Maillard (tiny change) + + * gnus-score.el (gnus-update-score-entry-dates): Doc fix. + +2005-10-31 Katsumi Yamaoka + + * mm-util.el (mm-special-display-p): New function. + + * mml.el (mml-preview): Use it; doc fix. + +2005-10-29 Romain Francoise + + * message.el (message-fix-before-sending): Fix comment. + +2005-10-29 Jari Aalto + + * gnus-sum.el (gnus-article-sort-by-date-reverse): New function. + +2005-10-29 Jari Aalto + + * score-mode.el (gnus-score-edit-done-hook): Introduce variable. + Used in gnus-score.el. + +2005-10-28 Reiner Steib + + * mm-util.el (mm-codepage-setup): Remove bogus alias test. + +2005-10-27 Reiner Steib + + * flow-fill.el (fill-flowed-encode-tests): Restore trailing + whitespace removed in revision 7.8. Use concatenated string to + protect trailing whitespace. + +2005-10-27 Jouni K Seppanen (tiny change) + + * nnimap.el (nnimap-search-uids-not-since-is-evil): Add variable. + (nnimap-request-expire-articles): Use it to avoid sending 'UID + SEARCH UID ... NOT SINCE' queries, for inefficient servers like + Courier IMAP ("some version from 2004"). Mostly based on similar + code in the same function. + +2005-10-26 Didier Verna + + * gnus-group.el (gnus-group-compact-group): invalidate original + article buffer. + * gnus-srvr.el (gnus-server-compact-server): ditto. + * nnml.el (nnml-request-compact-group): handle self Xref: field in + NOV database and in article itself. + Invalidate article backlog. + +2005-10-26 Reiner Steib + + * mm-uu.el (mm-uu-hide-markers): Fix XEmacs case. + +2005-10-26 Simon Josefsson + + * flow-fill.el (fill-flowed): Flow-fill unquoted lines too, revert + part of 2004-07-25 change. + +2005-10-26 Katsumi Yamaoka + + * message.el (message-display-completion-list): New function. + (message-expand-group): Use it; make sure the Completions buffer + is modifiable. + +2005-10-23 Chong Yidong + + * gnus-sum.el (gnus-ignored-from-addresses): Handle case where + user-mail-name is an empty string. + +2005-10-25 Reiner Steib + + * gnus-score.el (gnus-default-adaptive-score-alist): Set defaults + depending on gnus-score-decay-constant. + + * encrypt.el (encrypt-insert-file-contents) + (encrypt-write-file-contents): Don't use `gnus-message'. + + * mm-uu.el (mm-uu-verbatim-marks-extract): Add four start and end + arguments. + (mm-uu-type-alist): Add message-marks and insert-marks. Pass + arguments to mm-uu-verbatim-marks-extract. + (mm-uu-hide-markers): New variable. + (mm-uu-extract): Use face similar to `gnus-cite-3'. + + * gnus-fun.el (gnus-convert-image-to-x-face-command) + (gnus-convert-image-to-face-command): Use "convert" by default to + allow other input image formats. + (gnus-x-face-from-file, gnus-face-from-file): Adjust doc strings + accordingly. + +2005-10-23 Simon Josefsson + + * imap.el (imap-gssapi-program): Align command line parameters + with latest GNU SASL. + (imap-gssapi-open): Ignore 'Trying ...' messages from GNU SASL. + +2005-10-21 Lars Magne Ingebrigtsen + + * nnslashdot.el (nnslashdot-retrieve-headers-1): Update to new + HTML. + (nnslashdot-request-article): Ditto. + + * lpath.el (featurep): Add nobreak-char-display. + +2005-10-20 Hiroshi Fujishima (tiny change) + + * mail-source.el (mail-source-fetch-pop): Require pop3. + (mail-source-check-pop): Ditto. + +2005-10-20 Katsumi Yamaoka + + * rfc2047.el (rfc2047-decode-encoded-words): Fix the handling of + errors. + +2005-10-19 Reiner Steib + + * gnus-art.el (gnus-treat-strip-trailing-blank-lines) + (gnus-treat-strip-leading-blank-lines): Improve doc string. + + * message.el (message-tool-bar-local-item-from-menu): Fix comment. + + * mm-bodies.el (mm-decode-string): Call + `mm-charset-to-coding-system' with allow-override argument. + +2005-10-19 Katsumi Yamaoka + + * rfc2047.el (rfc2047-allow-incomplete-encoded-text): New variable. + (rfc2047-charset-to-coding-system): New function. + (rfc2047-decode-encoded-words): New function. + (rfc2047-decode-region): Use them. + (rfc2047-decode-cte): Remove. + (rfc2047-parse-and-decode): Remove. + (rfc2047-decode): Remove. + +2005-10-15 Kenichi Handa + + * rfc2047.el (rfc2047-decode-cte): New function. + (rfc2047-decode-region): Change the way to decode successive + encoded-words: decode B- or Q-encoding in each encoded-word, + concatenate them, and decode it as charset. + +2005-10-14 Katsumi Yamaoka + + * lpath.el: Fbind codepage-setup for XEmacs. + +2005-10-17 Chong Yidong + + * gnus-cus.el (gnus-custom-map): New variable. Bind mouse-1 to + widget-move-and-invoke. + (gnus-custom-mode): Use gnus-custom-map. + +2005-10-15 Bill Wohler + + * message.el (message-tool-bar-map): Renamed image file from + mail_send to mail/send. + +2005-10-16 Masatake YAMATO + + * message.el (message-expand-group): Pass the common + prefix substring of completion to `display-completion-list'. + +2005-10-13 Reiner Steib + + * mml-sec.el (mml-secure-method): New internal variable. + (mml-secure-sign, mml-secure-encrypt, mml-secure-message-sign) + (mml-secure-message-sign-encrypt, mml-secure-message-encrypt): New + functions using mml-secure-method. + + * mml.el (mml-mode-map): Add key bindings for those functions. + (mml-menu): Simplify security menu entries. Suggested by Jesper + Harder . + (mml-attach-file, mml-attach-buffer, mml-attach-external): Goto + end of message if point is the headers of the message. + + * message.el (message-in-body-p): New function. + + * assistant.el: Autoload gnus-util and netrc. + + * mm-util.el (mm-charset-to-coding-system): Add allow-override. + Use `mm-charset-override-alist' only when decoding. + + * mm-bodies.el (mm-decode-body): Call + `mm-charset-to-coding-system' with allow-override argument. + + * gnus-art.el (gnus-mime-view-part-as-type-internal): Try to fetch + `filename' from Content-Disposition if Content-Type doesn't + provide `name'. + (gnus-mime-view-part-as-type): Set default instead of + initial-input. + +2005-10-09 Daniel Brockman + + * format-spec.el (format-spec): Propagate text properties of % spec. + +2005-10-12 Reiner Steib + + * gnus-art.el (gnus-treat-predicate): Add `first'. + +2005-10-11 Reiner Steib + + * mm-util.el (mm-charset-synonym-alist): Improve doc string. + (mm-charset-override-alist): New variable. + (mm-charset-to-coding-system): Use it. + (mm-codepage-setup): New helper function. + (mm-charset-eval-alist): New variable. + (mm-charset-to-coding-system): Use mm-charset-eval-alist. Warn + about unknown charsets. + + * dgnushack.el (with-syntax-table): Add some URLs WRT the XEmacs bug. + +2005-10-04 David Hansen + + * nnrss.el (nnrss-request-article): Add support for the comments tag. + (nnrss-check-group): Ditto. + +2005-10-04 Reiner Steib + + * mm-uu.el (mm-uu-verbatim-marks-extract, mm-uu-latex-extract): + Rename x-gnus-verbatim to x-verbatim. + (mm-uu-type-alist): Fix regexp for verbatim-marks. + + * mm-decode.el (mm-automatic-display): Rename x-gnus-verbatim to + x-verbatim. + + * mm-url.el (mm-url-predefined-programs): Add switches for curl. + + * gnus-util.el (gnus-remove-duplicates): Remove. + + * nnmail.el (nnmail-article-group): Use mm-delete-duplicates + instead of gnus-remove-duplicates. + + * message.el (message-remove-duplicates): Remove. + (message-idna-to-ascii-rhs-1): Use mm-delete-duplicates instead of + message-remove-duplicates. + + * mm-util.el (mm-delete-duplicates): Use `delete-dups' if + available, else use implementation from `delete-dups'. + + * message.el (message-insert-expires): New function. + (message-mode-map): Add key binding. + (message-mode-field-menu): Add menu entry. + (message-mode): Document it. + (message-make-expires-date): Use `message-make-date'. + +2005-10-04 Josh Huber + + * message.el (message-make-expires-date): New function. + +2005-10-04 Katsumi Yamaoka + + * Makefile.in (list-installed-shadows): New entry. + (install): Use it. + (remove-installed-shadows): New entry. + + * dgnushack.el (dgnushack-default-load-path): New variable. + (dgnushack-find-lisp-shadows): New function. + (dgnushack-remove-lisp-shadows): New function. + +2005-10-02 Katsumi Yamaoka + + * Makefile.in (install-el-elc): New entry. + (install): Use it so that .el files are necessarily installed. + +2005-09-30 Katsumi Yamaoka + + * time-date.el: Autoload parse-time-string, XEmacs needs it. + +2005-09-30 Stefan Monnier + + * mm-decode.el (mm-inline-media-tests): Check presence of the diff-mode + function rather than the diff-mode.el package. + (mm-display-external): Use with-current-buffer. + (mm-viewer-completion-map, mm-viewer-completion-map): + Move initialization inside declaration. + +2005-09-29 Simon Josefsson + + * spam.el: Load hashcash when compiling, to avoid warnings. Don't + autoload mail-check-payment. + (spam-check-hashcash): Define unconditionally, since hashcash.el + is part of Gnus now. Ignore errors from payment checking. + +2005-09-28 Reiner Steib + + * message.el (message-bold-region, message-unbold-region): Rename + from `bold-region' and `unbold-region'. + + * message.el: Remove useless autoloads. + +2005-09-28 Simon Josefsson + + * message.el (message-use-idna): Default to t. + (message-use-idna): Test whether encoding works too. Doc fix. + +2005-09-28 Katsumi Yamaoka + + * nntp.el (nntp-warn-about-losing-connection): Remove. + +2005-09-27 Reiner Steib + + * mm-uu.el (mm-uu-emacs-sources-regexp): Make variable + customizable. Change default value. + (mm-uu-diff-groups-regexp): Change default value. + (mm-uu-type-alist): Add doc string. + (mm-uu-configure): Add doc string. Make it interactive. + (mm-uu-tex-groups-regexp): New variable. + (mm-uu-latex-extract, mm-uu-latex-test): New functions. + (mm-uu-type-alist): Add LaTeX documents. + (mm-uu-verbatim-marks-extract): Use "text/x-gnus-verbatim" instead + of "text/verbatim". + (mm-uu-diff-groups-regexp): Fix missing quotes from previous commit. + + * mm-decode.el (mm-automatic-display): Use "text/x-gnus-verbatim" + instead of "text/verbatim". + + * message.el (message-mark-inserted-region) + (message-mark-insert-file): Use slrn style marks when called with + prefix argument. + +2005-09-27 Simon Josefsson + + * message.el (message-idna-to-ascii-rhs-1): Reformat. + +2005-09-27 Arne J,Ax(Brgensen + + * message.el (message-remove-duplicates): New function. + Implementation borrowed from `gnus-remove-duplicates'. + (message-idna-to-ascii-rhs): Also encode idna addresses in + Reply-To:, Mail-Reply-To: and Mail-Followup-To:. + (message-idna-to-ascii-rhs-1): When `message-use-idna' is 'ask + only ask about the same idna domain once per header and also tell + in what header to replace the idna domain. + + * gnus-art.el (article-decode-idna-rhs): Also decode idna + addresses in Reply-To:, Mail-Reply-To: and Mail-Followup-To:. + (article-decode-idna-rhs): Fix regexp so that all idna-address in + a header is decoded and not just the last one. + +2005-09-27 Katsumi Yamaoka + + * gnus-art.el (gnus-mime-display-single): Don't modify text if it + has been decoded. + + * mm-decode.el (mm-automatic-display): Add text/verbatim. + (mm-insert-part): Don't modify text if it has been decoded. + + * mm-uu.el (mm-uu-verbatim-marks-extract): Say text has been + decoded. + + * mm-view.el (mm-inline-text): Don't strip text props unless + decoding enriched or richtext parts. + +2005-09-25 Romain Francoise + + * gnus-agent.el (gnus-agent-expire-group, gnus-agent-expire): + * gnus-start.el (gnus-subscribe-interactively): + * gnus-uu.el (gnus-uu-grab-articles): + End `yes-or-no-p' and `y-or-n-p' prompts with question mark and + space. + +2005-09-24 Emilio C. Lopes + + * smime.el (smime-sign-buffer, smime-decrypt-buffer): + * mm-view.el (mm-view-pkcs7-decrypt): + * gnus-sum.el (gnus-summary-limit-to-extra) + (gnus-summary-respool-article, gnus-read-move-group-name): + * gnus-score.el (gnus-summary-increase-score): + * gnus-util.el (gnus-completing-read-with-default): + * gnus-art.el (gnus-read-save-file-name) + (gnus-summary-save-in-rmail, gnus-summary-save-in-mail) + (gnus-summary-save-in-file, gnus-summary-save-body-in-file): + * message.el (message-check-news-header-syntax): + Follow convention for reading with the minibuffer. + +2005-09-22 Reiner Steib + + * spam-report.el (spam-report-url-ping-plain): + Use gnus-extended-version as User-Agent. + + * gnus-agent.el (gnus-agent-synchronize-flags): Explain why the + default value is nil. + + * mm-uu.el (mm-uu-type-alist): Added slrn style verbatim-marks. + (mm-uu-verbatim-marks-extract): New function. + (mm-uu-extract): New face. + (mm-uu-copy-to-buffer): Use it. + + * spam-report.el (spam-report-gmane-ham): Renamed from + `spam-report-gmane-unspam'. + (spam-report-gmane-internal): Renamed from `spam-report-gmane'. + Simplify use of UNSPAM argument. Fetch "X-Report-Unspam" header. + + * spam.el (spam-report-gmane-spam, spam-report-gmane-ham): + Autoload. + (spam-report-gmane-unregister-routine): Renamed + `spam-report-gmane-unspam' to `spam-report-gmane-ham'. + +2005-09-21 Teodor Zlatanov + + * spam.el (spam-use-gmane, spam-report-gmane-register-routine) + (spam-report-gmane-unregister-routine): added support for gmane + unregistration + + * spam-report.el (spam-report-gmane-unspam) + (spam-report-gmane-spam): new wrappers around spam-report-gmane + (spam-report-gmane): changed to take a single article and do + unspam registration + +2005-09-19 Reiner Steib + + * mm-url.el (mm-url-decode-entities): Fix regexp. + +2005-09-20 Lars Magne Ingebrigtsen + + * gnus-agent.el (gnus-agent-synchronize-flags): Switch the + default to nil, to be able to use Gnus at all. If the default + switches to something else, then the function should be fixed not + be exceedingly slow. + +2005-09-20 Teodor Zlatanov + + * gnus-start.el (gnus-activate-group): if the server is nil, don't + fail hard + + * spam-report.el: better Keywords line + + * spam.el: added Maintainer and better Keywords line + +2005-09-19 Reiner Steib + + * gnus-art.el (gnus-article-replace-part) + (gnus-mime-replace-part): New functions. + (gnus-mime-action-alist, gnus-mime-button-commands) + (gnus-mime-save-part-and-strip): Added file argument. + (gnus-article-part-wrapper): Added interactive argument. + + * gnus-sum.el (gnus-summary-mime-map): Add + `gnus-article-replace-part'. + +2005-09-19 Didier Verna + + The nnml compaction feature: + * nnml.el (nnml-request-compact-group): New function. + * nnml.el (nnml-request-compact): New function. + * gnus-int.el (gnus-request-compact-group): New function. + * gnus-int.el (gnus-request-compact): New function. + * gnus-group.el (gnus-group-compact-group): New function. + * gnus-group.el (gnus-group-group-map): Bind it to 'G z'. + * gnus-group.el (gnus-group-make-menu-bar): Add an entry for it. + * gnus-srvr.el (gnus-server-compact-server): New function. + * gnus-srvr.el (gnus-server-mode-map): Bind it to 'z'. + * gnus-srvr.el (gnus-server-make-menu-bar): Add an entry for it. + +2005-09-18 Deepak Goel + + * sieve.el (sieve-help): Fix `message' call: first arg should be a + format spec. + +2005-09-16 Katsumi Yamaoka + + * gnus.el (gnus-group-startup-message): Bind image-load-path. + +2005-09-15 Romain Francoise + + * message.el (message-fill-paragraph): Clarify docstring. + +2005-09-14 Katsumi Yamaoka + + * gnus-art.el (gnus-mime-display-part): Protect against broken + MIME messages. + +2005-09-13 Katsumi Yamaoka + + * gnus-sum.el (gnus-summary-edit-article-done): Remove text props + before parsing header. + +2005-09-11 Jari Aalto + + * html2text.el: (html2text-replace-list): Add new entities. + +2005-09-11 Romain Francoise + + * message.el (message-alternative-emails): Improve docstring. + (message-setup-1): Call `message-use-alternative-email-as-from' + after `message-setup-hook' to give it precedence over posting + styles, etc. + (message-use-alternative-email-as-from): Add docstring. Remove + the original From header if present. + + * nnml.el (nnml-compressed-files-size-threshold): New variable. + (nnml-save-mail): Use it. + + * gnus-uu.el (gnus-uu-mark-series): Return number of marked + articles. Add new argument `silent'. + (gnus-uu-mark-all): Report the total number of marked articles. + +2005-09-10 Romain Francoise + + * gnus-uu.el (gnus-message-process-mark): Use gnus-message. + (gnus-uu-mark-series): Likewise. + +2005-09-10 Reiner Steib + + * spam-report.el (spam-report-gmane): Fix generation of spam + report URL. + +2005-09-10 Simon Josefsson + + * gnus-agent.el (gnus-agent-synchronize-flags): Make the default + t, based on discussion on the ding list with Robert Epprecht + . + +2005-09-07 Reiner Steib + + * spam-report.el (spam-report-gmane): Make it work without + X-Report-Spam header. Gmane now only provides Archived-At. + This is only used if `spam-report-gmane-use-article-number' is nil. + (spam-report-gmane-spam-header): Remove. Not used anymore. + + * gnus-sum.el (gnus-thread-sort-by-recipient): New function to + make `gnus-summary-sort-by-recipient' work with threading. + + * nnweb.el (nnweb-google-wash-article): Print a message if article + is not available. + +2005-09-07 TSUCHIYA Masatoshi + + * gnus-art.el (gnus-mime-display-single): Revert 2004-10-07 + change. Decode text/* parts content before displaying. + +2005-09-06 Reiner Steib + + * mml-smime.el: Remove defvar of gnus-extract-address-components. + +2005-09-06 Katsumi Yamaoka + + * mm-view.el (mm-display-inline-fontify): Disable support modes. + + * lpath.el: Don't bind mc-pgp-always-sign, url-current-object, + url-package-name, url-package-version, + w3m-cid-retrieve-function-alist, w3m-current-buffer, + w3m-display-inline-images, and w3m-minor-mode-map. + +2005-09-05 Reiner Steib + + * message.el (message-tab-body-function): Fixed mismatched custom + type. + + * gnus.el (gnus-group-change-level-function): Ditto. + + * gnus-msg.el (gnus-outgoing-message-group): Ditto. + + * gnus-art.el (gnus-signature-limit) + (gnus-article-mime-part-function): Ditto. + +2005-09-05 Katsumi Yamaoka + + * mml.el (mml-mode): Silence the byte compiler. + + * gnus-art.el (gnus-article-jump-to-part): Redisplay the article + using `(sit-for 0)' before moving the point to the specified part; + skip unbuttonized parts. + (gnus-article-part-wrapper): Don't use save-window-excursion; don't + return to the summary window if gnus-auto-select-part is non-nil. + +2005-09-04 Reiner Steib + + * mml.el (mml-dnd-protocol-alist, mml-dnd-attach-options): New + variables. + (mml-dnd-attach-file, mml-mode): Use them. + + * nnweb.el (nnweb-type-definition, nnweb-google-wash-article): + Make fetching article by MID work again for Google Groups. Added + FIXME concerning gnus-group-make-web-group. + + * mml-smime.el (mml-smime-sign-query, mml-smime-get-dns-cert): + Don't depend on Gnus by using mail-extract-address-components if + gnus-extract-address-components is not bound. + +2005-09-04 Lars Magne Ingebrigtsen + + * gnus-art.el (gnus-mime-display-security): Don't display the + signature, but only the signed part. + +2005-09-02 Katsumi Yamaoka + + * gnus-sum.el (gnus-thread-hide-subtree): Doc fix. + + * gnus-msg.el (gnus-inews-insert-gcc): Fix the mistake of using + list, not listp. + +2005-09-02 Hrvoje Niksic + + * mm-encode.el (mm-encode-content-transfer-encoding): Likewise + when encoding. + + * mm-bodies.el (mm-decode-content-transfer-encoding): + De-canonicalize CRLF for all text content types, not just + text/plain. + +2005-09-01 Katsumi Yamaoka + + * gnus-art.el (gnus-article-part-wrapper): Error if there's no + valid article; point arrow and cursor at the MIME button. + +2005-08-30 Katsumi Yamaoka + + * gnus-art.el (gnus-mime-save-part-and-strip): Clarify prompt. + Suggested by Dan Christensen . + + * mm-decode.el (mm-save-part): Enable change of prompt. + +2005-08-29 Jari Aalto + + * gnus-msg.el (gnus-inews-add-send-actions): Made + `message-post-method' lambda parameter ARG `&optional'. + +2005-08-29 Reiner Steib + + * gnus-sum.el (gnus-summary-mime-map): Added + gnus-article-save-part-and-strip, gnus-article-delete-part and + gnus-article-jump-to-part. + + * gnus-art.el (gnus-article-edit-article): Added quiet argument. + (gnus-article-edit-part): Use it. + (gnus-article-part-wrapper): Added no-handle argument. + (gnus-article-save-part-and-strip, gnus-article-delete-part): New + functions. + +2005-08-29 Romain Francoise + + * gnus-fun.el (gnus-convert-image-to-face-command): Fix typo in + docstring. + (gnus-face-from-file): Likewise. + +2005-08-29 Reiner Steib + + * gnus-art.el (gnus-mime-save-part-and-strip): Don't prompt. + (gnus-mime-delete-part): Don't prompt if `gnus-expert-user' is + non-nil. + (gnus-auto-select-part): New variable. + (gnus-article-jump-to-part): New function. + (gnus-article-edit-part, gnus-mime-save-part-and-strip) + (gnus-mime-delete-part): Allow selecting specified part after + deleting or stripping parts. + (gnus-article-jump-to-part): Don't use `read-number'. Use last + part if argument is bogus. + +2005-08-31 Juanma Barranquero + + * gnus-art.el (w3m-minor-mode-map): + * gnus-spec.el (gnus-newsrc-file-version): + * gnus-util.el (nnmail-active-file-coding-system) + (gnus-original-article-buffer, gnus-user-agent): + * gnus.el (gnus-ham-process-destinations) + (gnus-parameter-ham-marks-alist) + (gnus-parameter-spam-marks-alist, gnus-spam-autodetect) + (gnus-spam-autodetect-methods, gnus-spam-newsgroup-contents) + (gnus-spam-process-destinations, gnus-spam-process-newsgroups): + * mm-decode.el (gnus-current-window-configuration): + * mm-extern.el (gnus-article-mime-handles): + * mm-url.el (url-current-object, url-package-name) + (url-package-version): + * mm-view.el (gnus-article-mime-handles, gnus-newsgroup-charset) + (smime-keys, w3m-cid-retrieve-function-alist) + (w3m-current-buffer, w3m-display-inline-images) + (w3m-minor-mode-map): + * mml-smime.el (gnus-extract-address-components): + * mml.el (gnus-article-mime-handles, gnus-mouse-2) + (gnus-newsrc-hashtb, message-default-charset) + (message-deletable-headers, message-options) + (message-posting-charset, message-required-mail-headers) + (message-required-news-headers): + * mml1991.el (mc-pgp-always-sign): + * mml2015.el (mc-pgp-always-sign): + * nnheader.el (nnmail-extra-headers): + * rfc1843.el (gnus-decode-encoded-word-function) + (gnus-decode-header-function, gnus-newsgroup-name): + * spam-stat.el (gnus-original-article-buffer): Add defvars. + +2005-08-22 Karl Chen (tiny change) + + * gnus-art.el (gnus-treatment-function-alist): Move date-lapsed to + the end of the date treatments. + +2005-08-15 Simon Josefsson + + * pgg.el (url-insert-file-contents): Don't autoload it, Emacs has + it in url-handlers.el and XEmacs in url.el. Reported by Luca + Capello and Romain Francoise. + (pgg-fetch-key-function): Removed, not used? + (pgg-insert-url-with-w3): Require url, to get + url-insert-file-contents regardless of where it is defined. + +2005-08-13 Romain Francoise + + * message.el (message-cite-original-1): New function. + (message-cite-original): Use it. + (message-cite-original-without-signature): Ditto. + +2005-08-08 Romain Francoise + + * message.el (message-yank-empty-prefix): New variable. + (message-indent-citation): Use it. + (message-cite-original-without-signature): Respect X-No-Archive. + +2005-08-08 Simon Josefsson + + * pgg.el: Autoload url-insert-file-contents instead of loading + w3/url. + (pgg-insert-url-with-w3): Don't load url here. + +2005-08-07 Jesper Harder + + * message.el (message-kill-to-signature): Don't insert newline at + bol. + (message-newline-and-reformat): Bind fill-paragraph-function to nil. + +2005-08-06 Romain Francoise + + * message.el (message-user-fqdn): Fix typo in docstring. + +2005-08-05 Daiki Ueno + + * mml2015.el (mml2015-pgg-sign): Make sure micalg is correct. + + * pgg-parse.el (pgg-parse-hash-algorithm-alist): Add SHA-2. + +2005-08-05 Katsumi Yamaoka + + * mm-bodies.el (mm-encode-body): Use coding system rather than + charset to encode text. + + * mm-util.el (mm-find-mime-charset-region): Attempt to reduce the + number of charsets if utf-8 is available (XEmacs). + +2005-08-04 Reiner Steib + + * gnus-art.el (gnus-button-valid-localpart-regexp): New variable + taken from `gnus-button-mid-or-mail-regexp'. + (gnus-button-mid-or-mail-regexp, gnus-button-alist): Use it. + (gnus-button-alist): Improve regexp for domain part of the MIDs + for news:localpart@domain buttons. + (gnus-button-ctan-directory-regexp): Update. + +2005-08-02 Katsumi Yamaoka + + * sieve-manage.el (sieve-manage-interactive-login): Use + make-local-variable rather than make-variable-buffer-local. + (sieve-manage-open): Ditto. + (sieve-manage-authenticate): Ditto. + + * mml.el (mml-generate-mime-1): Make the content type default to + text/plain if the filename is not specified. + +2005-08-01 Katsumi Yamaoka + + * gnus-uu.el (gnus-uu-save-article): Use insert-buffer-substring + instead of insert-buffer. + + * message.el (message-yank-original): Ditto; set the mark at the + end of the yanked message. + +2005-07-29 Katsumi Yamaoka + + * gnus-art.el (gnus-article-next-page-1): Reduce the number of + lines to scroll rather than to stop it. + + * mml.el (mml-generate-default-type): Add doc string. + (mml-generate-mime-1): Use mm-default-file-encoding or make it + default to application/octet-stream when determining the content + type if it is not specified for the part or the mml contents; add + a comment about mml-generate-default-type. + +2005-07-29 Reiner Steib + + * mml.el (mml-generate-mime-1): Use mm-default-file-encoding or + make it default to application/octet-stream when determining the + content type if it is not specified for the external contents. + +2005-07-28 Katsumi Yamaoka + + * rfc2231.el (rfc2231-parse-string): Take care that not only a + segmented parameter but also other parameters might be there. + +2005-07-27 Katsumi Yamaoka + + * mm-decode.el (mm-display-external): Delete temp file, directory + and buffer immediately if the external process is exited. + +2005-07-26 Katsumi Yamaoka + + * gnus-art.el (gnus-article-next-page-1): Don't scroll if there're + fewer lines than that of scroll-margin. + (gnus-article-prev-page): Narrow the range to bind scroll-in-place. + +2005-07-25 Katsumi Yamaoka + + * gnus-art.el (gnus-article-next-page): Revert. + (gnus-article-beginning-of-window): New macro. + (gnus-article-next-page-1): Use it. + (gnus-article-prev-page): Ditto. + (gnus-article-edit-part): Use insert-buffer-substring instead of + insert-buffer. + (gnus-article-edit-exit): Ditto. + + * gnus-util.el (gnus-beginning-of-window): Remove. + (gnus-end-of-window): Remove. + + * lpath.el: Don't bind header-line-format and scroll-margin. + +2005-07-25 Simon Josefsson + + * pgg.el (pgg-insert-url-with-w3): Don't load w3, it is possible + to have the url package without w3. Reported by Daiki Ueno + and Luigi Panzeri . + +2005-07-20 Didier Verna + + * gnus-diary.el: Remove the description comment (nndiary is now + properly documented in the Gnus manual). + Fix the spelling of "Back End". + * nndiary.el: Ditto. + Fix the copyright notice. + +2005-07-18 Romain Francoise + + * gnus-sum.el (gnus-summary-to-prefix, + gnus-summary-newsgroup-prefix): New variables. + (gnus-summary-from-or-to-or-newsgroups): Use them. + +2005-07-17 Romain Francoise + + * mml2015.el (mml2015-clean-buffer): Prefix buffer name with a + space as it's generally not especially interesting to the user. + +2005-07-16 Romain Francoise + + * nnfolder.el (nnfolder-save-buffer): Bind `copyright-update' to + nil to avoid prompting and file modification if one of the + messages at the top of the nnfolder file contains a copyright + notice. + Update copyright notice. + + * gnus-uu.el (gnus-uu-save-article): Use `message-make-date' + instead of `current-time-string' as the latter creates a time + string that is not RFC 2822 compliant (it lacks the zone). + Update copyright notice. + +2005-07-21 Stefan Monnier + + * mml.el (mml-minibuffer-read-disposition): Don't use inline by default + for text/rtf. Display default in prompt. Pass default for M-n. + + * mm-uu.el (mm-uu-copy-to-buffer): Use with-current-buffer. + +2005-07-16 Lars Magne Ingebrigtsen + + * gnus-msg.el (gnus-button-mailto): Remove + save-selected-window-window hackery because it relies on + save-selected-window internals. + +2005-07-15 Katsumi Yamaoka + + * gnus-art.el (gnus-article-next-page): Use gnus-end-of-window. + (gnus-article-next-page-1): Use gnus-beginning-of-window. + (gnus-article-prev-page): Ditto. + + * gnus-util.el (gnus-beginning-of-window): New function. + (gnus-end-of-window): New function. + + * lpath.el: Bind header-line-format and scroll-margin for XEmacs. + +2005-07-14 Hiroshi Fujishima (tiny change) + + * gnus-score.el (gnus-score-edit-all-score): Set + gnus-score-edit-exit-function to gnus-score-edit-done and call + gnus-message. + +2005-07-14 Lars Magne Ingebrigtsen + + * gnus-msg.el (gnus-button-mailto): Remove + save-selected-window-window hackery because it relies on + save-selected-window internals. + +2005-07-13 Katsumi Yamaoka + + * gnus-salt.el (gnus-pick-mode): Remove the 5th arg of + add-minor-mode. + (gnus-binary-mode): Ditto. + + * gnus-topic.el (gnus-topic-mode): Ditto. + +2005-07-08 Ralf Angeli + + * gnus-art.el (gnus-article-next-page, gnus-article-next-page-1) + (gnus-article-prev-page): Take scroll-margin into consideration. + +2005-07-04 Lute Kamstra + + Update FSF's address in GPL notices. + +2005-07-04 Juanma Barranquero + + * gnus.el (gnus-exit): + * gnus-group.el (gnus-group-icons): + * nnmail.el (nnmail-prepare): Fix typos in docstrings. + + * gnus-nocem.el (gnus-nocem): + * message.el (message-various, message-buffers, message-sending) + (message-interface, message-forwarding, message-insertion) + (message-headers, message-news, message-mail): + * pgg-gpg.el (pgg-gpg): + * pgg-parse.el (pgg-parse): + * pgg-pgp.el (pgg-pgp): + * pgg-pgp5.el (pgg-pgp5): + * pop3.el (pop3): Finish `defgroup' description with period. + +2005-07-01 Katsumi Yamaoka + + * gnus-art.el (article-display-face): Improve the efficiency. + (article-display-x-face): Ditto; remove grey x-face stuff. + +2005-06-30 Katsumi Yamaoka + + * gnus-art.el (article-display-face): Correct the position in + which Faces are inserted. + +2005-06-29 Didier Verna + + * gnus-art.el (article-display-face): Display faces in correct + order. + +2005-06-29 Katsumi Yamaoka + + * gnus-nocem.el (gnus-nocem-verifyer): Default to pgg-verify. + (gnus-fill-real-hashtb): Use hash table instead of obarray. + (gnus-nocem-check-article): Fetch the Type header. + (gnus-nocem-message-wanted-p): Fix the way to examine types. + (gnus-nocem-verify-issuer): Use functionp instead of fboundp. + (gnus-nocem-enter-article): Use hash tables rather than obarrays; + make sure gnus-nocem-hashtb is initialized. + (gnus-nocem-alist-to-hashtb): Use hash table instead of obarray. + (gnus-nocem-unwanted-article-p): Ditto. + + * pgg.el (pgg-verify): Return the verification result. + +2005-06-27 Lars Magne Ingebrigtsen + + * gnus-art.el (gnus-mime-copy-part): Check whether coding-system + is ascii. + +2005-06-24 Juanma Barranquero + + * gnus-art.el (gnus-article-mode): Set `nobreak-char-display', not + `show-nonbreak-escape'. + +2005-06-23 Lute Kamstra + + * gnus-art.el (gnus-article-mode): Use kill-all-local-variables. + + * dig.el (dig-mode): + * smime.el (smime-mode): Use gnus-run-mode-hooks. + +2005-06-21 Juanma Barranquero + + * nnimap.el (nnimap-split-download-body): Fix spellings. + +2005-06-16 Juanma Barranquero + + * gnus-art.el (gnus-article-encrypt-body): + * gnus-cus.el (gnus-score-customize): + * mm-extern.el (mm-extern-local-file, mm-inline-external-body): + * pop3.el (pop3-user): Don't use `format' on `error' arguments. + +2005-06-16 Arne J,Ax(Brgensen + + * smime.el (smime-cert-by-ldap-1): Detect PEM format without + header by looking for magic "MII" at the beginnig. + +2005-06-16 Miles Bader + + * gnus-xmas.el (gnus-xmas-group-startup-message): + Use renamed gnus-splash face. + + * assistant.el (assistant-field): Remove "-face" suffix from face name. + (assistant-field-face): New backward-compatibility alias for renamed + face. + (assistant-render-text): Use renamed assistant-field face. + + * spam.el (spam): Remove "-face" suffix from face name. + (spam-face): New backward-compatibility alias for renamed face. + (spam-face, spam-initialize): Use renamed spam face. + + * message.el (message-header-to, message-header-cc) + (message-header-subject, message-header-newsgroups) + (message-header-other, message-header-name) + (message-header-xheader, message-separator, message-cited-text) + (message-mml): Remove "-face" suffix from face names. + (message-header-to-face, message-header-cc-face) + (message-header-subject-face, message-header-newsgroups-face) + (message-header-other-face, message-header-name-face) + (message-header-xheader-face, message-separator-face) + (message-cited-text-face, message-mml-face): + New backward-compatibility aliases for renamed faces. + (message-font-lock-keywords): Use renamed message faces. + + * sieve-mode.el (sieve-control-commands, sieve-action-commands) + (sieve-test-commands, sieve-tagged-arguments): + Remove "-face" suffix from face names. + (sieve-control-commands-face, sieve-action-commands-face) + (sieve-test-commands-face, sieve-tagged-arguments-face): + New backward-compatibility aliases for renamed faces. + (sieve-control-commands-face, sieve-action-commands-face) + (sieve-test-commands-face, sieve-tagged-arguments-face): + Use renamed sieve faces. + + * gnus.el (gnus-group-news-1, gnus-group-news-1-empty) + (gnus-group-news-2, gnus-group-news-2-empty, gnus-group-news-3) + (gnus-group-news-3-empty, gnus-group-news-4) + (gnus-group-news-4-empty, gnus-group-news-5) + (gnus-group-news-5-empty, gnus-group-news-6) + (gnus-group-news-6-empty, gnus-group-news-low) + (gnus-group-news-low-empty, gnus-group-mail-1) + (gnus-group-mail-1-empty, gnus-group-mail-2) + (gnus-group-mail-2-empty, gnus-group-mail-3) + (gnus-group-mail-3-empty, gnus-group-mail-low) + (gnus-group-mail-low-empty, gnus-summary-selected) + (gnus-summary-cancelled, gnus-summary-high-ticked) + (gnus-summary-low-ticked, gnus-summary-normal-ticked) + (gnus-summary-high-ancient, gnus-summary-low-ancient) + (gnus-summary-normal-ancient, gnus-summary-high-undownloaded) + (gnus-summary-low-undownloaded) + (gnus-summary-normal-undownloaded, gnus-summary-high-unread) + (gnus-summary-low-unread, gnus-summary-normal-unread) + (gnus-summary-high-read, gnus-summary-low-read) + (gnus-summary-normal-read, gnus-splash): + Remove "-face" suffix from face names. + (gnus-group-news-1-face, gnus-group-news-1-empty-face) + (gnus-group-news-2-face, gnus-group-news-2-empty-face) + (gnus-group-news-3-face, gnus-group-news-3-empty-face) + (gnus-group-news-4-face, gnus-group-news-4-empty-face) + (gnus-group-news-5-face, gnus-group-news-5-empty-face) + (gnus-group-news-6-face, gnus-group-news-6-empty-face) + (gnus-group-news-low-face, gnus-group-news-low-empty-face) + (gnus-group-mail-1-face, gnus-group-mail-1-empty-face) + (gnus-group-mail-2-face, gnus-group-mail-2-empty-face) + (gnus-group-mail-3-face, gnus-group-mail-3-empty-face) + (gnus-group-mail-low-face, gnus-group-mail-low-empty-face) + (gnus-summary-selected-face, gnus-summary-cancelled-face) + (gnus-summary-high-ticked-face, gnus-summary-low-ticked-face) + (gnus-summary-normal-ticked-face) + (gnus-summary-high-ancient-face, gnus-summary-low-ancient-face) + (gnus-summary-normal-ancient-face) + (gnus-summary-high-undownloaded-face) + (gnus-summary-low-undownloaded-face) + (gnus-summary-normal-undownloaded-face) + (gnus-summary-high-unread-face, gnus-summary-low-unread-face) + (gnus-summary-normal-unread-face, gnus-summary-high-read-face) + (gnus-summary-low-read-face, gnus-summary-normal-read-face) + (gnus-splash-face): + New backward-compatibility aliases for renamed faces. + (gnus-group-startup-message): Use renamed gnus faces. + + * gnus-srvr.el (gnus-server-agent, gnus-server-opened) + (gnus-server-closed, gnus-server-denied, gnus-server-offline) + (gnus-server-agent): Remove "-face" suffix from face names. + (gnus-server-agent-face, gnus-server-opened-face) + (gnus-server-closed-face, gnus-server-denied-face) + (gnus-server-offline-face): + New backward-compatibility aliases for renamed faces. + (gnus-server-agent-face, gnus-server-opened-face) + (gnus-server-closed-face, gnus-server-denied-face) + (gnus-server-offline-face): Use renamed gnus faces. + + * gnus-picon.el (gnus-picon-xbm, gnus-picon): + Remove "-face" suffix from face names. + (gnus-picon-xbm-face, gnus-picon-face): + New backward-compatibility aliases for renamed faces. + + * gnus-cite.el (gnus-cite-attribution, gnus-cite-1, gnus-cite-2) + (gnus-cite-3, gnus-cite-4, gnus-cite-5, gnus-cite-6) + (gnus-cite-7, gnus-cite-8, gnus-cite-9, gnus-cite-10) + (gnus-cite-11): Remove "-face" suffix from face names. + (gnus-cite-attribution-face, gnus-cite-face-1, gnus-cite-face-2) + (gnus-cite-face-3, gnus-cite-face-4, gnus-cite-face-5) + (gnus-cite-face-6, gnus-cite-face-7, gnus-cite-face-8) + (gnus-cite-face-9, gnus-cite-face-10, gnus-cite-face-11): + New backward-compatibility aliases for renamed faces. + (gnus-cite-attribution-face, gnus-cite-face-list) + (gnus-article-boring-faces): Use renamed gnus faces. + + * gnus-art.el (gnus-signature, gnus-header-from) + (gnus-header-subject, gnus-header-newsgroups, gnus-header-name) + (gnus-header-content): Remove "-face" suffix from face names. + (gnus-signature-face, gnus-header-from-face) + (gnus-header-subject-face, gnus-header-newsgroups-face) + (gnus-header-name-face, gnus-header-content-face): + New backward-compatibility aliases for renamed faces. + (gnus-signature-face, gnus-header-face-alist): Use renamed gnus faces. + + * gnus-sum.el (gnus-summary-selected-face) + (gnus-summary-highlight): Use renamed gnus faces. + * gnus-group.el (gnus-group-highlight): Likewise. + +2005-06-14 Juanma Barranquero + + * gnus-sieve.el (gnus-sieve-article-add-rule): + * legacy-gnus-agent.el (gnus-agent-unlist-expire-days): + * spam-stat.el (spam-stat-buffer-change-to-spam) + (spam-stat-buffer-change-to-non-spam): Follow error conventions. + + * message.el (message-is-yours-p): + * gnus-sum.el (gnus-auto-select-subject): Fix quoting in docstring. + +2005-06-14 Katsumi Yamaoka + + * mm-view.el (mm-inline-text): Withdraw the last change. + +2005-06-09 Katsumi Yamaoka + + * mm-view.el (mm-inline-text): Turn off adaptive-fill-mode while + executing enriched-decode. + +2005-06-07 Katsumi Yamaoka + + * mm-util.el (mm-find-buffer-file-coding-system): Don't examine + charset of tar files. + +2005-06-04 Luc Teirlinck + + * gnus-art.el (article-update-date-lapsed): Use `save-match-data'. + +2005-06-04 Lute Kamstra + + * nnfolder.el (nnfolder-read-folder): Make sure that undo + information is never recorded. + +2005-06-03 Stefan Monnier + + * gnus-art.el (gnus-emphasis-alist): Disable the strikethru thingy. + +2005-06-02 Katsumi Yamaoka + + * pop3.el (pop3-apop): Run md5 in the binary mode. + + * starttls.el (starttls-set-process-query-on-exit-flag): + Use eval-and-compile. + +2005-05-31 Simon Josefsson + + * smime.el (smime-replace-in-string): Define. + (smime-cert-by-ldap-1): Use it. + +2005-05-31 Katsumi Yamaoka + + * gnus-art.el (article-display-x-face): Replace + process-kill-without-query by gnus-set-process-query-on-exit-flag. + + * gnus-util.el (gnus-set-process-query-on-exit-flag): Alias to + set-process-query-on-exit-flag or process-kill-without-query. + + * html2text.el (html2text-fix-paragraphs): Use `while - re-search' + loop instead of replace-regexp. + + * imap.el (imap-ssl-open): Use set-process-query-on-exit-flag + instead of process-kill-without-query if it is available. + + * lpath.el: Fbind ldap-search-entries. + + * mm-util.el (mm-insert-file-contents): Bind find-file-hook + instead of find-file-hooks if it is available. + + * mml1991.el: Bind pgg-default-user-id when compiling. + + * mml2015.el: Bind pgg-default-user-id when compiling. + + * nndraft.el (nndraft-request-associate-buffer): + Use write-contents-functions instead of write-contents-hooks if it is + available. + + * nnheader.el (nnheader-find-file-noselect): Bind find-file-hook + instead of find-file-hooks if it is available. + + * nntp.el (nntp-open-connection): Replace + process-kill-without-query by gnus-set-process-query-on-exit-flag. + (nntp-open-ssl-stream): Ditto. + (nntp-open-tls-stream): Ditto. + + * starttls.el (starttls-set-process-query-on-exit-flag): Alias to + set-process-query-on-exit-flag or process-kill-without-query. + (starttls-open-stream-gnutls): Use it instead of + process-kill-without-query. + (starttls-open-stream): Ditto. + +2005-05-31 Ulf Stegemann (tiny change) + + * smime.el (smime-cert-by-ldap-1): Don't use + replace-regexp-in-string. + +2005-05-31 Arne J,Ax(Brgensen + + * smime-ldap.el (smime-ldap-search): Add compatibility for XEmacs. + + * smime.el (smime-cert-by-ldap-1): Handle certificates distributed + in PEM format. Adjust to the XEmacs compability. + +2005-05-30 Reiner Steib + + * encrypt.el (encrypt-xor-process-buffer): Replace `string-to-int' + by `string-to-number'. + * gnus-agent.el (gnus-agent-regenerate-group) + (gnus-agent-fetch-articles): Ditto. + * gnus-art.el (gnus-button-fetch-group): Ditto. + * gnus-cache.el (gnus-cache-generate-active) + (gnus-cache-articles-in-group): Ditto. + * gnus-group.el (gnus-group-set-current-level) + (gnus-group-insert-group-line): Ditto. + * gnus-score.el (gnus-score-set-expunge-below) + (gnus-score-set-mark-below, gnus-summary-score-effect) + (gnus-summary-score-entry): Ditto. + * gnus-soup.el (gnus-soup-send-packet, gnus-soup-parse-areas) + (gnus-soup-pack): Ditto. + * gnus-spec.el (gnus-xmas-format): Ditto. + * gnus-start.el (gnus-newsrc-to-gnus-format): Ditto. + * gnus-sum.el (gnus-create-xref-hashtb): Ditto. + * gnus-uu.el (gnus-uu-expand-numbers): Ditto. + * nnbabyl.el (nnbabyl-article-group-number): Ditto. + * nndb.el (nndb-get-remote-expire-response): Ditto. + * nndiary.el (nndiary-parse-schedule-value) + (nndiary-string-to-number, nndiary-request-replace-article) + (nndiary-request-article): Ditto. + * nndoc.el (nndoc-rnews-body-end, nndoc-mbox-body-end): Ditto. + * nndraft.el (nndraft-articles, nndraft-request-group): Ditto. + * nneething.el (nneething-make-head): Ditto. + * nnfolder.el (nnfolder-request-article) + (nnfolder-retrieve-headers): Ditto. + * nnheader.el (nnheader-file-to-number): Ditto. + * nnkiboze.el (nnkiboze-request-article): Ditto. + * nnmail.el (nnmail-process-unix-mail-format) + (nnmail-process-babyl-mail-format): Ditto. + * nnmbox.el (nnmbox-read-mbox, nnmbox-article-group-number): Ditto. + * nnmh.el (nnmh-update-gnus-unreads, nnmh-active-number) + (nnmh-request-create-group, nnmh-request-list-1) + (nnmh-request-group, nnmh-request-article): Ditto. + * nnml.el (nnml-request-replace-article, nnml-request-article): Ditto. + * nnrss.el (nnrss-find-rss-via-syndic8): Ditto. + * nnsoup.el (nnsoup-make-active): Ditto. + * nnspool.el (nnspool-find-id, nnspool-request-group): Ditto. + * nntp.el (nntp-find-group-and-number) + (nntp-retrieve-headers-with-xover): Ditto. + * pgg-gpg.el (pgg-gpg-snarf-keys-region): Ditto. + * pgg-parse.el (pgg-read-body, pgg-read-bytes) + (pgg-format-key-identifier): Ditto. + * pop3.el (pop3-last, pop3-stat): Ditto. + * qp.el (quoted-printable-decode-region): Ditto. + + * spam-report.el (spam-report-url-ping-mm-url): Use format instead + of concat. + +2005-05-30 Katsumi Yamaoka + + * gnus-agent.el (gnus-category-mode): Use gnus-run-mode-hooks. + + * gnus-art.el (gnus-article-mode): Use gnus-run-mode-hooks. + + * gnus-cus.el (gnus-custom-mode): Use gnus-run-mode-hooks. + + * gnus-eform.el (gnus-edit-form-mode): Use gnus-run-mode-hooks. + + * gnus-group.el (gnus-group-mode): Use gnus-run-mode-hooks. + + * gnus-kill.el (gnus-kill-file-mode): Use gnus-run-mode-hooks. + + * gnus-salt.el (gnus-tree-mode): Use gnus-run-mode-hooks. + (gnus-carpal-mode): Ditto. + + * gnus-srvr.el (gnus-server-mode): Use gnus-run-mode-hooks. + (gnus-browse-mode): Ditto. + + * gnus-sum.el (gnus-summary-mode): Use gnus-run-mode-hooks. + + * gnus-util.el (gnus-run-mode-hooks): Save current buffer. + +2005-05-29 Richard M. Stallman + + * gnus-cite.el (gnus-cite-add-face): Set overlay's evaporate property. + +2005-05-27 Katsumi Yamaoka + + * gnus-util.el (gnus-run-mode-hooks): New function. + + * score-mode.el (gnus-score-mode): Use gnus-run-mode-hooks. + + * dgnushack.el: Advise byte-optimize-form-code-walker to avoid the + ``...called for effect'' warnings for Emacs 21.4 as well as 21.3. + +2005-05-26 Luc Teirlinck + + * gnus-agent.el (gnus-agent-make-mode-line-string): + Use mode-line-highlight as mouse-face. + +2005-05-17 Katsumi Yamaoka + + * canlock.el (canlock): Change the parent group to news. + + * deuglify.el (gnus-outlook-deuglify): Add :group. + + * dig.el (dig): Add :group. + + * dns-mode.el (dns-mode): Add :group. + + * encrypt.el (encrypt): Add :group. + + * gnus-cite.el (gnus-cite-attribution-face): Add :group. + (gnus-cite-face-1, gnus-cite-face-2, gnus-cite-face-3): Ditto. + (gnus-cite-face-4, gnus-cite-face-5, gnus-cite-face-6): Ditto. + (gnus-cite-face-7, gnus-cite-face-8, gnus-cite-face-9): Ditto. + (gnus-cite-face-10, gnus-cite-face-11): Ditto. + + * gnus-diary.el (gnus-diary): Add :group. + + * gnus.el (gnus-group-news-1-face): Add :group. + (gnus-group-news-1-empty-face): Ditto. + (gnus-group-news-2-face, gnus-group-news-2-empty-face): Ditto. + (gnus-group-news-3-face, gnus-group-news-3-empty-face): Ditto. + (gnus-group-news-4-face, gnus-group-news-4-empty-face): Ditto. + (gnus-group-news-5-face, gnus-group-news-5-empty-face): Ditto. + (gnus-group-news-6-face, gnus-group-news-6-empty-face): Ditto. + (gnus-group-news-low-face, gnus-group-news-low-empty-face): Ditto. + (gnus-group-mail-1-face, gnus-group-mail-1-empty-face): Ditto. + (gnus-group-mail-2-face, gnus-group-mail-2-empty-face): Ditto. + (gnus-group-mail-3-face, gnus-group-mail-3-empty-face): Ditto. + (gnus-group-mail-low-face, gnus-group-mail-low-empty-face): Ditto. + (gnus-summary-selected-face, gnus-summary-cancelled-face): Ditto. + (gnus-summary-high-ticked-face): Ditto. + (gnus-summary-low-ticked-face): Ditto. + (gnus-summary-normal-ticked-face): Ditto. + (gnus-summary-high-ancient-face): Ditto. + (gnus-summary-low-ancient-face): Ditto. + (gnus-summary-normal-ancient-face): Ditto. + (gnus-summary-high-undownloaded-face): Ditto. + (gnus-summary-low-undownloaded-face): Ditto. + (gnus-summary-normal-undownloaded-face): Ditto. + (gnus-summary-high-unread-face): Ditto. + (gnus-summary-low-unread-face): Ditto. + (gnus-summary-normal-unread-face): Ditto. + (gnus-summary-high-read-face, gnus-summary-low-read-face): Ditto. + (gnus-summary-normal-read-face, gnus-splash-face): Ditto. + + * hashcash.el (hashcash): New custom group. + (hashcash-default-payment): Add :group. + (hashcash-payment-alist): Ditto. + (hashcash-default-accept-payment): Ditto. + (hashcash-accept-resources): Ditto. + (hashcash-path): Ditto. + (hashcash-extra-generate-parameters): Ditto. + (hashcash-double-spend-database): Ditto. + (hashcash-in-news): Ditto. + + * message.el (message-minibuffer-local-map): Add :group. + + * netrc.el (netrc): Add :group. + + * sieve-manage.el (sieve-manage-log): Add :group. + (sieve-manage-default-user): Diito. + (sieve-manage-server-eol, sieve-manage-client-eol): Ditto. + (sieve-manage-streams, sieve-manage-stream-alist): Ditto. + (sieve-manage-authenticators): Ditto. + (sieve-manage-authenticator-alist): Ditto. + (sieve-manage-default-port): Ditto. + + * sieve-mode.el (sieve-control-commands-face): Add :group. + (sieve-action-commands-face): Ditto. + (sieve-test-commands-face): Ditto. + (sieve-tagged-arguments-face): Ditto. + + * smime.el (smime): Add :group. + + * spam-report.el (spam-report): Add :group. + + * spam.el (spam, spam-face): Add :group. + +2005-05-16 Lars Magne Ingebrigtsen + + * nntp.el (nntp-next-result-arrived-p): Some news servers may + return \n.\n.\n at the end of articles. Protect against that. + (nntp-with-open-group): Allow debugging. + + * nnheader.el (mail-header-set-extra): Make into a function + because I just could't understand how to quote the list properly. + + * dns.el (query-dns-cached): New function. + +2005-05-26 Lute Kamstra + + * score-mode.el (gnus-score-mode): Use run-mode-hooks. + +2005-05-16 Katsumi Yamaoka + + * dgnushack.el: Autoload mail-extract-address-components for XEmacs. + + * gnus-art.el: Don't autoload mail-extract-address-components. + + * gnus.el: Remove duplicated autoload for message-y-or-n-p; use + eval-and-compile to evaluate it. + + * hashcash.el: Don't autoload executable-find. + + * nndb.el: Don't declare the nndb back end two or more times; don't + autoload news-reply-mode, news-setup, cancel-timer and telnet. + + * nntp.el: Autoload format-spec instead of format; use + eval-and-compile to evaluate autoload forms. + +2005-05-09 Georg C. F. Greve (tiny change) + + * pgg-gpg.el (pgg-gpg-possibly-cache-passphrase): Fix PIN caching. + +2005-05-01 Lars Magne Ingebrigtsen + + * gnus.el (gnus-version-number): Bump version. + 2005-05-01 Lars Magne Ingebrigtsen * gnus.el: No Gnus v0.3 is released. @@ -135,11 +3171,11 @@ * nnimap.el (nnimap-date-days-ago): Add defvars in order to silence the byte compiler inside the defun - * gnus-demon.el (parse-time-string): Added autoload. + * gnus-demon.el (parse-time-string): Add autoload. - * gnus-delay.el (parse-time-string): Added autoload. + * gnus-delay.el (parse-time-string): Add autoload. - * gnus-art.el (parse-time-string): Added autoload. + * gnus-art.el (parse-time-string): Add autoload. * nnultimate.el (parse-time): Require for `parse-time-string'. @@ -204,22 +3240,21 @@ * nnmaildir.el (nnmaildir-request-accept-article): Use `nnheader-cancel-timer' for compatibility with current XEmacs. -2005-03-13 Steve Youngs +2005-03-13 Andrey Slusar (tiny change) * gnus-async.el: Require timer-funcs at compile time when in XEmacs for `run-with-idle-timer'. -2005-03-13 Steve Youngs +2005-03-13 Andrey Slusar (tiny change) * gnus.el: Don't try and mark `gnus-agent-save-groups' as an autoloaded function. - From: Andrey Slusar . 2005-03-10 Stefan Monnier * nnimap.el (nnimap-retrieve-headers-from-server): Fix last change. -2005-03-10 Arne J,Ax(Brgensen (tiny change) +2005-03-10 Arne J,Ax(Brgensen (tiny change) * nnimap.el (nnimap-retrieve-headers-from-server): Fix off-by-one flaw. @@ -228,13 +3263,13 @@ * gnus-msg.el (gnus-confirm-mail-reply-to-news): Add gnus-expert-user to default. -2005-03-08 Juergen Kreileder (tiny change) +2005-03-08 Juergen Kreileder (tiny change) * nnimap.el (nnimap-open-server): Ditto. * imap.el (imap-authenticate): Fix typo. -2005-03-08 Bjorn Solberg (tiny change) +2005-03-08 Bjorn Solberg (tiny change) * nnimap.el (nnimap-retrieve-headers-from-server): Sort NOV buffer (since IMAP server might return FETCH response out of @@ -261,7 +3296,7 @@ gnus-agent-synchronize-group-flags to reset read status in both gnus and server. (gnus-agent-update-files-total-fetched-for): Fixed initial size. - + 2005-03-04 Reiner Steib * message.el: Don't autoload former message-utils variables. @@ -387,7 +3422,7 @@ * mml.el (mml-parse-1): Use them. -2005-02-21 Arne J,Ax(Brgensen +2005-02-21 Arne J,Ax(Brgensen * nnrss.el (nnrss-verbose): Removed. (nnrss-request-group): Use `nnheader-message' instead. @@ -451,7 +3486,7 @@ mml-smime-get-dns-ldap. (mml-smime-encrypt-query): Use new function. Default to ldap. -2005-02-14 Arne J,Ax(Brgensen +2005-02-14 Arne J,Ax(Brgensen * smime.el: Require smime-ldap. (smime-ldap-host-list): New variable. @@ -542,7 +3577,7 @@ (mm-display-inline-fontify): Rewrite for decoding and decompressing parts. -2004-10-15 TSUCHIYA Masatoshi +2005-02-07 TSUCHIYA Masatoshi * mm-view.el (mm-display-inline-fontify): Decode a part according to the charset parameter. @@ -557,12 +3592,12 @@ * nntp.el (nntp-marks-changed-p): Use time-less-p to compare the timestamps. -2005-01-29 Jari Aalto +2005-02-02 Jari Aalto * gnus-sum.el (gnus-list-of-unread-articles): Improve active groups error checking and notify user. -2004-09-04 Jari Aalto +2005-02-02 Jari Aalto * message.el (message-send-mail-function): Check existence of sendmail-program first before using default value @@ -610,20 +3645,20 @@ XEmacs. Remove `password-run-at-time' macro. (password-cache-add): Use `run-at-time' instead of - `password-run-at-time'. + `password-run-at-time'. * nnheaderxm.el: Require timer-funcs instead of run-at-time. Remove `nnheader-cancel-function-timers' alias, - `cancel-function-timers' exists in XEmacs in timer-funcs. + `cancel-function-timers' exists in XEmacs in timer-funcs. * mail-source.el: Require timer-funcs instead of itimer in XEmacs - for `run-with-idle-timer'. + for `run-with-idle-timer'. * gnus-demon.el: Require timer-funcs instead of itimer in XEmacs for `run-at-time'. * mm-url.el: Require timer-funcs at compile time when in XEmacs - for `with-timeout'. + for `with-timeout'. * dgnushack.el: Autoload the correct `setenv' for SXEmacs which is the same as for XEmacs 21.4. @@ -638,12 +3673,12 @@ * mml.el (mml-generate-mime-1): Convert string into unibyte when inserting " *mml*" buffer's contents into a unibyte temp buffer. -2005-01-24 Harald Meland (tiny change) +2005-01-24 Harald Meland (tiny change) * mail-source.el (mail-source-fetch-imap): Search for ^From case sensitively. -2005-01-21 Derek Atkins (tiny change) +2005-01-21 Derek Atkins (tiny change) * pgg-pgp.el (pgg-pgp-decrypt-region): Use passphrase cache. @@ -1069,7 +4104,7 @@ * dns.el (query-dns): Use sit-for to time instead of accept-process-output, since that doesn't seem to work on udp - sockets. + sockets. 2004-11-17 Katsumi Yamaoka @@ -1269,11 +4304,13 @@ * deuglify.el (gnus-outlook-deuglify): Add :version. - * html2text.el: Beautify code. Improve doc strings. Some checkdoc - cleanup. + * html2text.el: Beautify code. Improve doc strings. Some + checkdoc cleanup. (html2text-get-attr, html2text-fix-paragraph): Simplify code. - (html2text-format-tag-list): Add "strong" and "em". - From "Alfred M. Szmidt" (tiny change). + +2004-11-01 Alfred M. Szmidt (tiny change) + + * html2text.el (html2text-format-tag-list): Add "strong" and "em". 2004-10-29 Teodor Zlatanov @@ -1438,7 +4475,7 @@ 2004-10-17 Richard M. Stallman - * gnus-registry.el (gnus-registry-unload-hook): + * gnus-registry.el (gnus-registry-unload-hook): Set as a variable with add-hook. * nnspool.el (nnspool-spool-directory): Use news-directory instead @@ -1641,7 +4678,7 @@ * gnus-agent.el (gnus-agent-synchronize-group-flags): When necessary, pass full group name to gnus-request-set-marks. - + 2004-10-01 Simon Josefsson * mailcap.el (mailcap-mime-data): Add pdf. Remove non-free @@ -1651,12 +4688,12 @@ * spam-report.el (spam-report-gmane): Fix interactive. - * gnus-art.el (gnus-treat-body-boundary): Only do stuff under X. + * gnus-art.el (gnus-treat-body-boundary): Only do stuff under X. * gnus-agent.el (gnus-agent-synchronize-flags-server): Be silent when writing file. (gnus-agent-synchronize-flags): Don't default to being - interactive. + interactive. 2004-09-30 Simon Josefsson @@ -1674,7 +4711,7 @@ info read flags with the marks being sync'd to the backend. *gnus-util.el (gnus-pp): Added optional stream to match pp API. - + 2004-09-28 Teodor Zlatanov * spam.el (spam-verify-bogofilter): new function @@ -1729,7 +4766,7 @@ * gnus-dup.el (gnus-dup-open): Use mapc. (gnus-dup-enter-articles, gnus-dup-suppress-articles): Use dolist. - + (gnus-dup-enter-articles): Remove excess ID's from gnus-dup-hashtb. Reported by Stefan Wiens . @@ -1748,7 +4785,7 @@ * gnus-agent.el (gnus-agent-check-overview-buffer): Fixed range of deletion to remove entire duplicate line. Fixes merged article number bug. - + 2004-09-25 Kevin Greiner * gnus-agent.el (gnus-agent-possibly-synchronize-flags): Ignore @@ -1768,7 +4805,7 @@ gnus-agent-synchronize-group-flags, not backend's request-set-mark method, to ensure that synchronization updates marks in the backend and in the info (in memory) structure. - + 2004-09-24 Katsumi Yamaoka * gnus-uu.el (gnus-uu-digest-mail-forward): Obey the process/prefix @@ -2131,16 +5168,13 @@ * nnimap.el (nnimap-authinfo-file, nnimap-prune-cache): Add :group 'nnimap. -2004-08-30 Simon Josefsson +2004-08-30 Andreas Schwab * rfc2231.el (rfc2231-parse-string): Restore whitespace syntax for - ?* and ?\; (tiny patch). From Andreas Schwab . - -2004-08-30 Simon Josefsson + ?* and ?\;. * ietf-drums.el (ietf-drums-syntax-table): Set syntax of ?* ?\; - and ?\' to symbol instead of whitespace (tiny patch). From - Andreas Schwab . + and ?\' to symbol instead of whitespace. 2004-08-30 Katsumi Yamaoka @@ -2170,6 +5204,17 @@ * gnus-sum.el (gnus-summary-make-menu-bar): Avoid the "Unrecognized menu descriptor" error in XEmacs. +2004-08-26 Stefan Wiens (tiny change) + + * gnus-sum.el (gnus-read-header): Don't remove a header for the + parent article of a sparse article in the thread hashtb. + +2004-08-26 David Hedbor (tiny change) + + * nnmail.el (nnmail-split-lowercase-expanded): New user option. + (nnmail-expand-newtext): Lowercase expanded entries if + nnmail-split-lowercase-expanded is non-nil. + 2004-08-26 Katsumi Yamaoka * nndoc.el (nndoc-type-alist): Fix regexp in the rfc822-forward @@ -2348,7 +5393,7 @@ * flow-fill.el (fill-flowed): Remove space stuffing, and only do quotes that actually start with ">" at the beginning of the - lines. + lines. 2004-07-23 Katsumi Yamaoka @@ -2385,13 +5430,6 @@ * rfc2047.el (rfc2047-encode-region): Fix last change. 2004-07-12 Katsumi Yamaoka - From David Hedbor . - - * nnmail.el (nnmail-split-lowercase-expanded): New user option. - (nnmail-expand-newtext): Lowercase expanded entries if - nnmail-split-lowercase-expanded is non-nil. - -2004-07-12 Katsumi Yamaoka * rfc2047.el (rfc2047-encode-region): Treat backslash-quoted characters as non-special. @@ -2423,7 +5461,7 @@ 2004-07-03 Lars Magne Ingebrigtsen * nnheader.el (nnheader-uniquify-message-id): New experimental - variable. + variable. (nnheader-nov-read-message-id): Use it. * spam-report.el (spam-report-gmane): Add interactive. @@ -2433,10 +5471,9 @@ * mm-encode.el (mm-content-transfer-encoding-defaults): Use qp-or-base64 for the application/* types. -2004-07-02 Jesper Harder +2004-07-02 Joakim Verona (tiny change) - * nnrss.el (nnrss-read-group-data): Fix off-by-one error. From - Joakim Verona . + * nnrss.el (nnrss-read-group-data): Fix off-by-one error. 2004-06-30 Teodor Zlatanov @@ -2459,6 +5496,11 @@ * gnus-group.el (gnus-group-get-new-news-this-group): Don't update info that isn't there. +2004-06-29 Ilya N. Golubev . + + * mm-util.el (mm-mime-mule-charset-alist): Add the windows-1251 + entry. + 2004-06-29 Katsumi Yamaoka * mm-view.el (mm-inline-render-with-function): Use multibyte @@ -2466,11 +5508,9 @@ * mm-encode.el (mm-content-transfer-encoding-defaults): Doc fix. - * mm-util.el (mm-mime-mule-charset-alist): Add the windows-1251 - entry. From Ilya N. Golubev . - (mm-enrich-utf-8-by-mule-ucs): New function run when Mule-UCS is - loaded under XEmacs. - (): Don't make duplicated entries in mm-mime-mule-charset-alist. + * mm-util.el (mm-enrich-utf-8-by-mule-ucs): New function run when + Mule-UCS is loaded under XEmacs. + (mm-mime-mule-charset-alist): Avoid duplicated entries. 2004-06-28 Jesper Harder @@ -2658,7 +5698,7 @@ 2004-06-12 Lars Magne Ingebrigtsen - * message.el (message-ignored-supersedes-headers): Add Approved. + * message.el (message-ignored-supersedes-headers): Add Approved. 2004-06-11 Katsumi Yamaoka @@ -2670,7 +5710,7 @@ * rfc2047.el (rfc2047-encode-message-header): Disabled header folding -- not all headers can be folded, and this should be done - by the message composition mode. Probably. I think. + by the message composition mode. Probably. I think. 2004-06-10 Katsumi Yamaoka @@ -2724,12 +5764,12 @@ 2004-06-06 Lars Magne Ingebrigtsen * message.el (message-cite-articles-with-x-no-archive): New - variable. + variable. (message-cite-original): Use it. 2004-06-04 Lars Magne Ingebrigtsen - * message.el (message-cite-original): Respect X-No-Archive. + * message.el (message-cite-original): Respect X-No-Archive. 2004-06-04 Katsumi Yamaoka @@ -2777,13 +5817,15 @@ * spam.el (spam-group-spam-contents-p): handle empty groupname strings (spam-report-articles-resend) - (spam-report-resend-register-routine): allow spam-report-resend-to - to be a group parameter or a global value - (tiny change). From Daniel Pittman . (spam-register-routine): do registration iff any articles warrant it. (spam-summary-prepare-exit): changed log message for nil group - destinations + destinations + +2004-05-27 Daniel Pittman + + * spam.el (spam-report-resend-register-routine): allow + spam-report-resend-to to be a group parameter or a global value 2004-05-26 Simon Josefsson @@ -2810,11 +5852,14 @@ 2004-05-26 Teodor Zlatanov - * spam.el (spam-mark-junk-as-spam-routine) - (spam-mark-new-messages-in-spam-group-as-spam): allow user to - disable assigning the spam-mark to new messages - (spam-ham-copy-or-move-routine): todo decleared twice (tiny - change). From Adam Sj,Ax(Bgren . + * spam.el (spam-mark-new-messages-in-spam-group-as-spam): New + variable. + (spam-mark-junk-as-spam-routine): Use it. Allow to disable + assigning the spam-mark to new messages. + +2004-05-26 Adam Sj,Ax(Bgren (tiny change) + + (spam-ham-copy-or-move-routine): Don't declare `todo' twice. 2004-05-26 Katsumi Yamaoka @@ -2824,10 +5869,10 @@ (rfc2047-decode): Treat the ascii coding-system as raw-text by default. -2004-05-25 Teodor Zlatanov +2004-05-25 Anand Mitra (tiny change) * gnus-sum.el (gnus-summary-delete-article): invoke hook with - correct data (tiny change). From Anand Mitra . + correct data. 2004-05-24 Teodor Zlatanov @@ -2888,24 +5933,24 @@ * nnimap.el (nnimap-open-connection): Use netrc. * gnus-util.el (gnus-netrc-get): Remove aliases. - + * gnus-sum.el (gnus-auto-center-summary): Change default to 2. * assistant.el (wid-edit): Fix compilation. - * gnus-util.el (gnus-set-file-modes): Just ignore errors. + * gnus-util.el (gnus-set-file-modes): Just ignore errors. 2004-05-23 Paul Stodghill * gnus-util.el (gnus-set-file-modes): New function. (small - patch). + patch). 2004-05-23 Lars Magne Ingebrigtsen * gnus-topic.el (gnus-topic-jump-to-topic): Goto missing topic. * assistant.el (assistant-render-node): Fix up rendering and - read-only text. + read-only text. (assistant-render-node): Reset. (assistant-make-read-only): Not sticky. @@ -3017,7 +6062,7 @@ 2004-05-19 Lars Magne Ingebrigtsen * gnus-msg.el (gnus-inews-make-draft-meta-information): Fix quote - stuff. + stuff. * gnus-start.el (gnus-subscribe-hierarchical-interactive): Match on real group name. @@ -3028,7 +6073,7 @@ * pgg-pgp.el (pgg-pgp-verify-region): Clean up. -2004-05-19 Michael Schierl +2004-05-19 Michael Schierl (tiny change) * pgg-pgp.el (pgg-pgp-verify-region): Default when signature isn't a string. @@ -3038,17 +6083,17 @@ * gnus-draft.el (gnus-draft-send): Bind rfc2047-encode-encoded-words. - * rfc2047.el (rfc2047-encode-region): Encode =? strings. + * rfc2047.el (rfc2047-encode-region): Encode =? strings. (rfc2047-encodable-p): Say that =? needs encoding. (rfc2047-encode-encoded-words): New variable. * gnus-group.el (gnus-group-select-group): Doc fix. - * gnus-draft.el (gnus-draft-setup): Mark all replied as replied. + * gnus-draft.el (gnus-draft-setup): Mark all replied as replied. * gnus-group.el (gnus-group-mode): Set show-trailing-whitespace to nil. - + * gnus-cache.el (gnus-cache-possibly-enter-article): Use it. * nnheader.el (nnheader-get-lines-and-char): New function. @@ -3089,7 +6134,7 @@ * gnus-msg.el (gnus-inews-do-gcc): Don't use read-only-p to see whether backend can accept message. - * message.el (message-idna-to-ascii-rhs-1): Don't use equalp. + * message.el (message-idna-to-ascii-rhs-1): Don't use equalp. 2004-05-18 Kai Grossjohann @@ -3128,7 +6173,7 @@ * mail-source.el (mail-source-delete-crash-box): Refactor. (mail-source-fetch): Use it. (mail-source-fetch-file): Ditto. - (mail-source-fetch-directory): Run postscript in loop. + (mail-source-fetch-directory): Run postscript in loop. (mail-source-fetch-pop): Delete. (mail-source-fetch-maildir): Ditto. (mail-source-fetch-imap): Ditto. @@ -3141,7 +6186,7 @@ (message-delete-address): Use it. (message-fill-header-general): Refactor. (message-fill-field-address): Rename. - (message-narrow-to-field): Find the start of the header. + (message-narrow-to-field): Find the start of the header. (message-header-format-alist): Don't pre-fill. (message-fill-header): Removed. (message-insert-header): New function. @@ -3155,10 +6200,10 @@ * imap.el: Add compiler directives. - * gnus-score.el (gnus-score-edit-done): run-hook->run-hooks. + * gnus-score.el (gnus-score-edit-done): run-hook->run-hooks. * gnus-art.el (article-decode-idna-rhs): Don't use - message-idna-inside-rhs-p. + message-idna-inside-rhs-p. 2004-05-16 Lars Magne Ingebrigtsen @@ -3170,21 +6215,21 @@ 2004-05-16 Kim Minh Kaplan - * imap.el (imap-sasl-make-mechanisms): Use sasl. + * imap.el (imap-sasl-make-mechanisms): Use sasl. 2004-05-16 Lars Magne Ingebrigtsen * nneething.el (nneething-file-name): Don't create spurions - files. + files. - * gnus-msg.el (gnus-inews-do-gcc): Ignore read-only groups. + * gnus-msg.el (gnus-inews-do-gcc): Ignore read-only groups. (gnus-inews-do-gcc): Remove sleep. * gnus-art.el (gnus-mime-delete-part): Error message when no MIME part under point. - * gnus-agent.el (gnus-agent-synchronize-flags): Default to nil. - (gnus-agent-regenerate-group): Using nil messages aren't valid. + * gnus-agent.el (gnus-agent-synchronize-flags): Default to nil. + (gnus-agent-regenerate-group): Using nil messages aren't valid. 2004-05-15 Teodor Zlatanov @@ -3192,14 +6237,15 @@ 2004-05-14 Teodor Zlatanov - * gnus-dup.el (gnus-dup-unsuppress-article): don't assume the mail - header is not nil (tiny change). From Nelson Ferreira - . - * spam.el (spam-summary-prepare-exit): only produce "marking spam as expired without moving it" message when there are spam messages left +2004-05-14 Nelson Ferreira (tiny change) + + * gnus-dup.el (gnus-dup-unsuppress-article): don't assume the mail + header is not nil. + 2004-05-14 Kai Grossjohann * nntp.el (nntp-request-set-mark, nntp-request-update-info): Call @@ -3397,7 +6443,7 @@ From Dan Christensen , asjo@koldfront.dk (Adam Sj,Ax(Bgren), Wes Hardaker , and Michael Shields : - + * spam.el (spam-necessary-extra-headers): get the extra headers we may need for spam sorting and scoring (spam-user-format-function-S): a user format function suitable for @@ -3444,7 +6490,7 @@ hasn't worked for a while. 2004-04-15 Kevin Greiner - + * gnus-agent.el (gnus-agentize): gnus-agent-send-mail-real-function no longer set to current value of message-send-mail-function but rather a lambda that calls @@ -3452,7 +6498,7 @@ responsive to user changes to message-send-mail-function. 2004-04-15 Kevin Greiner - + * legacy-gnus-agent.el (gnus-agent-convert-to-compressed-agentview): Fixed typos with help from Florian Weimer @@ -3541,7 +6587,7 @@ (gnus-agent-need-update-total-fetched-for): New variable. (gnus-agent-update-files-total-fetched-for): New function. (gnus-agent-update-view-total-fetched-for): New function. - (gnus-agent-total-fetched-for): New function. + (gnus-agent-total-fetched-for): New function. * gnus-cache.el (gnus-cache-save-buffers): Use gnus-cache-update-overview-total-fetched-for to change disk space @@ -3564,7 +6610,7 @@ (gnus-cache-delete-group-total-fetched-for): New function. (gnus-cache-total-fetched-for): New function. - * gnus-group.el (): Require gnus-sum and autoload functions to + * gnus-group.el: Require gnus-sum and autoload functions to resolve warnings when gnus-group.el compiled alone. (gnus-group-line-format): Documented new %F (size of Fetched data) group line format; identifies disk space @@ -3589,14 +6635,15 @@ * gnus-util.el (gnus-rename-file): New function. +2004-04-07 Christian Neukirchen (tiny change) + + * mm-util.el (mm-image-load-path): Handle nil in load-path. + 2004-04-07 Jesper Harder * rfc2047.el (rfc2047-encoded-word-regexp): Remove unnecessary '+'. Reported by Stefan Wiens . - * mm-util.el (mm-image-load-path): Handle nil in load-path. - From Christian Neukirchen . - 2004-04-06 Jesper Harder * gnus-cache.el (gnus-cache-save-buffers): Check if buffer is @@ -3708,10 +6755,6 @@ * gnus-agent.el (gnus-agent-read-agentview): Add a missing arg to error. - * gnus-sum.el (gnus-read-header): Don't remove a header for the - parent article of a sparse article in the thread hashtb. From - Stefan Wiens . - 2004-03-12 Reiner Steib * imap.el (imap-store-password): New variable. @@ -3723,13 +6766,13 @@ * gnus-art.el (gnus-article-read-summary-keys): Restore new window-start and hscroll to summary window. -2004-03-12 Kevin Greiner +2004-03-12 Kevin Greiner * gnus-start.el (gnus-convert-old-newsrc): Only write the conversion message to newsrc-dribble when an actual conversion is performed. -2004-03-10 Malcolm Purvis (tiny change) +2004-03-10 Malcolm Purvis (tiny change) * spam-stat.el (spam-stat-coding-system): Use mm-coding-system-p. @@ -3741,7 +6784,7 @@ * gnus-art.el (gnus-mime-save-part-and-strip): Use it. (gnus-mime-delete-part): Use it. -2004-03-09 Kevin Greiner +2004-03-09 Kevin Greiner * gnus-agent.el (gnus-agent-read-local): Bind nnheader-file-coding-system to gnus-agent-file-coding-system to @@ -3757,7 +6800,7 @@ signaling an error; don't use mm-multiple-handles. (gnus-mime-delete-part): Ditto. -2004-03-08 Kevin Greiner +2004-03-08 Kevin Greiner * gnus-agent.el (gnus-agent-read-agentview): Removed support for old file versions. @@ -3779,7 +6822,7 @@ * legacy-gnus-agent.el (): New. Provides converters that are only loaded when gnus-convert-old-newsrc needs to call them. - + 2004-03-08 Katsumi Yamaoka * mail-source.el (mail-source-touch-pop): Doc fix. @@ -3796,8 +6839,8 @@ 2004-03-05 Per Abrahamsen - * gnus-sum.el (gnus-widget-reversible-match) - (gnus-widget-reversible-to-internal) + * gnus-sum.el (gnus-widget-reversible-match) + (gnus-widget-reversible-to-internal) (gnus-widget-reversible-to-external): New functions. (gnus-widget-reversible): New widget. (gnus-article-sort-functions, gnus-thread-sort-functions): Use it. @@ -3822,13 +6865,13 @@ * gnus.el (spam-autodetect-methods): add spam-use-gmane-xref as an autodetect method -2004-03-04 Kevin Greiner +2004-03-04 Kevin Greiner * gnus-int.el (gnus-request-accept-article): Inform the agent that articles are being added to a group. (gnus-request-replace-article): Inform the agent that articles need to be uncached as the cached contents are no longer valid. - + 2004-03-04 Katsumi Yamaoka * binhex.el: Don't autoload executable-find. @@ -3869,7 +6912,7 @@ * uudecode.el: Don't autoload executable-find. -2004-03-04 Kevin Greiner +2004-03-04 Kevin Greiner * gnus-agent.el (gnus-agent-file-header-cache): Removed. (gnus-agent-possibly-alter-active): Avoid null in numeric @@ -3901,7 +6944,7 @@ * gnus-cus.el (gnus-agent-customize-category): Mismatched paren. -2004-03-02 Kevin Greiner +2004-03-02 Kevin Greiner * gnus-cus.el (gnus-agent-customize-category): Removed ignore-errors macro reference that required cl to be loaded at @@ -3981,11 +7024,11 @@ * flow-fill.el: Typo. -2004-02-26 Andrew Cohen +2004-02-26 Andrew Cohen * spam-wash.el: New file. -2004-02-26 Mark A. Hershberger +2004-02-26 Mark A. Hershberger * nnrss.el (nnrss-opml-import, nnrss-opml-export): New functions. @@ -4234,7 +7277,7 @@ * nnlistserv.el (nnlistserv-kk-wash-article): do. - * nnml.el (nnml-request-set-mark, nnml-save-marks): do. + * nnml.el (nnml-request-set-mark, nnml-save-marks): do. * mm-bodies.el (mm-7bit-chars): Don't include \r. @@ -4248,11 +7291,10 @@ * rfc2047.el (rfc2047-pad-base64): Deal with more cases of invalid padding. -2004-01-27 Simon Josefsson +2004-01-27 Ralf Angeli - * mm-view.el (mm-fill-flowed): Add. - (mm-inline-text): Use it. Tiny patch from Ralf Angeli - . + * mm-view.el (mm-fill-flowed): New variable. + (mm-inline-text): Use it. 2004-01-27 Teodor Zlatanov @@ -4274,7 +7316,7 @@ 2004-01-27 Steve Youngs * gnus-spec.el (gnus-parse-simple-format): Fix setq value - omission. + omission. From Jerry James 2004-01-26 Katsumi Yamaoka @@ -4297,7 +7339,7 @@ * spam-stat.el (spam-stat-process-directory-age): New option. (spam-stat-process-directory): Use it. -2004-01-24 Hiroshi Fujishima (tiny change) +2004-01-24 Hiroshi Fujishima (tiny change) * spam-stat.el (spam-stat-reduce-size): Set spam-stat-dirty. (spam-stat-save): Accept prefix argument. @@ -4329,7 +7371,7 @@ * gnus-gl.el: Remove. -2004-01-23 Kevin Greiner +2004-01-23 Kevin Greiner * gnus-sum.el (gnus-adjust-marks): Now correctly handles a list of marks consisting of a single range {for example, (3 . 5)} rather @@ -4345,7 +7387,7 @@ * mm-util.el (mm-charset-synonym-alist): Add ks_c_5601-1987. Remove obsolete entries for big5 and gb2312. -2004-01-22 Kevin Greiner +2004-01-22 Kevin Greiner * gnus-sum.el (gnus-adjust-marks): Avoid splicing null INTO the uncompressed list. @@ -4358,7 +7400,7 @@ * gnus-util.el (gnus-fetch-field): Don't bind case-fold-search here -- it's done in message-fetch-field. -2004-01-21 Kevin Greiner +2004-01-21 Kevin Greiner * gnus-agent.el (gnus-agent-queue-mail, gnus-agent-prompt-send-queue): New variables. @@ -4429,7 +7471,7 @@ * gnus-sum.el (gnus-select-newgroup): Replaced inline code with gnus-agent-possibly-alter-active. (gnus-adjust-marked-articles): Faster handling of simple lists - + 2004-01-21 Jesper Harder * spam-stat.el (spam-stat-test-directory): New optional argument @@ -4438,7 +7480,7 @@ (spam-stat-buffer-words-with-scores): Don't narrow and change syntax table here. Reported by Andrew Cohen . -2004-01-20 Teodor Zlatanov +2004-01-20 Teodor Zlatanov * spam.el (gnus-summary-mode-map): make spam-generic-score the default scoring function @@ -4582,7 +7624,7 @@ * rfc2047.el (rfc2047-parse-and-decode, rfc2047-decode): Use a character for the encoding to avoid consing a string. - + * rfc2047.el (rfc2047-decode-string): Don't cons a string unnecessarily. @@ -4596,7 +7638,7 @@ * gnus.sum.el (gnus-remove-odd-characters): Don't cons two new strings. - * mm-util.el (mm-subst-char-in-string): Support inplace. + * mm-util.el (mm-subst-char-in-string): Support inplace. * gnus-sum.el (gnus-summary-remove-list-identifiers): Don't cons a new string in every iteration. Use shy groups. @@ -4643,21 +7685,21 @@ * gnus-topic.el (gnus-topic-find-groups, gnus-topic-clean-alist) (gnus-group-prepare-topics, gnus-topic-check-topology): do. - + * gnus-sum.el (gnus-update-read-articles, gnus-select-newsgroup) (gnus-mark-xrefs-as-read, gnus-compute-read-articles) (gnus-summary-walk-group-buffer, gnus-summary-move-article) (gnus-group-make-articles-read): do. - + 2004-01-09 Jesper Harder * gnus-art.el (article-decode-mime-words, article-babel) (gnus-article-highlight-signature, gnus-article-add-buttons) (gnus-signature-toggle): Use gnus-with-article-buffer. - + * gnus-art.el (gnus-article-highlight-headers) (gnus-article-add-buttons-to-head): Use gnus-with-article-headers. - + * gnus-art.el (gnus-mm-display-part, gnus-article-wash-status) (gnus-article-set-globals, gnus-request-article-this-buffer) (gnus-button-message-id, gnus-article-maybe-hide-headers) @@ -4915,10 +7957,10 @@ * nnheaderxm.el: Remove definition of run-at-time. -2004-01-05 Karl Pfl,Ad(Bsterer +2004-01-05 Karl Pfl,Ad(Bsterer (tiny change) * mml.el (mml-minibuffer-read-disposition): Show attachment type - in prompt (tiny change) + in prompt. 2004-01-06 Steve Youngs @@ -4931,7 +7973,7 @@ (gnus-xmas-define): Don't alias `gnus-set-text-properties' to `gnus-xmas-set-text-properties'. (gnus-xmas-redefine): Don't alias `gnus-completing-read' to - `gnus-xmas-completing-read'. + `gnus-xmas-completing-read'. (gnus-xmas-completing-read): Removed. (gnus-xmas-open-network-stream): Removed. @@ -5160,7 +8202,7 @@ * gnus-group.el (gnus-no-groups-message): Update. - * gnus-sum.el (gnus-summary-insert-new-articles): Remove . + * gnus-sum.el (gnus-summary-insert-new-articles): Remove . 2003-11-09 Simon Josefsson @@ -5214,7 +8256,7 @@ See ChangeLog.2 for earlier changes. - Copyright (C) 2000, 2001, 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. Copying and distribution of this file, with or without modification, are permitted provided the copyright notice and this notice are preserved. diff --git a/lisp/ChangeLog.2 b/lisp/ChangeLog.2 index 5d7a608..50b978e 100644 --- a/lisp/ChangeLog.2 +++ b/lisp/ChangeLog.2 @@ -7390,7 +7390,7 @@ instead of mm-auto-save-coding-system for the draft or delayed group. -2002-10-28 Josh +2002-10-28 Josh Huber * mml.el (mml-mode-map): Fixed keybindings for mml-secure-* functions. @@ -7658,7 +7658,7 @@ * spam.el: more compilation fixes for BBDB - * spam-stat.el added code from Alex Schroeder + * spam-stat.el: added code from Alex Schroeder (spam-stat-reduce-size): Interactive. (spam-stat-reset): New function. (spam-stat-save): Interactive. @@ -12404,7 +12404,7 @@ 2001-12-05 Katsumi Yamaoka - * mm-view.wl (mm-inline-text): Decode a charset-encoded rich text. + * mm-view.el (mm-inline-text): Decode a charset-encoded rich text. 2001-12-04 08:00:00 ShengHuo ZHU diff --git a/lisp/Makefile.in b/lisp/Makefile.in index b0b5447..df6acc9 100644 --- a/lisp/Makefile.in +++ b/lisp/Makefile.in @@ -29,8 +29,9 @@ warn: clean-some gnus-load.el clever some l: gnus-load.el $(EMACS_COMP) -f dgnushack-compile -install: install-el install-elc +install: install-el-elc list-installed-shadows +# This entry will never install .el files if there are no .elc files. install-el: gnus-load.el $(SHELL) $(top_srcdir)/mkinstalldirs $(lispdir) echo " $(INSTALL_DATA) gnus-load.el $(lispdir)/gnus-load.el" @@ -51,6 +52,27 @@ install-elc: clever $(INSTALL_DATA) $$p $(lispdir)/$$p; \ done +install-el-elc: clever + rm -f dgnushack.elc + $(SHELL) $(top_srcdir)/mkinstalldirs $(lispdir) + echo " $(INSTALL_DATA) gnus-load.el $(lispdir)/gnus-load.el" + $(INSTALL_DATA) gnus-load.el $(lispdir)/gnus-load.el + for p in *.elc; do \ + q=`basename $$p c`; \ + if [ -f "$(srcdir)/$$q" ]; then \ + echo " $(INSTALL_DATA) $$q $(lispdir)/$$q"; \ + $(INSTALL_DATA) $(srcdir)/$$q $(lispdir)/$$q; \ + fi; \ + echo " $(INSTALL_DATA) $$p $(lispdir)/$$p"; \ + $(INSTALL_DATA) $$p $(lispdir)/$$p; \ + done + +list-installed-shadows: + $(EMACS_COMP) -f dgnushack-find-lisp-shadows + +remove-installed-shadows: + $(EMACS_COMP) -f dgnushack-remove-lisp-shadows + uninstall: for p in *.elc; do \ rm -f "$(lispdir)/$$p"; \ @@ -74,8 +96,11 @@ gnus-load.el: $(EMACS_COMP) -f dgnushack-make-auto-load $(srcdir) $(EMACS_COMP) -f dgnushack-make-load -distclean: - rm -f *.orig *.rej *.elc auto-autoloads.* custom-load.* *~ Makefile +clean: + rm -f *.elc *.orig *.rej *~ auto-autoloads.* custom-load.* gnus-load.el + +distclean: clean + rm -f Makefile Makefile: $(srcdir)/Makefile.in ../config.status cd .. \ diff --git a/lisp/assistant.el b/lisp/assistant.el index 79f83d5..1048c42 100644 --- a/lisp/assistant.el +++ b/lisp/assistant.el @@ -1,5 +1,5 @@ ;;; assistant.el --- guiding users through Emacs setup -;; Copyright (C) 2004 Free Software Foundation, Inc. +;; Copyright (C) 2004, 2005 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: util @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,6 +31,11 @@ (require 'widget) (require 'wid-edit) +(autoload 'gnus-error "gnus-util") +(autoload 'netrc-get "netrc") +(autoload 'netrc-machine "netrc") +(autoload 'netrc-parse "netrc") + (defvar assistant-readers '(("variable" assistant-variable-reader) ("validate" assistant-sexp-reader) @@ -38,9 +43,11 @@ ("next" assistant-list-reader) ("text" assistant-text-reader))) -(defface assistant-field-face '((t (:bold t))) +(defface assistant-field '((t (:bold t))) "Face used for editable fields." :group 'gnus-article-emphasis) +;; backward-compatibility alias +(put 'assistant-field-face 'face-alias 'assistant-field) ;;; Internal variables @@ -268,7 +275,7 @@ (push (widget-create 'editable-field - :value-face 'assistant-field-face + :value-face 'assistant-field :assistant-variable variable (assistant-get-variable node variable)) assistant-widgets) @@ -278,7 +285,7 @@ (add-text-properties start (point) (list 'bold t - 'face 'assistant-field-face + 'face 'assistant-field 'not-read-only t)))))))) (defun assistant-render-node (node-name) diff --git a/lisp/binhex.el b/lisp/binhex.el index 9af2d46..cb69456 100644 --- a/lisp/binhex.el +++ b/lisp/binhex.el @@ -1,6 +1,7 @@ ;;; binhex.el --- elisp native binhex decode -;; Copyright (c) 1998, 1999, 2000, 2001, 2002, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: binhex news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/canlock.el b/lisp/canlock.el index 71c7dbe..9f063bb 100644 --- a/lisp/canlock.el +++ b/lisp/canlock.el @@ -1,7 +1,7 @@ ;;; canlock.el --- functions for Cancel-Lock feature -;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Katsumi Yamaoka ;; Keywords: news, cancel-lock, hmac, sha1, rfc2104 @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -50,7 +50,7 @@ (defgroup canlock nil "The Cancel-Lock feature." - :group 'applications) + :group 'news) (defcustom canlock-password nil "Password to use when signing a Cancel-Lock or a Cancel-Key header." diff --git a/lisp/compface.el b/lisp/compface.el index fc2ac46..f6bd9bf 100644 --- a/lisp/compface.el +++ b/lisp/compface.el @@ -1,5 +1,6 @@ ;;; compface.el --- functions for converting X-Face headers -;; Copyright (C) 2002 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/deuglify.el b/lisp/deuglify.el index 7140ab6..5c303b5 100644 --- a/lisp/deuglify.el +++ b/lisp/deuglify.el @@ -1,6 +1,6 @@ ;;; deuglify.el --- deuglify broken Outlook (Express) articles -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Copyright (C) 2001, 2002 Raymond Scholz ;; Author: Raymond Scholz @@ -22,8 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -231,7 +231,8 @@ (defgroup gnus-outlook-deuglify nil "Deuglify articles generated by broken user agents like MS Outlook (Express)." - :version "22.1") + :version "22.1" + :group 'gnus) ;;;###autoload (defcustom gnus-outlook-deuglify-unwrap-min 45 diff --git a/lisp/dgnushack.el b/lisp/dgnushack.el index 261f38d..4d6a119 100644 --- a/lisp/dgnushack.el +++ b/lisp/dgnushack.el @@ -1,5 +1,6 @@ ;;; dgnushack.el --- a hack to set the load path for byte-compiling -;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 +;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, +;; 2004, 2005 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -20,13 +21,15 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;;; Code: +(defvar dgnushack-default-load-path (copy-sequence load-path)) + (defalias 'facep 'ignore) (require 'cl) @@ -79,7 +82,7 @@ (when (and (not (featurep 'xemacs)) (= emacs-major-version 21) - (= emacs-minor-version 3) + (>= emacs-minor-version 3) (condition-case code (let ((byte-compile-error-on-warn t)) (byte-optimize-form (quote (pop x)) t) @@ -137,6 +140,17 @@ fixed in Emacs after 21.3." (setq ad-return-value (cons fn (nreverse backwards)))) ad-do-it))) +;; Work around for an incompatibility (XEmacs 21.4 vs. 21.5), see the +;; following threads: +;; +;; http://thread.gmane.org/gmane.emacs.gnus.general/56414 +;; Subject: attachment problems found but not fixed +;; +;; http://thread.gmane.org/gmane.emacs.gnus.general/56459 +;; Subject: Splitting mail -- XEmacs 21.4 vs 21.5 +;; +;; http://thread.gmane.org/gmane.emacs.xemacs.beta/20519 +;; Subject: XEmacs 21.5 and Gnus fancy splitting. (when (and (featurep 'xemacs) (let ((table (copy-syntax-table emacs-lisp-mode-syntax-table))) (modify-syntax-entry ?= " " table) @@ -189,6 +203,7 @@ fixed in Emacs after 21.3." (autoload 'browse-url "browse-url" nil t) (autoload 'c-mode "cc-mode" nil t) (autoload 'customize-apropos "cus-edit" nil t) + (autoload 'customize-group "cus-edit" nil t) (autoload 'customize-save-variable "cus-edit" nil t) (autoload 'customize-set-variable "cus-edit" nil t) (autoload 'customize-variable "cus-edit" nil t) @@ -198,6 +213,7 @@ fixed in Emacs after 21.3." (autoload 'executable-find "executable") (autoload 'font-lock-fontify-buffer "font-lock" nil t) (autoload 'info "info" nil t) + (autoload 'mail-extract-address-components "mail-extr") (autoload 'mail-fetch-field "mail-utils") (autoload 'make-annotation "annotations") (autoload 'make-display-table "disp-table") @@ -409,6 +425,83 @@ dgnushack-compile." ;;; End: ;;; gnus-load.el ends here")))) +(defun dgnushack-find-lisp-shadows (&optional lispdir) + "Return a list of directories in which other Gnus installations exist. +This function looks for the other Gnus installations which will shadow +the new Gnus Lisp modules which have been installed in LISPDIR, using +the default `load-path'. The return value will make sense only when +LISPDIR is existent and is listed in the default `load-path'. Assume +LISPDIR will be prepended to `load-path' by a user if the default +`load-path' does not contain it." + (unless lispdir + (setq lispdir (getenv "lispdir"))) + (when (and lispdir (file-directory-p lispdir)) + (setq lispdir (file-truename (directory-file-name lispdir))) + (let ((indices '("gnus.elc" "gnus.el" "gnus.el.bz2" "gnus.el.gz" + "message.elc" "message.el" "message.el.bz2" + "message.el.gz")) + (path (delq nil (mapcar + (lambda (p) + (condition-case nil + (when (and p (file-directory-p p)) + (file-truename (directory-file-name p))) + (error nil))) + dgnushack-default-load-path))) + rest elcs) + (while path + (setq rest (cons (car path) rest) + path (delete (car rest) (cdr path)))) + (setq path (nreverse (cdr (member lispdir rest))) + rest nil) + (while path + (setq elcs indices) + (while elcs + (when (file-exists-p (expand-file-name (pop elcs) (car path))) + (setq rest (cons (car path) rest) + elcs nil))) + (setq path (cdr path))) + (prog1 + (setq path (nreverse rest)) + (when path + (let (print-level print-length) + (princ (concat "\n\ +WARNING: The other Gnus installation" (if (cdr path) "s have" " has") "\ + been detected in:\n\n " (mapconcat 'identity path "\n ") "\n\n\ +You will need to modify the run-time `load-path', remove them manually, +or remove them using `make remove-installed-shadows'.\n\n")))))))) + +(defun dgnushack-remove-lisp-shadows (&optional lispdir) + "Remove the other Gnus installations which shadow the recent one." + (let ((path (with-temp-buffer + (let ((standard-output (current-buffer))) + (dgnushack-find-lisp-shadows lispdir)))) + elcs files shadows file) + (when path + (unless (setq elcs (directory-files srcdir nil "\\.elc\\'")) + (error "You should build .elc files first.")) + (setq files + (apply + 'append + (mapcar + (lambda (el) + (list (concat el "c") el (concat el ".bz2") (concat el ".gz"))) + (append + (list (file-name-nondirectory dgnushack-gnus-load-file) + (file-name-nondirectory dgnushack-cus-load-file)) + (mapcar (lambda (elc) (substring elc 0 -1)) elcs))))) + (while path + (setq shadows files) + (while shadows + (setq file (expand-file-name (pop shadows) (car path))) + (when (file-exists-p file) + (princ (concat " Removing " file "...")) + (condition-case nil + (progn + (delete-file file) + (princ "done\n")) + (error (princ "failed\n"))))) + (setq path (cdr path)))))) + ;;; dgnushack.el ends here ;;; arch-tag: 579f585a-24eb-4e1c-8d34-4808e11b68f2 diff --git a/lisp/dig.el b/lisp/dig.el index 08070e9..e180cda 100644 --- a/lisp/dig.el +++ b/lisp/dig.el @@ -1,5 +1,7 @@ ;;; dig.el --- Domain Name System dig interface -;; Copyright (c) 2000, 2001, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: DNS BIND dig @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -40,7 +42,8 @@ (eval-when-compile (require 'cl)) (defgroup dig nil - "Dig configuration.") + "Dig configuration." + :group 'comm) (defcustom dig-program "dig" "Name of dig (domain information groper) binary." @@ -147,7 +150,8 @@ Buffer should contain output generated by `dig-invoke'." (set (make-local-variable 'font-lock-defaults) '(dig-font-lock-keywords t))) (when (featurep 'font-lock) - (font-lock-set-defaults))) + (font-lock-set-defaults)) + (gnus-run-mode-hooks 'dig-mode-hook)) (defun dig-exit () "Quit dig output buffer." diff --git a/lisp/dns-mode.el b/lisp/dns-mode.el index 400f872..2c16b6f 100644 --- a/lisp/dns-mode.el +++ b/lisp/dns-mode.el @@ -1,5 +1,5 @@ ;;; dns-mode.el --- a mode for viewing/editing Domain Name System master files -;; Copyright (c) 2000, 2001, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (c) 2000, 2001, 2003, 2004, 2005 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: DNS master zone file SOA @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -48,7 +48,8 @@ ;;; Code: (defgroup dns-mode nil - "DNS master file mode configuration.") + "DNS master file mode configuration." + :group 'comm) (defconst dns-mode-classes '("IN" "CS" "CH" "HS") "List of strings with known DNS classes.") diff --git a/lisp/dns.el b/lisp/dns.el index b2001b1..05b2f73 100644 --- a/lisp/dns.el +++ b/lisp/dns.el @@ -1,5 +1,6 @@ ;;; dns.el --- Domain Name Service lookups -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: network @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -348,6 +349,18 @@ If TCP-P, the first two bytes of the package with be the length field." ;; connection to the DNS server. (open-network-stream "dns" (current-buffer) server "domain"))))) +(defvar dns-cache (make-vector 4096 0)) + +(defun query-dns-cached (name &optional type fullp reversep) + (let* ((key (format "%s:%s:%s:%s" name type fullp reversep)) + (sym (intern-soft key dns-cache))) + (if (and sym + (boundp sym)) + (symbol-value sym) + (let ((result (query-dns name type fullp reversep))) + (set (intern key dns-cache) result) + result)))) + (defun query-dns (name &optional type fullp reversep) "Query a DNS server for NAME of TYPE. If FULLP, return the entire record returned. @@ -391,10 +404,11 @@ If REVERSEP, look up an IP address." (decf times step)) (ignore-errors (delete-process process)) - (when tcp-p + (when (and tcp-p + (>= (buffer-size) 2)) (goto-char (point-min)) (delete-region (point) (+ (point) 2))) - (unless (zerop (buffer-size)) + (when (>= (buffer-size) 2) (let ((result (dns-read (buffer-string)))) (if fullp result diff --git a/lisp/earcon.el b/lisp/earcon.el index c595de0..a70e68d 100644 --- a/lisp/earcon.el +++ b/lisp/earcon.el @@ -1,6 +1,7 @@ ;;; earcon.el --- Sound effects for messages -;; Copyright (C) 1996, 2000, 2001, 2003 Free Software Foundation +;; Copyright (C) 1996, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Steven L. Baur @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;; This file provides access to sound effects in Gnus. diff --git a/lisp/encrypt.el b/lisp/encrypt.el index 0e14ca9..bbf631a 100644 --- a/lisp/encrypt.el +++ b/lisp/encrypt.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -36,7 +36,8 @@ (defgroup encrypt '((password-cache custom-variable) (password-cache-expiry custom-variable)) - "File encryption configuration.") + "File encryption configuration." + :group 'applications) (defcustom encrypt-file-alist nil "List of file names or regexes matched with encryptions. @@ -125,8 +126,8 @@ Format example: (if outdata (progn - (gnus-message 9 "%s was decrypted with %s (cipher %s)" - file (symbol-name method) cipher) + (message "%s was decrypted with %s (cipher %s)" + file (symbol-name method) cipher) (delete-region (point-min) (point-max)) (goto-char (point-min)) (insert outdata)) @@ -171,8 +172,8 @@ Format example: (if outdata (progn - (gnus-message 9 "%s was encrypted with %s (cipher %s)" - file (symbol-name method) cipher) + (message "%s was encrypted with %s (cipher %s)" + file (symbol-name method) cipher) (delete-region (point-min) (point-max)) (goto-char (point-min)) (insert outdata) @@ -212,7 +213,7 @@ Format example: (progn (setq new-list (reverse (split-string bs))) (dolist (x new-list) - (setq x (string-to-int x)) + (setq x (string-to-number x)) (insert (format "%c" (logxor x passphrase-sum)))))) (buffer-substring-no-properties (point-min) (point-max))))) diff --git a/lisp/flow-fill.el b/lisp/flow-fill.el index 2feb48d..e54100a 100644 --- a/lisp/flow-fill.el +++ b/lisp/flow-fill.el @@ -1,6 +1,7 @@ ;;; flow-fill.el --- interpret RFC2646 "flowed" text -;; Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -109,7 +110,7 @@ RFC 2646 suggests 66 characters for readability." (while (re-search-forward " $" nil t) (when (save-excursion (beginning-of-line) - (looking-at "^\\(>+\\)\\( ?\\)")) + (looking-at "^\\(>*\\)\\( ?\\)")) (let ((quote (match-string 1)) sig) (if (string= quote "") @@ -139,7 +140,8 @@ RFC 2646 suggests 66 characters for readability." (condition-case nil (let ((fill-prefix (when quote (concat quote " "))) (fill-column (eval fill-flowed-display-column)) - filladapt-mode) + filladapt-mode + adaptive-fill-mode) (fill-region (point-at-bol) (min (1+ (point-at-eol)) (point-max)) @@ -154,38 +156,43 @@ RFC 2646 suggests 66 characters for readability." (defvar show-trailing-whitespace)) (defvar fill-flowed-encode-tests - '( + `( ;; The syntax of each list element is: ;; (INPUT . EXPECTED-OUTPUT) - ("> Thou villainous ill-breeding spongy dizzy-eyed -> reeky elf-skinned pigeon-egg! ->> Thou artless swag-bellied milk-livered ->> dismal-dreaming idle-headed scut! ->>> Thou errant folly-fallen spleeny reeling-ripe ->>> unmuzzled ratsbane! ->>>> Henceforth, the coding style is to be strictly ->>>> enforced, including the use of only upper case. ->>>>> I've noticed a lack of adherence to the coding ->>>>> styles, of late. ->>>>>> Any complaints? -" . "> Thou villainous ill-breeding spongy dizzy-eyed reeky elf-skinned -> pigeon-egg! ->> Thou artless swag-bellied milk-livered dismal-dreaming idle-headed ->> scut! ->>> Thou errant folly-fallen spleeny reeling-ripe unmuzzled ratsbane! ->>>> Henceforth, the coding style is to be strictly enforced, ->>>> including the use of only upper case. ->>>>> I've noticed a lack of adherence to the coding styles, of late. ->>>>>> Any complaints? -") -; (" -;> foo -;> -;> -;> bar -;" . " -;> foo bar -;") + (,(concat + "> Thou villainous ill-breeding spongy dizzy-eyed \n" + "> reeky elf-skinned pigeon-egg! \n" + ">> Thou artless swag-bellied milk-livered \n" + ">> dismal-dreaming idle-headed scut!\n" + ">>> Thou errant folly-fallen spleeny reeling-ripe \n" + ">>> unmuzzled ratsbane!\n" + ">>>> Henceforth, the coding style is to be strictly \n" + ">>>> enforced, including the use of only upper case.\n" + ">>>>> I've noticed a lack of adherence to the coding \n" + ">>>>> styles, of late.\n" + ">>>>>> Any complaints?") + . + ,(concat + "> Thou villainous ill-breeding spongy dizzy-eyed reeky elf-skinned\n" + "> pigeon-egg! \n" + ">> Thou artless swag-bellied milk-livered dismal-dreaming idle-headed\n" + ">> scut!\n" + ">>> Thou errant folly-fallen spleeny reeling-ripe unmuzzled ratsbane!\n" + ">>>> Henceforth, the coding style is to be strictly enforced,\n" + ">>>> including the use of only upper case.\n" + ">>>>> I've noticed a lack of adherence to the coding styles, of late.\n" + ">>>>>> Any complaints?\n" + )) + ;; (,(concat + ;; "\n" + ;; "> foo\n" + ;; "> \n" + ;; "> \n" + ;; "> bar\n") + ;; . + ;; ,(concat + ;; "\n" + ;; "> foo bar\n")) )) (defun fill-flowed-test () diff --git a/lisp/format-spec.el b/lisp/format-spec.el index 1ffab56..aa290be 100644 --- a/lisp/format-spec.el +++ b/lisp/format-spec.el @@ -1,5 +1,7 @@ ;;; format-spec.el --- functions for formatting arbitrary formatting strings -;; Copyright (C) 1999, 2000 Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: tools @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,7 +33,8 @@ "Return a string based on FORMAT and SPECIFICATION. FORMAT is a string containing `format'-like specs like \"bash %u %k\", while SPECIFICATION is an alist mapping from format spec characters -to values." +to values. Any text properties on a %-spec itself are propagated to +the text that it generates." (with-temp-buffer (insert format) (goto-char (point-min)) @@ -45,10 +48,17 @@ to values." (let* ((num (match-string 1)) (spec (string-to-char (match-string 2))) (val (cdr (assq spec specification)))) - (delete-region (1- (match-beginning 0)) (match-end 0)) (unless val - (error "Invalid format character: `%%%c'" spec)) - (insert (format (concat "%" num "s") val)))) + (error "Invalid format character: `%%%c'" spec)) + ;; Pad result to desired length. + (let ((text (format (concat "%" num "s") val))) + ;; Insert first, to preserve text properties. + (insert-and-inherit text) + ;; Delete the specifier body. + (delete-region (+ (match-beginning 0) (length text)) + (+ (match-end 0) (length text))) + ;; Delete the percent sign. + (delete-region (1- (match-beginning 0)) (match-beginning 0))))) ;; Signal an error on bogus format strings. (t (error "Invalid format string")))) diff --git a/lisp/gmm-utils.el b/lisp/gmm-utils.el new file mode 100644 index 0000000..fef6dd5 --- /dev/null +++ b/lisp/gmm-utils.el @@ -0,0 +1,411 @@ +;;; gmm-utils.el --- Utility functions for Gnus, Message and MML + +;; Copyright (C) 2006 Free Software Foundation, Inc. + +;; Author: Reiner Steib +;; Keywords: news + +;; 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 the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; This library provides self-contained utility functions. The functions are +;; used in Gnus, Message and MML, but within this library there are no +;; dependencies on Gnus, Message, or MML or Gnus. + +;;; Code: + +(defgroup gmm nil + "Utility functions for Gnus, Message and MML" + :prefix "gmm-" + :version "23.0" ;; No Gnus + :group 'lisp) + +;; Helper functions from `gnus-utils.el': gmm-verbose, gmm-message, gmm-error + +(defcustom gmm-verbose 7 + "Integer that says how verbose gmm should be. +The higher the number, the more messages will flash to say what +it done. At zero, it will be totally mute; at five, it will +display most important messages; and at ten, it will keep on +jabbering all the time." + :type 'integer + :group 'gmm) + +;;;###autoload +(defun gmm-message (level &rest args) + "If LEVEL is lower than `gmm-verbose' print ARGS using `message'. + +Guideline for numbers: +1 - error messages, 3 - non-serious error messages, 5 - messages for things +that take a long time, 7 - not very important messages on stuff, 9 - messages +inside loops." + (if (<= level gmm-verbose) + (apply 'message args) + ;; We have to do this format thingy here even if the result isn't + ;; shown - the return value has to be the same as the return value + ;; from `message'. + (apply 'format args))) + +;;;###autoload +(defun gmm-error (level &rest args) + "Beep an error if LEVEL is equal to or less than `gmm-verbose'. +ARGS are passed to `message'." + (when (<= (floor level) gmm-verbose) + (apply 'message args) + (ding) + (let (duration) + (when (and (floatp level) + (not (zerop (setq duration (* 10 (- level (floor level))))))) + (sit-for duration)))) + nil) + +;;;###autoload +(defun gmm-widget-p (symbol) + "Non-nil iff SYMBOL is a widget." + (get symbol 'widget-type)) + +;; Copy of the `nnmail-lazy' code from `nnmail.el': +(define-widget 'gmm-lazy 'default + "Base widget for recursive datastructures. + +This is copy of the `lazy' widget in Emacs 22.1 provided for compatibility." + :format "%{%t%}: %v" + :convert-widget 'widget-value-convert-widget + :value-create (lambda (widget) + (let ((value (widget-get widget :value)) + (type (widget-get widget :type))) + (widget-put widget :children + (list (widget-create-child-value + widget (widget-convert type) value))))) + :value-delete 'widget-children-value-delete + :value-get (lambda (widget) + (widget-value (car (widget-get widget :children)))) + :value-inline (lambda (widget) + (widget-apply (car (widget-get widget :children)) + :value-inline)) + :default-get (lambda (widget) + (widget-default-get + (widget-convert (widget-get widget :type)))) + :match (lambda (widget value) + (widget-apply (widget-convert (widget-get widget :type)) + :match value)) + :validate (lambda (widget) + (widget-apply (car (widget-get widget :children)) :validate))) + +;; Note: The format of `gmm-tool-bar-item' may change if some future Emacs +;; version will provide customizable tool bar buttons using a different +;; interface. + +;; TODO: Extend API so that the "Command" entry can be a function or a plist. +;; In case of a list it should have the format... +;; +;; (:none command-without-modifier +;; :shift command-with-shift-pressed +;; :control command-with-ctrl-pressed +;; :control-shift command-with-control-and-shift-pressed +;; ;; mouse-2 and mouse-3 can't be used in Emacs yet. +;; :mouse-2 command-on-mouse-2-press +;; :mouse-3 command-on-mouse-3-press) ;; typically a menu of related commands +;; +;; Combinations of mouse-[23] plus shift and/or controll might be overkill. +;; +;; Then use (plist-get rs-command :none), (plist-get rs-command :shift) + +(define-widget 'gmm-tool-bar-item (if (gmm-widget-p 'lazy) 'lazy 'gmm-lazy) + "Tool bar list item." + :tag "Tool bar item" + :type '(choice + (list :tag "Command and Icon" + (function :tag "Command") + (string :tag "Icon file") + (choice + (const :tag "Default map" nil) + ;; Note: Usually we need non-nil attributes if map is t. + (const :tag "No menu" t) + (sexp :tag "Other map")) + (plist :inline t :tag "Properties")) + (list :tag "Separator" + (const :tag "No command" gmm-ignore) + (string :tag "Icon file") + (const :tag "No map") + (plist :inline t :tag "Properties")))) + +(define-widget 'gmm-tool-bar-zap-list (if (gmm-widget-p 'lazy) 'lazy 'gmm-lazy) + "Tool bar zap list." + :tag "Tool bar zap list" + :type '(choice (const :tag "Zap all" t) + (const :tag "Keep all" nil) + (list + ;; :value + ;; Work around (bug in customize?), see + ;; + ;; (new-file open-file dired kill-buffer write-file + ;; print-buffer customize help) + (set :inline t + (const new-file) + (const open-file) + (const dired) + (const kill-buffer) + (const save-buffer) + (const write-file) + (const undo) + (const cut) + (const copy) + (const paste) + (const search-forward) + (const print-buffer) + (const customize) + (const help)) + (repeat :inline t + :tag "Other" + (symbol :tag "Icon item"))))) + +;; (defun gmm-color-cells (&optional display) +;; "Return the number of color cells supported by DISPLAY. +;; Compatibility function." +;; ;; `display-color-cells' doesn't return more than 256 even if color depth is +;; ;; > 8 in Emacs 21. +;; ;; +;; ;; Feel free to add proper XEmacs support. +;; (let* ((cells (and (fboundp 'display-color-cells) +;; (display-color-cells display))) +;; (plane (and (fboundp 'x-display-planes) +;; (ash 1 (x-display-planes)))) +;; (none -1)) +;; (max (if (integerp cells) cells none) +;; (if (integerp plane) plane none)))) + +(defcustom gmm-tool-bar-style + (if (and (boundp 'tool-bar-mode) + tool-bar-mode + (and (fboundp 'display-visual-class) + (not (memq (display-visual-class) + (list 'static-gray 'gray-scale + 'static-color 'pseudo-color))))) + 'gnome + 'retro) + "Prefered tool bar style." + :type '(choice (const :tag "GNOME style" 'gnome) + (const :tag "Retro look" 'retro)) + :group 'gmm) + +(defvar tool-bar-map) + +;;;###autoload +(defun gmm-tool-bar-from-list (icon-list zap-list default-map) + "Make a tool bar from ICON-LIST. + +Within each entry of ICON-LIST, the first element is a menu +command, the second element is an icon file name and the third +element is a test function. You can use \\[describe-key] + to find out the name of a menu command. The fourth +and all following elements are passed a the PROPS argument to the +function `tool-bar-local-item'. + +If ZAP-LIST is a list, remove those item from the default +`tool-bar-map'. If it is t, start with a new sparse map. You +can use \\[describe-key] to find out the name of an icon +item. When \\[describe-key] shows \" +runs the command find-file\", then use `new-file' in ZAP-LIST. + +DEFAULT-MAP specifies the default key map for ICON-LIST." + (let (;; For Emacs 21, we must let-bind `tool-bar-map'. In Emacs 22, we + ;; could use some other local variable. + (tool-bar-map (if (eq zap-list t) + (make-sparse-keymap) + (copy-keymap tool-bar-map)))) + (when (listp zap-list) + ;; Zap some items which aren't relevant for this mode and take up space. + (dolist (key zap-list) + (define-key tool-bar-map (vector key) nil))) + (mapc (lambda (el) + (let ((command (car el)) + (icon (nth 1 el)) + (fmap (or (nth 2 el) default-map)) + (props (cdr (cdr (cdr el)))) ) + ;; command may stem from different from-maps: + (cond ((eq command 'gmm-ignore) + ;; The dummy `gmm-ignore', see `gmm-tool-bar-item' + ;; widget. Suppress tooltip by adding `:enable nil'. + (if (fboundp 'tool-bar-local-item) + (apply 'tool-bar-local-item icon nil nil + tool-bar-map :enable nil props) + ;; (tool-bar-local-item ICON DEF KEY MAP &rest PROPS) + ;; (tool-bar-add-item ICON DEF KEY &rest PROPS) + (apply 'tool-bar-add-item icon nil nil :enable nil props))) + ((equal fmap t) ;; Not a menu command + (if (fboundp 'tool-bar-local-item) + (apply 'tool-bar-local-item + icon command + (intern icon) ;; reuse icon or fmap here? + tool-bar-map props) + ;; Emacs 21 compatibility: + (apply 'tool-bar-add-item + icon command + (intern icon) + props))) + (t ;; A menu command + (if (fboundp 'tool-bar-local-item-from-menu) + (apply 'tool-bar-local-item-from-menu + ;; (apply 'tool-bar-local-item icon def key + ;; tool-bar-map props) + command icon tool-bar-map (symbol-value fmap) + props) + ;; Emacs 21 compatibility: + (apply 'tool-bar-add-item-from-menu + command icon (symbol-value fmap) + props)))) + t)) + (if (symbolp icon-list) + (eval icon-list) + icon-list)) + tool-bar-map)) + +;; WARNING: The following is subject to change. Don't rely on it yet. + +;; From MH-E without modifications: + +(defmacro gmm-defun-compat (name function arg-list &rest body) + "Create function NAME. +If FUNCTION exists, then NAME becomes an alias for FUNCTION. +Otherwise, create function NAME with ARG-LIST and BODY." + (let ((defined-p (fboundp function))) + (if defined-p + `(defalias ',name ',function) + `(defun ,name ,arg-list ,@body)))) + +(gmm-defun-compat gmm-image-search-load-path + image-search-load-path (file &optional path) + "Emacs 21 and XEmacs don't have `image-search-load-path'. +This function returns nil on those systems." + nil) + +;; From MH-E with modifications: + +;; Don't use `gmm-defun-compat' until API changes in +;; `image-load-path-for-library' in Emacs CVS are completed. + +(defun gmm-image-load-path-for-library (library image &optional path no-error) + "Return a suitable search path for images relative to LIBRARY. + +First it searches for IMAGE in `image-load-path' (excluding +\"`data-directory'/images\") and `load-path', followed by a path +suitable for LIBRARY, which includes \"../../etc/images\" and +\"../etc/images\" relative to the library file itself, and then +in \"`data-directory'/images\". + +Then this function returns a list of directories which contains +first the directory in which IMAGE was found, followed by the +value of `load-path'. If PATH is given, it is used instead of +`load-path'. + +If NO-ERROR is non-nil and a suitable path can't be found, don't +signal an error. Instead, return a list of directories as before, +except that nil appears in place of the image directory. + +Here is an example that uses a common idiom to provide +compatibility with versions of Emacs that lack the variable +`image-load-path': + + ;; Shush compiler. + (defvar image-load-path) + + (let* ((load-path (image-load-path-for-library \"mh-e\" \"mh-logo.xpm\")) + (image-load-path (cons (car load-path) + (when (boundp 'image-load-path) + image-load-path)))) + (mh-tool-bar-folder-buttons-init))" + (unless library (error "No library specified")) + (unless image (error "No image specified")) + (let (image-directory image-directory-load-path) + ;; Check for images in image-load-path or load-path. + (let ((img image) + (dir (or + ;; Images in image-load-path. + (gmm-image-search-load-path image) ;; "gmm-" prefix! + ;; Images in load-path. + (locate-library image))) + parent) + ;; Since the image might be in a nested directory (for + ;; example, mail/attach.pbm), adjust `image-directory' + ;; accordingly. + (when dir + (setq dir (file-name-directory dir)) + (while (setq parent (file-name-directory img)) + (setq img (directory-file-name parent) + dir (expand-file-name "../" dir)))) + (setq image-directory-load-path dir)) + + ;; If `image-directory-load-path' isn't Emacs' image directory, + ;; it's probably a user preference, so use it. Then use a + ;; relative setting if possible; otherwise, use + ;; `image-directory-load-path'. + (cond + ;; User-modified image-load-path? + ((and image-directory-load-path + (not (equal image-directory-load-path + (file-name-as-directory + (expand-file-name "images" data-directory))))) + (setq image-directory image-directory-load-path)) + ;; Try relative setting. + ((let (library-name d1ei d2ei) + ;; First, find library in the load-path. + (setq library-name (locate-library library)) + (if (not library-name) + (error "Cannot find library %s in load-path" library)) + ;; And then set image-directory relative to that. + (setq + ;; Go down 2 levels. + d2ei (file-name-as-directory + (expand-file-name + (concat (file-name-directory library-name) "../../etc/images"))) + ;; Go down 1 level. + d1ei (file-name-as-directory + (expand-file-name + (concat (file-name-directory library-name) "../etc/images")))) + (setq image-directory + ;; Set it to nil if image is not found. + (cond ((file-exists-p (expand-file-name image d2ei)) d2ei) + ((file-exists-p (expand-file-name image d1ei)) d1ei))))) + ;; Use Emacs' image directory. + (image-directory-load-path + (setq image-directory image-directory-load-path)) + (no-error + (message "Could not find image %s for library %s" image library)) + (t + (error "Could not find image %s for library %s" image library))) + + ;; Return an augmented `path' or `load-path'. + (nconc (list image-directory) + (delete image-directory (copy-sequence (or path load-path)))))) + +(defun gmm-customize-mode (&optional mode) + "Customize customization group for MODE. +If mode is nil, use `major-mode' of the curent buffer." + (interactive) + (customize-group + (or mode + (intern (let ((mode (symbol-name major-mode))) + (string-match "^\\(.+\\)-mode$" mode) + (match-string 1 mode)))))) + +(provide 'gmm-utils) + +;; arch-tag: e0b60920-2ce6-40c1-bfc0-cadbbe26b602 +;;; gmm-utils.el ends here diff --git a/lisp/gnus-agent.el b/lisp/gnus-agent.el index c33fac7..b6220c7 100644 --- a/lisp/gnus-agent.el +++ b/lisp/gnus-agent.el @@ -1,6 +1,7 @@ ;;; gnus-agent.el --- unplugged support for Gnus -;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -117,6 +118,8 @@ If nil, only read articles will be expired." (defcustom gnus-agent-synchronize-flags nil "Indicate if flags are synchronized when you plug in. If this is `ask' the hook will query the user." + ;; If the default switches to something else than nil, then the function + ;; should be fixed not be exceedingly slow. See 2005-09-20 ChangeLog entry. :version "21.1" :type '(choice (const :tag "Always" t) (const :tag "Never" nil) @@ -201,7 +204,7 @@ queue. Otherwise, queue if and only if unplugged." :group 'gnus-agent :type '(radio (const :format "Always" always) (const :format "Never" nil) - (const :format "When plugged" t))) + (const :format "When unplugged" t))) (defcustom gnus-agent-prompt-send-queue nil "If non-nil, `gnus-group-send-queue' will prompt if called when @@ -210,6 +213,18 @@ unplugged." :group 'gnus-agent :type 'boolean) +(defcustom gnus-agent-article-alist-save-format 1 + "Indicates whether to use compression(2), versus no +compression(1), when writing agentview files. The compressed +files do save space but load times are 6-7 times higher. A group +must be opened then closed for the agentview to be updated using +the new format." + ;; Wouldn't symbols instead numbers be nicer? --rsteib + :version "22.1" + :group 'gnus-agent + :type '(radio (const :format "Compressed" 2) + (const :format "Uncompressed" 1))) + ;;; Internal variables (defvar gnus-agent-history-buffers nil) @@ -575,7 +590,8 @@ manipulated as follows: (if (and (fboundp 'propertize) (fboundp 'make-mode-line-mouse-map)) (propertize string 'local-map - (make-mode-line-mouse-map mouse-button mouse-func)) + (make-mode-line-mouse-map mouse-button mouse-func) + 'mouse-face 'mode-line-highlight) string)) (defun gnus-agent-toggle-plugged (set-to) @@ -823,7 +839,7 @@ be a select method." (save-excursion (dolist (gnus-command-method (gnus-agent-covered-methods)) (when (and (file-exists-p (gnus-agent-lib-file "flags")) - (not (eq (gnus-server-status gnus-command-method) 'offline))) + (eq (gnus-server-status gnus-command-method) 'ok)) (gnus-agent-possibly-synchronize-flags-server gnus-command-method))))) (defun gnus-agent-synchronize-flags-server (method) @@ -868,9 +884,11 @@ be a select method." ;;;###autoload (defun gnus-agent-rename-group (old-group new-group) - "Rename fully-qualified OLD-GROUP as NEW-GROUP. Always updates the agent, even when -disabled, as the old agent files would corrupt gnus when the agent was -next enabled. Depends upon the caller to determine whether group renaming is supported." + "Rename fully-qualified OLD-GROUP as NEW-GROUP. +Always updates the agent, even when disabled, as the old agent +files would corrupt gnus when the agent was next enabled. +Depends upon the caller to determine whether group renaming is +supported." (let* ((old-command-method (gnus-find-method-for-group old-group)) (old-path (directory-file-name (let (gnus-command-method old-command-method) @@ -898,9 +916,11 @@ next enabled. Depends upon the caller to determine whether group renaming is sup ;;;###autoload (defun gnus-agent-delete-group (group) - "Delete fully-qualified GROUP. Always updates the agent, even when -disabled, as the old agent files would corrupt gnus when the agent was -next enabled. Depends upon the caller to determine whether group deletion is supported." + "Delete fully-qualified GROUP. +Always updates the agent, even when disabled, as the old agent +files would corrupt gnus when the agent was next enabled. +Depends upon the caller to determine whether group deletion is +supported." (let* ((command-method (gnus-find-method-for-group group)) (path (directory-file-name (let (gnus-command-method command-method) @@ -1561,7 +1581,7 @@ downloaded into the agent." (while (looking-at "\\([^: \n]+\\):\\([0-9]+\\) *") (push (cons (buffer-substring (match-beginning 1) (match-end 1)) - (string-to-int + (string-to-number (buffer-substring (match-beginning 2) (match-end 2)))) crosses) @@ -1851,7 +1871,7 @@ article numbers will be returned." (defsubst gnus-agent-read-article-number () "Reads the article number at point. Returns nil when a valid article number can not be read." - ;; It is unfortunite but the read function quietly overflows + ;; It is unfortunate but the read function quietly overflows ;; integer. As a result, I have to use string operations to test ;; for overflow BEFORE calling read. (when (looking-at "[0-9]+\t") @@ -1910,21 +1930,21 @@ doesn't exist, to valid the overview buffer." (gnus-agent-copy-nov-line (pop articles)) (ignore-errors - (while articles - (while (let ((art (read (current-buffer)))) - (cond ((< art (car articles)) - (forward-line 1) - t) - ((= art (car articles)) - (beginning-of-line) - (delete-region - (point) (progn (forward-line 1) (point))) - nil) - (t - (beginning-of-line) - nil)))) - - (gnus-agent-copy-nov-line (pop articles))))) + (while articles + (while (let ((art (read (current-buffer)))) + (cond ((< art (car articles)) + (forward-line 1) + t) + ((= art (car articles)) + (beginning-of-line) + (delete-region + (point) (progn (forward-line 1) (point))) + nil) + (t + (beginning-of-line) + nil)))) + + (gnus-agent-copy-nov-line (pop articles))))) (goto-char (point-max)) @@ -1940,23 +1960,39 @@ doesn't exist, to valid the overview buffer." (goto-char p)) (setq last (or last -134217728)) - (let (sort art) - (while (not (eobp)) - (setq art (gnus-agent-read-article-number)) - (cond ((not art) - ;; Bad art num - delete this line - (beginning-of-line) - (delete-region (point) (progn (forward-line 1) (point)))) - ((< art last) - ;; Art num out of order - enable sort - (setq sort t) - (forward-line 1)) - (t - ;; Good art num - (setq last art) - (forward-line 1)))) - (when sort - (sort-numeric-fields 1 (point-min) (point-max))))))) + (while (catch 'problems + (let (sort art) + (while (not (eobp)) + (setq art (gnus-agent-read-article-number)) + (cond ((not art) + ;; Bad art num - delete this line + (beginning-of-line) + (delete-region (point) (progn (forward-line 1) (point)))) + ((< art last) + ;; Art num out of order - enable sort + (setq sort t) + (forward-line 1)) + ((= art last) + ;; Bad repeat of art number - delete this line + (beginning-of-line) + (delete-region (point) (progn (forward-line 1) (point)))) + (t + ;; Good art num + (setq last art) + (forward-line 1)))) + (when sort + ;; something is seriously wrong as we simply shouldn't see out-of-order data. + ;; First, we'll fix the sort. + (sort-numeric-fields 1 (point-min) (point-max)) + + ;; but now we have to consider that we may have duplicate rows... + ;; so reset to beginning of file + (goto-char (point-min)) + (setq last -134217728) + + ;; and throw a code that restarts this scan + (throw 'problems t)) + nil)))))) ;; Keeps the compiler from warning about the free variable in ;; gnus-agent-read-agentview. @@ -1973,61 +2009,55 @@ doesn't exist, to valid the overview buffer." 'gnus-agent-file-loading-cache 'gnus-agent-read-agentview)))) -;; Save format may be either 1 or 2. Two is the new, compressed -;; format that is still being tested. Format 1 is uncompressed but -;; known to be reliable. -(defconst gnus-agent-article-alist-save-format 2) - (defun gnus-agent-read-agentview (file) "Load FILE and do a `read' there." (with-temp-buffer (condition-case nil - (progn - (nnheader-insert-file-contents file) - (goto-char (point-min)) - (let ((alist (read (current-buffer))) - (version (condition-case nil (read (current-buffer)) - (end-of-file 0))) - changed-version) - - (cond - ((< version 2) - (error "gnus-agent-read-agentview no longer supports version %d. Stop gnus, manually evaluate gnus-agent-convert-to-compressed-agentview, then restart gnus." version)) - ((= version 0) - (let ((inhibit-quit t) - entry) - (gnus-agent-open-history) - (set-buffer (gnus-agent-history-buffer)) - (goto-char (point-min)) - (while (not (eobp)) - (if (and (looking-at - "[^\t\n]+\t\\([0-9]+\\)\t\\([^ \n]+\\) \\([0-9]+\\)") - (string= (match-string 2) - gnus-agent-read-agentview) - (setq entry (assoc (string-to-number (match-string 3)) alist))) - (setcdr entry (string-to-number (match-string 1)))) - (forward-line 1)) - (gnus-agent-close-history) - (setq changed-version t))) - ((= version 1) - (setq changed-version (not (= 1 gnus-agent-article-alist-save-format)))) - ((= version 2) - (let (uncomp) - (mapcar - (lambda (comp-list) - (let ((state (car comp-list)) - (sequence (inline - (gnus-uncompress-range - (cdr comp-list))))) - (mapcar (lambda (article-id) - (setq uncomp (cons (cons article-id state) uncomp))) - sequence))) - alist) - (setq alist (sort uncomp 'car-less-than-car))))) - (when changed-version - (let ((gnus-agent-article-alist alist)) - (gnus-agent-save-alist gnus-agent-read-agentview))) - alist)) + (progn + (nnheader-insert-file-contents file) + (goto-char (point-min)) + (let ((alist (read (current-buffer))) + (version (condition-case nil (read (current-buffer)) + (end-of-file 0))) + changed-version) + + (cond + ((= version 0) + (let ((inhibit-quit t) + entry) + (gnus-agent-open-history) + (set-buffer (gnus-agent-history-buffer)) + (goto-char (point-min)) + (while (not (eobp)) + (if (and (looking-at + "[^\t\n]+\t\\([0-9]+\\)\t\\([^ \n]+\\) \\([0-9]+\\)") + (string= (match-string 2) + gnus-agent-read-agentview) + (setq entry (assoc (string-to-number (match-string 3)) alist))) + (setcdr entry (string-to-number (match-string 1)))) + (forward-line 1)) + (gnus-agent-close-history) + (setq changed-version t))) + ((= version 1) + (setq changed-version (not (= 1 gnus-agent-article-alist-save-format)))) + ((= version 2) + (let (uncomp) + (mapcar + (lambda (comp-list) + (let ((state (car comp-list)) + (sequence (inline + (gnus-uncompress-range + (cdr comp-list))))) + (mapcar (lambda (article-id) + (setq uncomp (cons (cons article-id state) uncomp))) + sequence))) + alist) + (setq alist (sort uncomp 'car-less-than-car))) + (setq changed-version (not (= 2 gnus-agent-article-alist-save-format))))) + (when changed-version + (let ((gnus-agent-article-alist alist)) + (gnus-agent-save-alist gnus-agent-read-agentview))) + alist)) (file-error nil)))) (defun gnus-agent-save-alist (group &optional articles state) @@ -2139,7 +2169,7 @@ modified) original contents, they are first saved to their own file." ;; NOTE: The '+ 0' ensure that min and max are both numerics. (set group (cons (+ 0 min) (+ 0 max)))) (error - (gnus-message 3 "Warning - invalid agent local: %s on line %d: " + (gnus-message 3 "Warning - invalid agent local: %s on line %d: %s" file line (error-message-string err)))) (forward-line 1) (setq line (1+ line)))) @@ -2170,13 +2200,14 @@ modified) original contents, they are first saved to their own file." ((member (symbol-name symbol) '("+dirty" "+method")) nil) (t - (prin1 symbol) (let ((range (symbol-value symbol))) - (princ " ") - (princ (car range)) - (princ " ") - (princ (cdr range)) - (princ "\n"))))) + (when range + (prin1 symbol) + (princ " ") + (princ (car range)) + (princ " ") + (princ (cdr range)) + (princ "\n")))))) my-obarray)))))))) (defun gnus-agent-get-local (group &optional gmane method) @@ -2586,7 +2617,7 @@ The following commands are available: (buffer-disable-undo) (setq truncate-lines t) (setq buffer-read-only t) - (gnus-run-hooks 'gnus-category-mode-hook)) + (gnus-run-mode-hooks 'gnus-category-mode-hook)) (defalias 'gnus-category-position-point 'gnus-goto-colon) @@ -2967,7 +2998,7 @@ FORCE is equivalent to setting the expiration predicates to true." (if (or (not (eq articles t)) (yes-or-no-p (concat "Are you sure that you want to " - "expire all articles in " group "."))) + "expire all articles in " group "? "))) (let ((gnus-command-method (gnus-find-method-for-group group)) (overview (gnus-get-buffer-create " *expire overview*")) orig) @@ -3376,7 +3407,7 @@ FORCE is equivalent to setting the expiration predicates to true." (gnus-agent-expire-group group articles force) (if (or (not (eq articles t)) (yes-or-no-p "Are you sure that you want to expire all \ -articles in every agentized group.")) +articles in every agentized group? ")) (let ((methods (gnus-agent-covered-methods)) ;; Bind gnus-agent-expire-current-dirs to enable tracking ;; of agent directories. @@ -3774,7 +3805,7 @@ If REREAD is not nil, downloaded articles are marked as unread." (dir (file-name-directory file)) point (downloaded (if (file-exists-p dir) - (sort (mapcar (lambda (name) (string-to-int name)) + (sort (mapcar (lambda (name) (string-to-number name)) (directory-files dir nil "^[0-9]+$" t)) '>) (progn (gnus-make-directory dir) nil))) diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index c5a4e54..fe2a992 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -1,6 +1,7 @@ ;;; gnus-art.el --- article mode commands for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -28,7 +29,8 @@ (eval-when-compile (require 'cl) - (defvar tool-bar-map)) + (defvar tool-bar-map) + (defvar w3m-minor-mode-map)) (require 'gnus) ;; Avoid the "Recursive load suspected" error in Emacs 21.1. @@ -51,6 +53,8 @@ (autoload 'gnus-button-reply "gnus-msg" nil t) (autoload 'parse-time-string "parse-time" nil nil) (autoload 'ansi-color-apply-on-region "ansi-color") +(autoload 'mm-url-insert-file-contents-external "mm-url") +(autoload 'mm-extern-cache-contents "mm-extern") (defgroup gnus-article nil "Article display." @@ -227,7 +231,9 @@ only of boring text. Boring text is controlled by This can also be a list of regexps. In that case, it will be checked from head to tail looking for a separator. Searches will be done from the end of the buffer." - :type '(repeat string) + :type '(choice :format "%{%t%}: %[Value Menu%]\n%v" + (regexp) + (repeat :tag "List of regexp" regexp)) :group 'gnus-article-signature) (defcustom gnus-signature-limit nil @@ -240,7 +246,8 @@ no signature in the buffer. If it is a string, it will be used as a regexp. If it matches, the text in question is not a signature. This can also be a list of the above values." - :type '(choice (integer :value 200) + :type '(choice (const nil) + (integer :value 200) (number :value 4.0) (function :value fun) (regexp :value ".*")) @@ -373,7 +380,13 @@ advertisements. For example: (or (nth 4 spec) 3) (intern (format "gnus-emphasis-%s" (nth 2 spec))))) types)) - '(("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)" + '(;; I've never seen anyone use this strikethru convention whereas I've + ;; several times seen it triggered by normal text. --Stef + ;; Miles suggests that this form is sometimes used but for italics, + ;; so maybe we should map it to `italic'. + ;; ("\\(\\s-\\|^\\)\\(-\\(\\(\\w\\|-[^-]\\)+\\)-\\)\\(\\s-\\|[?!.,;]\\)" + ;; 2 3 gnus-emphasis-strikethru) + ("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)" 2 3 gnus-emphasis-underline)))) "*Alist that says how to fontify certain phrases. Each item looks like this: @@ -485,9 +498,6 @@ be fed to `format-time-string'." :link '(custom-manual "(gnus)Article Date") :group 'gnus-article-washing) -(eval-and-compile - (autoload 'mail-extract-address-components "mail-extr")) - (defcustom gnus-save-all-headers t "*If non-nil, don't remove any headers before saving." :group 'gnus-article-saving @@ -535,7 +545,8 @@ Gnus provides the following functions: (function-item gnus-summary-save-in-file) (function-item gnus-summary-save-body-in-file) (function-item gnus-summary-save-in-vm) - (function-item gnus-summary-write-to-file))) + (function-item gnus-summary-write-to-file) + (function))) (defcustom gnus-rmail-save-name 'gnus-plain-save-name "A function generating a file name to save articles in Rmail format. @@ -641,7 +652,12 @@ Each element is a regular expression." (make-obsolete-variable 'gnus-article-hide-pgp-hook "This variable is obsolete in Gnus 5.10.") -(defcustom gnus-article-button-face 'bold +(defface gnus-button + '((t (:weight bold))) + "Face used for highlighting a button in the article buffer." + :group 'gnus-article-buttons) + +(defcustom gnus-article-button-face 'gnus-button "Face used for highlighting buttons in the article buffer. An article button is a piece of text that you can activate by pressing @@ -657,21 +673,23 @@ above them." :type 'face :group 'gnus-article-buttons) -(defcustom gnus-signature-face 'gnus-signature-face +(defcustom gnus-signature-face 'gnus-signature "Face used for highlighting a signature in the article buffer. -Obsolete; use the face `gnus-signature-face' for customizations instead." +Obsolete; use the face `gnus-signature' for customizations instead." :type 'face :group 'gnus-article-highlight :group 'gnus-article-signature) -(defface gnus-signature-face +(defface gnus-signature '((t (:italic t))) "Face used for highlighting a signature in the article buffer." :group 'gnus-article-highlight :group 'gnus-article-signature) +;; backward-compatibility alias +(put 'gnus-signature-face 'face-alias 'gnus-signature) -(defface gnus-header-from-face +(defface gnus-header-from '((((class color) (background dark)) (:foreground "spring green")) @@ -683,8 +701,10 @@ Obsolete; use the face `gnus-signature-face' for customizations instead." "Face used for displaying from headers." :group 'gnus-article-headers :group 'gnus-article-highlight) +;; backward-compatibility alias +(put 'gnus-header-from-face 'face-alias 'gnus-header-from) -(defface gnus-header-subject-face +(defface gnus-header-subject '((((class color) (background dark)) (:foreground "SeaGreen3")) @@ -696,8 +716,10 @@ Obsolete; use the face `gnus-signature-face' for customizations instead." "Face used for displaying subject headers." :group 'gnus-article-headers :group 'gnus-article-highlight) +;; backward-compatibility alias +(put 'gnus-header-subject-face 'face-alias 'gnus-header-subject) -(defface gnus-header-newsgroups-face +(defface gnus-header-newsgroups '((((class color) (background dark)) (:foreground "yellow" :italic t)) @@ -711,8 +733,10 @@ In the default setup this face is only used for crossposted articles." :group 'gnus-article-headers :group 'gnus-article-highlight) +;; backward-compatibility alias +(put 'gnus-header-newsgroups-face 'face-alias 'gnus-header-newsgroups) -(defface gnus-header-name-face +(defface gnus-header-name '((((class color) (background dark)) (:foreground "SeaGreen")) @@ -724,8 +748,10 @@ articles." "Face used for displaying header names." :group 'gnus-article-headers :group 'gnus-article-highlight) +;; backward-compatibility alias +(put 'gnus-header-name-face 'face-alias 'gnus-header-name) -(defface gnus-header-content-face +(defface gnus-header-content '((((class color) (background dark)) (:foreground "forest green" :italic t)) @@ -736,12 +762,14 @@ articles." (:italic t))) "Face used for displaying header content." :group 'gnus-article-headers :group 'gnus-article-highlight) +;; backward-compatibility alias +(put 'gnus-header-content-face 'face-alias 'gnus-header-content) (defcustom gnus-header-face-alist - '(("From" nil gnus-header-from-face) - ("Subject" nil gnus-header-subject-face) - ("Newsgroups:.*," nil gnus-header-newsgroups-face) - ("" gnus-header-name-face gnus-header-content-face)) + '(("From" nil gnus-header-from) + ("Subject" nil gnus-header-subject) + ("Newsgroups:.*," nil gnus-header-newsgroups) + ("" gnus-header-name gnus-header-content)) "*Controls highlighting of article headers. An alist of the form (HEADER NAME CONTENT). @@ -818,7 +846,9 @@ This variable is only used when `gnus-inhibit-mime-unbuttonizing' is nil." "List of MIME types that should be given buttons when rendered inline. If set, this variable overrides `gnus-unbuttonized-mime-types'. To see e.g. security buttons you could set this to -`(\"multipart/signed\")'. +`(\"multipart/signed\")'. You could also add \"multipart/alternative\" to +this list to display radio buttons that allow you to choose one of two +media types those mails include. See also `mm-discouraged-alternatives'. This variable is only used when `gnus-inhibit-mime-unbuttonizing' is nil." :version "22.1" :group 'gnus-article-mime @@ -867,7 +897,8 @@ see http://www.cs.indiana.edu/picons/ftp/index.html" This is meant for people who want to do something automatic based on parts -- for instance, adding Vcard info to a database." :group 'gnus-article-mime - :type 'function) + :type '(choice (const nil) + function)) (defcustom gnus-mime-multipart-functions nil "An alist of MIME types to functions to display them." @@ -904,6 +935,7 @@ used." (defcustom gnus-mime-action-alist '(("save to file" . gnus-mime-save-part) ("save and strip" . gnus-mime-save-part-and-strip) + ("replace with file" . gnus-mime-replace-part) ("delete part" . gnus-mime-delete-part) ("display as text" . gnus-mime-inline-part) ("view the part" . gnus-mime-view-part) @@ -918,6 +950,19 @@ used." :type '(repeat (cons (string :tag "name") (function)))) +(defcustom gnus-auto-select-part 1 + "Advance to next MIME part when deleting or stripping parts. + +When 0, point will be placed on the same part as before. When +positive (negative), move point forward (backwards) this many +parts. When nil, redisplay article." + :version "23.0" ;; No Gnus + :group 'gnus-article-mime + :type '(choice (const nil :tag "Redisplay article.") + (const 1 :tag "Next part.") + (const 0 :tag "Current part.") + integer)) + ;;; ;;; The treatment variables ;;; @@ -929,6 +974,7 @@ used." '(choice (const :tag "Off" nil) (const :tag "On" t) (const :tag "Header" head) + (const :tag "First" first) (const :tag "Last" last) (integer :tag "Less") (repeat :tag "Groups" regexp) @@ -946,8 +992,8 @@ used." (defcustom gnus-treat-highlight-signature '(or t (typep "text/x-vcard")) "Highlight the signature. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles'." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -955,8 +1001,8 @@ 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 Info node `(gnus)Customizing Articles'." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -964,8 +1010,8 @@ See Info node `(gnus)Customizing Articles'." (defcustom gnus-treat-buttonize-head 'head "Add buttons to the head. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-head-custom) @@ -976,8 +1022,8 @@ See Info node `(gnus)Customizing Articles' for details." (featurep 'xemacs)) 50000) "Emphasize text. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -985,8 +1031,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-strip-cr nil "Remove carriage returns. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -994,8 +1040,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-unsplit-urls nil "Remove newlines from within URLs. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1003,8 +1049,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-leading-whitespace nil "Remove leading whitespace in headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1012,56 +1058,56 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-hide-headers 'head "Hide headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1072,8 +1118,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-strip-pem nil "Strip PEM signatures. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -1081,16 +1127,16 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-strip-banner t "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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-head-custom) @@ -1098,8 +1144,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-highlight-citation t "Highlight cited text. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -1107,24 +1153,24 @@ See Info node `(gnus)Customizing Articles' 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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1132,24 +1178,24 @@ See Info node `(gnus)Customizing Articles' for details." (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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1158,16 +1204,16 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-date-user-defined nil "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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1175,32 +1221,37 @@ See Info node `(gnus)Customizing Articles' 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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'. + +When set to t, it also strips trailing blanks in all MIME parts. +Consider to use `last' instead." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'. + +When set to t, it also strips trailing blanks in all MIME parts." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1208,8 +1259,8 @@ See Info node `(gnus)Customizing Articles' for details." (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." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1217,8 +1268,8 @@ See Info node `(gnus)Customizing Articles' for details." (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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1226,8 +1277,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-overstrike t "Treat overstrike highlighting. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -1235,8 +1286,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-ansi-sequences (if (locate-library "ansi-color") t) "Treat ANSI SGR control sequences. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :type gnus-article-treat-custom) @@ -1254,9 +1305,9 @@ See Info node `(gnus)Customizing Articles' for details." (featurep 'xface))) 'head) "Display X-Face headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)X-Face' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)X-Face' for details." :group 'gnus-article-treat :version "21.1" :link '(custom-manual "(gnus)Customizing Articles") @@ -1289,9 +1340,9 @@ See Info node `(gnus)Customizing Articles' and Info node (featurep 'png))) 'head) "Display Face headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)X-Face' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)X-Face' for details." :group 'gnus-article-treat :version "22.1" :link '(custom-manual "(gnus)Customizing Articles") @@ -1306,9 +1357,9 @@ See Info node `(gnus)Customizing Articles' and Info node (image-type-available-p 'pbm))) t nil) "Display smileys. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)Smileys' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)Smileys' for details." :group 'gnus-article-treat :version "21.1" :link '(custom-manual "(gnus)Customizing Articles") @@ -1321,9 +1372,9 @@ See Info node `(gnus)Customizing Articles' and Info node (gnus-picons-installed-p)) 'head nil) "Display picons in the From header. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)Picons' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)Picons' for details." :version "22.1" :group 'gnus-article-treat :group 'gnus-picon @@ -1337,9 +1388,9 @@ See Info node `(gnus)Customizing Articles' and Info node (gnus-picons-installed-p)) 'head nil) "Display picons in To and Cc headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)Picons' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)Picons' for details." :version "22.1" :group 'gnus-article-treat :group 'gnus-picon @@ -1353,9 +1404,9 @@ See Info node `(gnus)Customizing Articles' and Info node (gnus-picons-installed-p)) 'head nil) "Display picons in the Newsgroups and Followup-To headers. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' and Info node -`(gnus)Picons' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles' and Info +node `(gnus)Picons' for details." :version "22.1" :group 'gnus-article-treat :group 'gnus-picon @@ -1380,8 +1431,8 @@ See Info node `(gnus)Customizing Articles' 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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1389,8 +1440,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-wash-html nil "Format as HTML. -Valid values are nil, t, `head', `last', an integer or a predicate. -See Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1398,16 +1449,16 @@ See Info node `(gnus)Customizing Articles' 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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") :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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1415,8 +1466,8 @@ See Info node `(gnus)Customizing Articles' for details." (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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "21.1" :group 'gnus-article-treat :link '(custom-manual "(gnus)Customizing Articles") @@ -1425,8 +1476,8 @@ See Info node `(gnus)Customizing Articles' for details." (defcustom gnus-treat-x-pgp-sig nil "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 Info node `(gnus)Customizing Articles' for details." +Valid values are nil, t, `head', `first', `last', an integer or a +predicate. See Info node `(gnus)Customizing Articles'." :version "22.1" :group 'gnus-article-treat :group 'mime-security @@ -1495,10 +1546,10 @@ This requires GNU Libidn, and by default only enabled if it is found." (gnus-treat-date-ut gnus-article-date-ut) (gnus-treat-date-local gnus-article-date-local) (gnus-treat-date-english gnus-article-date-english) - (gnus-treat-date-lapsed gnus-article-date-lapsed) (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-date-lapsed gnus-article-date-lapsed) (gnus-treat-display-x-face gnus-article-display-x-face) (gnus-treat-display-face gnus-article-display-face) (gnus-treat-hide-headers gnus-article-maybe-hide-headers) @@ -1634,10 +1685,24 @@ Initialized from `text-mode-syntax-table.") "Delete text of TYPE in the current buffer." (save-excursion (let ((b (point-min))) - (while (setq b (text-property-any b (point-max) 'article-type type)) - (delete-region - b (or (text-property-not-all b (point-max) 'article-type type) - (point-max))))))) + (if (eq type 'multipart) + ;; Remove MIME buttons associated with multipart/alternative parts. + (progn + (goto-char b) + (while (if (get-text-property (point) 'gnus-part) + (setq b (point)) + (when (setq b (next-single-property-change (point) + 'gnus-part)) + (goto-char b) + t)) + (end-of-line) + (skip-chars-forward "\n") + (when (eq (get-text-property b 'article-type) 'multipart) + (delete-region b (point))))) + (while (setq b (text-property-any b (point-max) 'article-type type)) + (delete-region + b (or (text-property-not-all b (point-max) 'article-type type) + (point-max)))))))) (defun gnus-article-delete-invisible-text () "Delete all invisible text in the current buffer." @@ -2147,33 +2212,33 @@ unfolded." ;; read-only. (if (and wash-face-p (memq 'face gnus-article-wash-types)) (gnus-delete-images 'face) - (let (face faces) - (save-excursion + (let (face faces from) + (save-current-buffer (when (and wash-face-p - (progn - (goto-char (point-min)) - (not (re-search-forward "^Face:[\t ]*" nil t))) - (gnus-buffer-live-p gnus-original-article-buffer)) + (gnus-buffer-live-p gnus-original-article-buffer) + (not (re-search-forward "^Face:[\t ]*" nil t))) (set-buffer gnus-original-article-buffer)) (save-restriction (mail-narrow-to-head) (while (gnus-article-goto-header "Face") - (setq faces (nconc faces (list (mail-header-field-value))))))) - (dolist (face faces) - (let ((png (gnus-convert-face-to-png face)) - image) - (when png - (setq image - (apply 'gnus-create-image png 'png t - (cdr (assq 'png gnus-face-properties-alist)))) - (gnus-article-goto-header "from") - (when (bobp) - (insert "From: [no `from' set]\n") - (forward-char -17)) - (gnus-add-wash-type 'face) - (gnus-add-image 'face image) - (gnus-put-image image nil 'face)))))) - ))) + (push (mail-header-field-value) faces)))) + (when faces + (goto-char (point-min)) + (let ((from (gnus-article-goto-header "from")) + png image) + (unless from + (insert "From:") + (setq from (point)) + (insert "[no `from' set]\n")) + (while faces + (when (setq png (gnus-convert-face-to-png (pop faces))) + (setq image + (apply 'gnus-create-image png 'png t + (cdr (assq 'png gnus-face-properties-alist)))) + (goto-char from) + (gnus-add-wash-type 'face) + (gnus-add-image 'face image) + (gnus-put-image image nil 'face)))))))))) (defun article-display-x-face (&optional force) "Look for an X-Face header and display it if present." @@ -2190,13 +2255,10 @@ unfolded." (gnus-delete-images 'xface) ;; Display X-Faces. (let (x-faces from face) - (save-excursion + (save-current-buffer (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)) + (gnus-buffer-live-p gnus-original-article-buffer) + (not (re-search-forward "^X-Face:[\t ]*" nil t))) ;; If type `W f', use gnus-original-article-buffer, ;; otherwise use the current buffer because displaying ;; RFC822 parts calls this function too. @@ -2210,34 +2272,36 @@ unfolded." ;; 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. - (cond ((stringp 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"))) - ((functionp gnus-article-x-face-command) - ;; The command is a lisp function, so we call it. - (funcall gnus-article-x-face-command face)) - (t - (error "%s is not a function" - gnus-article-x-face-command))))))))) + (when (and x-faces + gnus-article-x-face-command + (or force + ;; Check whether this face is censored. + (not gnus-article-x-face-too-ugly) + (and from + (not (string-match gnus-article-x-face-too-ugly + from))))) + (while (setq face (pop x-faces)) + ;; We display the face. + (cond ((stringp 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)) + (gnus-set-process-query-on-exit-flag + (start-process + "article-x-face" nil shell-file-name + shell-command-switch gnus-article-x-face-command) + nil) + (with-temp-buffer + (insert face) + (process-send-region "article-x-face" + (point-min) (point-max))) + (process-send-eof "article-x-face"))) + ((functionp gnus-article-x-face-command) + ;; The command is a lisp function, so we call it. + (funcall gnus-article-x-face-command face)) + (t + (error "%s is not a function" + gnus-article-x-face-command)))))))))) (defun article-decode-mime-words () "Decode all MIME-encoded words in the article." @@ -2263,38 +2327,37 @@ If PROMPT (the prefix), prompt for a coding system to use." (error)) gnus-newsgroup-ignored-charsets)) ct cte ctl charset format) - (save-excursion - (save-restriction - (article-narrow-to-head) - (setq ct (message-fetch-field "Content-Type" t) - cte (message-fetch-field "Content-Transfer-Encoding" t) - ctl (and ct (ignore-errors - (mail-header-parse-content-type ct))) - charset (cond - (prompt - (mm-read-coding-system "Charset to decode: ")) - (ctl - (mail-content-type-get ctl 'charset))) - format (and ctl (mail-content-type-get ctl 'format))) - (when cte - (setq cte (mail-header-strip cte))) - (if (and ctl (not (string-match "/" (car ctl)))) - (setq ctl nil)) - (goto-char (point-max))) - (forward-line 1) - (save-restriction - (narrow-to-region (point) (point-max)) - (when (and (eq mail-parse-charset 'gnus-decoded) - (eq (mm-body-7-or-8) '8bit)) - ;; The text code could have been decoded. - (setq charset mail-parse-charset)) - (when (and (or (not ctl) - (equal (car ctl) "text/plain")) - (not format)) ;; article with format will decode later. - (mm-decode-body - charset (and cte (intern (downcase - (gnus-strip-whitespace cte)))) - (car ctl))))))) + (save-excursion + (save-restriction + (article-narrow-to-head) + (setq ct (message-fetch-field "Content-Type" t) + cte (message-fetch-field "Content-Transfer-Encoding" t) + ctl (and ct (mail-header-parse-content-type ct)) + charset (cond + (prompt + (mm-read-coding-system "Charset to decode: ")) + (ctl + (mail-content-type-get ctl 'charset))) + format (and ctl (mail-content-type-get ctl 'format))) + (when cte + (setq cte (mail-header-strip cte))) + (if (and ctl (not (string-match "/" (car ctl)))) + (setq ctl nil)) + (goto-char (point-max))) + (forward-line 1) + (save-restriction + (narrow-to-region (point) (point-max)) + (when (and (eq mail-parse-charset 'gnus-decoded) + (eq (mm-body-7-or-8) '8bit)) + ;; The text code could have been decoded. + (setq charset mail-parse-charset)) + (when (and (or (not ctl) + (equal (car ctl) "text/plain")) + (not format)) ;; article with format will decode later. + (mm-decode-body + charset (and cte (intern (downcase + (gnus-strip-whitespace cte)))) + (car ctl))))))) (defun article-decode-encoded-words () "Remove encoded-word encoding from headers." @@ -2353,20 +2416,22 @@ If PROMPT (the prefix), prompt for a coding system to use." (autoload 'idna-to-unicode "idna") (defun article-decode-idna-rhs () - "Decode IDNA strings in RHS in From:, To: and Cc: headers in current buffer." + "Decode IDNA strings in RHS in various headers in current buffer. +The following headers are decoded: From:, To:, Cc:, Reply-To:, +Mail-Reply-To: and Mail-Followup-To:." (when gnus-use-idna (save-restriction (let ((inhibit-point-motion-hooks t) (inhibit-read-only t)) (article-narrow-to-head) (goto-char (point-min)) - (while (re-search-forward "@.*\\(xn--[-A-Za-z0-9.]*\\)[ \t\n\r,>]" nil t) + (while (re-search-forward "@[^ \t\n\r,>]*\\(xn--[-A-Za-z0-9.]*\\)[ \t\n\r,>]" nil t) (let (ace unicode) (when (save-match-data (and (setq ace (match-string 1)) (save-excursion (and (re-search-backward "^[^ \t]" nil t) - (looking-at "From\\|To\\|Cc"))) + (looking-at "From\\|To\\|Cc\\|Reply-To\\|Mail-Reply-To\\|Mail-Followup-To"))) (setq unicode (idna-to-unicode ace)))) (unless (string= ace unicode) (replace-match unicode nil nil nil 1))))))))) @@ -2384,9 +2449,7 @@ If READ-CHARSET, ask for a coding system." (setq type (gnus-fetch-field "content-transfer-encoding")) (let* ((ct (gnus-fetch-field "content-type")) - (ctl (and ct - (ignore-errors - (mail-header-parse-content-type ct))))) + (ctl (and ct (mail-header-parse-content-type ct)))) (setq charset (and ctl (mail-content-type-get ctl 'charset))) (if (stringp charset) @@ -2414,9 +2477,7 @@ If READ-CHARSET, ask for a coding system." (setq type (gnus-fetch-field "content-transfer-encoding")) (let* ((ct (gnus-fetch-field "content-type")) - (ctl (and ct - (ignore-errors - (mail-header-parse-content-type ct))))) + (ctl (and ct (mail-header-parse-content-type ct)))) (setq charset (and ctl (mail-content-type-get ctl 'charset))) (if (stringp charset) @@ -2461,25 +2522,34 @@ If READ-CHARSET, ask for a coding system." (defun article-wash-html (&optional read-charset) "Format an HTML article. -If READ-CHARSET, ask for a coding system." +If READ-CHARSET, ask for a coding system. If it is a number, the +charset defined in `gnus-summary-show-article-charset-alist' is used." (interactive "P") (save-excursion (let ((inhibit-read-only t) charset) - (when (gnus-buffer-live-p gnus-original-article-buffer) - (with-current-buffer gnus-original-article-buffer - (let* ((ct (gnus-fetch-field "content-type")) - (ctl (and ct - (ignore-errors - (mail-header-parse-content-type ct))))) - (setq charset (and ctl - (mail-content-type-get ctl 'charset))) - (when (stringp charset) - (setq charset (intern (downcase charset))))))) - (when read-charset - (setq charset (mm-read-coding-system "Charset: " charset))) - (unless charset - (setq charset gnus-newsgroup-charset)) + (if read-charset + (if (or (and (numberp read-charset) + (setq charset + (cdr + (assq read-charset + gnus-summary-show-article-charset-alist)))) + (setq charset (mm-read-coding-system "Charset: "))) + (let ((gnus-summary-show-article-charset-alist + (list (cons 1 charset)))) + (with-current-buffer gnus-summary-buffer + (gnus-summary-show-article 1))) + (error "No charset is given")) + (when (gnus-buffer-live-p gnus-original-article-buffer) + (with-current-buffer gnus-original-article-buffer + (let* ((ct (gnus-fetch-field "content-type")) + (ctl (and ct (mail-header-parse-content-type ct)))) + (setq charset (and ctl + (mail-content-type-get ctl 'charset))) + (when (stringp charset) + (setq charset (intern (downcase charset))))))) + (unless charset + (setq charset gnus-newsgroup-charset))) (article-goto-body) (save-window-excursion (save-restriction @@ -2508,19 +2578,123 @@ If READ-CHARSET, ask for a coding system." (defun gnus-article-wash-html-with-w3m () "Wash the current buffer with emacs-w3m." (mm-setup-w3m) - (save-restriction - (narrow-to-region (point) (point-max)) - (let ((w3m-safe-url-regexp mm-w3m-safe-url-regexp) - w3m-force-redisplay) - (w3m-region (point-min) (point-max))) - (when (and mm-inline-text-html-with-w3m-keymap - (boundp 'w3m-minor-mode-map) - w3m-minor-mode-map) - (add-text-properties - (point-min) (point-max) - (list 'keymap w3m-minor-mode-map - ;; Put the mark meaning this part was rendered by emacs-w3m. - 'mm-inline-text-html-with-w3m t))))) + (let ((w3m-safe-url-regexp mm-w3m-safe-url-regexp) + w3m-force-redisplay) + (w3m-region (point-min) (point-max))) + (when (and mm-inline-text-html-with-w3m-keymap + (boundp 'w3m-minor-mode-map) + w3m-minor-mode-map) + (add-text-properties + (point-min) (point-max) + (list 'keymap w3m-minor-mode-map + ;; Put the mark meaning this part was rendered by emacs-w3m. + 'mm-inline-text-html-with-w3m t)))) + +(eval-when-compile (defvar charset)) ;; Bound by `article-wash-html'. + +(defun gnus-article-wash-html-with-w3m-standalone () + "Wash the current buffer with w3m." + (if (mm-w3m-standalone-supports-m17n-p) + (progn + (unless (mm-coding-system-p charset) ;; Bound by `article-wash-html'. + ;; The default. + (setq charset 'iso-8859-1)) + (let ((coding-system-for-write charset) + (coding-system-for-read charset)) + (call-process-region + (point-min) (point-max) + "w3m" t t nil "-dump" "-T" "text/html" + "-I" (symbol-name charset) "-O" (symbol-name charset)))) + (mm-inline-wash-with-stdin nil "w3m" "-dump" "-T" "text/html"))) + +(defvar gnus-article-browse-html-temp-list nil + "List of temporary files created by `gnus-article-browse-html-parts'. +Internal variable.") + +(defcustom gnus-article-browse-delete-temp 'ask + "What to do with temporary files from `gnus-article-browse-html-parts'. +If nil, don't delete temporary files. If it is t, delete them on +exit from the summary buffer. If it is the symbol `file', query +on each file, if it is `ask' ask once when exiting from the +summary buffer." + :group 'gnus-article + :type '(choice (const :tag "Don't delete" nil) + (const :tag "Don't ask" t) + (const :tag "Ask" ask) + (const :tag "Ask for each file" file))) + +;; Cf. mm-postponed-undisplay-list / mm-destroy-postponed-undisplay-list. + +(defun gnus-article-browse-delete-temp-files (&optional how) + "Delete temp-files created by `gnus-article-browse-html-parts'." + (when (and gnus-article-browse-html-temp-list + (or how + (setq how gnus-article-browse-delete-temp))) + (when (and (eq how 'ask) + (y-or-n-p (format + "Delete all %s temporary HTML file(s)? " + (length gnus-article-browse-html-temp-list))) + (setq how t))) + (dolist (file gnus-article-browse-html-temp-list) + (when (and (file-exists-p file) + (or (eq how t) + ;; `how' is neither `nil', `ask' nor `t' (i.e. `file'): + (gnus-y-or-n-p + (format "Delete temporary HTML file `%s'? " file)))) + (delete-file file))) + ;; Also remove file from the list when not deleted or if file doesn't + ;; exist anymore. + (setq gnus-article-browse-html-temp-list nil)) + gnus-article-browse-html-temp-list) + +(defun gnus-article-browse-html-parts (list) + "View all \"text/html\" parts from LIST. +Recurse into multiparts." + ;; Internal function used by `gnus-article-browse-html-article'. + (let ((showed)) + ;; Find and show the html-parts. + (dolist (handle list) + ;; If HTML, show it: + (when (listp handle) + (cond ((and (bufferp (car handle)) + (string-match "text/html" (car (mm-handle-type handle)))) + (let ((tmp-file (mm-make-temp-file + ;; Do we need to care for 8.3 filenames? + "mm-" nil ".html"))) + (mm-save-part-to-file handle tmp-file) + (add-to-list 'gnus-article-browse-html-temp-list tmp-file) + (add-hook 'gnus-summary-prepare-exit-hook + 'gnus-article-browse-delete-temp-files) + (add-hook 'gnus-exit-gnus-hook + (lambda () + (gnus-article-browse-delete-temp-files t))) + (browse-url tmp-file) + (setq showed t))) + ;; If multipart, recurse + ((and (stringp (car handle)) + (string-match "^multipart/" (car handle)) + (setq showed + (or showed + (gnus-article-browse-html-parts handle)))))))) + showed)) + +;; TODO: Key binding +(defun gnus-article-browse-html-article () + "View \"text/html\" parts of the current article with a WWW browser." + (interactive) + (save-window-excursion + ;; Open raw article and select the buffer + (gnus-summary-show-article t) + (gnus-summary-select-article-buffer) + (let ((parts (mm-dissect-buffer t t))) + ;; If singlepart, enforce a list. + (when (and (bufferp (car parts)) + (stringp (car (mm-handle-type parts)))) + (setq parts (list parts))) + ;; Process the list + (unless (gnus-article-browse-html-parts parts) + (gnus-error 3 "Mail doesn't contain a \"text/html\" part!")) + (gnus-summary-show-article)))) (defun article-hide-list-identifiers () "Remove list identifies from the Subject header. @@ -2583,20 +2757,17 @@ always hide." (article-really-strip-banner (gnus-parameter-banner gnus-newsgroup-name))) (when gnus-article-address-banner-alist - ;; It is necessary to encode from fields before checking, - ;; because `mail-header-parse-addresses' does not work - ;; (reliably) on decoded headers. And more, it is - ;; impossible to use `gnus-fetch-original-field' here, - ;; because `article-strip-banner' may be called in draft - ;; buffers to preview them. + ;; Note that the From header is decoded here, so it is + ;; required that the *-extract-address-components function + ;; supports non-ASCII text. (let ((from (save-restriction (widen) (article-narrow-to-head) (mail-fetch-field "from")))) (when (and from (setq from - (caar (mail-header-parse-addresses - (mail-encode-encoded-word-string from))))) + (cadr (funcall gnus-extract-address-components + from)))) (catch 'found (dolist (pair gnus-article-address-banner-alist) (when (string-match (car pair) from) @@ -3075,20 +3246,21 @@ function and want to see what the date was before converting." (defun article-update-date-lapsed () "Function to be run from a timer to update the lapsed time line." - (let (deactivate-mark) - (save-excursion - (ignore-errors - (walk-windows - (lambda (w) - (set-buffer (window-buffer w)) - (when (eq major-mode 'gnus-article-mode) - (let ((mark (point-marker))) - (goto-char (point-min)) - (when (re-search-forward "^X-Sent:" nil t) - (article-date-lapsed t)) - (goto-char (marker-position mark)) - (move-marker mark nil)))) - nil 'visible))))) + (save-match-data + (let (deactivate-mark) + (save-excursion + (ignore-errors + (walk-windows + (lambda (w) + (set-buffer (window-buffer w)) + (when (eq major-mode 'gnus-article-mode) + (let ((mark (point-marker))) + (goto-char (point-min)) + (when (re-search-forward "^X-Sent:" nil t) + (article-date-lapsed t)) + (goto-char (marker-position mark)) + (move-marker mark nil)))) + nil 'visible)))))) (defun gnus-start-date-timer (&optional n) "Start a timer to update the X-Sent header in the article buffers. @@ -3276,7 +3448,7 @@ This format is defined by the `gnus-article-time-format' variable." ((null split-name) (read-file-name (concat prompt " (default " - (file-name-nondirectory default-name) ") ") + (file-name-nondirectory default-name) "): ") (file-name-directory default-name) default-name)) ;; A single group name is returned. @@ -3286,7 +3458,7 @@ This format is defined by the `gnus-article-time-format' variable." (symbol-value variable))) (read-file-name (concat prompt " (default " - (file-name-nondirectory default-name) ") ") + (file-name-nondirectory default-name) "): ") (file-name-directory default-name) default-name)) ;; A single split name was found @@ -3299,7 +3471,7 @@ This format is defined by the `gnus-article-time-format' variable." ((file-exists-p name) name) (t gnus-article-save-directory)))) (read-file-name - (concat prompt " (default " name ") ") + (concat prompt " (default " name "): ") dir name))) ;; A list of splits was found. (t @@ -3310,7 +3482,7 @@ This format is defined by the `gnus-article-time-format' variable." (setq result (expand-file-name (read-file-name - (concat prompt " (`M-p' for defaults) ") + (concat prompt " (`M-p' for defaults): ") gnus-article-save-directory (car split-name)) gnus-article-save-directory))) @@ -3344,7 +3516,7 @@ This format is defined by the `gnus-article-time-format' variable." Optional argument FILENAME specifies file name. Directory to save to is default to `gnus-article-save-directory'." (setq filename (gnus-read-save-file-name - "Save %s in rmail file:" filename + "Save %s in rmail file" filename gnus-rmail-save-name gnus-newsgroup-name gnus-current-headers 'gnus-newsgroup-last-rmail)) (gnus-eval-in-buffer-window gnus-save-article-buffer @@ -3359,7 +3531,7 @@ Directory to save to is default to `gnus-article-save-directory'." Optional argument FILENAME specifies file name. Directory to save to is default to `gnus-article-save-directory'." (setq filename (gnus-read-save-file-name - "Save %s in Unix mail file:" filename + "Save %s in Unix mail file" filename gnus-mail-save-name gnus-newsgroup-name gnus-current-headers 'gnus-newsgroup-last-mail)) (gnus-eval-in-buffer-window gnus-save-article-buffer @@ -3378,7 +3550,7 @@ Directory to save to is default to `gnus-article-save-directory'." Optional argument FILENAME specifies file name. Directory to save to is default to `gnus-article-save-directory'." (setq filename (gnus-read-save-file-name - "Save %s in file:" filename + "Save %s in file" filename gnus-file-save-name gnus-newsgroup-name gnus-current-headers 'gnus-newsgroup-last-file)) (gnus-eval-in-buffer-window gnus-save-article-buffer @@ -3402,7 +3574,7 @@ The directory to save in defaults to `gnus-article-save-directory'." Optional argument FILENAME specifies file name. The directory to save in defaults to `gnus-article-save-directory'." (setq filename (gnus-read-save-file-name - "Save %s body in file:" filename + "Save %s body in file" filename gnus-file-save-name gnus-newsgroup-name gnus-current-headers 'gnus-newsgroup-last-file)) (gnus-eval-in-buffer-window gnus-save-article-buffer @@ -3750,6 +3922,7 @@ commands: \\[gnus-article-describe-briefly]\t Describe the current mode briefly \\[gnus-info-find-node]\t Go to the Gnus info node" (interactive) + (kill-all-local-variables) (gnus-simplify-mode-line) (setq mode-name "Article") (setq major-mode 'gnus-article-mode) @@ -3772,14 +3945,14 @@ commands: (make-local-variable 'gnus-article-charset) (make-local-variable 'gnus-article-ignored-charsets) ;; Prevent recent Emacsen from displaying non-break space as "\ ". - (set (make-local-variable 'show-nonbreak-escape) nil) + (set (make-local-variable 'nobreak-char-display) nil) (gnus-set-default-directory) (buffer-disable-undo) (setq buffer-read-only t show-trailing-whitespace nil) (set-syntax-table gnus-article-mode-syntax-table) (mm-enable-multibyte) - (gnus-run-hooks 'gnus-article-mode-hook)) + (gnus-run-mode-hooks 'gnus-article-mode-hook)) (defun gnus-article-setup-buffer () "Initialize the article buffer." @@ -4018,10 +4191,11 @@ General format specifiers can also be used. See Info node (gnus-mime-view-part-as-charset "C" "View As charset...") (gnus-mime-save-part "o" "Save...") (gnus-mime-save-part-and-strip "\C-o" "Save and Strip") + (gnus-mime-replace-part "r" "Replace part") (gnus-mime-delete-part "d" "Delete part") (gnus-mime-copy-part "c" "View As Text, In Other Buffer") (gnus-mime-inline-part "i" "View As Text, In This Buffer") - (gnus-mime-view-part-internally "E" "View Internally") + (gnus-mime-view-part-internally "E" "View Internally") ;; Why `E'? (gnus-mime-view-part-externally "e" "View Externally") (gnus-mime-print-part "p" "Print") (gnus-mime-pipe-part "|" "Pipe To Command...") @@ -4076,8 +4250,37 @@ General format specifiers can also be used. See Info node (delete-region (point) (point-max)) (mm-display-parts handles)))))) +(defun gnus-article-jump-to-part (n) + "Jump to MIME part N." + (interactive "P") + (pop-to-buffer gnus-article-buffer) + ;; FIXME: why is it necessary? + (sit-for 0) + (let ((parts (length gnus-article-mime-handle-alist))) + (or n (setq n + (string-to-number + (read-string ;; Emacs 21 doesn't have `read-number'. + (format "Jump to part (2..%s): " parts))))) + (unless (and (integerp n) (<= n parts) (>= n 1)) + (setq n + (progn + (gnus-message 7 "Invalid part `%s', using %s instead." + n parts) + parts))) + (gnus-message 9 "Jumping to part %s." n) + (cond ((>= gnus-auto-select-part 1) + (while (and (<= n parts) + (not (gnus-article-goto-part n))) + (setq n (1+ n)))) + ((< gnus-auto-select-part 0) + (while (and (>= n 1) + (not (gnus-article-goto-part n))) + (setq n (1- n)))) + (t + (gnus-article-goto-part n))))) + (eval-when-compile - (defsubst gnus-article-edit-part (handles) + (defsubst gnus-article-edit-part (handles &optional current-id) "Edit an article in order to delete a mime part. This function is exclusively used by `gnus-mime-save-part-and-strip' and `gnus-mime-delete-part', and not provided at run-time normally." @@ -4092,7 +4295,7 @@ and `gnus-mime-delete-part', and not provided at run-time normally." ',gnus-newsgroup-ignored-charsets)) (mbl mml-buffer-list)) (setq mml-buffer-list nil) - (insert-buffer gnus-original-article-buffer) + (insert-buffer-substring gnus-original-article-buffer) (mime-to-mml ',handles) (setq gnus-article-mime-handles nil) (let ((mbl1 mml-buffer-list)) @@ -4116,13 +4319,29 @@ and `gnus-mime-delete-part', and not provided at run-time normally." (gnus-summary-edit-article-done ,(or (mail-header-references gnus-current-headers) "") ,(gnus-group-read-only-p) - ,gnus-summary-buffer no-highlight))) + ,gnus-summary-buffer no-highlight)) + t) (gnus-article-edit-done) (gnus-summary-expand-window) - (gnus-summary-show-article))) - -(defun gnus-mime-save-part-and-strip () - "Save the MIME part under point then replace it with an external body." + (gnus-summary-show-article) + (when (and current-id (integerp gnus-auto-select-part)) + (gnus-article-jump-to-part + (+ current-id gnus-auto-select-part))))) + +(defun gnus-mime-replace-part (file) + "Replace MIME part under point with an external body." + ;; Useful if file has already been saved to disk + (interactive + (list + (mm-with-multibyte + (read-file-name "Replace MIME part with file: " + (or mm-default-directory default-directory) + nil nil)))) + (gnus-mime-save-part-and-strip file)) + +(defun gnus-mime-save-part-and-strip (&optional file) + "Save the MIME part under point then replace it with an external body. +If FILE is given, use it for the external part." (interactive) (gnus-article-check-buffer) (when (gnus-group-read-only-p) @@ -4130,29 +4349,36 @@ and `gnus-mime-delete-part', and not provided at run-time normally." (when (mm-complicated-handles gnus-article-mime-handles) (error "\ The current article has a complicated MIME structure, giving up...")) - (when (gnus-yes-or-no-p "\ -Deleting parts may malfunction or destroy the article; continue? ") - (let* ((data (get-text-property (point) 'gnus-data)) - file param - (handles gnus-article-mime-handles)) - (setq file (and data (mm-save-part data))) - (when file - (with-current-buffer (mm-handle-buffer data) - (erase-buffer) - (insert "Content-Type: " (mm-handle-media-type data)) - (mml-insert-parameter-string (cdr (mm-handle-type data)) - '(charset)) - (insert "\n") - (insert "Content-ID: " (message-make-message-id) "\n") - (insert "Content-Transfer-Encoding: binary\n") - (insert "\n")) - (setcdr data - (cdr (mm-make-handle nil - `("message/external-body" - (access-type . "LOCAL-FILE") - (name . ,file))))) - (set-buffer gnus-summary-buffer) - (gnus-article-edit-part handles))))) + (let* ((data (get-text-property (point) 'gnus-data)) + (id (get-text-property (point) 'gnus-part)) + param + (handles gnus-article-mime-handles)) + (unless file + (setq file + (and data (mm-save-part data "Delete MIME part and save to: ")))) + (when file + (with-current-buffer (mm-handle-buffer data) + (erase-buffer) + (insert "Content-Type: " (mm-handle-media-type data)) + (mml-insert-parameter-string (cdr (mm-handle-type data)) + '(charset)) + ;; Add a filename for the sake of saving the part again. + (mml-insert-parameter + (mail-header-encode-parameter "name" (file-name-nondirectory file))) + (insert "\n") + (insert "Content-ID: " (message-make-message-id) "\n") + (insert "Content-Transfer-Encoding: binary\n") + (insert "\n")) + (setcdr data + (cdr (mm-make-handle nil + `("message/external-body" + (access-type . "LOCAL-FILE") + (name . ,file))))) + ;; (set-buffer gnus-summary-buffer) + (gnus-article-edit-part handles id)))) + +;; A function like `gnus-summary-save-parts' (`X m', ` ') but with stripping would be nice. (defun gnus-mime-delete-part () "Delete the MIME part under point. @@ -4164,9 +4390,11 @@ Replace it with some information about the removed part." (when (mm-complicated-handles gnus-article-mime-handles) (error "\ The current article has a complicated MIME structure, giving up...")) - (when (gnus-yes-or-no-p "\ -Deleting parts may malfunction or destroy the article; continue? ") + (when (or gnus-expert-user + (gnus-yes-or-no-p "\ +Deleting parts may malfunction or destroy the article; continue? ")) (let* ((data (get-text-property (point) 'gnus-data)) + (id (get-text-property (point) 'gnus-part)) (handles gnus-article-mime-handles) (none "(none)") (description @@ -4197,8 +4425,8 @@ Deleting parts may malfunction or destroy the article; continue? ") nil `("text/plain") nil nil (list "attachment") (format "Deleted attachment (%s bytes)" bsize)))))) - (set-buffer gnus-summary-buffer) - (gnus-article-edit-part handles)))) + ;; (set-buffer gnus-summary-buffer) + (gnus-article-edit-part handles id)))) (defun gnus-mime-save-part () "Save the MIME part under point." @@ -4229,9 +4457,12 @@ Deleting parts may malfunction or destroy the article; continue? ") (defun gnus-mime-view-part-as-type-internal () (gnus-article-check-buffer) - (let* ((name (mail-content-type-get - (mm-handle-type (get-text-property (point) 'gnus-data)) - 'name)) + (let* ((handle (get-text-property (point) 'gnus-data)) + (name (or + ;; Content-Type: foo/bar; name=... + (mail-content-type-get (mm-handle-type handle) 'name) + ;; Content-Disposition: attachment; filename=... + (cdr (assq 'filename (cdr (mm-handle-disposition handle)))))) (def-type (and name (mm-default-file-encoding name)))) (and def-type (cons def-type 0)))) @@ -4239,14 +4470,21 @@ Deleting parts may malfunction or destroy the article; continue? ") "Choose a MIME media type, and view the part as such." (interactive) (unless mime-type - (setq mime-type (completing-read - "View as MIME type: " - (mapcar #'list (mailcap-mime-types)) - nil nil - (gnus-mime-view-part-as-type-internal)))) + (setq mime-type + (let ((default (gnus-mime-view-part-as-type-internal))) + (completing-read + (format "View as MIME type (default %s): " + (car default)) + (mapcar #'list (mailcap-mime-types)) + nil nil nil nil + (car default))))) (gnus-article-check-buffer) (let ((handle (get-text-property (point) 'gnus-data))) (when handle + (when (equal (mm-handle-media-type handle) "message/external-body") + (unless (mm-handle-cache handle) + (mm-extern-cache-contents handle)) + (setq handle (mm-handle-cache handle))) (setq handle (mm-make-handle (mm-handle-buffer handle) (cons mime-type (cdr (mm-handle-type handle))) @@ -4395,7 +4633,7 @@ Compressed files like .gz and .bz2 are decompressed." (and charset (setq coding-system (mm-charset-to-coding-system charset)) - (not (eq charset 'ascii)))) + (not (eq coding-system 'ascii)))) (mm-decode-coding-string contents coding-system) (mm-string-to-multibyte contents))) (goto-char b))))) @@ -4462,13 +4700,68 @@ If no internal viewer is available, use an external viewer." (if action-pair (funcall (cdr action-pair))))) -(defun gnus-article-part-wrapper (n function) - (with-current-buffer gnus-article-buffer - (when (> n (length gnus-article-mime-handle-alist)) - (error "No such part")) - (gnus-article-goto-part n) - (let ((handle (cdr (assq n gnus-article-mime-handle-alist)))) - (funcall function handle)))) +(defun gnus-article-part-wrapper (n function &optional no-handle interactive) + "Call FUNCTION on MIME part N. +Unless NO-HANDLE, call FUNCTION with N-th MIME handle as it's only argument. +If INTERACTIVE, call FUNCTION interactivly." + (let (window frame) + ;; Check whether the article is displayed. + (unless (and (gnus-buffer-live-p gnus-article-buffer) + (setq window (get-buffer-window gnus-article-buffer t)) + (frame-visible-p (setq frame (window-frame window)))) + (error "No article is displayed")) + (with-current-buffer gnus-article-buffer + ;; Check whether the article displays the right contents. + (unless (with-current-buffer gnus-summary-buffer + (eq gnus-current-article (gnus-summary-article-number))) + (error "You should select the right article first")) + ;; Check whether the specified part exists. + (when (> n (length gnus-article-mime-handle-alist)) + (error "No such part"))) + (unless + (progn + ;; To select the window is needed so that the cursor + ;; might be visible on the MIME button. + (select-window (prog1 + window + (setq window (selected-window)) + ;; Article may be displayed in the other frame. + (gnus-select-frame-set-input-focus + (prog1 + frame + (setq frame (selected-frame)))))) + (when (gnus-article-goto-part n) + ;; We point the cursor and the arrow at the MIME button + ;; when the `function' prompt the user for something. + (let ((cursor-in-non-selected-windows t) + (overlay-arrow-string "=>") + (overlay-arrow-position (point-marker))) + (unwind-protect + (cond + ((and no-handle interactive) + (call-interactively function)) + (no-handle + (funcall function)) + (interactive + (call-interactively + function + (cdr (assq n gnus-article-mime-handle-alist)))) + (t + (funcall function + (cdr (assq n gnus-article-mime-handle-alist))))) + (set-marker overlay-arrow-position nil) + (unless gnus-auto-select-part + (gnus-select-frame-set-input-focus frame) + (select-window window)))) + t)) + (if gnus-inhibit-mime-unbuttonizing + ;; This is the default though the program shouldn't reach here. + (error "No such part") + ;; The part which doesn't have the MIME button is selected. + ;; So, we display all the buttons and redo it. + (let ((gnus-inhibit-mime-unbuttonizing t)) + (gnus-summary-show-article) + (gnus-article-part-wrapper n function no-handle)))))) (defun gnus-article-pipe-part (n) "Pipe MIME part N, which is the numerical prefix." @@ -4506,6 +4799,24 @@ N is the numerical prefix." (interactive "p") (gnus-article-part-wrapper n 'gnus-mime-inline-part)) +(defun gnus-article-save-part-and-strip (n) + "Save MIME part N and replace it with an external body. +N is the numerical prefix." + (interactive "p") + (gnus-article-part-wrapper n 'gnus-mime-save-part-and-strip t)) + +(defun gnus-article-replace-part (n) + "Replace MIME part N with an external body. +N is the numerical prefix." + (interactive "p") + (gnus-article-part-wrapper n 'gnus-mime-replace-part t t)) + +(defun gnus-article-delete-part (n) + "Delete MIME part N and add some information about the removed part. +N is the numerical prefix." + (interactive "p") + (gnus-article-part-wrapper n 'gnus-mime-delete-part t)) + (defun gnus-article-mime-match-handle-first (condition) (if condition (let (n) @@ -4747,6 +5058,8 @@ If displaying \"text/html\" is discouraged \(see (defun gnus-mime-display-part (handle) (cond + ;; Maybe a broken MIME message. + ((null handle)) ;; Single part. ((not (stringp (car handle))) (gnus-mime-display-single handle)) @@ -4820,6 +5133,13 @@ If displaying \"text/html\" is discouraged \(see (let ((id (1+ (length gnus-article-mime-handle-alist))) beg) (push (cons id handle) gnus-article-mime-handle-alist) + (when (and display + (equal (mm-handle-media-supertype handle) "message")) + (insert-char + ?\n + (cond ((not (bolp)) 2) + ((or (bobp) (eq (char-before (1- (point))) ?\n)) 0) + (t 1)))) (when (or (not display) (not (gnus-unbuttonized-mime-type-p type))) (gnus-insert-mime-button @@ -4846,7 +5166,17 @@ If displaying \"text/html\" is discouraged \(see (forward-line -1) (setq beg (point))) (gnus-article-insert-newline) - (mm-display-inline handle) + (mm-insert-inline + handle + (let ((charset (mail-content-type-get (mm-handle-type handle) + 'charset))) + (cond ((not charset) + (mm-string-as-multibyte (mm-get-part handle))) + ((eq charset 'gnus-decoded) + (with-current-buffer (mm-handle-buffer handle) + (buffer-string))) + (t + (mm-decode-string (mm-get-part handle) charset))))) (goto-char (point-max)))) ;; Do highlighting. (save-excursion @@ -4916,7 +5246,7 @@ If displaying \"text/html\" is discouraged \(see ,gnus-mouse-face-prop ,gnus-article-mouse-face face ,gnus-article-button-face gnus-part ,id - gnus-data ,handle)) + article-type multipart)) (widget-convert-button 'link from (point) :action 'gnus-widget-press-button :button-keymap gnus-widget-button-keymap) @@ -5170,14 +5500,36 @@ Argument LINES specifies lines to be scrolled up." (gnus-article-next-page-1 lines) nil)) +(defmacro gnus-article-beginning-of-window () + "Move point to the beginning of the window. +In Emacs, the point is placed at the line number which `scroll-margin' +specifies." + (if (featurep 'xemacs) + '(move-to-window-line 0) + '(move-to-window-line + (min (max 0 scroll-margin) + (max 1 (- (window-height) + (if mode-line-format 1 0) + (if header-line-format 1 0))))))) + (defun gnus-article-next-page-1 (lines) - (let ((scroll-in-place nil)) - (condition-case () - (scroll-up lines) - (end-of-buffer - ;; Long lines may cause an end-of-buffer error. - (goto-char (point-max))))) - (move-to-window-line 0)) + (when (and (not (featurep 'xemacs)) + (numberp lines) + (> lines 0) + (numberp (symbol-value 'scroll-margin)) + (> (symbol-value 'scroll-margin) 0)) + ;; Protect against the bug that Emacs 21.x hangs up when scrolling up for + ;; too many number of lines if `scroll-margin' is set as two or greater. + (setq lines (min lines + (max 0 (- (count-lines (window-start) (point-max)) + (symbol-value 'scroll-margin)))))) + (condition-case () + (let ((scroll-in-place nil)) + (scroll-up lines)) + (end-of-buffer + ;; Long lines may cause an end-of-buffer error. + (goto-char (point-max)))) + (gnus-article-beginning-of-window)) (defun gnus-article-prev-page (&optional lines) "Show previous page of current article. @@ -5191,13 +5543,13 @@ Argument LINES specifies lines to be scrolled down." (gnus-narrow-to-page -1) ;Go to previous page. (goto-char (point-max)) (recenter -1)) - (let ((scroll-in-place nil)) - (prog1 - (condition-case () - (scroll-down lines) - (beginning-of-buffer - (goto-char (point-min)))) - (move-to-window-line 0))))) + (prog1 + (condition-case () + (let ((scroll-in-place nil)) + (scroll-down lines)) + (beginning-of-buffer + (goto-char (point-min)))) + (gnus-article-beginning-of-window)))) (defun gnus-article-only-boring-p () "Decide whether there is only boring text remaining in the article. @@ -5207,14 +5559,15 @@ not have a face in `gnus-article-boring-faces'." (boundp 'gnus-article-boring-faces) (symbol-value 'gnus-article-boring-faces)) (save-excursion - (catch 'only-boring - (while (re-search-forward "\\b\\w\\w" nil t) - (forward-char -1) - (when (not (gnus-intersection - (gnus-faces-at (point)) - (symbol-value 'gnus-article-boring-faces))) - (throw 'only-boring nil))) - (throw 'only-boring t))))) + (let ((inhibit-point-motion-hooks t)) + (catch 'only-boring + (while (re-search-forward "\\b\\w\\w" nil t) + (forward-char -1) + (when (not (gnus-intersection + (gnus-faces-at (point)) + (symbol-value 'gnus-article-boring-faces))) + (throw 'only-boring nil))) + (throw 'only-boring t)))))) (defun gnus-article-refer-article () "Read article specified by message-id around point." @@ -5745,7 +6098,7 @@ groups." ,(or (mail-header-references gnus-current-headers) "") ,(gnus-group-read-only-p) ,gnus-summary-buffer no-highlight)))) -(defun gnus-article-edit-article (start-func exit-func) +(defun gnus-article-edit-article (start-func exit-func &optional quiet) "Start editing the contents of the current article buffer." (let ((winconf (current-window-configuration))) (set-buffer gnus-article-buffer) @@ -5758,7 +6111,8 @@ groups." (gnus-configure-windows 'edit-article) (setq gnus-article-edit-done-function exit-func) (setq gnus-prev-winconf winconf) - (gnus-message 6 "C-c C-c to end edits"))) + (unless quiet + (gnus-message 6 "C-c C-c to end edits")))) (defun gnus-article-edit-done (&optional arg) "Update the article edits and exit." @@ -5803,7 +6157,7 @@ groups." (window-start (window-start))) (erase-buffer) (if (gnus-buffer-live-p gnus-original-article-buffer) - (insert-buffer gnus-original-article-buffer)) + (insert-buffer-substring gnus-original-article-buffer)) (let ((winconf gnus-prev-winconf)) (kill-all-local-variables) (gnus-article-mode) @@ -5847,6 +6201,14 @@ groups." :group 'gnus-article-buttons :type 'regexp) +;; Regexp suggested by Felix Wiemann in <87oeuomcz9.fsf@news2.ososo.de> +(defcustom gnus-button-valid-localpart-regexp + "[a-z0-9$%(*-=?[_][^<>\")!;:,{}\n\t ]*" + "Regular expression that matches a localpart of mail addresses or MIDs." + :version "22.1" + :group 'gnus-article-buttons + :type 'regexp) + (defcustom gnus-button-man-handler 'manual-entry "Function to use for displaying man pages. The function must take at least one argument with a string naming the @@ -5886,12 +6248,11 @@ The function must take one argument, the string naming the URL." (regexp :tag "Other"))) (defcustom gnus-button-ctan-directory-regexp - (concat - "\\(?:" - "biblio\\|digests\\|dviware\\|fonts\\|graphics\\|help\\|" - "indexing\\|info\\|language\\|macros\\|support\\|systems\\|" - "tds\\|tools\\|usergrps\\|web\\|nonfree\\|obsolete" - "\\)") + (regexp-opt + (list "archive-tools" "biblio" "bibliography" "digests" "documentation" + "dviware" "fonts" "graphics" "help" "indexing" "info" "language" + "languages" "macros" "nonfree" "obsolete" "support" "systems" + "tds" "tools" "usergrps" "web") t) "Regular expression for ctan directories. It should match all directories in the top level of `gnus-ctan-url'." :version "22.1" @@ -5899,8 +6260,7 @@ It should match all directories in the top level of `gnus-ctan-url'." :type 'regexp) (defcustom gnus-button-mid-or-mail-regexp - (concat "\\b\\(\")!;:,{}\n\t ]*@" - ;; Felix Wiemann in <87oeuomcz9.fsf@news2.ososo.de> + (concat "\\b\\(?\\)\\b") "Regular expression that matches a message ID or a mail address." @@ -6081,9 +6441,11 @@ address, `ask' if unsure and `invalid' if the string is invalid." (gnus-url-mailto url-mailto)) (t (gnus-message 3 "Invalid string."))))) -(defun gnus-button-handle-custom (url) - "Follow a Custom URL." - (customize-apropos (gnus-url-unhex-string url))) +(defun gnus-button-handle-custom (fun arg) + "Call function FUN on argument ARG. +Both FUN and ARG are supposed to be strings. ARG will be passed +as a symbol to FUN." + (funcall (intern fun) (intern arg))) (defvar gnus-button-handle-describe-prefix "^\\(C-h\\|?\\)") @@ -6215,8 +6577,9 @@ positives are possible." (defcustom gnus-button-alist '(("<\\(url:[>\n\t ]*?\\)?\\(nntp\\|news\\):[>\n\t ]*\\([^>\n\t ]*@[^>\n\t ]*\\)>" 0 (>= gnus-button-message-level 0) gnus-button-handle-news 3) - ("\\b\\(nntp\\|news\\):\\([^>\n\t ]*@[^>)!;:,\n\t ]*\\)" 0 t - gnus-button-handle-news 2) + ((concat "\\b\\(nntp\\|news\\):\\(" + gnus-button-valid-localpart-regexp "@[a-z0-9.-]+[a-z]\\)") + 0 t gnus-button-handle-news 2) ("\\(\\b<\\(url:[>\n\t ]*\\)?\\(nntp\\|news\\):[>\n\t ]*\\(//\\)?\\([^>\n\t ]*\\)>\\)" 1 (>= gnus-button-message-level 0) gnus-button-fetch-group 5) ("\\b\\(nntp\\|news\\):\\(//\\)?\\([^'\">\n\t ]+\\)" @@ -6262,10 +6625,8 @@ positives are possible." ;; Info links like `C-h i d m CC Mode RET' 0 (>= gnus-button-emacs-level 1) gnus-button-handle-info-keystrokes 2) ;; This is custom - ("\\bcustom:\\(//\\)?\\([^'\">\n\t ]+\\)" - 0 (>= gnus-button-emacs-level 5) gnus-button-handle-custom 2) - ("M-x[ \t\n]customize-[^ ]+[ \t\n]RET[ \t\n]\\([^ ]+\\)[ \t\n]RET" 0 - (>= gnus-button-emacs-level 1) gnus-button-handle-custom 1) + ("M-x[ \t\n]\\(customize-[^ ]+\\)[ \t\n]RET[ \t\n]\\([^ ]+\\)[ \t\n]RET" 0 + (>= gnus-button-emacs-level 1) gnus-button-handle-custom 1 2) ;; Emacs help commands ("M-x[ \t\n]+apropos[ \t\n]+RET[ \t\n]+\\([^ \t\n]+\\)[ \t\n]+RET" ;; regexp doesn't match arguments containing ` '. @@ -6474,7 +6835,7 @@ do the highlighting. See the documentation for those functions." (defun gnus-article-highlight-signature () "Highlight the signature in an article. It does this by highlighting everything after -`gnus-signature-separator' using `gnus-signature-face'." +`gnus-signature-separator' using the face `gnus-signature'." (interactive) (gnus-with-article-buffer (let ((inhibit-point-motion-hooks t)) @@ -6767,7 +7128,7 @@ specified by `gnus-button-alist'." (match-string 3 address) "nntp"))) nil nil nil - (and (match-end 6) (list (string-to-int (match-string 6 address)))))))) + (and (match-end 6) (list (string-to-number (match-string 6 address)))))))) (defun gnus-url-parse-query-string (query &optional downcase) (let (retval pairs cur key val) @@ -7010,6 +7371,8 @@ For example: t) ((eq val 'head) nil) + ((eq val 'first) + (eq part-number 1)) ((eq val 'last) (eq part-number total-parts)) ((numberp val) @@ -7028,7 +7391,7 @@ For example: current-prefix-arg)) (let ((func (cdr (assoc protocol gnus-article-encrypt-protocol-alist)))) (unless func - (error (format "Can't find the encrypt protocol %s" protocol))) + (error "Can't find the encrypt protocol %s" protocol)) (if (member gnus-newsgroup-name '("nndraft:delayed" "nndraft:drafts" "nndraft:queue")) @@ -7110,12 +7473,51 @@ For example: (?d gnus-tmp-details ?s) (?D gnus-tmp-pressed-details ?s))) +(defvar gnus-mime-security-button-commands + '((gnus-article-press-button "\r" "Show Detail") + (undefined "v") + (undefined "t") + (undefined "C") + (gnus-mime-security-save-part "o" "Save...") + (undefined "\C-o") + (undefined "r") + (undefined "d") + (undefined "c") + (undefined "i") + (undefined "E") + (undefined "e") + (undefined "p") + (gnus-mime-security-pipe-part "|" "Pipe To Command...") + (undefined "."))) + (defvar gnus-mime-security-button-map (let ((map (make-sparse-keymap))) (define-key map gnus-mouse-2 'gnus-article-push-button) - (define-key map "\r" 'gnus-article-press-button) + (define-key map gnus-down-mouse-3 'gnus-mime-security-button-menu) + (dolist (c gnus-mime-security-button-commands) + (define-key map (cadr c) (car c))) map)) +(easy-menu-define + gnus-mime-security-button-menu gnus-mime-security-button-map + "Security button menu." + `("Security Part" + ,@(delq nil + (mapcar (lambda (c) + (unless (eq (car c) 'undefined) + (vector (caddr c) (car c) :enable t))) + gnus-mime-security-button-commands)))) + +(defun gnus-mime-security-button-menu (event prefix) + "Construct a context-sensitive menu of security commands." + (interactive "e\nP") + (save-window-excursion + (let ((pos (event-start event))) + (select-window (posn-window pos)) + (goto-char (posn-point pos)) + (gnus-article-check-buffer) + (popup-menu gnus-mime-security-button-menu nil prefix)))) + (defvar gnus-mime-security-details-buffer nil) (defvar gnus-mime-security-button-pressed nil) @@ -7240,15 +7642,16 @@ For example: (when (boundp 'help-echo-owns-message) (setq help-echo-owns-message t)) (format - "%S: show detail" - (aref gnus-mouse-2 0)))))) + "%S: show detail; %S: more options" + (aref gnus-mouse-2 0) + (aref gnus-down-mouse-3 0)))))) (defun gnus-mime-display-security (handle) (save-restriction (narrow-to-region (point) (point)) (unless (gnus-unbuttonized-mime-type-p (car handle)) (gnus-insert-mime-security-button handle)) - (gnus-mime-display-mixed (cdr handle)) + (gnus-mime-display-part (cadr handle)) (unless (bolp) (insert "\n")) (unless (gnus-unbuttonized-mime-type-p (car handle)) @@ -7260,6 +7663,34 @@ For example: (cons (set-marker (make-marker) (point-min)) (set-marker (make-marker) (point-max)))))) +(defun gnus-mime-security-run-function (function) + "Run FUNCTION with the security part under point." + (gnus-article-check-buffer) + (let ((data (get-text-property (point) 'gnus-data)) + buffer handle) + (when (and (stringp (car-safe data)) + (setq buffer (mm-handle-multipart-original-buffer data)) + (setq handle (cadr data))) + (if (bufferp (mm-handle-buffer handle)) + (progn + (setq handle (cons buffer (copy-sequence (cdr handle)))) + (mm-handle-set-undisplayer handle nil)) + (setq handle (mm-make-handle + buffer + (mm-handle-multipart-ctl-parameter handle 'protocol) + nil nil nil nil nil nil))) + (funcall function handle)))) + +(defun gnus-mime-security-save-part () + "Save the security part under point." + (interactive) + (gnus-mime-security-run-function 'mm-save-part)) + +(defun gnus-mime-security-pipe-part () + "Pipe the security part under point to a process." + (interactive) + (gnus-mime-security-run-function 'mm-pipe-part)) + (gnus-ems-redefine) (provide 'gnus-art) diff --git a/lisp/gnus-async.el b/lisp/gnus-async.el index 1b0074d..35af6bc 100644 --- a/lisp/gnus-async.el +++ b/lisp/gnus-async.el @@ -1,6 +1,7 @@ ;;; gnus-async.el --- asynchronous support for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-audio.el b/lisp/gnus-audio.el index 1171713..be10019 100644 --- a/lisp/gnus-audio.el +++ b/lisp/gnus-audio.el @@ -1,5 +1,7 @@ ;;; gnus-audio.el --- Sound effects for Gnus -;; Copyright (C) 1996, 2000, 2003 Free Software Foundation + +;; Copyright (C) 1996, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Steven L. Baur ;; Keywords: news, mail, multimedia @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-bcklg.el b/lisp/gnus-bcklg.el index e6564c4..e1456d8 100644 --- a/lisp/gnus-bcklg.el +++ b/lisp/gnus-bcklg.el @@ -1,6 +1,7 @@ ;;; gnus-bcklg.el --- backlog functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-cache.el b/lisp/gnus-cache.el index f54236a..b3e9b65 100644 --- a/lisp/gnus-cache.el +++ b/lisp/gnus-cache.el @@ -1,6 +1,7 @@ ;;; gnus-cache.el --- cache interface for Gnus + ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, -;; 2004, 2005 Free Software Foundation, Inc. +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -358,7 +359,7 @@ Returns the list of articles removed." (let ((alist (gnus-agent-load-alist gnus-newsgroup-name))) (unless (cdr (assoc article alist)) (setq gnus-newsgroup-undownloaded - (gnus-add-to-sorted-list + (gnus-add-to-sorted-list gnus-newsgroup-undownloaded article))))) (push article out)) (gnus-summary-update-download-mark article) @@ -490,7 +491,7 @@ Returns the list of articles removed." articles) (when (file-exists-p dir) (setq articles - (sort (mapcar (lambda (name) (string-to-int name)) + (sort (mapcar (lambda (name) (string-to-number name)) (directory-files dir nil "^[0-9]+$" t)) '<)) ;; Update the cache active file, just to synch more. @@ -682,7 +683,7 @@ If LOW, update the lower bound instead." ;; Separate articles from all other files and directories. (while files (if (string-match "^[0-9]+$" (file-name-nondirectory (car files))) - (push (string-to-int (file-name-nondirectory (pop files))) nums) + (push (string-to-number (file-name-nondirectory (pop files))) nums) (push (pop files) alphs))) ;; If we have nums, then this is probably a valid group. (when (setq nums (sort nums '<)) @@ -732,9 +733,11 @@ If GROUP is non-nil, also cater to `gnus-cacheable-groups' and ;;;###autoload (defun gnus-cache-rename-group (old-group new-group) - "Rename OLD-GROUP as NEW-GROUP. Always updates the cache, even when -disabled, as the old cache files would corrupt gnus when the cache was -next enabled. Depends upon the caller to determine whether group renaming is supported." + "Rename OLD-GROUP as NEW-GROUP. +Always updates the cache, even when disabled, as the old cache +files would corrupt Gnus when the cache was next enabled. It +depends on the caller to determine whether group renaming is +supported." (let ((old-dir (gnus-cache-file-name old-group "")) (new-dir (gnus-cache-file-name new-group ""))) (gnus-rename-file old-dir new-dir t)) @@ -744,9 +747,12 @@ next enabled. Depends upon the caller to determine whether group renaming is sup (let ((no-save gnus-cache-active-hashtb)) (unless gnus-cache-active-hashtb (gnus-cache-read-active)) - (let* ((old-group-hash-value (gnus-gethash old-group gnus-cache-active-hashtb)) - (new-group-hash-value (gnus-gethash new-group gnus-cache-active-hashtb)) - (delta (or old-group-hash-value new-group-hash-value))) + (let* ((old-group-hash-value + (gnus-gethash old-group gnus-cache-active-hashtb)) + (new-group-hash-value + (gnus-gethash new-group gnus-cache-active-hashtb)) + (delta + (or old-group-hash-value new-group-hash-value))) (gnus-sethash new-group old-group-hash-value gnus-cache-active-hashtb) (gnus-sethash old-group nil gnus-cache-active-hashtb) @@ -756,9 +762,11 @@ next enabled. Depends upon the caller to determine whether group renaming is sup ;;;###autoload (defun gnus-cache-delete-group (group) - "Delete GROUP. Always updates the cache, even when -disabled, as the old cache files would corrupt gnus when the cache was -next enabled. Depends upon the caller to determine whether group deletion is supported." + "Delete GROUP from the cache. +Always updates the cache, even when disabled, as the old cache +files would corrupt gnus when the cache was next enabled. +Depends upon the caller to determine whether group deletion is +supported." (let ((dir (gnus-cache-file-name group ""))) (gnus-delete-directory dir)) diff --git a/lisp/gnus-cite.el b/lisp/gnus-cite.el index f25d816..7c60d76 100644 --- a/lisp/gnus-cite.el +++ b/lisp/gnus-cite.el @@ -1,7 +1,7 @@ ;;; gnus-cite.el --- parse citations in articles for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Per Abhiddenware @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -136,131 +136,165 @@ the envelope From line." :group 'gnus-cite :type 'boolean) -(defface gnus-cite-attribution-face '((t - (:italic t))) - "Face used for attribution lines.") +(defface gnus-cite-attribution '((t (:italic t))) + "Face used for attribution lines." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-attribution-face 'face-alias 'gnus-cite-attribution) -(defcustom gnus-cite-attribution-face 'gnus-cite-attribution-face +(defcustom gnus-cite-attribution-face 'gnus-cite-attribution "Face used for attribution lines. It is merged with the face for the cited text belonging to the attribution." :version "22.1" :group 'gnus-cite :type 'face) -(defface gnus-cite-face-1 '((((class color) - (background dark)) - (:foreground "light blue")) - (((class color) - (background light)) - (:foreground "MidnightBlue")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-2 '((((class color) - (background dark)) - (:foreground "light cyan")) - (((class color) - (background light)) - (:foreground "firebrick")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-3 '((((class color) - (background dark)) - (:foreground "light yellow")) - (((class color) - (background light)) - (:foreground "dark green")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-4 '((((class color) - (background dark)) - (:foreground "light pink")) - (((class color) - (background light)) - (:foreground "OrangeRed")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-5 '((((class color) - (background dark)) - (:foreground "pale green")) - (((class color) - (background light)) - (:foreground "dark khaki")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-6 '((((class color) - (background dark)) - (:foreground "beige")) - (((class color) - (background light)) - (:foreground "dark violet")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-7 '((((class color) - (background dark)) - (:foreground "orange")) - (((class color) - (background light)) - (:foreground "SteelBlue4")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-8 '((((class color) - (background dark)) - (:foreground "magenta")) - (((class color) - (background light)) - (:foreground "magenta")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-9 '((((class color) - (background dark)) - (:foreground "violet")) - (((class color) - (background light)) - (:foreground "violet")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-10 '((((class color) - (background dark)) - (:foreground "medium purple")) - (((class color) - (background light)) - (:foreground "medium purple")) - (t - (:italic t))) - "Citation face.") - -(defface gnus-cite-face-11 '((((class color) - (background dark)) - (:foreground "turquoise")) - (((class color) - (background light)) - (:foreground "turquoise")) - (t - (:italic t))) - "Citation face.") +(defface gnus-cite-1 '((((class color) + (background dark)) + (:foreground "light blue")) + (((class color) + (background light)) + (:foreground "MidnightBlue")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-1 'face-alias 'gnus-cite-1) + +(defface gnus-cite-2 '((((class color) + (background dark)) + (:foreground "light cyan")) + (((class color) + (background light)) + (:foreground "firebrick")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-2 'face-alias 'gnus-cite-2) + +(defface gnus-cite-3 '((((class color) + (background dark)) + (:foreground "light yellow")) + (((class color) + (background light)) + (:foreground "dark green")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-3 'face-alias 'gnus-cite-3) + +(defface gnus-cite-4 '((((class color) + (background dark)) + (:foreground "light pink")) + (((class color) + (background light)) + (:foreground "OrangeRed")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-4 'face-alias 'gnus-cite-4) + +(defface gnus-cite-5 '((((class color) + (background dark)) + (:foreground "pale green")) + (((class color) + (background light)) + (:foreground "dark khaki")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-5 'face-alias 'gnus-cite-5) + +(defface gnus-cite-6 '((((class color) + (background dark)) + (:foreground "beige")) + (((class color) + (background light)) + (:foreground "dark violet")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-6 'face-alias 'gnus-cite-6) + +(defface gnus-cite-7 '((((class color) + (background dark)) + (:foreground "orange")) + (((class color) + (background light)) + (:foreground "SteelBlue4")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-7 'face-alias 'gnus-cite-7) + +(defface gnus-cite-8 '((((class color) + (background dark)) + (:foreground "magenta")) + (((class color) + (background light)) + (:foreground "magenta")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-8 'face-alias 'gnus-cite-8) + +(defface gnus-cite-9 '((((class color) + (background dark)) + (:foreground "violet")) + (((class color) + (background light)) + (:foreground "violet")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-9 'face-alias 'gnus-cite-9) + +(defface gnus-cite-10 '((((class color) + (background dark)) + (:foreground "medium purple")) + (((class color) + (background light)) + (:foreground "medium purple")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-10 'face-alias 'gnus-cite-10) + +(defface gnus-cite-11 '((((class color) + (background dark)) + (:foreground "turquoise")) + (((class color) + (background light)) + (:foreground "turquoise")) + (t + (:italic t))) + "Citation face." + :group 'gnus-cite) +;; backward-compatibility alias +(put 'gnus-cite-face-11 'face-alias 'gnus-cite-11) (defcustom gnus-cite-face-list - '(gnus-cite-face-1 gnus-cite-face-2 gnus-cite-face-3 gnus-cite-face-4 - gnus-cite-face-5 gnus-cite-face-6 gnus-cite-face-7 gnus-cite-face-8 - gnus-cite-face-9 gnus-cite-face-10 gnus-cite-face-11) + '(gnus-cite-1 gnus-cite-2 gnus-cite-3 gnus-cite-4 gnus-cite-5 gnus-cite-6 + gnus-cite-7 gnus-cite-8 gnus-cite-9 gnus-cite-10 gnus-cite-11) "*List of faces used for highlighting citations. When there are citations from multiple articles in the same message, @@ -286,8 +320,7 @@ This should make it easier to see who wrote what." ;; This has to go here because its default value depends on ;; gnus-cite-face-list. -(defcustom gnus-article-boring-faces (cons 'gnus-signature-face - gnus-cite-face-list) +(defcustom gnus-article-boring-faces (cons 'gnus-signature gnus-cite-face-list) "List of faces that are not worth reading. If an article has more pages below the one you are looking at, but nothing on those pages is a word of at least three letters that is not @@ -339,7 +372,7 @@ in a boring face, then the pages will be skipped." Each citation in the article will be highlighted with a different face. The faces are taken from `gnus-cite-face-list'. Attribution lines are highlighted with the same face as the -corresponding citation merged with `gnus-cite-attribution-face'. +corresponding citation merged with the face `gnus-cite-attribution'. Text is considered cited if at least `gnus-cite-minimum-match-count' lines matches `message-cite-prefix-regexp' with the same prefix. @@ -1003,6 +1036,7 @@ See also the documentation for `gnus-article-highlight-citation'." (when (< from to) (push (setq overlay (gnus-make-overlay from to)) gnus-cite-overlay-list) + (gnus-overlay-put overlay 'evaporate t) (gnus-overlay-put overlay 'face face)))))) (defun gnus-cite-toggle (prefix) diff --git a/lisp/gnus-cus.el b/lisp/gnus-cus.el index a5e09ca..f88f533 100644 --- a/lisp/gnus-cus.el +++ b/lisp/gnus-cus.el @@ -1,7 +1,7 @@ ;;; gnus-cus.el --- customization commands for Gnus -;; -;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Per Abrahamsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -67,7 +67,7 @@ if that value is non-nil." (set (make-local-variable 'widget-push-button-suffix) "") (set (make-local-variable 'widget-link-prefix) "") (set (make-local-variable 'widget-link-suffix) "")) - (gnus-run-hooks 'gnus-custom-mode-hook)) + (gnus-run-mode-hooks 'gnus-custom-mode-hook)) ;;; Group Customization: @@ -227,8 +227,11 @@ See `gnus-emphasis-alist'.") (const signature-file) (const organization) (const address) + (const x-face-file) (const name) - (const body)) + (const body) + (symbol) + (string :tag "Header")) (string :format "%v")))) "post style. See `gnus-posting-styles'.")) @@ -772,8 +775,8 @@ When called interactively, FILE defaults to the current score file. This can be changed using the `\\[gnus-score-change-score-file]' command." (interactive (list gnus-current-score-file)) (unless file - (error (format "No score file for %s" - (gnus-group-decoded-name gnus-newsgroup-name)))) + (error "No score file for %s" + (gnus-group-decoded-name gnus-newsgroup-name))) (let ((scores (gnus-score-load file)) (types (mapcar (lambda (entry) `(group :format "%v%h\n" @@ -1014,9 +1017,9 @@ articles in the thread. ;; gnus-agent-cat-prepare-category-field as I don't want the ;; group list to appear when customizing a topic. (widget-insert "\n") - - (let ((symb - (set + + (let ((symb + (set (make-local-variable 'gnus-agent-cat-groups) (widget-create `(choice diff --git a/lisp/gnus-delay.el b/lisp/gnus-delay.el index 371d9e0..db7c2dc 100644 --- a/lisp/gnus-delay.el +++ b/lisp/gnus-delay.el @@ -1,6 +1,7 @@ ;;; gnus-delay.el --- Delayed posting of articles -;; Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Kai Großjohann ;; Keywords: mail, news, extensions @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -39,7 +40,6 @@ (require 'gnus-draft) (autoload 'parse-time-string "parse-time" nil nil) -;;;###autoload (defgroup gnus-delay nil "Arrange for sending postings later." :version "22.1" @@ -195,5 +195,5 @@ Checking delayed messages is skipped if optional arg NO-CHECK is non-nil." ;; coding: iso-8859-1 ;; End: -;;; arch-tag: fb2ad634-a897-4142-a503-f5991ec2349d +;; arch-tag: fb2ad634-a897-4142-a503-f5991ec2349d ;;; gnus-delay.el ends here diff --git a/lisp/gnus-demon.el b/lisp/gnus-demon.el index 86ba34e..01457de 100644 --- a/lisp/gnus-demon.el +++ b/lisp/gnus-demon.el @@ -1,7 +1,7 @@ ;;; gnus-demon.el --- daemonic Gnus behaviour -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-diary.el b/lisp/gnus-diary.el index ef83122..f49f5b4 100644 --- a/lisp/gnus-diary.el +++ b/lisp/gnus-diary.el @@ -1,6 +1,6 @@ -;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend +;;; gnus-diary.el --- Wrapper around the NNDiary Gnus back end -;; Copyright (c) 2001, 2002, 2003 Free Software Foundation, Inc. +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Copyright (C) 1999, 2000, 2001 Didier Verna. ;; Author: Didier Verna @@ -22,7 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, write to the Free Software -;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +;; MA 02110-1301, USA. ;;; Commentary: @@ -32,63 +33,8 @@ ;; Description: ;; =========== -;; Gnus-Diary is a wrapper around the NNDiary Gnus backend. It is here to -;; make your nndiary-user life easier in different ways. So, you don't have -;; to use it if you don't want to. But, really, you should. - -;; Gnus-Diary offers the following features on top of the NNDiary backend: - -;; - A nice summary line format: -;; Displaying diary messages in standard summary line format (usually -;; something like ": ") is pretty useless. Most of the -;; time, you're the one who wrote the message, and you mostly want to see -;; the event's date. Gnus-Diary offers you a nice summary line format -;; which will do this. By default, a summary line will appear like this: -;; -;; : -;; -;; for example, here's how Joe's birthday is displayed in my -;; "nndiary:birhdays" summary buffer (the message is expirable, but will -;; never be deleted, as it specifies a regular event): -;; -;; E Sat, Sep 22 01, 12:00: Joe's birthday (in 6 months, 1 week) - -;; - More article sorting functions: -;; Gnus-Diary adds a new sorting function called -;; `gnus-summary-sort-by-schedule'. This function lets you organize your -;; diary summary buffers from the closest event to the farthest one. - -;; - Automatic generation of diary group parameters: -;; When you create a new diary group, or visit one, Gnus-Diary checks your -;; group parameters, and if needed, sets the summary line format to the -;; diary-specific value, adds the diary-specific sorting functions, and -;; also adds the different `X-Diary-*' headers to the group's -;; posting-style. It is then easier to send a diary message, because if -;; you use `C-u a' or `C-u m' on a diary group to prepare a message, these -;; headers will be inserted automatically (but not filled with proper -;; values yet). - -;; - An interactive mail-to-diary convertion function: -;; The function `gnus-diary-check-message' ensures that the current message -;; contains all the required diary headers, and prompts you for values / -;; correction if needed. This function is hooked in the nndiary backend so -;; that moving an article to an nndiary group will trigger it -;; automatically. It is also bound to `C-c D c' in message-mode and -;; article-edit-mode in order to ease the process of converting a usual -;; mail to a diary one. This function takes a prefix argument which will -;; force prompting of all diary headers, regardless of their -;; presence/validity. That way, you can very easily reschedule a diary -;; message for instance. - - -;; Usage: -;; ===== - -;; 0/ Don't use any `gnus-user-format-function-[d|D]'. Gnus-Diary provides -;; both of these (sorry if you used them before). -;; 1/ Add '(require 'gnus-diary) to your gnusrc file. -;; 2/ Customize your gnus-diary options to suit your needs. - +;; gnus-diary is a utility toolkit used on top of the nndiary back end. It is +;; now fully documented in the Gnus manual. ;; Bugs / Todo: @@ -102,8 +48,9 @@ (require 'gnus-art) (defgroup gnus-diary nil - "Utilities on top of the nndiary backend for Gnus." - :version "22.1") + "Utilities on top of the nndiary back end for Gnus." + :version "22.1" + :group 'gnus) (defcustom gnus-diary-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n" "*Summary line format for nndiary groups." @@ -134,7 +81,7 @@ There are currently two built-in format functions: :group 'gnus-diary) (defconst gnus-diary-version nndiary-version - "Current Diary backend version.") + "Current Diary back end version.") ;; Compatibility functions ================================================== @@ -330,7 +277,7 @@ Optional prefix (or REVERSE argument) means sort in reverse order." )) ;; Called when a group is subscribed. This is needed because groups created -;; because of mail splitting are *not* created with the backend function. +;; because of mail splitting are *not* created with the back end function. ;; Thus, `nndiary-request-create-group-hooks' is inoperative. (defun gnus-diary-maybe-update-group-parameters (group) (when (eq (car (gnus-find-method-for-group group)) 'nndiary) @@ -448,7 +395,7 @@ If ARG (or prefix) is non-nil, force prompting for all fields." ;; The end ================================================================== (defun gnus-diary-version () - "Current Diary backend version." + "Current Diary back end version." (interactive) (message "NNDiary version %s" nndiary-version)) diff --git a/lisp/gnus-dired.el b/lisp/gnus-dired.el index 3423cf6..dbb2cc1 100644 --- a/lisp/gnus-dired.el +++ b/lisp/gnus-dired.el @@ -1,7 +1,7 @@ ;;; gnus-dired.el --- utility functions where gnus and dired meet -;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Authors: Benjamin Rutt , ;; Shenghuo Zhu @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-draft.el b/lisp/gnus-draft.el index 2eca0ff..2c53aa7 100644 --- a/lisp/gnus-draft.el +++ b/lisp/gnus-draft.el @@ -1,6 +1,7 @@ ;;; gnus-draft.el --- draft message support for Gnus -;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -97,6 +98,7 @@ (interactive) (let ((article (gnus-summary-article-number)) (group gnus-newsgroup-name)) + (gnus-draft-check-draft-articles (list article)) (gnus-summary-mark-as-read article gnus-canceled-mark) (gnus-draft-setup article group t) (set-buffer-modified-p t) @@ -121,6 +123,7 @@ (let* ((articles (gnus-summary-work-articles n)) (total (length articles)) article) + (gnus-draft-check-draft-articles articles) (while (setq article (pop articles)) (gnus-summary-remove-process-mark article) (unless (memq article gnus-newsgroup-unsendable) @@ -143,6 +146,8 @@ message-send-hook)) (message-setup-hook (and (not is-queue) message-setup-hook)) + (message-signature (and (not is-queue) + message-signature)) (gnus-agent-queue-mail (and (not is-queue) gnus-agent-queue-mail)) (rfc2047-encode-encoded-words nil) @@ -151,7 +156,7 @@ ;; We read the meta-information that says how and where ;; this message is to be sent. (save-restriction - (message-narrow-to-head) + (message-narrow-to-headers) (when (re-search-forward (concat "^" (regexp-quote gnus-agent-target-move-group-header) ":") nil t) @@ -257,9 +262,12 @@ (goto-char (point-min)) (search-forward "\n\n") (forward-char -1) + (save-restriction + (narrow-to-region (point-min) (point)) + (setq ga + (message-fetch-field gnus-draft-meta-information-header))) (insert mail-header-separator) (forward-line 1) - (setq ga (message-fetch-field gnus-draft-meta-information-header)) (message-set-auto-save-file-name)))) (gnus-backlog-remove-article group narticle) (when (and ga @@ -284,6 +292,32 @@ "Say whether ARTICLE is sendable." (not (memq article gnus-newsgroup-unsendable))) +(defun gnus-draft-check-draft-articles (articles) + "Check whether the draft articles ARTICLES are under edit." + (when (equal gnus-newsgroup-name "nndraft:drafts") + (let ((buffers (buffer-list)) + file buffs buff) + (save-current-buffer + (while (and articles + (not buff)) + (setq file (nndraft-article-filename (pop articles)) + buffs buffers) + (while buffs + (set-buffer (setq buff (pop buffs))) + (if (and buffer-file-name + (string-equal (file-truename buffer-file-name) + (file-truename file)) + (buffer-modified-p)) + (setq buffs nil) + (setq buff nil))))) + (when buff + (let* ((window (get-buffer-window buff t)) + (frame (and window (window-frame window)))) + (if frame + (gnus-select-frame-set-input-focus frame) + (pop-to-buffer buff t))) + (error "The draft %s is under edit" file))))) + (provide 'gnus-draft) ;;; arch-tag: 3d92af58-8c97-4a5c-9db4-a98e85198022 diff --git a/lisp/gnus-dup.el b/lisp/gnus-dup.el index 98d20a6..bdff653 100644 --- a/lisp/gnus-dup.el +++ b/lisp/gnus-dup.el @@ -1,6 +1,7 @@ ;;; gnus-dup.el --- suppression of duplicate articles in Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-eform.el b/lisp/gnus-eform.el index ae5deba..be31e37 100644 --- a/lisp/gnus-eform.el +++ b/lisp/gnus-eform.el @@ -1,6 +1,7 @@ ;;; gnus-eform.el --- a mode for editing forms for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -83,7 +84,7 @@ It is a slightly enhanced emacs-lisp-mode. (use-local-map gnus-edit-form-mode-map) (make-local-variable 'gnus-edit-form-done-function) (make-local-variable 'gnus-prev-winconf) - (gnus-run-hooks 'gnus-edit-form-mode-hook)) + (gnus-run-mode-hooks 'gnus-edit-form-mode-hook)) (defun gnus-edit-form (form documentation exit-func) "Edit FORM in a new buffer. diff --git a/lisp/gnus-ems.el b/lisp/gnus-ems.el index 296a4ca..aed735f 100644 --- a/lisp/gnus-ems.el +++ b/lisp/gnus-ems.el @@ -1,6 +1,7 @@ ;;; gnus-ems.el --- functions for making Gnus work under different Emacsen -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-fun.el b/lisp/gnus-fun.el index 5dc28c6..9747e4b 100644 --- a/lisp/gnus-fun.el +++ b/lisp/gnus-fun.el @@ -1,5 +1,6 @@ ;;; gnus-fun.el --- various frivolous extension functions to Gnus -;; Copyright (C) 2002, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,6 +32,7 @@ (require 'mm-util) (require 'gnus-ems) (require 'gnus-util) +(require 'gnus) (defcustom gnus-x-face-directory (expand-file-name "x-faces" gnus-directory) "*Directory where X-Face PBM files are stored." @@ -44,21 +46,37 @@ :group 'gnus-fun :type 'string) -(defcustom gnus-convert-image-to-x-face-command "giftopnm %s | ppmnorm | pnmscale -width 48 -height 48 | ppmtopgm | pgmtopbm | pbmtoxbm | compface" +(defcustom gnus-convert-image-to-x-face-command + "convert -scale 48x48! %s xbm:- | xbm2xface.pl" "Command for converting an image to an X-Face. +The command must take a image filename (use \"%s\") as input. +The output must be the Face header data on stdout in PNG format. + By default it takes a GIF filename and output the X-Face header data on stdout." :version "22.1" :group 'gnus-fun - :type 'string) - -(defcustom gnus-convert-image-to-face-command "djpeg %s | ppmnorm | pnmscale -width 48 -height 48 | ppmquant %d | pnmtopng" - "Command for converting an image to an Face. -By default it takes a JPEG filename and output the Face header data -on stdout." + :type '(choice (const :tag "giftopnm, netpbm (GIF input only)" + "giftopnm %s | ppmnorm | pnmscale -width 48 -height 48 | ppmtopgm | pgmtopbm | pbmtoxbm | compface") + (const :tag "convert" + "convert -scale 48x48! %s xbm:- | xbm2xface.pl") + (string))) + +(defcustom gnus-convert-image-to-face-command + "convert -scale 48x48! %s -colors %d png:-" + "Command for converting an image to a Face. + +The command must take an image filename (first format argument +\"%s\") and the number of colors (second format argument: \"%d\") +as input. The output must be the Face header data on stdout in +PNG format." :version "22.1" :group 'gnus-fun - :type 'string) + :type '(choice (const :tag "djpeg, netpbm (JPG input only)" + "djpeg %s | ppmnorm | pnmscale -width 48 -height 48 | ppmquant %d | pnmtopng") + (const :tag "convert" + "convert -scale 48x48! %s -colors %d png:-") + (string))) (defcustom gnus-face-properties-alist (if (featurep 'xemacs) '((xface . (:face gnus-x-face))) @@ -81,6 +99,7 @@ See the manual for the valid properties for various image types. Currently, `pbm' is used for X-Face images and `png' is used for Face images in Emacs. Only the `:face' property is effective on the `xface' image type in XEmacs if it is built with the libcompface library." + :version "23.0" ;; No Gnus :group 'gnus-fun :type '(repeat (cons :format "%v" (symbol :tag "Image type") plist))) @@ -124,8 +143,11 @@ Output to the current buffer, replace text, and don't mingle error." ;;;###autoload (defun gnus-x-face-from-file (file) - "Insert an X-Face header based on an image file." - (interactive "fImage file name (by default GIF): ") + "Insert an X-Face header based on an image file. + +Depending on `gnus-convert-image-to-x-face-command' it may accept +different input formats." + (interactive "fImage file name: ") (when (file-exists-p file) (gnus-shell-command-to-string (format gnus-convert-image-to-x-face-command @@ -133,8 +155,11 @@ Output to the current buffer, replace text, and don't mingle error." ;;;###autoload (defun gnus-face-from-file (file) - "Return an Face header based on an image file." - (interactive "fImage file name (by default JPEG): ") + "Return a Face header based on an image file. + +Depending on `gnus-convert-image-to-face-command' it may accept +different input formats." + (interactive "fImage file name: ") (when (file-exists-p file) (let ((done nil) (attempt "") @@ -149,7 +174,7 @@ Output to the current buffer, replace text, and don't mingle error." quant)))) (if (> (length attempt) 726) (progn - (setq quant (- quant 2)) + (setq quant (- quant (if (< quant 10) 1 2))) (gnus-message 9 "Length %d; trying quant %d" (length attempt) quant)) (setq done t))) diff --git a/lisp/gnus-group.el b/lisp/gnus-group.el index c3a51b1..b601cab 100644 --- a/lisp/gnus-group.el +++ b/lisp/gnus-group.el @@ -1,6 +1,7 @@ ;;; gnus-group.el --- group mode commands for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -28,7 +29,7 @@ (eval-when-compile (require 'cl) - (defvar tool-bar-map)) + (defvar tool-bar-mode)) (require 'gnus) (require 'gnus-start) @@ -38,10 +39,11 @@ (require 'gnus-range) (require 'gnus-win) (require 'gnus-undo) +(require 'gmm-utils) (require 'time-date) (require 'gnus-ems) -(eval-when-compile +(eval-when-compile (require 'mm-url) (let ((features (cons 'gnus-group features))) (require 'gnus-sum)) @@ -287,14 +289,15 @@ variable." :type 'hook) (defcustom gnus-useful-groups - '(("(ding) mailing list mirrored at sunsite.auc.dk" - "emacs.ding" - (nntp "sunsite.auc.dk" - (nntp-address "sunsite.auc.dk"))) - ("gnus-bug archive" - "gnus-bug" - (nndir "/ftp@ftp.ifi.uio.no:/pub/emacs/gnus/gnus-bug/")) - ("Gnus help group" + '(("(ding) mailing list mirrored at gmane.org" + "gmane.emacs.gnus.general" + (nntp "Gmane" + (nntp-address "news.gmane.org"))) + ("Gnus bug archive" + "gnus.gnus-bug" + (nntp "news.gnus.org" + (nntp-address "news.gnus.org"))) + ("Local Gnus help group" "gnus-help" (nndoc "gnus-help" (nndoc-article-type mbox) @@ -313,50 +316,50 @@ variable." (defcustom gnus-group-highlight '(;; Mail. ((and mailp (= unread 0) (eq level 1)) . - gnus-group-mail-1-empty-face) + gnus-group-mail-1-empty) ((and mailp (eq level 1)) . - gnus-group-mail-1-face) + gnus-group-mail-1) ((and mailp (= unread 0) (eq level 2)) . - gnus-group-mail-2-empty-face) + gnus-group-mail-2-empty) ((and mailp (eq level 2)) . - gnus-group-mail-2-face) + gnus-group-mail-2) ((and mailp (= unread 0) (eq level 3)) . - gnus-group-mail-3-empty-face) + gnus-group-mail-3-empty) ((and mailp (eq level 3)) . - gnus-group-mail-3-face) + gnus-group-mail-3) ((and mailp (= unread 0)) . - gnus-group-mail-low-empty-face) + gnus-group-mail-low-empty) ((and mailp) . - gnus-group-mail-low-face) + gnus-group-mail-low) ;; News. ((and (= unread 0) (eq level 1)) . - gnus-group-news-1-empty-face) + gnus-group-news-1-empty) ((and (eq level 1)) . - gnus-group-news-1-face) + gnus-group-news-1) ((and (= unread 0) (eq level 2)) . - gnus-group-news-2-empty-face) + gnus-group-news-2-empty) ((and (eq level 2)) . - gnus-group-news-2-face) + gnus-group-news-2) ((and (= unread 0) (eq level 3)) . - gnus-group-news-3-empty-face) + gnus-group-news-3-empty) ((and (eq level 3)) . - gnus-group-news-3-face) + gnus-group-news-3) ((and (= unread 0) (eq level 4)) . - gnus-group-news-4-empty-face) + gnus-group-news-4-empty) ((and (eq level 4)) . - gnus-group-news-4-face) + gnus-group-news-4) ((and (= unread 0) (eq level 5)) . - gnus-group-news-5-empty-face) + gnus-group-news-5-empty) ((and (eq level 5)) . - gnus-group-news-5-face) + gnus-group-news-5) ((and (= unread 0) (eq level 6)) . - gnus-group-news-6-empty-face) + gnus-group-news-6-empty) ((and (eq level 6)) . - gnus-group-news-6-face) + gnus-group-news-6) ((and (= unread 0)) . - gnus-group-news-low-empty-face) + gnus-group-news-low-empty) (t . - gnus-group-news-low-face)) + gnus-group-news-low)) "*Controls the highlighting of group buffer lines. Below is a list of `Form'/`Face' pairs. When deciding how a a @@ -386,7 +389,7 @@ ticked: The number of ticked articles." :type 'character) (defgroup gnus-group-icons nil - "Add Icons to your group buffer. " + "Add Icons to your group buffer." :group 'gnus-group-visual) (defcustom gnus-group-icon-list @@ -656,6 +659,7 @@ simple manner.") "r" gnus-group-rename-group "R" gnus-group-make-rss-group "c" gnus-group-customize + "z" gnus-group-compact-group "x" gnus-group-nnimap-expunge "\177" gnus-group-delete-group [delete] gnus-group-delete-group) @@ -834,6 +838,8 @@ simple manner.") (gnus-group-group-name)] ["Select quick" gnus-group-quick-select-group (gnus-group-group-name)] ["Customize" gnus-group-customize (gnus-group-group-name)] + ["Compact" gnus-group-compact-group + :active (gnus-group-group-name)] ("Edit" ["Parameters" gnus-group-edit-group-parameters :included (not (gnus-topic-mode-p)) @@ -990,36 +996,146 @@ simple manner.") (gnus-run-hooks 'gnus-group-menu-hook))) -(defvar gnus-group-toolbar-map nil) - -;; Emacs 21 tool bar. Should be no-op otherwise. -(defun gnus-group-make-tool-bar () - (if (and - (condition-case nil (require 'tool-bar) (error nil)) - (fboundp 'tool-bar-add-item-from-menu) - (default-value 'tool-bar-mode) - (not gnus-group-toolbar-map)) - (setq gnus-group-toolbar-map - (let ((tool-bar-map (make-sparse-keymap)) - (load-path (mm-image-load-path))) - (tool-bar-add-item-from-menu - 'gnus-group-get-new-news "get-news" gnus-group-mode-map) - (tool-bar-add-item-from-menu - 'gnus-group-get-new-news-this-group "gnntg" gnus-group-mode-map) - (tool-bar-add-item-from-menu - 'gnus-group-catchup-current "catchup" gnus-group-mode-map) - (tool-bar-add-item-from-menu - 'gnus-group-describe-group "describe-group" gnus-group-mode-map) - (tool-bar-add-item "subscribe" 'gnus-group-subscribe 'subscribe - :help "Subscribe to the current group") - (tool-bar-add-item "unsubscribe" 'gnus-group-unsubscribe - 'unsubscribe - :help "Unsubscribe from the current group") - (tool-bar-add-item-from-menu - 'gnus-group-exit "exit-gnus" gnus-group-mode-map) - tool-bar-map))) - (if gnus-group-toolbar-map - (set (make-local-variable 'tool-bar-map) gnus-group-toolbar-map))) + +(defvar gnus-group-tool-bar-map nil) + +(defun gnus-group-tool-bar-update (&optional symbol value) + "Update group buffer toolbar. +Setter function for custom variables." + (when symbol + (set-default symbol value)) + ;; (setq-default gnus-group-tool-bar-map nil) + ;; (use-local-map gnus-group-mode-map) + (when (gnus-alive-p) + (with-current-buffer gnus-group-buffer + (gnus-group-make-tool-bar t)))) + +(defcustom gnus-group-tool-bar (if (eq gmm-tool-bar-style 'gnome) + 'gnus-group-tool-bar-gnome + 'gnus-group-tool-bar-retro) + "Specifies the Gnus group tool bar. + +It can be either a list or a symbol refering to a list. See +`gmm-tool-bar-from-list' for the format of the list. The +default key map is `gnus-group-mode-map'. + +Pre-defined symbols include `gnus-group-tool-bar-gnome' and +`gnus-group-tool-bar-retro'." + :type '(choice (const :tag "GNOME style" gnus-group-tool-bar-gnome) + (const :tag "Retro look" gnus-group-tool-bar-retro) + (repeat :tag "User defined list" gmm-tool-bar-item) + (symbol)) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-group-tool-bar-update + :group 'gnus-group) + +(defcustom gnus-group-tool-bar-gnome + '((gnus-group-post-news "mail/compose") + ;; Some useful agent icons? I don't use the agent so agent users should + ;; suggest useful commands: + (gnus-agent-toggle-plugged "connect" t + :visible (and gnus-agent (not gnus-plugged))) + (gnus-agent-toggle-plugged "disconnect" t + :visible (and gnus-agent gnus-plugged)) + ;; FIXME: gnus-agent-toggle-plugged (in gnus-agent-group-make-menu-bar) + ;; should have a better help text. + (gnus-group-send-queue "mail/outbox" t + :visible (and gnus-agent gnus-plugged) + :help "Send articles from the queue group") + (gnus-group-get-new-news "mail/inbox" nil + :visible (or (not gnus-agent) + gnus-plugged)) + ;; FIXME: gnus-*-read-group should have a better help text. + (gnus-topic-read-group "open" nil + :visible (and (boundp 'gnus-topic-mode) + gnus-topic-mode)) + (gnus-group-read-group "open" nil + :visible (not (and (boundp 'gnus-topic-mode) + gnus-topic-mode))) + ;; (gnus-group-find-new-groups "???" nil) + (gnus-group-save-newsrc "save") + (gnus-group-describe-group "describe") + (gnus-group-unsubscribe-current-group "gnus/toggle-subscription") + (gnus-group-prev-unread-group "left-arrow") + (gnus-group-next-unread-group "right-arrow") + (gnus-group-exit "exit") + (gmm-customize-mode "preferences" t :help "Edit mode preferences") + (gnus-info-find-node "help")) + "List of functions for the group tool bar (GNOME style). + +See `gmm-tool-bar-from-list' for the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-group-tool-bar-update + :group 'gnus-group) + +(defcustom gnus-group-tool-bar-retro + '((gnus-group-get-new-news "gnus/get-news") + (gnus-group-get-new-news-this-group "gnus/gnntg") + (gnus-group-catchup-current "gnus/catchup") + (gnus-group-describe-group "gnus/describe-group") + (gnus-group-subscribe "gnus/subscribe" t + :help "Subscribe to the current group") + (gnus-group-unsubscribe "gnus/unsubscribe" t + :help "Unsubscribe from the current group") + (gnus-group-exit "gnus/exit-gnus" gnus-group-mode-map)) + "List of functions for the group tool bar (retro look). + +See `gmm-tool-bar-from-list' for the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-group-tool-bar-update + :group 'gnus-group) + +;; FIXME: Moving through the Group buffer (in topic mode) e.g. with C-n +;; doesn't update the state (enabled/disabled) of the icon +;; `gnus-group-describe-group'. After `C-l' the state is correct. +;; See the following report on emacs-devel +;; : +;; From: Reiner Steib +;; Subject: tool bar icons not updated according to :active condition +;; Newsgroups: gmane.emacs.devel +;; Date: Mon, 23 Jan 2006 19:59:13 +0100 +;; Message-ID: + +(defcustom gnus-group-tool-bar-zap-list t + "List of icon items from the global tool bar. +These items are not displayed in the Gnus group mode tool bar. + +See `gmm-tool-bar-from-list' for the format of the list." + :type 'gmm-tool-bar-zap-list + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-group-tool-bar-update + :group 'gnus-group) + +(defvar image-load-path) + +(defun gnus-group-make-tool-bar (&optional force) + "Make a group mode tool bar from `gnus-group-tool-bar'. +When FORCE, rebuild the tool bar." + (when (and (not (featurep 'xemacs)) + (boundp 'tool-bar-mode) + tool-bar-mode + ;; The Gnus 5.10.6 code checked (default-value 'tool-bar-mode). + ;; Why? --rsteib + (or (not gnus-group-tool-bar-map) force)) + (let* ((load-path + (gmm-image-load-path-for-library "gnus" + "gnus/toggle-subscription.xpm" + nil t)) + (image-load-path (cons (car load-path) + (when (boundp 'image-load-path) + image-load-path))) + (map (gmm-tool-bar-from-list gnus-group-tool-bar + gnus-group-tool-bar-zap-list + 'gnus-group-mode-map))) + (if map + (set (make-local-variable 'tool-bar-map) map)))) + gnus-group-tool-bar-map) (defun gnus-group-mode () "Major mode for reading news. @@ -1060,7 +1176,7 @@ The following commands are available: (gnus-undo-mode 1)) (when gnus-slave (gnus-slave-mode)) - (gnus-run-hooks 'gnus-group-mode-hook)) + (gnus-run-mode-hooks 'gnus-group-mode-hook)) (defun gnus-update-group-mark-positions () (save-excursion @@ -1391,6 +1507,25 @@ if it is a string, only list groups matching REGEXP." (gnus-range-difference (list active) (gnus-info-read info)) seen)))))) +(defcustom gnus-group-update-tool-bar + (and (not (featurep 'xemacs)) + (boundp 'tool-bar-mode) + tool-bar-mode + ;; Using `redraw-frame' (see `gnus-tool-bar-update') in Emacs 21 might + ;; be confusing, so maybe we shouldn't call it by default. + (fboundp 'force-window-update)) + "Force updating the group buffer tool bar." + :group 'gnus-group + :version "22.1" + :initialize 'custom-initialize-default + :set (lambda (symbol value) + (set-default symbol value) + (when (gnus-alive-p) + (with-current-buffer gnus-group-buffer + ;; FIXME: Is there a better way to redraw the group buffer? + (gnus-group-get-new-news 0)))) + :type 'boolean) + (defun gnus-group-insert-group-line (gnus-tmp-group gnus-tmp-level gnus-tmp-marked number gnus-tmp-method) @@ -1455,8 +1590,10 @@ if it is a string, only list groups matching REGEXP." (if (member gnus-tmp-group gnus-group-marked) gnus-process-mark ? )) (buffer-read-only nil) + beg end header gnus-tmp-header) ; passed as parameter to user-funcs. (beginning-of-line) + (setq beg (point)) (gnus-add-text-properties (point) (prog1 (1+ (point)) @@ -1466,11 +1603,17 @@ if it is a string, only list groups matching REGEXP." (eval gnus-group-line-format-spec))) `(gnus-group ,(gnus-intern-safe gnus-tmp-group gnus-active-hashtb) gnus-unread ,(if (numberp number) - (string-to-int gnus-tmp-number-of-unread) + (string-to-number gnus-tmp-number-of-unread) t) gnus-marked ,gnus-tmp-marked-mark gnus-indentation ,gnus-group-indentation gnus-level ,gnus-tmp-level)) + (setq end (point)) + (when gnus-group-update-tool-bar + (gnus-put-text-property beg end 'point-entered + 'gnus-tool-bar-update) + (gnus-put-text-property beg end 'point-left + 'gnus-tool-bar-update)) (forward-line -1) (when (inline (gnus-visual-p 'group-highlight 'highlight)) (gnus-run-hooks 'gnus-group-update-hook)) @@ -1699,7 +1842,7 @@ If FIRST-TOO, the current line is also eligible as a target." (size (+ size-in-cache size-in-agent)) (suffix '("B" "K" "M" "G")) (scale 1024.0) - (cutoff (* 10 scale))) + (cutoff scale)) (while (> size cutoff) (setq size (/ size scale) suffix (cdr suffix))) @@ -2243,6 +2386,25 @@ If EXCLUDE-GROUP, do not go to that group." (gnus-group-position-point) (and best-point (gnus-group-group-name)))) +;; Is there something like an after-point-motion-hook? +;; (inhibit-point-motion-hooks?). Is there a tool-bar-update function? + +;; (defun gnus-group-menu-bar-update () +;; (let* ((buf (list (with-current-buffer gnus-group-buffer +;; (current-buffer)))) +;; (name (buffer-name (car buf)))) +;; (setcdr buf +;; (if (> (length name) 27) +;; (concat (substring name 0 12) +;; "..." +;; (substring name -12)) +;; name)) +;; (menu-bar-update-buffers-1 buf))) + +;; (defun gnus-group-position-point () +;; (gnus-goto-colon) +;; (gnus-group-menu-bar-update)) + (defun gnus-group-first-unread-group () "Go to the first group with unread articles." (interactive) @@ -3288,7 +3450,7 @@ Uses the process/prefix convention." (progn (unless (gnus-group-process-prefix current-prefix-arg) (error "No group on the current line")) - (string-to-int + (string-to-number (let ((s (read-string (format "Level (default %s): " (or (gnus-group-group-level) @@ -3634,7 +3796,10 @@ re-scanning. If ARG is non-nil and not a number, this will force ;; We might read in new NoCeM messages here. (when (and gnus-use-nocem - (null arg)) + (or (and (numberp gnus-use-nocem) + (numberp arg) + (>= arg gnus-use-nocem)) + (not arg))) (gnus-nocem-scan-groups)) ;; If ARG is not a number, then we read the active file. (when (and arg (not (numberp arg))) @@ -4338,6 +4503,40 @@ This command may read the active file." (gnus-add-marked-articles group 'expire (list article)))))) + +;;; +;;; Group compaction. -- dvl +;;; + +(defun gnus-group-compact-group (group) + "Compact the current group. +Compaction means removing gaps between article numbers. Hence, this +operation is only meaningful for back ends using one file per article +\(e.g. nnml). + +Note: currently only implemented in nnml." + (interactive (list (gnus-group-group-name))) + (unless group + (error "No group to compact")) + (unless (gnus-check-backend-function 'request-compact-group group) + (error "This back end does not support group compaction")) + (let ((group-decoded (gnus-group-decoded-name group))) + (gnus-message 6 "\ +Compacting group %s... (this may take a long time)" + group-decoded) + (prog1 + (if (not (gnus-request-compact-group group)) + (gnus-error 3 "Couldn't compact group %s" group-decoded) + (gnus-message 6 "Compacting group %s...done" group-decoded) + t) + ;; Invalidate the "original article" buffer which might be out of date. + ;; #### NOTE: Yes, this might be a bit rude, but since compaction + ;; #### will not happen very often, I think this is acceptable. + (let ((original (get-buffer gnus-original-article-buffer))) + (and original (gnus-kill-buffer original))) + ;; Update the group line to reflect new information (art number etc). + (gnus-group-update-group-line)))) + (provide 'gnus-group) ;;; arch-tag: 2eb5440f-0bca-4091-814c-e37817536af6 diff --git a/lisp/gnus-int.el b/lisp/gnus-int.el index 8d47064..586b005 100644 --- a/lisp/gnus-int.el +++ b/lisp/gnus-int.el @@ -1,6 +1,7 @@ ;;; gnus-int.el --- backend interface functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -249,10 +250,12 @@ If it is down, start it up (again)." ;; recurse to open the agent's backend. (setq open-offline (eq gnus-server-unopen-status 'offline)) gnus-server-unopen-status) - ((gnus-y-or-n-p - (format "Unable to open %s:%s, go offline? " - (car gnus-command-method) - (cadr gnus-command-method))) + ((and + (not gnus-batch-mode) + (gnus-y-or-n-p + (format "Unable to open %s:%s, go offline? " + (car gnus-command-method) + (cadr gnus-command-method)))) (setq open-offline t) 'offline) (t @@ -332,6 +335,23 @@ name. The method this group uses will be queried." (funcall (gnus-get-function gnus-command-method 'request-regenerate) (nth 1 gnus-command-method))) +(defun gnus-request-compact-group (group) + (let* ((method (gnus-find-method-for-group group)) + (gnus-command-method method) + (result + (funcall (gnus-get-function gnus-command-method + 'request-compact-group) + (gnus-group-real-name group) + (nth 1 gnus-command-method) t))) + result)) + +(defun gnus-request-compact (gnus-command-method) + "Request groups compaction from GNUS-COMMAND-METHOD." + (when (stringp gnus-command-method) + (setq gnus-command-method (gnus-server-to-method gnus-command-method))) + (funcall (gnus-get-function gnus-command-method 'request-compact) + (nth 1 gnus-command-method))) + (defun gnus-request-group (group &optional dont-check gnus-command-method) "Request GROUP. If DONT-CHECK, no information is required." (let ((gnus-command-method diff --git a/lisp/gnus-kill.el b/lisp/gnus-kill.el index 68146b3..97b5ec5 100644 --- a/lisp/gnus-kill.el +++ b/lisp/gnus-kill.el @@ -1,6 +1,7 @@ ;;; gnus-kill.el --- kill commands for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -161,7 +162,7 @@ gnus-kill-file-mode-hook with no arguments, if that value is non-nil." (setq major-mode 'gnus-kill-file-mode) (setq mode-name "Kill") (lisp-mode-variables nil) - (gnus-run-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook)) + (gnus-run-mode-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook)) (defun gnus-kill-file-edit-file (newsgroup) "Begin editing a kill file for NEWSGROUP. diff --git a/lisp/gnus-logic.el b/lisp/gnus-logic.el index 0baf705..b7091ed 100644 --- a/lisp/gnus-logic.el +++ b/lisp/gnus-logic.el @@ -1,6 +1,7 @@ ;;; gnus-logic.el --- advanced scoring code for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-mh.el b/lisp/gnus-mh.el index 75ccab4..34c310f 100644 --- a/lisp/gnus-mh.el +++ b/lisp/gnus-mh.el @@ -1,6 +1,7 @@ ;;; gnus-mh.el --- mh-e interface for Gnus -;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-ml.el b/lisp/gnus-ml.el index 87d645b..75ed4f4 100644 --- a/lisp/gnus-ml.el +++ b/lisp/gnus-ml.el @@ -1,6 +1,7 @@ ;;; gnus-ml.el --- Mailing list minor mode for Gnus -;; Copyright (C) 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Julien Gilles ;; Keywords: news, mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-mlspl.el b/lisp/gnus-mlspl.el index 4a6809e..12b8abe 100644 --- a/lisp/gnus-mlspl.el +++ b/lisp/gnus-mlspl.el @@ -1,7 +1,7 @@ ;;; gnus-mlspl.el --- a group params-based mail splitting mechanism -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Alexandre Oliva ;; Keywords: news, mail @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-move.el b/lisp/gnus-move.el index 26f8305..9cecb2f 100644 --- a/lisp/gnus-move.el +++ b/lisp/gnus-move.el @@ -1,6 +1,7 @@ ;;; gnus-move.el --- commands for moving Gnus from one server to another -;; Copyright (C) 1996, 1997, 1998, 1999, 2000 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-msg.el b/lisp/gnus-msg.el index da7916d..8ae9518 100644 --- a/lisp/gnus-msg.el +++ b/lisp/gnus-msg.el @@ -1,6 +1,7 @@ ;;; gnus-msg.el --- mail and post interface for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -;; 2005 Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -66,8 +67,10 @@ message in, you can set this variable to a function that checks the current newsgroup name and then returns a suitable group name (or list of names)." :group 'gnus-message - :type '(choice (string :tag "Group") - (function))) + :type '(choice (const nil) + (function) + (string :tag "Group") + (repeat :tag "List of groups" (string :tag "Group")))) (defcustom gnus-mailing-list-groups nil "*If non-nil a regexp matching groups that are really mailing lists. @@ -471,27 +474,19 @@ Gcc: header for archiving purposes." ;; COMPOSEFUNC should return t if succeed. Undocumented ??? t) -(defvar save-selected-window-window) - ;;;###autoload (defun gnus-button-mailto (address) "Mail to ADDRESS." (set-buffer (gnus-copy-article-buffer)) (gnus-setup-message 'message - (message-reply address)) - (and (boundp 'save-selected-window-window) - (not (window-live-p save-selected-window-window)) - (setq save-selected-window-window (selected-window)))) + (message-reply address))) ;;;###autoload (defun gnus-button-reply (&optional to-address wide) "Like `message-reply'." (interactive) (gnus-setup-message 'message - (message-reply to-address wide)) - (and (boundp 'save-selected-window-window) - (not (window-live-p save-selected-window-window)) - (setq save-selected-window-window (selected-window)))) + (message-reply to-address wide))) ;;;###autoload (define-mail-user-agent 'gnus-user-agent @@ -522,7 +517,7 @@ Gcc: header for archiving purposes." (gnus-make-local-hook 'message-header-hook) (add-hook 'message-header-hook 'gnus-agent-possibly-save-gcc nil t)) (setq message-post-method - `(lambda (arg) + `(lambda (&optional arg) (gnus-post-method arg ,gnus-newsgroup-name))) (setq message-newsreader (setq message-mailer (gnus-extended-version))) (message-add-action @@ -852,6 +847,7 @@ header line with the old Message-ID." (delete-region (point) (point-max)) (insert yank-string)) (gnus-article-delete-text-of-type 'annotation) + (gnus-article-delete-text-of-type 'multipart) (gnus-remove-text-with-property 'gnus-prev) (gnus-remove-text-with-property 'gnus-next) (gnus-remove-text-with-property 'gnus-decoration) @@ -1670,7 +1666,7 @@ this is a reply." (gcc (cond ((functionp group) (funcall group)) - ((or (stringp group) (list group)) + ((or (stringp group) (listp group)) group)))) (when gcc (insert "Gcc: " diff --git a/lisp/gnus-nocem.el b/lisp/gnus-nocem.el index 487b77e..f40bdba 100644 --- a/lisp/gnus-nocem.el +++ b/lisp/gnus-nocem.el @@ -1,8 +1,7 @@ ;;; gnus-nocem.el --- NoCeM pseudo-cancellation treatment -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2004 -;; Free Software Foundation, Inc. - +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -21,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -37,7 +36,7 @@ (require 'gnus-range) (defgroup gnus-nocem nil - "NoCeM pseudo-cancellation treatment" + "NoCeM pseudo-cancellation treatment." :group 'gnus-score) (defcustom gnus-nocem-groups @@ -74,12 +73,13 @@ issuer registry." :group 'gnus-nocem :type 'integer) -(defcustom gnus-nocem-verifyer 'mc-verify +(defcustom gnus-nocem-verifyer 'pgg-verify "*Function called to verify that the NoCeM message is valid. -One likely value is `mc-verify'. If the function in this variable +One likely value is `pgg-verify'. If the function in this variable isn't bound, the message will be used unconditionally." :group 'gnus-nocem - :type '(radio (function-item mc-verify) + :type '(radio (function-item pgg-verify) + (function-item mc-verify) (function :tag "other"))) (defcustom gnus-nocem-liberal-fetch nil @@ -129,13 +129,15 @@ valid issuer, which is much faster if you are selective about the issuers." (defun gnus-fill-real-hashtb () "Fill up a hash table with the real-name mappings from the user's active file." - (setq gnus-nocem-real-group-hashtb (gnus-make-hashtable - (length gnus-newsrc-alist))) + (if (hash-table-p gnus-nocem-real-group-hashtb) + (clrhash gnus-nocem-real-group-hashtb) + (setq gnus-nocem-real-group-hashtb (make-hash-table :test 'equal))) (mapcar (lambda (group) (setq group (gnus-group-real-name (car group))) - (gnus-sethash group t gnus-nocem-real-group-hashtb)) + (puthash group t gnus-nocem-real-group-hashtb)) gnus-newsrc-alist)) +;;;###autoload (defun gnus-nocem-scan-groups () "Scan all NoCeM groups for new NoCeM messages." (interactive) @@ -206,10 +208,10 @@ valid issuer, which is much faster if you are selective about the issuers." (not (member (mail-header-message-id header) gnus-nocem-seen-message-ids)))) (push header check-headers))) - (let* ((i 0) - (check-headers - (last check-headers gnus-nocem-check-article-limit)) - (len (length check-headers))) + (setq check-headers (last (nreverse check-headers) + gnus-nocem-check-article-limit)) + (let ((i 0) + (len (length check-headers))) (dolist (h check-headers) (gnus-message 7 "Checking article %d in %s for NoCeM (%d of %d)..." @@ -235,9 +237,13 @@ valid issuer, which is much faster if you are selective about the issuers." (days-to-time gnus-nocem-expiry-wait))) (gnus-request-article-this-buffer (mail-header-number header) group) (goto-char (point-min)) - (when (re-search-forward "-----BEGIN PGP MESSAGE-----" nil t) + (when (re-search-forward + "-----BEGIN PGP\\(?: SIGNED\\)? MESSAGE-----" + nil t) (delete-region (point-min) (match-beginning 0))) - (when (re-search-forward "-----END PGP MESSAGE-----\n?" nil t) + (when (re-search-forward + "-----END PGP \\(?:MESSAGE\\|SIGNATURE\\)-----\n?" + nil t) (delete-region (match-end 0) (point-max))) (goto-char (point-min)) ;; The article has to have proper NoCeM headers. @@ -246,7 +252,7 @@ valid issuer, which is much faster if you are selective about the issuers." ;; We get the name of the issuer. (narrow-to-region b e) (setq issuer (mail-fetch-field "issuer") - type (mail-fetch-field "issuer")) + type (mail-fetch-field "type")) (widen) (if (not (gnus-nocem-message-wanted-p issuer type)) (message "invalid NoCeM issuer: %s" issuer) @@ -267,18 +273,20 @@ valid issuer, which is much faster if you are selective about the issuers." (while (setq condition (pop conditions)) (cond ((stringp condition) - (setq wanted (string-match condition type))) + (when (string-match condition type) + (setq wanted t))) ((and (consp condition) (eq (car condition) 'not) (stringp (cadr condition))) - (setq wanted (not (string-match (cadr condition) type)))) + (when (string-match (cadr condition) type) + (setq wanted nil))) (t (error "Invalid NoCeM condition: %S" condition)))) wanted)))) (defun gnus-nocem-verify-issuer (person) "Verify using PGP that the canceler is who she says she is." - (if (fboundp gnus-nocem-verifyer) + (if (functionp gnus-nocem-verifyer) (ignore-errors (funcall gnus-nocem-verifyer)) ;; If we don't have Mailcrypt, then we use the message anyway. @@ -297,31 +305,26 @@ valid issuer, which is much faster if you are selective about the issuers." (while (search-forward "\t" nil t) (cond ((not (ignore-errors - (setq group (let ((obarray gnus-nocem-real-group-hashtb)) - (read buf))))) + (setq group (gnus-group-real-name (symbol-name (read buf)))) + (gethash group gnus-nocem-real-group-hashtb))) ;; An error. ) - ((not (symbolp group)) - ;; Ignore invalid entries. - ) - ((not (boundp group)) - ;; Make sure all entries in the hashtb are bound. - (set group nil)) (t - (when (gnus-gethash (gnus-group-real-name (symbol-name group)) - gnus-nocem-real-group-hashtb) - ;; Valid group. - (beginning-of-line) - (while (eq (char-after) ?\t) - (forward-line -1)) - (setq id (buffer-substring (point) (1- (search-forward "\t")))) - (unless (gnus-gethash id gnus-nocem-hashtb) - ;; only store if not already present - (gnus-sethash id t gnus-nocem-hashtb) - (push id ncm)) - (forward-line 1) - (while (eq (char-after) ?\t) - (forward-line 1)))))) + ;; Valid group. + (beginning-of-line) + (while (eq (char-after) ?\t) + (forward-line -1)) + (setq id (buffer-substring (point) (1- (search-forward "\t")))) + (unless (if (hash-table-p gnus-nocem-hashtb) + (gethash id gnus-nocem-hashtb) + (setq gnus-nocem-hashtb (make-hash-table :test 'equal)) + nil) + ;; only store if not already present + (puthash id t gnus-nocem-hashtb) + (push id ncm)) + (forward-line 1) + (while (eq (char-after) ?\t) + (forward-line 1))))) (when ncm (setq gnus-nocem-touched-alist t) (push (cons (let ((time (current-time))) (setcdr (cdr time) nil) time) @@ -329,6 +332,7 @@ valid issuer, which is much faster if you are selective about the issuers." gnus-nocem-alist)) t))) +;;;###autoload (defun gnus-nocem-load-cache () "Load the NoCeM cache." (interactive) @@ -359,7 +363,9 @@ valid issuer, which is much faster if you are selective about the issuers." (prev pprev) (expiry (days-to-time gnus-nocem-expiry-wait)) entry) - (setq gnus-nocem-hashtb (gnus-make-hashtable (* (length alist) 51))) + (if (hash-table-p gnus-nocem-hashtb) + (clrhash gnus-nocem-hashtb) + (setq gnus-nocem-hashtb (make-hash-table :test 'equal))) (while (setq entry (car alist)) (if (not (time-less-p (time-since (car entry)) expiry)) ;; This entry has expired, so we remove it. @@ -368,7 +374,7 @@ valid issuer, which is much faster if you are selective about the issuers." ;; This is ok, so we enter it into the hashtable. (setq entry (cdr entry)) (while entry - (gnus-sethash (car entry) t gnus-nocem-hashtb) + (puthash (car entry) t gnus-nocem-hashtb) (setq entry (cdr entry)))) (setq alist (cdr alist))))) @@ -386,7 +392,7 @@ valid issuer, which is much faster if you are selective about the issuers." (defun gnus-nocem-unwanted-article-p (id) "Say whether article ID in the current group is wanted." (and gnus-nocem-hashtb - (gnus-gethash id gnus-nocem-hashtb))) + (gethash id gnus-nocem-hashtb))) (provide 'gnus-nocem) diff --git a/lisp/gnus-picon.el b/lisp/gnus-picon.el index ef75a17..0e4c772 100644 --- a/lisp/gnus-picon.el +++ b/lisp/gnus-picon.el @@ -1,7 +1,7 @@ ;;; gnus-picon.el --- displaying pretty icons in Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news xpm annotation glyph faces @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -83,13 +83,17 @@ added right to the textual representation." (const right)) :group 'gnus-picon) -(defface gnus-picon-xbm-face '((t (:foreground "black" :background "white"))) +(defface gnus-picon-xbm '((t (:foreground "black" :background "white"))) "Face to show xbm picon in." :group 'gnus-picon) +;; backward-compatibility alias +(put 'gnus-picon-xbm-face 'face-alias 'gnus-picon-xbm) -(defface gnus-picon-face '((t (:foreground "black" :background "white"))) +(defface gnus-picon '((t (:foreground "black" :background "white"))) "Face to show picon in." :group 'gnus-picon) +;; backward-compatibility alias +(put 'gnus-picon-face 'face-alias 'gnus-picon) ;;; Internal variables: diff --git a/lisp/gnus-range.el b/lisp/gnus-range.el index 454712a..13a00dd 100644 --- a/lisp/gnus-range.el +++ b/lisp/gnus-range.el @@ -1,7 +1,7 @@ ;;; gnus-range.el --- range and sequence functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-registry.el b/lisp/gnus-registry.el index 5c9c205..192f644 100644 --- a/lisp/gnus-registry.el +++ b/lisp/gnus-registry.el @@ -1,6 +1,7 @@ ;;; gnus-registry.el --- article registry for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Ted Zlatanov ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-salt.el b/lisp/gnus-salt.el index cd2aec8..3f92c97 100644 --- a/lisp/gnus-salt.el +++ b/lisp/gnus-salt.el @@ -1,7 +1,7 @@ ;;; gnus-salt.el --- alternate summary mode interfaces for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2001 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -128,8 +128,7 @@ It accepts the same format specs that `gnus-summary-line-format' does." ;; Set up the menu. (when (gnus-visual-p 'pick-menu 'menu) (gnus-pick-make-menu-bar)) - (add-minor-mode 'gnus-pick-mode " Pick" gnus-pick-mode-map - nil 'gnus-pick-mode) + (add-minor-mode 'gnus-pick-mode " Pick" gnus-pick-mode-map) (gnus-run-hooks 'gnus-pick-mode-hook)))) (defun gnus-pick-setup-message () @@ -362,8 +361,7 @@ This must be bound to a button-down mouse event." ;; Set up the menu. (when (gnus-visual-p 'binary-menu 'menu) (gnus-binary-make-menu-bar)) - (add-minor-mode 'gnus-binary-mode " Binary" - gnus-binary-mode-map nil 'gnus-binary-mode) + (add-minor-mode 'gnus-binary-mode " Binary" gnus-binary-mode-map) (gnus-run-hooks 'gnus-binary-mode-hook)))) (defun gnus-binary-display-article (article &optional all-header) @@ -496,7 +494,7 @@ Two predefined functions are available: (gnus-set-work-buffer) (gnus-tree-node-insert (make-mail-header "") nil) (setq gnus-tree-node-length (1- (point)))) - (gnus-run-hooks 'gnus-tree-mode-hook)) + (gnus-run-mode-hooks 'gnus-tree-mode-hook)) (defun gnus-tree-read-summary-keys (&optional arg) "Read a summary buffer key sequence and execute it." @@ -1009,7 +1007,7 @@ The following commands are available: (buffer-disable-undo) (setq buffer-read-only t) (make-local-variable 'gnus-carpal-attached-buffer) - (gnus-run-hooks 'gnus-carpal-mode-hook)) + (gnus-run-mode-hooks 'gnus-carpal-mode-hook)) (defun gnus-carpal-setup-buffer (type) (let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type))))) diff --git a/lisp/gnus-score.el b/lisp/gnus-score.el index 5c3d74a..e0b4612 100644 --- a/lisp/gnus-score.el +++ b/lisp/gnus-score.el @@ -1,6 +1,7 @@ ;;; gnus-score.el --- scoring code for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Per Abrahamsen ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -139,7 +140,7 @@ If this variable is nil, no score file entries will be expired." number)) (defcustom gnus-update-score-entry-dates t - "*In non-nil, update matching score entry dates. + "*If non-nil, update matching score entry dates. If this variable is nil, then score entries that provide matches will be expired along with non-matching score entries." :group 'gnus-score-expire @@ -178,7 +179,7 @@ It is called with one parameter -- the score to be decayed." It can be: * A string - This file file will be used as the home score file. + This file will be used as the home score file. * A function The result of this function will be used as the home score file. @@ -189,7 +190,7 @@ It can be: The elements in this list can be: * `(regexp file-name ...)' - If the `regexp' matches the group name, the first `file-name' will + If the `regexp' matches the group name, the first `file-name' will be used as the home score file. (Multiple filenames are allowed so that one may use gnus-score-file-single-match-alist to set this variable.) @@ -224,13 +225,22 @@ This variable allows the same syntax as `gnus-home-score-file'." (function :value fun))) (defcustom gnus-default-adaptive-score-alist - '((gnus-kill-file-mark) + `((gnus-kill-file-mark) (gnus-unread-mark) - (gnus-read-mark (from 3) (subject 30)) - (gnus-catchup-mark (subject -10)) - (gnus-killed-mark (from -1) (subject -20)) - (gnus-del-mark (from -2) (subject -15))) - "*Alist of marks and scores." + (gnus-read-mark + (from , (+ 2 gnus-score-decay-constant)) + (subject , (+ 27 gnus-score-decay-constant))) + (gnus-catchup-mark + (subject , (+ -7 (* -1 gnus-score-decay-constant)))) + (gnus-killed-mark + (from , (- -1 gnus-score-decay-constant)) + (subject , (+ -17 (* -1 gnus-score-decay-constant)))) + (gnus-del-mark + (from , (- -1 gnus-score-decay-constant)) + (subject , (+ -12 (* -1 gnus-score-decay-constant))))) + "Alist of marks and scores. +If you use score decays, you might want to set values higher than +`gnus-score-decay-constant'." :group 'gnus-score-adapt :type '(repeat (cons (symbol :tag "Mark") (repeat (list (choice :tag "Header" @@ -662,7 +672,7 @@ file for the command instead of the current score file." (intern ; need symbol (gnus-completing-read-with-default (symbol-name (car gnus-extra-headers)) ; default response - "Score extra header:" ; prompt + "Score extra header" ; prompt (mapcar (lambda (x) ; completion list (cons (symbol-name x) x)) gnus-extra-headers) @@ -837,7 +847,7 @@ If optional argument `EXTRA' is non-nil, it's a non-standard overview header." ;; If this is an integer comparison, we transform from string to int. (if (eq (nth 2 (assoc header gnus-header-index)) 'gnus-score-integer) (if (stringp match) - (setq match (string-to-int match))) + (setq match (string-to-number match))) (set-text-properties 0 (length match) nil match)) (unless (eq date 'now) @@ -902,7 +912,7 @@ EXTRA is the possible non-standard header." t) (read-string "Match: ") (if (y-or-n-p "Use regexp match? ") 'r 's) - (string-to-int (read-string "Score: ")))) + (string-to-number (read-string "Score: ")))) (save-excursion (unless (and (stringp match) (> (length match) 0)) (error "No match")) @@ -956,7 +966,7 @@ EXTRA is the possible non-standard header." "Automatically mark articles with score below SCORE as read." (interactive (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) - (string-to-int (read-string "Mark below: "))))) + (string-to-number (read-string "Mark below: "))))) (setq score (or score gnus-summary-default-score 0)) (gnus-score-set 'mark (list score)) (gnus-score-set 'touched '(t)) @@ -990,7 +1000,7 @@ EXTRA is the possible non-standard header." "Automatically expunge articles with score below SCORE." (interactive (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) - (string-to-int (read-string "Set expunge below: "))))) + (string-to-number (read-string "Set expunge below: "))))) (setq score (or score gnus-summary-default-score 0)) (gnus-score-set 'expunge (list score)) (gnus-score-set 'touched '(t))) @@ -1104,7 +1114,11 @@ EXTRA is the possible non-standard header." "Edit the all.SCORE file." (interactive) (find-file (gnus-score-file-name "all")) - (gnus-score-mode)) + (gnus-score-mode) + (setq gnus-score-edit-exit-function 'gnus-score-edit-done) + (gnus-message + 4 (substitute-command-keys + "\\\\[gnus-score-edit-exit] to save edits"))) (defun gnus-score-edit-file (file) "Edit a score file." diff --git a/lisp/gnus-setup.el b/lisp/gnus-setup.el index 1acb6f2..2e8d641 100644 --- a/lisp/gnus-setup.el +++ b/lisp/gnus-setup.el @@ -1,7 +1,7 @@ ;;; gnus-setup.el --- Initialization & Setup for Gnus 5 -;; Copyright (C) 1995, 1996, 2000, 2001, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Steven L. Baur ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;; My head is starting to spin with all the different mail/news packages. diff --git a/lisp/gnus-sieve.el b/lisp/gnus-sieve.el index e7409c3..99e8f6b 100644 --- a/lisp/gnus-sieve.el +++ b/lisp/gnus-sieve.el @@ -1,5 +1,6 @@ ;;; gnus-sieve.el --- Utilities to manage sieve scripts for Gnus -;; Copyright (C) 2001, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: NAGY Andras , ;; Simon Josefsson @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -129,7 +130,7 @@ Return nil if no rule could be guessed." (let ((rule (gnus-sieve-guess-rule-for-article)) (info (gnus-get-info gnus-newsgroup-name))) (if (null rule) - (error "Could not guess rule for article.") + (error "Could not guess rule for article") (gnus-info-set-params info (cons rule (gnus-info-params info))) (message "Added rule in group %s for article: %s" gnus-newsgroup-name rule))))) diff --git a/lisp/gnus-soup.el b/lisp/gnus-soup.el index 4b1185a..cca3159 100644 --- a/lisp/gnus-soup.el +++ b/lisp/gnus-soup.el @@ -1,7 +1,7 @@ ;;; gnus-soup.el --- SOUP packet writing support for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Per Abrahamsen ;; Lars Magne Ingebrigtsen @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -349,9 +349,9 @@ If NOT-ALL, don't pack ticked articles." (packer (if (< (string-match "%s" packer) (string-match "%d" packer)) (format packer files - (string-to-int (gnus-soup-unique-prefix dir))) + (string-to-number (gnus-soup-unique-prefix dir))) (format packer - (string-to-int (gnus-soup-unique-prefix dir)) + (string-to-number (gnus-soup-unique-prefix dir)) files))) (dir (expand-file-name dir))) (gnus-make-directory dir) @@ -385,7 +385,7 @@ though the two last may be nil if they are missing." (and (eq (preceding-char) ?\t) (gnus-soup-field)) (and (eq (preceding-char) ?\t) - (string-to-int (gnus-soup-field)))) + (string-to-number (gnus-soup-field)))) areas) (when (eq (preceding-char) ?\t) (beginning-of-line 2))) @@ -535,7 +535,7 @@ Return whether the unpacking was successful." (error "Bad header")) (forward-line 1) (setq beg (point) - end (+ (point) (string-to-int + end (+ (point) (string-to-number (buffer-substring (match-beginning 1) (match-end 1))))) (switch-to-buffer tmp-buf) diff --git a/lisp/gnus-spec.el b/lisp/gnus-spec.el index 201c5dd..4bf7571 100644 --- a/lisp/gnus-spec.el +++ b/lisp/gnus-spec.el @@ -1,6 +1,7 @@ ;;; gnus-spec.el --- format spec functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,14 +20,15 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;;; Code: (eval-when-compile (require 'cl)) +(defvar gnus-newsrc-file-version) (require 'gnus) @@ -510,7 +512,7 @@ are supported for %s." (t (if (null args) (error 'wrong-number-of-arguments #'my-format n fstring)) - (let* ((minlen (string-to-int (or (match-string 2) ""))) + (let* ((minlen (string-to-number (or (match-string 2) ""))) (arg (car args)) (str (if (stringp arg) arg (format "%s" arg))) (lpad (null (match-string 1))) diff --git a/lisp/gnus-srvr.el b/lisp/gnus-srvr.el index d33022c..f92b1ac 100644 --- a/lisp/gnus-srvr.el +++ b/lisp/gnus-srvr.el @@ -1,6 +1,7 @@ ;;; gnus-srvr.el --- virtual server support for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -115,6 +116,7 @@ If nil, a faster, but more primitive, buffer is used instead." ["Copy" gnus-server-copy-server t] ["Edit" gnus-server-edit-server t] ["Regenerate" gnus-server-regenerate-server t] + ["Compact" gnus-server-compact-server t] ["Exit" gnus-server-exit t])) (easy-menu-define @@ -164,70 +166,82 @@ If nil, a faster, but more primitive, buffer is used instead." "g" gnus-server-regenerate-server + "z" gnus-server-compact-server + "\C-c\C-i" gnus-info-find-node "\C-c\C-b" gnus-bug)) -(defface gnus-server-agent-face +(defface gnus-server-agent '((((class color) (background light)) (:foreground "PaleTurquoise" :bold t)) (((class color) (background dark)) (:foreground "PaleTurquoise" :bold t)) (t (:bold t))) "Face used for displaying AGENTIZED servers" :group 'gnus-server-visual) +;; backward-compatibility alias +(put 'gnus-server-agent-face 'face-alias 'gnus-server-agent) -(defface gnus-server-opened-face +(defface gnus-server-opened '((((class color) (background light)) (:foreground "Green3" :bold t)) (((class color) (background dark)) (:foreground "Green1" :bold t)) (t (:bold t))) "Face used for displaying OPENED servers" :group 'gnus-server-visual) +;; backward-compatibility alias +(put 'gnus-server-opened-face 'face-alias 'gnus-server-opened) -(defface gnus-server-closed-face +(defface gnus-server-closed '((((class color) (background light)) (:foreground "Steel Blue" :italic t)) (((class color) (background dark)) (:foreground "Light Steel Blue" :italic t)) (t (:italic t))) "Face used for displaying CLOSED servers" :group 'gnus-server-visual) +;; backward-compatibility alias +(put 'gnus-server-closed-face 'face-alias 'gnus-server-closed) -(defface gnus-server-denied-face +(defface gnus-server-denied '((((class color) (background light)) (:foreground "Red" :bold t)) (((class color) (background dark)) (:foreground "Pink" :bold t)) (t (:inverse-video t :bold t))) "Face used for displaying DENIED servers" :group 'gnus-server-visual) +;; backward-compatibility alias +(put 'gnus-server-denied-face 'face-alias 'gnus-server-denied) -(defface gnus-server-offline-face +(defface gnus-server-offline '((((class color) (background light)) (:foreground "Orange" :bold t)) (((class color) (background dark)) (:foreground "Yellow" :bold t)) (t (:inverse-video t :bold t))) "Face used for displaying OFFLINE servers" :group 'gnus-server-visual) +;; backward-compatibility alias +(put 'gnus-server-offline-face 'face-alias 'gnus-server-offline) -(defcustom gnus-server-agent-face 'gnus-server-agent-face +(defcustom gnus-server-agent-face 'gnus-server-agent "Face name to use on AGENTIZED servers." :version "22.1" :group 'gnus-server-visual :type 'face) -(defcustom gnus-server-opened-face 'gnus-server-opened-face +(defcustom gnus-server-opened-face 'gnus-server-opened "Face name to use on OPENED servers." :version "22.1" :group 'gnus-server-visual :type 'face) -(defcustom gnus-server-closed-face 'gnus-server-closed-face +(defcustom gnus-server-closed-face 'gnus-server-closed "Face name to use on CLOSED servers." :version "22.1" :group 'gnus-server-visual :type 'face) -(defcustom gnus-server-denied-face 'gnus-server-denied-face +(defcustom gnus-server-denied-face 'gnus-server-denied "Face name to use on DENIED servers." :version "22.1" :group 'gnus-server-visual :type 'face) -(defcustom gnus-server-offline-face 'gnus-server-offline-face +(defcustom gnus-server-offline-face 'gnus-server-offline "Face name to use on OFFLINE servers." :version "22.1" :group 'gnus-server-visual @@ -269,7 +283,7 @@ The following commands are available: (put 'gnus-server-mode 'font-lock-defaults '(gnus-server-font-lock-keywords t)) (set (make-local-variable 'font-lock-defaults) '(gnus-server-font-lock-keywords t))) - (gnus-run-hooks 'gnus-server-mode-hook)) + (gnus-run-mode-hooks 'gnus-server-mode-hook)) (defun gnus-server-insert-server-line (gnus-tmp-name method) (let* ((gnus-tmp-how (car method)) @@ -861,7 +875,7 @@ buffer. (setq truncate-lines t) (gnus-set-default-directory) (setq buffer-read-only t) - (gnus-run-hooks 'gnus-browse-mode-hook)) + (gnus-run-mode-hooks 'gnus-browse-mode-hook)) (defun gnus-browse-read-group (&optional no-article number) "Enter the group at the current line. @@ -1001,6 +1015,40 @@ If NUMBER, fetch this number of articles." (gnus-message 5 "Requesting regeneration of %s...done" server) (gnus-message 5 "Couldn't regenerate %s" server)))) + +;;; +;;; Server compaction. -- dvl +;;; + +;; #### FIXME: this function currently fails to update the Group buffer's +;; #### appearance. +(defun gnus-server-compact-server () + "Issue a command to the server to compact all its groups. + +Note: currently only implemented in nnml." + (interactive) + (let ((server (gnus-server-server-name))) + (unless server + (error "No server on the current line")) + (condition-case () + (gnus-get-function (gnus-server-to-method server) + 'request-compact) + (error + (error "This back end doesn't support compaction"))) + (gnus-message 5 "\ +Requesting compaction of %s... (this may take a long time)" + server) + (unless (gnus-open-server server) + (error "Couldn't open server")) + (if (not (gnus-request-compact server)) + (gnus-message 5 "Couldn't compact %s" server) + (gnus-message 5 "Requesting compaction of %s...done" server) + ;; Invalidate the original article buffer which might be out of date. + ;; #### NOTE: Yes, this might be a bit rude, but since compaction + ;; #### will not happen very often, I think this is acceptable. + (let ((original (get-buffer gnus-original-article-buffer))) + (and original (gnus-kill-buffer original)))))) + (provide 'gnus-srvr) ;;; arch-tag: c0117f64-27ca-475d-9406-8da6854c7a25 diff --git a/lisp/gnus-start.el b/lisp/gnus-start.el index c990667..8791fb2 100644 --- a/lisp/gnus-start.el +++ b/lisp/gnus-start.el @@ -1,6 +1,7 @@ ;;; gnus-start.el --- startup functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -611,7 +612,7 @@ Can be used to turn version control on or off." "Subscribe the new GROUP interactively. It is inserted in hierarchical newsgroup order if subscribed. If not, it is killed." - (if (gnus-y-or-n-p (format "Subscribe new newsgroup: %s " group)) + (if (gnus-y-or-n-p (format "Subscribe new newsgroup %s? " group)) (gnus-subscribe-hierarchically group) (push group gnus-killed-list))) @@ -721,11 +722,12 @@ the first newsgroup." (defun gnus-no-server-1 (&optional arg slave) "Read network news. -If ARG is a positive number, Gnus will use that as the -startup level. If ARG is nil, Gnus will be started at level 2. -If ARG is non-nil and not a positive number, Gnus will -prompt the user for the name of an NNTP server to use. -As opposed to `gnus', this command will not connect to the local server." +If ARG is a positive number, Gnus will use that as the startup +level. If ARG is nil, Gnus will be started at level 2 +\(`gnus-level-default-subscribed' minus one). If ARG is non-nil +and not a positive number, Gnus will prompt the user for the name +of an NNTP server to use. As opposed to \\[gnus], this command +will not connect to the local server." (interactive "P") (let ((val (or arg (1- gnus-level-default-subscribed)))) (gnus val t slave) @@ -753,6 +755,13 @@ prompt the user for the name of an NNTP server to use." (nnheader-init-server-buffer) (setq gnus-slave slave) (gnus-read-init-file) + + ;; Add "native" to gnus-predefined-server-alist just to have a + ;; name for the native select method. + (when gnus-select-method + (push (cons "native" gnus-select-method) + gnus-predefined-server-alist)) + (if gnus-agent (gnus-agentize)) @@ -805,7 +814,10 @@ prompt the user for the name of an NNTP server to use." (gnus-request-create-group "drafts" '(nndraft "")) (unless (gnus-group-entry "nndraft:drafts") (let ((gnus-level-default-subscribed 1)) - (gnus-subscribe-group "nndraft:drafts" nil '(nndraft ""))) + (gnus-subscribe-group "nndraft:drafts" nil '(nndraft "")))) + (unless (equal (gnus-group-get-parameter "nndraft:drafts" 'gnus-dummy t) + '((gnus-draft-mode))) + (gnus-message 3 "Setting up drafts group") (gnus-group-set-parameter "nndraft:drafts" 'gnus-dummy '((gnus-draft-mode))))) @@ -857,6 +869,7 @@ prompt the user for the name of an NNTP server to use." (set-buffer (setq gnus-dribble-buffer (gnus-get-buffer-create (file-name-nondirectory dribble-file)))) + (set (make-local-variable 'file-precious-flag) t) (erase-buffer) (setq buffer-file-name dribble-file) (auto-save-mode t) @@ -1040,9 +1053,12 @@ If LEVEL is non-nil, the news will be set up at level LEVEL." (gnus-check-bogus-newsgroups)) ;; We might read in new NoCeM messages here. - (when (and gnus-use-nocem - (not level) - (not dont-connect)) + (when (and (not dont-connect) + gnus-use-nocem + (or (and (numberp gnus-use-nocem) + (numberp level) + (>= level gnus-use-nocem)) + (not level))) (gnus-nocem-scan-groups)) ;; Read any slave files. @@ -1528,8 +1544,8 @@ If SCAN, request a scan of that group as well." ;; command may have responded with the `(0 . 0)'. We ;; ignore this if we already have an active entry ;; for the group. - (if (and (zerop (car active)) - (zerop (cdr active)) + (if (and (zerop (or (car active) 0)) + (zerop (or (cdr active) 0)) (gnus-active group)) (gnus-active group) @@ -2533,7 +2549,7 @@ If FORCE is non-nil, the .newsrc file is read." (cond ((looking-at "[0-9]+") ;; We narrow and read a number instead of buffer-substring/ - ;; string-to-int because it's faster. narrow/widen is + ;; string-to-number because it's faster. narrow/widen is ;; faster than save-restriction/narrow, and save-restriction ;; produces a garbage object. (setq num1 (progn @@ -2827,6 +2843,7 @@ If FORCE is non-nil, the .newsrc file is read." (print-escape-nonascii t) (print-length nil) (print-level nil) + (print-circle nil) (print-escape-newlines t) (gnus-killed-list (if (and gnus-save-killed-list diff --git a/lisp/gnus-sum.el b/lisp/gnus-sum.el index 6480c51..085a4bc 100644 --- a/lisp/gnus-sum.el +++ b/lisp/gnus-sum.el @@ -1,6 +1,7 @@ ;;; gnus-sum.el --- summary mode commands for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -28,7 +29,7 @@ (eval-when-compile (require 'cl) - (defvar tool-bar-map)) + (defvar tool-bar-mode)) (require 'gnus) (require 'gnus-group) @@ -37,6 +38,7 @@ (require 'gnus-int) (require 'gnus-undo) (require 'gnus-util) +(require 'gmm-utils) (require 'mm-decode) (require 'nnoo) @@ -62,17 +64,21 @@ it will be killed sometime later." (defcustom gnus-fetch-old-headers nil "*Non-nil means that Gnus will try to build threads by grabbing old headers. -If an unread article in the group refers to an older, already read (or -just marked as read) article, the old article will not normally be -displayed in the Summary buffer. If this variable is t, Gnus -will attempt to grab the headers to the old articles, and thereby -build complete threads. If it has the value `some', only enough -headers to connect otherwise loose threads will be displayed. This -variable can also be a number. In that case, no more than that number -of old headers will be fetched. If it has the value `invisible', all +If an unread article in the group refers to an older, already +read (or just marked as read) article, the old article will not +normally be displayed in the Summary buffer. If this variable is +t, Gnus will attempt to grab the headers to the old articles, and +thereby build complete threads. If it has the value `some', all +old headers will be fetched but only enough headers to connect +otherwise loose threads will be displayed. This variable can +also be a number. In that case, no more than that number of old +headers will be fetched. If it has the value `invisible', all old headers will be fetched, but none will be displayed. -The server has to support NOV for any of this to work." +The server has to support NOV for any of this to work. + +This feature can seriously impact performance it ignores all +locally cached header entries." :group 'gnus-thread :type '(choice (const :tag "off" nil) (const :tag "on" t) @@ -256,8 +262,7 @@ simplification is selected." "*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." +`gnus-summary-show-thread' by hand or select an article." :group 'gnus-thread :type '(radio (sexp :format "Non-nil\n" :match (lambda (widget value) @@ -320,7 +325,7 @@ This variable can either be the symbols `first' (place point on the first subject), `unread' (place point on the subject line of the first unread article), `best' (place point on the subject line of the higest-scored article), `unseen' (place point on the subject line of -the first unseen article), 'unseen-or-unread' (place point on the subject +the first unseen article), `unseen-or-unread' (place point on the subject line of the first unseen article or, if all article have been seen, on the subject line of the first unread article), or a function to be called to place point on some subject line." @@ -780,20 +785,21 @@ Each list item can also be a list `(not F)' where F is a function; this specifies reversed sort order. 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', -`gnus-thread-sort-by-most-recent-number', -`gnus-thread-sort-by-most-recent-date', -`gnus-thread-sort-by-random', and -`gnus-thread-sort-by-total-score' (see `gnus-thread-score-function'). +`gnus-thread-sort-by-author', `gnus-thread-sort-by-recipient' +`gnus-thread-sort-by-subject', `gnus-thread-sort-by-date', +`gnus-thread-sort-by-score', `gnus-thread-sort-by-most-recent-number', +`gnus-thread-sort-by-most-recent-date', `gnus-thread-sort-by-random', +and `gnus-thread-sort-by-total-score' (see +`gnus-thread-score-function'). When threading is turned off, the variable `gnus-article-sort-functions' controls how articles are sorted." :group 'gnus-summary-sort - :type '(repeat + :type '(repeat (gnus-widget-reversible (choice (function-item gnus-thread-sort-by-number) (function-item gnus-thread-sort-by-author) + (function-item gnus-thread-sort-by-recipient) (function-item gnus-thread-sort-by-subject) (function-item gnus-thread-sort-by-date) (function-item gnus-thread-sort-by-score) @@ -972,7 +978,7 @@ automatically when it is selected." :group 'gnus-summary :type 'boolean) -(defcustom gnus-summary-selected-face 'gnus-summary-selected-face +(defcustom gnus-summary-selected-face 'gnus-summary-selected "Face used for highlighting the current article in the summary buffer." :group 'gnus-summary-visual :type 'face) @@ -981,42 +987,42 @@ automatically when it is selected." (defcustom gnus-summary-highlight '(((eq mark gnus-canceled-mark) - . gnus-summary-cancelled-face) + . gnus-summary-cancelled) ((and uncached (> score default-high)) - . gnus-summary-high-undownloaded-face) + . gnus-summary-high-undownloaded) ((and uncached (< score default-low)) - . gnus-summary-low-undownloaded-face) + . gnus-summary-low-undownloaded) (uncached - . gnus-summary-normal-undownloaded-face) + . gnus-summary-normal-undownloaded) ((and (> score default-high) (or (eq mark gnus-dormant-mark) (eq mark gnus-ticked-mark))) - . gnus-summary-high-ticked-face) + . gnus-summary-high-ticked) ((and (< score default-low) (or (eq mark gnus-dormant-mark) (eq mark gnus-ticked-mark))) - . gnus-summary-low-ticked-face) + . gnus-summary-low-ticked) ((or (eq mark gnus-dormant-mark) (eq mark gnus-ticked-mark)) - . gnus-summary-normal-ticked-face) + . gnus-summary-normal-ticked) ((and (> score default-high) (eq mark gnus-ancient-mark)) - . gnus-summary-high-ancient-face) + . gnus-summary-high-ancient) ((and (< score default-low) (eq mark gnus-ancient-mark)) - . gnus-summary-low-ancient-face) + . gnus-summary-low-ancient) ((eq mark gnus-ancient-mark) - . gnus-summary-normal-ancient-face) + . gnus-summary-normal-ancient) ((and (> score default-high) (eq mark gnus-unread-mark)) - . gnus-summary-high-unread-face) + . gnus-summary-high-unread) ((and (< score default-low) (eq mark gnus-unread-mark)) - . gnus-summary-low-unread-face) + . gnus-summary-low-unread) ((eq mark gnus-unread-mark) - . gnus-summary-normal-unread-face) + . gnus-summary-normal-unread) ((> score default-high) - . gnus-summary-high-read-face) + . gnus-summary-high-read) ((< score default-low) - . gnus-summary-low-read-face) + . gnus-summary-low-read) (t - . gnus-summary-normal-read-face)) + . gnus-summary-normal-read)) "*Controls the highlighting of summary buffer lines. A list of (FORM . FACE) pairs. When deciding how a a particular @@ -1055,12 +1061,28 @@ which it may alter in any way." :type '(repeat symbol)) (defcustom gnus-ignored-from-addresses - (and user-mail-address (regexp-quote user-mail-address)) + (and user-mail-address + (not (string= user-mail-address "")) + (regexp-quote user-mail-address)) "*Regexp of From headers that may be suppressed in favor of To headers." :version "21.1" :group 'gnus-summary :type 'regexp) +(defcustom gnus-summary-to-prefix "-> " + "*String prefixed to the To field in the summary line when +using `gnus-ignored-from-addresses'." + :version "22.1" + :group 'gnus-summary + :type 'string) + +(defcustom gnus-summary-newsgroup-prefix "=> " + "*String prefixed to the Newsgroup field in the summary +line when using `gnus-ignored-from-addresses'." + :version "22.1" + :group 'gnus-summary + :type 'string) + (defcustom gnus-newsgroup-ignored-charsets '(unknown-8bit x-unknown) "List of charsets that should be ignored. When these charsets are used in the \"charset\" parameter, the @@ -1891,6 +1913,7 @@ increase the score of each group you read." "Q" gnus-summary-exit "Z" gnus-summary-exit "n" gnus-summary-catchup-and-goto-next-group + "p" gnus-summary-catchup-and-goto-prev-group "R" gnus-summary-reselect-current-group "G" gnus-summary-rescan-group "N" gnus-summary-next-group @@ -2057,6 +2080,10 @@ increase the score of each group you read." "m" gnus-summary-repair-multipart "v" gnus-article-view-part "o" gnus-article-save-part + "O" gnus-article-save-part-and-strip + "r" gnus-article-replace-part + "d" gnus-article-delete-part + "j" gnus-article-jump-to-part "c" gnus-article-copy-part "C" gnus-article-view-part-as-charset "e" gnus-article-view-part-externally @@ -2594,6 +2621,7 @@ gnus-summary-show-article-from-menu-as-charset-%s" cs)))) '(:help "Mark unread articles in this group as read, then exit"))] ["Catchup all and exit" gnus-summary-catchup-all-and-exit t] ["Catchup and goto next" gnus-summary-catchup-and-goto-next-group t] + ["Catchup and goto prev" gnus-summary-catchup-and-goto-prev-group t] ["Exit group" gnus-summary-exit ,@(if (featurep 'xemacs) '(t) '(:help "Exit current group, return to group selection mode"))] @@ -2608,49 +2636,161 @@ gnus-summary-show-article-from-menu-as-charset-%s" cs)))) (defvar gnus-summary-tool-bar-map nil) -;; Emacs 21 tool bar. Should be no-op otherwise. -(defun gnus-summary-make-tool-bar () - (if (and (fboundp 'tool-bar-add-item-from-menu) - (default-value 'tool-bar-mode) - (not gnus-summary-tool-bar-map)) - (setq gnus-summary-tool-bar-map - (let ((tool-bar-map (make-sparse-keymap)) - (load-path (mm-image-load-path))) - (tool-bar-add-item-from-menu - 'gnus-summary-prev-unread "prev-ur" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-next-unread "next-ur" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-post-news "post" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-followup-with-original "fuwo" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-followup "followup" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-reply-with-original "reply-wo" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-reply "reply" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-caesar-message "rot13" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-uu-decode-uu "uu-decode" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-save-article-file "save-aif" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-save-article "save-art" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-uu-post-news "uu-post" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-uu-post-news "uu-post" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-catchup "catchup" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-catchup-and-exit "cu-exit" gnus-summary-mode-map) - (tool-bar-add-item-from-menu - 'gnus-summary-exit "exit-summ" gnus-summary-mode-map) - tool-bar-map))) - (if gnus-summary-tool-bar-map - (set (make-local-variable 'tool-bar-map) gnus-summary-tool-bar-map))) +;; Note: The :set function in the `gnus-summary-tool-bar*' variables will only +;; affect _new_ message buffers. We might add a function that walks thru all +;; summary-mode buffers and force the update. +(defun gnus-summary-tool-bar-update (&optional symbol value) + "Update summary mode toolbar. +Setter function for custom variables." + (setq-default gnus-summary-tool-bar-map nil) + (when symbol + ;; When used as ":set" function: + (set-default symbol value)) + (when (gnus-buffer-live-p gnus-summary-buffer) + (with-current-buffer gnus-summary-buffer + (gnus-summary-make-tool-bar)))) + +(defcustom gnus-summary-tool-bar (if (eq gmm-tool-bar-style 'gnome) + 'gnus-summary-tool-bar-gnome + 'gnus-summary-tool-bar-retro) + "Specifies the Gnus summary tool bar. + +It can be either a list or a symbol refering to a list. See +`gmm-tool-bar-from-list' for the format of the list. The +default key map is `gnus-summary-mode-map'. + +Pre-defined symbols include `gnus-summary-tool-bar-gnome' and +`gnus-summary-tool-bar-retro'." + :type '(choice (const :tag "GNOME style" gnus-summary-tool-bar-gnome) + (const :tag "Retro look" gnus-summary-tool-bar-retro) + (repeat :tag "User defined list" gmm-tool-bar-item) + (symbol)) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-summary-tool-bar-update + :group 'gnus-summary) + +(defcustom gnus-summary-tool-bar-gnome + '((gnus-summary-post-news "mail/compose" nil) + (gnus-summary-insert-new-articles "mail/inbox" nil + :visible (or (not gnus-agent) + gnus-plugged)) + (gnus-summary-reply-with-original "mail/reply") + (gnus-summary-reply "mail/reply" nil :visible nil) + (gnus-summary-followup-with-original "mail/reply-all") + (gnus-summary-followup "mail/reply-all" nil :visible nil) + (gnus-summary-mail-forward "mail/forward") + (gnus-summary-save-article "mail/save") + (gnus-summary-search-article-forward "search" nil :visible nil) + (gnus-summary-print-article "print") + (gnus-summary-tick-article-forward "flag-followup" nil :visible nil) + ;; Some new commands that may need more suitable icons: + (gnus-summary-save-newsrc "save" nil :visible nil) + ;; (gnus-summary-show-article "stock_message-display" nil :visible nil) + (gnus-summary-prev-article "left-arrow") + (gnus-summary-next-article "right-arrow") + (gnus-summary-next-page "next-page") + ;; (gnus-summary-enter-digest-group "right_arrow" nil :visible nil) + ;; + ;; Maybe some sort-by-... could be added: + ;; (gnus-summary-sort-by-author "sort-a-z" nil :visible nil) + ;; (gnus-summary-sort-by-date "sort-1-9" nil :visible nil) + (gnus-summary-mark-as-expirable + "delete" nil + :visible (gnus-check-backend-function 'request-expire-articles + gnus-newsgroup-name)) + (gnus-summary-mark-as-spam + "mail/spam" t + :visible (and (fboundp 'spam-group-ham-contents-p) + (spam-group-ham-contents-p gnus-newsgroup-name)) + :help "Mark as spam") + (gnus-summary-mark-as-read-forward + "mail/not-spam" nil + :visible (and (fboundp 'spam-group-spam-contents-p) + (spam-group-spam-contents-p gnus-newsgroup-name))) + ;; + (gnus-summary-exit "exit") + (gmm-customize-mode "preferences" t :help "Edit mode preferences") + (gnus-info-find-node "help")) + "List of functions for the summary tool bar (GNOME style). + +See `gmm-tool-bar-from-list' for the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-summary-tool-bar-update + :group 'gnus-summary) + +(defcustom gnus-summary-tool-bar-retro + '((gnus-summary-prev-unread-article "gnus/prev-ur") + (gnus-summary-next-unread-article "gnus/next-ur") + (gnus-summary-post-news "gnus/post") + (gnus-summary-followup-with-original "gnus/fuwo") + (gnus-summary-followup "gnus/followup") + (gnus-summary-reply-with-original "gnus/reply-wo") + (gnus-summary-reply "gnus/reply") + (gnus-summary-caesar-message "gnus/rot13") + (gnus-uu-decode-uu "gnus/uu-decode") + (gnus-summary-save-article-file "gnus/save-aif") + (gnus-summary-save-article "gnus/save-art") + (gnus-uu-post-news "gnus/uu-post") + (gnus-summary-catchup "gnus/catchup") + (gnus-summary-catchup-and-exit "gnus/cu-exit") + (gnus-summary-exit "gnus/exit-summ") + ;; Some new command that may need more suitable icons: + (gnus-summary-print-article "gnus/print" nil :visible nil) + (gnus-summary-mark-as-expirable "gnus/close" nil :visible nil) + (gnus-summary-save-newsrc "gnus/save" nil :visible nil) + ;; (gnus-summary-enter-digest-group "gnus/right_arrow" nil :visible nil) + (gnus-summary-search-article-forward "gnus/search" nil :visible nil) + ;; (gnus-summary-insert-new-articles "gnus/paste" nil :visible nil) + ;; (gnus-summary-toggle-threads "gnus/open" nil :visible nil) + ;; + (gnus-info-find-node "gnus/help" nil :visible nil)) + "List of functions for the summary tool bar (retro look). + +See `gmm-tool-bar-from-list' for the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-summary-tool-bar-update + :group 'gnus-summary) + +(defcustom gnus-summary-tool-bar-zap-list t + "List of icon items from the global tool bar. +These items are not displayed in the Gnus summary mode tool bar. + +See `gmm-tool-bar-from-list' for the format of the list." + :type 'gmm-tool-bar-zap-list + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'gnus-summary-tool-bar-update + :group 'gnus-summary) + +(defvar image-load-path) + +(defun gnus-summary-make-tool-bar (&optional force) + "Make a summary mode tool bar from `gnus-summary-tool-bar'. +When FORCE, rebuild the tool bar." + (when (and (not (featurep 'xemacs)) + (boundp 'tool-bar-mode) + tool-bar-mode + (or (not gnus-summary-tool-bar-map) force)) + (let* ((load-path + (gmm-image-load-path-for-library "gnus" + "mail/save.xpm" + nil t)) + (image-load-path (cons (car load-path) + (when (boundp 'image-load-path) + image-load-path))) + (map (gmm-tool-bar-from-list gnus-summary-tool-bar + gnus-summary-tool-bar-zap-list + 'gnus-summary-mode-map))) + (when map + ;; Need to set `gnus-summary-tool-bar-map' because `gnus-article-mode' + ;; uses it's value. + (setq gnus-summary-tool-bar-map map)))) + (set (make-local-variable 'tool-bar-map) gnus-summary-tool-bar-map)) (defun gnus-score-set-default (var value) "A version of set that updates the GNU Emacs menu-bar." @@ -2761,12 +2901,13 @@ The following commands are available: \\{gnus-summary-mode-map}" (interactive) (kill-all-local-variables) + (let ((gnus-summary-local-variables gnus-newsgroup-variables)) + (gnus-summary-make-local-variables)) + (gnus-summary-make-local-variables) + (setq gnus-newsgroup-name group) (when (gnus-visual-p 'summary-menu 'menu) (gnus-summary-make-menu-bar) (gnus-summary-make-tool-bar)) - (gnus-summary-make-local-variables) - (let ((gnus-summary-local-variables gnus-newsgroup-variables)) - (gnus-summary-make-local-variables)) (gnus-make-thread-indent-array) (gnus-simplify-mode-line) (setq major-mode 'gnus-summary-mode) @@ -2781,7 +2922,6 @@ The following commands are available: (setq selective-display-ellipses t) ;Display `...' (gnus-summary-set-display-table) (gnus-set-default-directory) - (setq gnus-newsgroup-name group) (make-local-variable 'gnus-summary-line-format) (make-local-variable 'gnus-summary-line-format-spec) (make-local-variable 'gnus-summary-dummy-line-format) @@ -2789,7 +2929,7 @@ The following commands are available: (make-local-variable 'gnus-summary-mark-positions) (gnus-make-local-hook 'pre-command-hook) (add-hook 'pre-command-hook 'gnus-set-global-variables nil t) - (gnus-run-hooks 'gnus-summary-mode-hook) + (gnus-run-mode-hooks 'gnus-summary-mode-hook) (turn-on-gnus-mailing-list-mode) (mm-enable-multibyte) (gnus-update-format-specifications nil 'summary 'summary-mode 'summary-dummy) @@ -3162,8 +3302,11 @@ display only a single character." (aset table ?\r nil) ;; We keep TAB as well. (aset table ?\t nil) - ;; We nix out any glyphs over 126 that are not set already. - (let ((i 256)) + ;; We nix out any glyphs 127 through 255, or 127 through 159 in + ;; Emacs 23 (unicode), that are not set already. + (let ((i (if (ignore-errors (= (make-char 'latin-iso8859-1 160) 160)) + 160 + 256))) (while (>= (setq i (1- i)) 127) ;; Only modify if the entry is nil. (unless (aref table i) @@ -3375,12 +3518,19 @@ buffer that was in action when the last article was fetched." newsgroups) (cond ((setq to (cdr (assq 'To extra-headers))) - (concat "-> " + (concat gnus-summary-to-prefix (inline (gnus-summary-extract-address-component (funcall gnus-decode-encoded-word-function to))))) - ((setq newsgroups (cdr (assq 'Newsgroups extra-headers))) - (concat "=> " newsgroups))))) + ((setq newsgroups + (or + (cdr (assq 'Newsgroups extra-headers)) + (and + (memq 'Newsgroups gnus-extra-headers) + (eq (car (gnus-find-method-for-group + gnus-newsgroup-name)) 'nntp) + (gnus-group-real-name gnus-newsgroup-name)))) + (concat gnus-summary-newsgroup-prefix newsgroups))))) (inline (gnus-summary-extract-address-component gnus-tmp-from))))) (defun gnus-summary-insert-line (gnus-tmp-header @@ -4587,6 +4737,11 @@ using some other form will lead to serious barfage." (or (cdr (assq 'To (mail-header-extra h2))) "")))) (or (car extract) (cadr extract))))) +(defun gnus-thread-sort-by-recipient (h1 h2) + "Sort threads by root recipient." + (gnus-article-sort-by-recipient + (gnus-thread-header h1) (gnus-thread-header h2))) + (defsubst gnus-article-sort-by-subject (h1 h2) "Sort articles by root subject." (string-lessp @@ -4707,33 +4862,39 @@ If nil, use subject instead." :version "22.1" :type '(radio (const :format "%v " nil) string) :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-false-root "> " "With %B spec, used for a false root of a thread. If nil, use subject instead." :version "22.1" :type '(radio (const :format "%v " nil) string) :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-single-indent "" "With %B spec, used for a thread with just one message. If nil, use subject instead." :version "22.1" :type '(radio (const :format "%v " nil) string) :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-vertical "| " "With %B spec, used for drawing a vertical line." :version "22.1" :type 'string :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-indent " " "With %B spec, used for indenting." :version "22.1" :type 'string :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-leaf-with-other "+-> " "With %B spec, used for a leaf with brothers." :version "22.1" :type 'string :group 'gnus-thread) + (defcustom gnus-sum-thread-tree-single-leaf "\\-> " "With %B spec, used for a leaf without brothers." :version "22.1" @@ -5721,7 +5882,7 @@ The resulting hash table is returned, or nil if no Xrefs were found." (match-end 1))) (substring xrefs (match-beginning 1) (match-end 1)))) (setq number - (string-to-int (substring xrefs (match-beginning 2) + (string-to-number (substring xrefs (match-beginning 2) (match-end 2)))) (if (setq entry (gnus-gethash group xref-hashtb)) (setcdr entry (cons number (cdr entry))) @@ -6016,7 +6177,8 @@ Return a list of headers that match SEQUENCE (see (allp (cond ((eq gnus-read-all-available-headers t) t) - ((stringp gnus-read-all-available-headers) + ((and (stringp gnus-read-all-available-headers) + group) (string-match gnus-read-all-available-headers group)) (t nil))) @@ -6171,7 +6333,7 @@ current article will be taken into consideration." (let ((max (max (point) (mark))) articles article) (save-excursion - (goto-char (min (min (point) (mark)))) + (goto-char (min (point) (mark))) (while (and (push (setq article (gnus-summary-article-number)) articles) @@ -6508,10 +6670,12 @@ displayed, no centering will be performed." (setq nlast (if (atom (cadr read)) (cadr read) (caadr read))) (setq read (cdr read))))) ;; And add the last unread articles. - (cond ((< first last) - (push (cons first last) unread)) - ((= first last) - (push first unread))) + (cond ((not (and first last)) + nil) + ((< first last) + (push (cons first last) unread)) + ((= first last) + (push first unread))) ;; Return the sequence of unread articles. (delq 0 (nreverse unread)))) @@ -7782,8 +7946,8 @@ articles that are younger than AGE days." (gnus-completing-read-with-default (symbol-name (car gnus-extra-headers)) (if current-prefix-arg - "Exclude extra header:" - "Limit extra header:") + "Exclude extra header" + "Limit extra header") (mapcar (lambda (x) (cons (symbol-name x) x)) gnus-extra-headers) @@ -9348,7 +9512,7 @@ latter case, they will be copied into the relevant groups." gnus-newsgroup-name))))) (method (gnus-completing-read-with-default - methname "What backend do you want to use when respooling?" + methname "Backend to use when respooling" methods nil t nil 'gnus-mail-method-history)) ms) (cond @@ -9691,7 +9855,8 @@ groups." (save-excursion (save-restriction (message-narrow-to-head) - (let ((head (buffer-string)) + (let ((head (buffer-substring-no-properties + (point-min) (point-max))) header) (with-temp-buffer (insert (format "211 %d Article retrieved.\n" @@ -9985,7 +10150,8 @@ the actual number of articles marked is returned." (when (gnus-summary-goto-subject article) (gnus-summary-show-thread) (gnus-summary-goto-subject article) - (gnus-summary-update-secondary-mark article)))) + (gnus-summary-update-secondary-mark article))) + t) (defun gnus-summary-set-saved-mark (article) "Set the process mark on ARTICLE and update the summary line." @@ -10555,6 +10721,15 @@ read." (gnus-summary-catchup all)) (gnus-summary-next-group)) +(defun gnus-summary-catchup-and-goto-prev-group (&optional all) + "Mark all articles in this group as read and select the previous group. +If given a prefix, mark all articles, unread as well as ticked, as +read." + (interactive "P") + (save-excursion + (gnus-summary-catchup all)) + (gnus-summary-next-group nil nil t)) + ;;; ;;; with article ;;; @@ -10741,7 +10916,9 @@ Returns nil if no thread was there to be shown." (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)))) + (mapcar (lambda (number) + (gnus-summary-article-header number)) + articles)))) (defun gnus-summary-hide-all-threads (&optional predicate) "Hide all thread subtrees. @@ -11180,7 +11357,7 @@ save those articles instead." (let* ((split-name (gnus-get-split-value gnus-move-split-methods)) (minibuffer-confirm-incomplete nil) ; XEmacs (prom - (format "%s %s to:" + (format "%s %s to" prompt (if (> (length articles) 1) (format "these %d articles" (length articles)) diff --git a/lisp/gnus-topic.el b/lisp/gnus-topic.el index ff7e59a..8a873e9 100644 --- a/lisp/gnus-topic.el +++ b/lisp/gnus-topic.el @@ -1,6 +1,7 @@ ;;; gnus-topic.el --- a folding minor mode for Gnus group buffers -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Ilja Weis ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -435,7 +436,7 @@ If LOWEST is non-nil, list all newsgroups of level LOWEST or higher." (copy-sequence gnus-group-listed-groups)))) (gnus-update-format-specifications nil 'topic) - + (when (or (not gnus-topic-alist) (not gnus-topology-checked-p)) (gnus-topic-check-topology)) @@ -583,6 +584,11 @@ articles in the topic and its subtopics." (not (eq (nth 2 type) 'hidden)) level all-entries unread)) (gnus-topic-update-unreads (car type) unread) + (when gnus-group-update-tool-bar + (gnus-put-text-property beg end 'point-entered + 'gnus-tool-bar-update) + (gnus-put-text-property beg end 'point-left + 'gnus-tool-bar-update)) (goto-char end) unread)) @@ -1134,10 +1140,7 @@ articles in the topic and its subtopics." (when (gnus-visual-p 'topic-menu 'menu) (gnus-topic-make-menu-bar)) (gnus-set-format 'topic t) - (add-minor-mode 'gnus-topic-mode " Topic" - gnus-topic-mode-map nil (lambda (&rest junk) - (interactive) - (gnus-topic-mode nil t))) + (add-minor-mode 'gnus-topic-mode " Topic" gnus-topic-mode-map) (add-hook 'gnus-group-catchup-group-hook 'gnus-topic-update-topic) (set (make-local-variable 'gnus-group-prepare-function) 'gnus-group-prepare-topics) diff --git a/lisp/gnus-undo.el b/lisp/gnus-undo.el index f4eda2c..fcb0fd9 100644 --- a/lisp/gnus-undo.el +++ b/lisp/gnus-undo.el @@ -1,7 +1,7 @@ ;;; gnus-undo.el --- minor mode for undoing in Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-util.el b/lisp/gnus-util.el index 8e49234..a94f727 100644 --- a/lisp/gnus-util.el +++ b/lisp/gnus-util.el @@ -1,6 +1,7 @@ ;;; gnus-util.el --- utility functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -38,9 +39,12 @@ (require 'cl) ;; Fixme: this should be a gnus variable, not nnmail-. (defvar nnmail-pathname-coding-system) + (defvar nnmail-active-file-coding-system) ;; Inappropriate references to other parts of Gnus. (defvar gnus-emphasize-whitespace-regexp) + (defvar gnus-original-article-buffer) + (defvar gnus-user-agent) ) (require 'time-date) (require 'netrc) @@ -304,8 +308,8 @@ is slower." (defun gnus-completing-read-with-default (default prompt &rest args) ;; Like `completing-read', except that DEFAULT is the default argument. (let* ((prompt (if default - (concat prompt " (default " default ") ") - (concat prompt " "))) + (concat prompt " (default " default "): ") + (concat prompt ": "))) (answer (apply 'completing-read prompt args))) (if (or (null answer) (zerop (length answer))) default @@ -466,7 +470,8 @@ inside loops." (apply 'format args))) (defun gnus-error (level &rest args) - "Beep an error if LEVEL is equal to or less than `gnus-verbose'." + "Beep an error if LEVEL is equal to or less than `gnus-verbose'. +ARGS are passed to `message'." (when (<= (floor level) gnus-verbose) (apply 'message args) (ding) @@ -1008,6 +1013,13 @@ ARG is passed to the first function." (save-current-buffer (apply 'run-hooks funcs))) +(defun gnus-run-mode-hooks (&rest funcs) + "Run `run-mode-hooks' if it is available, otherwise `run-hooks'. +This function saves the current buffer." + (if (fboundp 'run-mode-hooks) + (save-current-buffer (apply 'run-mode-hooks funcs)) + (save-current-buffer (apply 'run-hooks funcs)))) + ;;; Various (defvar gnus-group-buffer) ; Compiler directive @@ -1019,14 +1031,6 @@ ARG is passed to the first function." (set-buffer gnus-group-buffer) (eq major-mode 'gnus-group-mode)))) -(defun gnus-remove-duplicates (list) - (let (new) - (while list - (or (member (car list) new) - (setq new (cons (car list) new))) - (setq list (cdr list))) - (nreverse new))) - (defun gnus-remove-if (predicate list) "Return a copy of LIST with all items satisfying PREDICATE removed." (let (out) @@ -1428,6 +1432,26 @@ Return nil otherwise." display)) display))))) +(eval-when-compile + (defvar tool-bar-mode)) + +(defun gnus-tool-bar-update (&rest ignore) + "Update the tool bar." + (when (and (boundp 'tool-bar-mode) + tool-bar-mode) + (let* ((args nil) + (func (cond ((featurep 'xemacs) + 'ignore) + ((fboundp 'tool-bar-update) + 'tool-bar-update) + ((fboundp 'force-window-update) + 'force-window-update) + ((fboundp 'redraw-frame) + (setq args (list (selected-frame))) + 'redraw-frame) + (t 'ignore)))) + (apply func args)))) + ;; Fixme: This has only one use (in gnus-agent), which isn't worthwhile. (defmacro gnus-mapcar (function seq1 &rest seqs2_n) "Apply FUNCTION to each element of the sequences, and make a list of the results. @@ -1549,6 +1573,12 @@ empty directories from OLD-PATH." (ignore-errors (set-file-modes filename mode))) +(if (fboundp 'set-process-query-on-exit-flag) + (defalias 'gnus-set-process-query-on-exit-flag + 'set-process-query-on-exit-flag) + (defalias 'gnus-set-process-query-on-exit-flag + 'process-kill-without-query)) + (provide 'gnus-util) ;;; arch-tag: f94991af-d32b-4c97-8c26-ca12a934de49 diff --git a/lisp/gnus-uu.el b/lisp/gnus-uu.el index 1ffce74..7c381ce 100644 --- a/lisp/gnus-uu.el +++ b/lisp/gnus-uu.el @@ -1,6 +1,7 @@ ;;; gnus-uu.el --- extract (uu)encoded files in Gnus -;; Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, 1998, 2000, -;; 2001, 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, 1998, +;; 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Created: 2 Oct 1993 @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -487,9 +488,10 @@ didn't work, and overwrite existing files. Otherwise, ask each time." ;; The case where neither a number of articles nor a region is ;; specified. (gnus-summary-top-thread) - (setq gnus-article-reply (gnus-uu-get-list-of-articles nil))) - ;; Specify articles to be forwarded. - (setq gnus-newsgroup-processable (copy-sequence gnus-article-reply)) + (setq gnus-article-reply (nreverse (gnus-uu-find-articles-matching)))) + ;; Specify articles to be forwarded. Note that they should be + ;; reversed; see `gnus-uu-get-list-of-articles'. + (setq gnus-newsgroup-processable (reverse gnus-article-reply)) (gnus-setup-message 'forward (setq gnus-uu-digest-from-subject nil) (setq gnus-uu-digest-buffer @@ -538,19 +540,19 @@ didn't work, and overwrite existing files. Otherwise, ask each time." (defun gnus-message-process-mark (unmarkp new-marked) (let ((old (- (length gnus-newsgroup-processable) (length new-marked)))) - (message "%d mark%s %s%s" - (length new-marked) - (if (= (length new-marked) 1) "" "s") - (if unmarkp "removed" "added") - (cond - ((and (zerop old) - (not unmarkp)) - "") - (unmarkp - (format ", %d remain marked" - (length gnus-newsgroup-processable))) - (t - (format ", %d already marked" old)))))) + (gnus-message 6 "%d mark%s %s%s" + (length new-marked) + (if (= (length new-marked) 1) "" "s") + (if unmarkp "removed" "added") + (cond + ((and (zerop old) + (not unmarkp)) + "") + (unmarkp + (format ", %d remain marked" + (length gnus-newsgroup-processable))) + (t + (format ", %d already marked" old)))))) (defun gnus-new-processable (unmarkp articles) (if unmarkp @@ -578,16 +580,18 @@ When called interactively, prompt for REGEXP." (interactive "sUnmark (regexp): ") (gnus-uu-mark-by-regexp regexp t)) -(defun gnus-uu-mark-series () +(defun gnus-uu-mark-series (&optional silent) "Mark the current series with the process mark." (interactive) (let* ((articles (gnus-uu-find-articles-matching)) - (l (length articles))) + (l (length articles))) (while articles (gnus-summary-set-process-mark (car articles)) (setq articles (cdr articles))) - (message "Marked %d articles" l)) - (gnus-summary-position-point)) + (unless silent + (gnus-message 6 "Marked %d articles" l)) + (gnus-summary-position-point) + l)) (defun gnus-uu-mark-region (beg end &optional unmark) "Set the process mark on all articles between point and mark." @@ -695,14 +699,16 @@ When called interactively, prompt for REGEXP." (setq gnus-newsgroup-processable nil) (save-excursion (let ((data gnus-newsgroup-data) + (count 0) number) (while data (when (and (not (memq (setq number (gnus-data-number (car data))) gnus-newsgroup-processable)) (vectorp (gnus-data-header (car data)))) (gnus-summary-goto-subject number) - (gnus-uu-mark-series)) - (setq data (cdr data))))) + (setq count (+ count (gnus-uu-mark-series t)))) + (setq data (cdr data))) + (gnus-message 6 "Marked %d articles" count))) (gnus-summary-position-point)) ;; All PostScript functions written by Erik Selberg . @@ -845,7 +851,7 @@ When called interactively, prompt for REGEXP." (erase-buffer) (insert (format "Date: %s\nFrom: %s\nSubject: %s Digest\n\n" - (current-time-string) name name)) + (message-make-date) name name)) (when (and message-forward-as-mime gnus-uu-digest-buffer) (insert "<#part type=message/rfc822>\nSubject: Topics\n\n")) (insert "Topics:\n"))) @@ -926,16 +932,16 @@ When called interactively, prompt for REGEXP." (if (and message-forward-as-mime gnus-uu-digest-buffer) (with-current-buffer gnus-uu-digest-buffer (erase-buffer) - (insert-buffer "*gnus-uu-pre*") + (insert-buffer-substring "*gnus-uu-pre*") (goto-char (point-max)) - (insert-buffer "*gnus-uu-body*")) + (insert-buffer-substring "*gnus-uu-body*")) (save-excursion (set-buffer "*gnus-uu-pre*") (insert (format "\n\n%s\n\n" (make-string 70 ?-))) (if gnus-uu-digest-buffer (with-current-buffer gnus-uu-digest-buffer (erase-buffer) - (insert-buffer "*gnus-uu-pre*")) + (insert-buffer-substring "*gnus-uu-pre*")) (let ((coding-system-for-write mm-text-coding-system)) (gnus-write-buffer gnus-uu-saved-article-name)))) (save-excursion @@ -948,7 +954,7 @@ When called interactively, prompt for REGEXP." (if gnus-uu-digest-buffer (with-current-buffer gnus-uu-digest-buffer (goto-char (point-max)) - (insert-buffer "*gnus-uu-body*")) + (insert-buffer-substring "*gnus-uu-body*")) (let ((coding-system-for-write mm-text-coding-system) (file-name-coding-system nnmail-pathname-coding-system)) (write-region @@ -1194,7 +1200,7 @@ When called interactively, prompt for REGEXP." (ignore-errors (replace-match (format "%06d" - (string-to-int (buffer-substring + (string-to-number (buffer-substring (match-beginning 0) (match-end 0))))))) (setq string (buffer-substring 1 (point-max))) (setcar (car string-list) string) @@ -1302,7 +1308,7 @@ When called interactively, prompt for REGEXP." (not gnus-uu-be-dangerous) (or (eq gnus-uu-be-dangerous t) (gnus-y-or-n-p - (format "Delete unsuccessfully decoded file %s" + (format "Delete unsuccessfully decoded file %s? " result-file)))) (delete-file result-file))) (when (memq 'begin process-state) @@ -1362,7 +1368,7 @@ When called interactively, prompt for REGEXP." (gnus-message 2 "No begin part at the beginning") (sleep-for 2)) (setq state 'middle)))) - + ;; When there are no result-files, then something must be wrong. (if result-files (message "") @@ -1448,7 +1454,7 @@ When called interactively, prompt for REGEXP." ;; We replace certain characters that could make things messy. (setq gnus-uu-file-name (gnus-map-function - mm-file-name-rewrite-functions + mm-file-name-rewrite-functions (file-name-nondirectory (match-string 1)))) (replace-match (concat "begin 644 " gnus-uu-file-name) t t) diff --git a/lisp/gnus-vm.el b/lisp/gnus-vm.el index d23777d..775e0aa 100644 --- a/lisp/gnus-vm.el +++ b/lisp/gnus-vm.el @@ -1,7 +1,7 @@ ;;; gnus-vm.el --- vm interface for Gnus -;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 -;; Free Software Foundation, Inc. +;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Per Persson ;; Keywords: news, mail @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-win.el b/lisp/gnus-win.el index 05f252c..84c726d 100644 --- a/lisp/gnus-win.el +++ b/lisp/gnus-win.el @@ -1,6 +1,7 @@ ;;; gnus-win.el --- window configuration functions for Gnus -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/gnus-xmas.el b/lisp/gnus-xmas.el index 32804a9..233912e 100644 --- a/lisp/gnus-xmas.el +++ b/lisp/gnus-xmas.el @@ -1,7 +1,7 @@ ;;; gnus-xmas.el --- Gnus functions for XEmacs -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -430,6 +430,8 @@ call it with the value of the `gnus-data' text property." (defalias 'gnus-mark-active-p 'region-exists-p) (defalias 'gnus-annotation-in-region-p 'gnus-xmas-annotation-in-region-p) (defalias 'gnus-mime-button-menu 'gnus-xmas-mime-button-menu) + (defalias 'gnus-mime-security-button-menu + 'gnus-xmas-mime-security-button-menu) (defalias 'gnus-image-type-available-p 'gnus-xmas-image-type-available-p) (defalias 'gnus-put-image 'gnus-xmas-put-image) (defalias 'gnus-create-image 'gnus-xmas-create-image) @@ -517,7 +519,7 @@ call it with the value of the `gnus-data' text property." (rest (- wheight pheight))) (insert (make-string (max 0 (* 2 (/ rest 3))) ?\n))) ;; Paint it. - (put-text-property (point-min) (point-max) 'face 'gnus-splash-face))) + (put-text-property (point-min) (point-max) 'face 'gnus-splash))) (setq modeline-buffer-identification (list (concat gnus-version ": *Group*"))) (set-buffer-modified-p t)) @@ -525,17 +527,53 @@ call it with the value of the `gnus-data' text property." ;;; The toolbar. -(defcustom gnus-use-toolbar (if (featurep 'toolbar) - 'default-toolbar - nil) - "*If nil, do not use a toolbar. -If it is non-nil, it must be a toolbar. The five valid values are -`default-toolbar', `top-toolbar', `bottom-toolbar', -`right-toolbar', and `left-toolbar'." - :type '(choice (const default-toolbar) - (const top-toolbar) (const bottom-toolbar) - (const left-toolbar) (const right-toolbar) +(defun gnus-xmas-update-toolbars () + "Update the toolbars' appearance." + (when (and (not noninteractive) + (featurep 'gnus-xmas)) + (save-excursion + (dolist (buffer (buffer-list)) + (set-buffer buffer) + (cond ((eq major-mode 'gnus-group-mode) + (gnus-xmas-setup-group-toolbar)) + ((eq major-mode 'gnus-summary-mode) + (gnus-xmas-setup-summary-toolbar))))))) + +(defcustom gnus-use-toolbar (if (featurep 'toolbar) 'default) + "*Position to display the toolbar. Nil means do not use a toolbar. +If it is non-nil, it should be one of the symbols `default', `top', +`bottom', `right', and `left'. `default' means to use the default +toolbar, the rest mean to display the toolbar on the place which those +names show." + :type '(choice (const default) + (const top) (const bottom) (const left) (const right) (const :tag "no toolbar" nil)) + :set (lambda (symbol value) + (set-default + symbol + (if (or (not value) + (memq value (list 'default 'top 'bottom 'right 'left))) + value + 'default)) + (gnus-xmas-update-toolbars)) + :group 'gnus-xmas) + +(defcustom gnus-toolbar-thickness + (if (featurep 'toolbar) + (cons (specifier-instance default-toolbar-height) + (specifier-instance default-toolbar-width))) + "*Cons of the height and the width specifying the thickness of a toolbar. +The height is used for the toolbar displayed on the top or the bottom, +the width is used for the toolbar displayed on the right or the left." + :type '(cons :tag "height & width" + (integer :tag "height") (integer :tag "width")) + :set (lambda (symbol value) + (set-default + symbol + (if (and (consp value) (natnump (car value)) (natnump (cdr value))) + value + '(37 . 40))) + (gnus-xmas-update-toolbars)) :group 'gnus-xmas) (defvar gnus-group-toolbar @@ -617,19 +655,57 @@ If it is non-nil, it must be a toolbar. The five valid values are [gnus-summary-exit gnus-summary-exit t "Exit this summary"]) "The summary buffer mail toolbar.") +(defun gnus-xmas-setup-toolbar (toolbar) + (when (featurep 'toolbar) + (if (and gnus-use-toolbar + (message-xmas-setup-toolbar toolbar nil "gnus")) + (let ((bar (or (intern-soft (format "%s-toolbar" gnus-use-toolbar)) + 'default-toolbar)) + (height (car gnus-toolbar-thickness)) + (width (cdr gnus-toolbar-thickness)) + (cur (current-buffer)) + bars) + (set-specifier (symbol-value bar) toolbar cur) + (set-specifier default-toolbar-height height cur) + (set-specifier default-toolbar-width width cur) + (set-specifier top-toolbar-height height cur) + (set-specifier bottom-toolbar-height height cur) + (set-specifier right-toolbar-width width cur) + (set-specifier left-toolbar-width width cur) + (if (eq bar 'default-toolbar) + (progn + (remove-specifier default-toolbar-visible-p cur) + (remove-specifier top-toolbar cur) + (remove-specifier top-toolbar-visible-p cur) + (remove-specifier bottom-toolbar cur) + (remove-specifier bottom-toolbar-visible-p cur) + (remove-specifier right-toolbar cur) + (remove-specifier right-toolbar-visible-p cur) + (remove-specifier left-toolbar cur) + (remove-specifier left-toolbar-visible-p cur)) + (set-specifier (symbol-value (intern (format "%s-visible-p" bar))) + t cur) + (setq bars (delq bar (list 'default-toolbar + 'bottom-toolbar 'top-toolbar + 'right-toolbar 'left-toolbar))) + (while bars + (set-specifier (symbol-value (intern (format "%s-visible-p" + (pop bars)))) + nil cur)))) + (let ((cur (current-buffer))) + (set-specifier default-toolbar-visible-p nil cur) + (set-specifier top-toolbar-visible-p nil cur) + (set-specifier bottom-toolbar-visible-p nil cur) + (set-specifier right-toolbar-visible-p nil cur) + (set-specifier left-toolbar-visible-p nil cur))))) + (defun gnus-xmas-setup-group-toolbar () - (and gnus-use-toolbar - (message-xmas-setup-toolbar gnus-group-toolbar nil "gnus") - (set-specifier (symbol-value gnus-use-toolbar) - (cons (current-buffer) gnus-group-toolbar)))) + (gnus-xmas-setup-toolbar gnus-group-toolbar)) (defun gnus-xmas-setup-summary-toolbar () - (let ((bar (if (gnus-news-group-p gnus-newsgroup-name) - gnus-summary-toolbar gnus-summary-mail-toolbar))) - (and gnus-use-toolbar - (message-xmas-setup-toolbar bar nil "gnus") - (set-specifier (symbol-value gnus-use-toolbar) - (cons (current-buffer) bar))))) + (gnus-xmas-setup-toolbar (if (gnus-news-group-p gnus-newsgroup-name) + gnus-summary-toolbar + gnus-summary-mail-toolbar))) (defun gnus-xmas-mail-strip-quoted-names (address) "Protect mail-strip-quoted-names from nil input. @@ -710,6 +786,21 @@ XEmacs compatibility workaround." (goto-char (event-point event)) (funcall (event-function response) (event-object response)))) +(defun gnus-xmas-mime-security-button-menu (event prefix) + "Construct a context-sensitive menu of security commands." + (interactive "e\nP") + (let ((response + (get-popup-menu-response + `("Security Part" + ,@(delq nil + (mapcar (lambda (c) + (unless (eq (car c) 'undefined) + `[,(caddr c) ,(car c) t])) + gnus-mime-security-button-commands)))))) + (set-buffer (event-buffer event)) + (goto-char (event-point event)) + (funcall (event-function response) (event-object response)))) + (defun gnus-group-add-icon () "Add an icon to the current line according to `gnus-group-icon-list'." (let* ((p (point)) diff --git a/lisp/gnus.el b/lisp/gnus.el index b6d7c39..036d479 100644 --- a/lisp/gnus.el +++ b/lisp/gnus.el @@ -1,7 +1,7 @@ ;;; gnus.el --- a newsreader for GNU Emacs -;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, 1997, -;; 1998, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, 1997, 1998, +;; 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -34,7 +34,17 @@ (require 'wid-edit) (require 'mm-util) (require 'nnheader) -(autoload 'message-y-or-n-p "message" nil nil 'macro) + +;; These are defined afterwards with gnus-define-group-parameter +(defvar gnus-ham-process-destinations) +(defvar gnus-parameter-ham-marks-alist) +(defvar gnus-parameter-spam-marks-alist) +(defvar gnus-spam-autodetect) +(defvar gnus-spam-autodetect-methods) +(defvar gnus-spam-newsgroup-contents) +(defvar gnus-spam-process-destinations) +(defvar gnus-spam-process-newsgroups) + (defgroup gnus nil "The coffee-brewing, all singing, all dancing, kitchen sink newsreader." @@ -274,7 +284,7 @@ is restarted, and sometimes reloaded." :group 'gnus) (defgroup gnus-exit nil - "Exiting gnus." + "Exiting Gnus." :link '(custom-manual "(gnus)Exiting Gnus") :group 'gnus) @@ -283,7 +293,7 @@ is restarted, and sometimes reloaded." :link '(custom-manual "(gnus)Exiting Gnus") :group 'gnus) -(defconst gnus-version-number "0.3" +(defconst gnus-version-number "0.4" "Version number for this version of Gnus.") (defconst gnus-version (format "No Gnus v%s" gnus-version-number) @@ -354,7 +364,7 @@ be set in `.emacs' instead." ;; We define these group faces here to avoid the display ;; update forced when creating new faces. -(defface gnus-group-news-1-face +(defface gnus-group-news-1 '((((class color) (background dark)) (:foreground "PaleTurquoise" :bold t)) @@ -363,9 +373,12 @@ be set in `.emacs' instead." (:foreground "ForestGreen" :bold t)) (t ())) - "Level 1 newsgroup face.") + "Level 1 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-1-face 'face-alias 'gnus-group-news-1) -(defface gnus-group-news-1-empty-face +(defface gnus-group-news-1-empty '((((class color) (background dark)) (:foreground "PaleTurquoise")) @@ -374,9 +387,12 @@ be set in `.emacs' instead." (:foreground "ForestGreen")) (t ())) - "Level 1 empty newsgroup face.") + "Level 1 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-1-empty-face 'face-alias 'gnus-group-news-1-empty) -(defface gnus-group-news-2-face +(defface gnus-group-news-2 '((((class color) (background dark)) (:foreground "turquoise" :bold t)) @@ -385,9 +401,12 @@ be set in `.emacs' instead." (:foreground "CadetBlue4" :bold t)) (t ())) - "Level 2 newsgroup face.") + "Level 2 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-2-face 'face-alias 'gnus-group-news-2) -(defface gnus-group-news-2-empty-face +(defface gnus-group-news-2-empty '((((class color) (background dark)) (:foreground "turquoise")) @@ -396,9 +415,12 @@ be set in `.emacs' instead." (:foreground "CadetBlue4")) (t ())) - "Level 2 empty newsgroup face.") + "Level 2 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-2-empty-face 'face-alias 'gnus-group-news-2-empty) -(defface gnus-group-news-3-face +(defface gnus-group-news-3 '((((class color) (background dark)) (:bold t)) @@ -407,9 +429,12 @@ be set in `.emacs' instead." (:bold t)) (t ())) - "Level 3 newsgroup face.") + "Level 3 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-3-face 'face-alias 'gnus-group-news-3) -(defface gnus-group-news-3-empty-face +(defface gnus-group-news-3-empty '((((class color) (background dark)) ()) @@ -418,9 +443,12 @@ be set in `.emacs' instead." ()) (t ())) - "Level 3 empty newsgroup face.") + "Level 3 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-3-empty-face 'face-alias 'gnus-group-news-3-empty) -(defface gnus-group-news-4-face +(defface gnus-group-news-4 '((((class color) (background dark)) (:bold t)) @@ -429,9 +457,12 @@ be set in `.emacs' instead." (:bold t)) (t ())) - "Level 4 newsgroup face.") + "Level 4 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-4-face 'face-alias 'gnus-group-news-4) -(defface gnus-group-news-4-empty-face +(defface gnus-group-news-4-empty '((((class color) (background dark)) ()) @@ -440,9 +471,12 @@ be set in `.emacs' instead." ()) (t ())) - "Level 4 empty newsgroup face.") + "Level 4 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-4-empty-face 'face-alias 'gnus-group-news-4-empty) -(defface gnus-group-news-5-face +(defface gnus-group-news-5 '((((class color) (background dark)) (:bold t)) @@ -451,9 +485,12 @@ be set in `.emacs' instead." (:bold t)) (t ())) - "Level 5 newsgroup face.") + "Level 5 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-5-face 'face-alias 'gnus-group-news-5) -(defface gnus-group-news-5-empty-face +(defface gnus-group-news-5-empty '((((class color) (background dark)) ()) @@ -462,9 +499,12 @@ be set in `.emacs' instead." ()) (t ())) - "Level 5 empty newsgroup face.") + "Level 5 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-5-empty-face 'face-alias 'gnus-group-news-5-empty) -(defface gnus-group-news-6-face +(defface gnus-group-news-6 '((((class color) (background dark)) (:bold t)) @@ -473,9 +513,12 @@ be set in `.emacs' instead." (:bold t)) (t ())) - "Level 6 newsgroup face.") + "Level 6 newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-6-face 'face-alias 'gnus-group-news-6) -(defface gnus-group-news-6-empty-face +(defface gnus-group-news-6-empty '((((class color) (background dark)) ()) @@ -484,9 +527,12 @@ be set in `.emacs' instead." ()) (t ())) - "Level 6 empty newsgroup face.") + "Level 6 empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-6-empty-face 'face-alias 'gnus-group-news-6-empty) -(defface gnus-group-news-low-face +(defface gnus-group-news-low '((((class color) (background dark)) (:foreground "DarkTurquoise" :bold t)) @@ -495,9 +541,12 @@ be set in `.emacs' instead." (:foreground "DarkGreen" :bold t)) (t ())) - "Low level newsgroup face.") + "Low level newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-low-face 'face-alias 'gnus-group-news-low) -(defface gnus-group-news-low-empty-face +(defface gnus-group-news-low-empty '((((class color) (background dark)) (:foreground "DarkTurquoise")) @@ -506,9 +555,12 @@ be set in `.emacs' instead." (:foreground "DarkGreen")) (t ())) - "Low level empty newsgroup face.") + "Low level empty newsgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-news-low-empty-face 'face-alias 'gnus-group-news-low-empty) -(defface gnus-group-mail-1-face +(defface gnus-group-mail-1 '((((class color) (background dark)) (:foreground "aquamarine1" :bold t)) @@ -517,9 +569,12 @@ be set in `.emacs' instead." (:foreground "DeepPink3" :bold t)) (t (:bold t))) - "Level 1 mailgroup face.") + "Level 1 mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-1-face 'face-alias 'gnus-group-mail-1) -(defface gnus-group-mail-1-empty-face +(defface gnus-group-mail-1-empty '((((class color) (background dark)) (:foreground "aquamarine1")) @@ -528,9 +583,12 @@ be set in `.emacs' instead." (:foreground "DeepPink3")) (t (:italic t :bold t))) - "Level 1 empty mailgroup face.") + "Level 1 empty mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-1-empty-face 'face-alias 'gnus-group-mail-1-empty) -(defface gnus-group-mail-2-face +(defface gnus-group-mail-2 '((((class color) (background dark)) (:foreground "aquamarine2" :bold t)) @@ -539,9 +597,12 @@ be set in `.emacs' instead." (:foreground "HotPink3" :bold t)) (t (:bold t))) - "Level 2 mailgroup face.") + "Level 2 mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-2-face 'face-alias 'gnus-group-mail-2) -(defface gnus-group-mail-2-empty-face +(defface gnus-group-mail-2-empty '((((class color) (background dark)) (:foreground "aquamarine2")) @@ -550,9 +611,12 @@ be set in `.emacs' instead." (:foreground "HotPink3")) (t (:bold t))) - "Level 2 empty mailgroup face.") + "Level 2 empty mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-2-empty-face 'face-alias 'gnus-group-mail-2-empty) -(defface gnus-group-mail-3-face +(defface gnus-group-mail-3 '((((class color) (background dark)) (:foreground "aquamarine3" :bold t)) @@ -561,9 +625,12 @@ be set in `.emacs' instead." (:foreground "magenta4" :bold t)) (t (:bold t))) - "Level 3 mailgroup face.") + "Level 3 mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-3-face 'face-alias 'gnus-group-mail-3) -(defface gnus-group-mail-3-empty-face +(defface gnus-group-mail-3-empty '((((class color) (background dark)) (:foreground "aquamarine3")) @@ -572,9 +639,12 @@ be set in `.emacs' instead." (:foreground "magenta4")) (t ())) - "Level 3 empty mailgroup face.") + "Level 3 empty mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-3-empty-face 'face-alias 'gnus-group-mail-3-empty) -(defface gnus-group-mail-low-face +(defface gnus-group-mail-low '((((class color) (background dark)) (:foreground "aquamarine4" :bold t)) @@ -583,9 +653,12 @@ be set in `.emacs' instead." (:foreground "DeepPink4" :bold t)) (t (:bold t))) - "Low level mailgroup face.") + "Low level mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-low-face 'face-alias 'gnus-group-mail-low) -(defface gnus-group-mail-low-empty-face +(defface gnus-group-mail-low-empty '((((class color) (background dark)) (:foreground "aquamarine4")) @@ -594,20 +667,28 @@ be set in `.emacs' instead." (:foreground "DeepPink4")) (t (:bold t))) - "Low level empty mailgroup face.") + "Low level empty mailgroup face." + :group 'gnus-group) +;; backward-compatibility alias +(put 'gnus-group-mail-low-empty-face 'face-alias 'gnus-group-mail-low-empty) ;; Summary mode faces. -(defface gnus-summary-selected-face '((t - (:underline t))) - "Face used for selected articles.") +(defface gnus-summary-selected '((t (:underline t))) + "Face used for selected articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-selected-face 'face-alias 'gnus-summary-selected) -(defface gnus-summary-cancelled-face +(defface gnus-summary-cancelled '((((class color)) (:foreground "yellow" :background "black"))) - "Face used for cancelled articles.") + "Face used for cancelled articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-cancelled-face 'face-alias 'gnus-summary-cancelled) -(defface gnus-summary-high-ticked-face +(defface gnus-summary-high-ticked '((((class color) (background dark)) (:foreground "pink" :bold t)) @@ -616,9 +697,12 @@ be set in `.emacs' instead." (:foreground "firebrick" :bold t)) (t (:bold t))) - "Face used for high interest ticked articles.") + "Face used for high interest ticked articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-high-ticked-face 'face-alias 'gnus-summary-high-ticked) -(defface gnus-summary-low-ticked-face +(defface gnus-summary-low-ticked '((((class color) (background dark)) (:foreground "pink" :italic t)) @@ -627,9 +711,12 @@ be set in `.emacs' instead." (:foreground "firebrick" :italic t)) (t (:italic t))) - "Face used for low interest ticked articles.") + "Face used for low interest ticked articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-low-ticked-face 'face-alias 'gnus-summary-low-ticked) -(defface gnus-summary-normal-ticked-face +(defface gnus-summary-normal-ticked '((((class color) (background dark)) (:foreground "pink")) @@ -638,9 +725,12 @@ be set in `.emacs' instead." (:foreground "firebrick")) (t ())) - "Face used for normal interest ticked articles.") + "Face used for normal interest ticked articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-normal-ticked-face 'face-alias 'gnus-summary-normal-ticked) -(defface gnus-summary-high-ancient-face +(defface gnus-summary-high-ancient '((((class color) (background dark)) (:foreground "SkyBlue" :bold t)) @@ -649,9 +739,12 @@ be set in `.emacs' instead." (:foreground "RoyalBlue" :bold t)) (t (:bold t))) - "Face used for high interest ancient articles.") + "Face used for high interest ancient articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-high-ancient-face 'face-alias 'gnus-summary-high-ancient) -(defface gnus-summary-low-ancient-face +(defface gnus-summary-low-ancient '((((class color) (background dark)) (:foreground "SkyBlue" :italic t)) @@ -660,9 +753,12 @@ be set in `.emacs' instead." (:foreground "RoyalBlue" :italic t)) (t (:italic t))) - "Face used for low interest ancient articles.") + "Face used for low interest ancient articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-low-ancient-face 'face-alias 'gnus-summary-low-ancient) -(defface gnus-summary-normal-ancient-face +(defface gnus-summary-normal-ancient '((((class color) (background dark)) (:foreground "SkyBlue")) @@ -671,51 +767,72 @@ be set in `.emacs' instead." (:foreground "RoyalBlue")) (t ())) - "Face used for normal interest ancient articles.") + "Face used for normal interest ancient articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-normal-ancient-face 'face-alias 'gnus-summary-normal-ancient) -(defface gnus-summary-high-undownloaded-face +(defface gnus-summary-high-undownloaded '((((class color) (background light)) (:bold t :foreground "cyan4")) (((class color) (background dark)) (:bold t :foreground "LightGray")) (t (:inverse-video t :bold t))) - "Face used for high interest uncached articles.") + "Face used for high interest uncached articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-high-undownloaded-face 'face-alias 'gnus-summary-high-undownloaded) -(defface gnus-summary-low-undownloaded-face +(defface gnus-summary-low-undownloaded '((((class color) (background light)) (:italic t :foreground "cyan4" :bold nil)) (((class color) (background dark)) (:italic t :foreground "LightGray" :bold nil)) (t (:inverse-video t :italic t))) - "Face used for low interest uncached articles.") + "Face used for low interest uncached articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-low-undownloaded-face 'face-alias 'gnus-summary-low-undownloaded) -(defface gnus-summary-normal-undownloaded-face +(defface gnus-summary-normal-undownloaded '((((class color) (background light)) (:foreground "cyan4" :bold nil)) (((class color) (background dark)) (:foreground "LightGray" :bold nil)) (t (:inverse-video t))) - "Face used for normal interest uncached articles.") + "Face used for normal interest uncached articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-normal-undownloaded-face 'face-alias 'gnus-summary-normal-undownloaded) -(defface gnus-summary-high-unread-face +(defface gnus-summary-high-unread '((t (:bold t))) - "Face used for high interest unread articles.") + "Face used for high interest unread articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-high-unread-face 'face-alias 'gnus-summary-high-unread) -(defface gnus-summary-low-unread-face +(defface gnus-summary-low-unread '((t (:italic t))) - "Face used for low interest unread articles.") + "Face used for low interest unread articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-low-unread-face 'face-alias 'gnus-summary-low-unread) -(defface gnus-summary-normal-unread-face +(defface gnus-summary-normal-unread '((t ())) - "Face used for normal interest unread articles.") + "Face used for normal interest unread articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-normal-unread-face 'face-alias 'gnus-summary-normal-unread) -(defface gnus-summary-high-read-face +(defface gnus-summary-high-read '((((class color) (background dark)) (:foreground "PaleGreen" @@ -726,9 +843,12 @@ be set in `.emacs' instead." :bold t)) (t (:bold t))) - "Face used for high interest read articles.") + "Face used for high interest read articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-high-read-face 'face-alias 'gnus-summary-high-read) -(defface gnus-summary-low-read-face +(defface gnus-summary-low-read '((((class color) (background dark)) (:foreground "PaleGreen" @@ -739,9 +859,12 @@ be set in `.emacs' instead." :italic t)) (t (:italic t))) - "Face used for low interest read articles.") + "Face used for low interest read articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-low-read-face 'face-alias 'gnus-summary-low-read) -(defface gnus-summary-normal-read-face +(defface gnus-summary-normal-read '((((class color) (background dark)) (:foreground "PaleGreen")) @@ -750,7 +873,10 @@ be set in `.emacs' instead." (:foreground "DarkGreen")) (t ())) - "Face used for normal interest read articles.") + "Face used for normal interest read articles." + :group 'gnus-summary) +;; backward-compatibility alias +(put 'gnus-summary-normal-read-face 'face-alias 'gnus-summary-normal-read) ;;; @@ -794,7 +920,7 @@ be set in `.emacs' instead." (eval-and-compile (autoload 'gnus-play-jingle "gnus-audio")) -(defface gnus-splash-face +(defface gnus-splash '((((class color) (background dark)) (:foreground "#888888")) @@ -803,7 +929,10 @@ be set in `.emacs' instead." (:foreground "#888888")) (t ())) - "Face for the splash screen.") + "Face for the splash screen." + :group 'gnus-start) +;; backward-compatibility alias +(put 'gnus-splash-face 'face-alias 'gnus-splash) (defun gnus-splash () (save-excursion @@ -873,6 +1002,11 @@ be set in `.emacs' instead." (fboundp 'find-image) (display-graphic-p) (let* ((data-directory (nnheader-find-etc-directory "images/gnus")) + (image-load-path (cond (data-directory + (list data-directory)) + ((boundp 'image-load-path) + (symbol-value 'image-load-path)) + (t load-path))) (image (find-image `((:type xpm :file "gnus.xpm" :color-symbols @@ -882,11 +1016,11 @@ be set in `.emacs' instead." ("background" . ,(face-background 'default)))) (:type pbm :file "gnus.pbm" ;; Account for the pbm's blackground. - :background ,(face-foreground 'gnus-splash-face) + :background ,(face-foreground 'gnus-splash) :foreground ,(face-background 'default)) (:type xbm :file "gnus.xbm" ;; Account for the xbm's blackground. - :background ,(face-foreground 'gnus-splash-face) + :background ,(face-foreground 'gnus-splash) :foreground ,(face-background 'default)))))) (when image (let ((size (image-size image))) @@ -930,7 +1064,7 @@ be set in `.emacs' instead." (rest (- wheight pheight))) (insert (make-string (max 0 (* 2 (/ rest 3))) ?\n))) ;; Fontify some. - (put-text-property (point-min) (point-max) 'face 'gnus-splash-face) + (put-text-property (point-min) (point-max) 'face 'gnus-splash) (setq gnus-simple-splash t))) (goto-char (point-min)) (setq mode-line-buffer-identification (concat " " gnus-version)) @@ -966,6 +1100,17 @@ For example: :type '(repeat (cons regexp (repeat sexp)))) +(defcustom gnus-parameters-case-fold-search 'default + "If it is t, ignore case of group names specified in `gnus-parameters'. +If it is nil, don't ignore case. If it is `default', which is for the +backward compatibility, use the value of `case-fold-search'." + :version "22.1" + :group 'gnus-group-various + :type '(choice :format "%{%t%}:\n %[Value Menu%] %v" + (const :tag "Use `case-fold-search'" default) + (const nil) + (const t))) + (defvar gnus-group-parameters-more nil) (defmacro gnus-define-group-parameter (param &rest rest) @@ -1426,9 +1571,23 @@ articles. This is not a good idea." :value t))) (defcustom gnus-use-nocem nil - "*If non-nil, Gnus will read NoCeM cancel messages." + "*If non-nil, Gnus will read NoCeM cancel messages. +You can also set this variable to a positive number as a group level. +In that case, Gnus scans NoCeM messages when checking new news if this +value is not exceeding a group level that you specify as the prefix +argument to some commands, e.g. `gnus', `gnus-group-get-new-news', etc. +Otherwise, Gnus does not scan NoCeM messages if you specify a group +level to those commands." :group 'gnus-meta - :type 'boolean) + :type '(choice + (const :tag "off" nil) + (const :tag "on" t) + (list :convert-widget + (lambda (widget) + (list 'integer :tag "group level" + :value (if (boundp 'gnus-level-default-subscribed) + gnus-level-default-subscribed + 3)))))) (defcustom gnus-suppress-duplicates nil "*If non-nil, Gnus will mark duplicate copies of the same article as read." @@ -2269,7 +2428,8 @@ following hook: "Function run when a group level is changed. It is called with three parameters -- GROUP, LEVEL and OLDLEVEL." :group 'gnus-group-levels - :type 'function) + :type '(choice (const nil) + function)) ;;; Face thingies. @@ -3355,11 +3515,8 @@ that that variable is buffer-local to the summary buffers." (push name-method gnus-server-method-cache)) (throw 'server-name (car name-method)))) server-alist)) - (let ((alists (list gnus-server-alist - gnus-predefined-server-alist))) - (if gnus-select-method - (push (list (cons "native" gnus-select-method)) alists)) - alists)) + (list gnus-server-alist + gnus-predefined-server-alist)) (let* ((name (if (member (cadr method) '(nil "")) (format "%s" (car method)) @@ -3634,7 +3791,10 @@ You should probably use `gnus-find-method-for-group' instead." (defun gnus-parameters-get-parameter (group) "Return the group parameters for GROUP from `gnus-parameters'." - (let (params-list) + (let ((case-fold-search (if (eq gnus-parameters-case-fold-search 'default) + case-fold-search + gnus-parameters-case-fold-search)) + params-list) (dolist (elem gnus-parameters) (when (string-match (car elem) group) (setq params-list @@ -3718,6 +3878,7 @@ If you call this function inside a loop, consider using the faster (defun gnus-group-get-parameter (group &optional symbol allow-list) "Return the group parameters for GROUP. If SYMBOL, return the value of that symbol in the group parameters. +If ALLOW-LIST, also allow list as a result. Most functions should use `gnus-group-find-parameter', which also examines the topic parameters." (let ((params (gnus-info-params (gnus-get-info group)))) @@ -3727,7 +3888,8 @@ also examines the topic parameters." (defun gnus-group-parameter-value (params symbol &optional allow-list present-p) - "Return the value of SYMBOL in group PARAMS." + "Return the value of SYMBOL in group PARAMS. +If ALLOW-LIST, also allow list as a result." ;; We only wish to return group parameters (dotted lists) and ;; not local variables, which may have the same names. ;; But first we handle single elements... @@ -3993,7 +4155,7 @@ If NEWSGROUP is nil, return the global kill file name instead." (setq valids (cdr valids))) outs)) -(eval-when-compile +(eval-and-compile (autoload 'message-y-or-n-p "message" nil nil 'macro)) (defun gnus-read-group (prompt &optional default) @@ -4153,9 +4315,6 @@ current display is used." (delete-frame gnus-other-frame-object)) (setq gnus-other-frame-object nil))))))) -;;(setq thing ? ; this is a comment -;; more 'yes) - ;;;###autoload (defun gnus (&optional arg dont-connect slave) "Read network news. diff --git a/lisp/hashcash.el b/lisp/hashcash.el index 94b140d..ac2e4a4 100644 --- a/lisp/hashcash.el +++ b/lisp/hashcash.el @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -49,14 +49,16 @@ ;;; Code: -(eval-and-compile - (autoload 'executable-find "executable")) +(defgroup hashcash nil + "Hashcash configuration." + :group 'mail) (defcustom hashcash-default-payment 20 "*The default number of bits to pay to unknown users. If this is zero, no payment header will be generated. See `hashcash-payment-alist'." - :type 'integer) + :type 'integer + :group 'hashcash) (defcustom hashcash-payment-alist '() "*An association list mapping email addresses to payment amounts. @@ -70,32 +72,39 @@ present, is the string to be hashed; if not present ADDR will be used." (list :tag "Replace hash input" (string :name "Address") (string :name "Hash input") - (integer :name "Amount"))))) + (integer :name "Amount")))) + :group 'hashcash) (defcustom hashcash-default-accept-payment 20 "*The default minimum number of bits to accept on incoming payments." - :type 'integer) + :type 'integer + :group 'hashcash) (defcustom hashcash-accept-resources `((,user-mail-address nil)) "*An association list mapping hashcash resources to payment amounts. Resources named here are to be accepted in incoming payments. If the corresponding AMOUNT is NIL, the value of `hashcash-default-accept-payment' -is used instead.") +is used instead." + :group 'hashcash) (defcustom hashcash-path (executable-find "hashcash") - "*The path to the hashcash binary.") + "*The path to the hashcash binary." + :group 'hashcash) (defcustom hashcash-extra-generate-parameters nil "*A list of parameter strings passed to `hashcash-path' when minting. For example, you may want to set this to '(\"-Z2\") to reduce header length." - :type '(repeat string)) + :type '(repeat string) + :group 'hashcash) (defcustom hashcash-double-spend-database "hashcash.db" - "*The path to the double-spending database.") + "*The path to the double-spending database." + :group 'hashcash) (defcustom hashcash-in-news nil "*Specifies whether or not hashcash payments should be made to newsgroups." - :type 'boolean) + :type 'boolean + :group 'hashcash) (defvar hashcash-process-alist nil "Alist of asynchronous hashcash processes and buffers.") @@ -201,7 +210,8 @@ Return immediately. Call CALLBACK with process and result when ready." (save-excursion (save-restriction (message-narrow-to-headers-or-head) - (let ((token (message-fetch-field "x-hashcash"))) + (let ((token (message-fetch-field "x-hashcash")) + (case-fold-search t)) (and (stringp token) (string-match (regexp-quote recipient) token)))))) diff --git a/lisp/hex-util.el b/lisp/hex-util.el index bdaf197c..51553c2 100644 --- a/lisp/hex-util.el +++ b/lisp/hex-util.el @@ -1,6 +1,7 @@ ;;; hex-util.el --- Functions to encode/decode hexadecimal string. -;; Copyright (C) 1999, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shuhei KOBAYASHI ;; Keywords: data @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/hmac-def.el b/lisp/hmac-def.el index 1275f74..4dfd8dd 100644 --- a/lisp/hmac-def.el +++ b/lisp/hmac-def.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/hmac-md5.el b/lisp/hmac-md5.el index b9bb877..a358153 100644 --- a/lisp/hmac-md5.el +++ b/lisp/hmac-md5.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/html2text.el b/lisp/html2text.el index 4e39d66..de9cf64 100644 --- a/lisp/html2text.el +++ b/lisp/html2text.el @@ -1,5 +1,6 @@ ;;; html2text.el --- a simple html to plain text converter -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Joakim Hove @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -42,8 +43,42 @@ (defvar html2text-format-single-element-list '(("hr" . html2text-clean-hr))) (defvar html2text-replace-list - '((" " . " ") (">" . ">") ("<" . "<") (""" . "\"") - ("&" . "&") ("'" . "'")) + '(("´" . "`") + ("&" . "&") + ("'" . "'") + ("¦" . "|") + ("¢" . "c") + ("ˆ" . "^") + ("©" . "(C)") + ("¤" . "(#)") + ("°" . "degree") + ("÷" . "/") + ("€" . "e") + ("½" . "1/2") + (">" . ">") + ("¿" . "?") + ("«" . "<<") + ("&ldquo" . "\"") + ("‹" . "(") + ("‘" . "`") + ("<" . "<") + ("—" . "--") + (" " . " ") + ("–" . "-") + ("‰" . "%%") + ("±" . "+-") + ("£" . "£") + (""" . "\"") + ("»" . ">>") + ("&rdquo" . "\"") + ("®" . "(R)") + ("›" . ")") + ("’" . "'") + ("§" . "§") + ("¹" . "^1") + ("²" . "^2") + ("³" . "^3") + ("˜" . "~")) "The map of entity to text. This is an alist were each element is a dotted pair consisting of an @@ -58,7 +93,7 @@ completely verbatim - without any use of REGEXP.") This is a list of tags which should be removed, without any formatting. Note that tags in the list are presented *without* -any \"<\" or \">\". All occurences of a tag appearing in this +any \"<\" or \">\". All occurrences of a tag appearing in this list are removed, irrespective of whether it is a closing or opening tag, or if the tag has additional attributes. The deletion is done by the function `html2text-remove-tags'. @@ -373,7 +408,8 @@ formatting, and then moved afterward.") fashion, quite close to pure guess-work. It does work in some cases though." (interactive) (goto-char (point-min)) - (replace-regexp "^
$" "") + (while (re-search-forward "^
$" nil t) + (delete-region (match-beginning 0) (match-end 0))) ;; Removing lonely
on a single line, if they are left intact we ;; dont have any paragraphs at all. (goto-char (point-min)) diff --git a/lisp/ietf-drums.el b/lisp/ietf-drums.el index 645a79a..0d9e3a5 100644 --- a/lisp/ietf-drums.el +++ b/lisp/ietf-drums.el @@ -1,6 +1,7 @@ ;;; ietf-drums.el --- Functions for parsing RFC822bis headers -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/imap.el b/lisp/imap.el index 238e0b9..6d489b6 100644 --- a/lisp/imap.el +++ b/lisp/imap.el @@ -1,6 +1,7 @@ ;;; imap.el --- imap library -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -171,8 +172,7 @@ the list is tried until a successful connection is made." :type '(repeat string)) (defcustom imap-gssapi-program (list - (concat "gsasl --client --connect %s:%p " - "--imap --application-data " + (concat "gsasl %s %p " "--mechanism GSSAPI " "--authentication-id %l") "imtest -m gssapi -u %l -p %p %s") @@ -588,6 +588,13 @@ sure of changing the value of `foo'." (while (and (memq (process-status process) '(open run)) (set-buffer buffer) ;; XXX "blue moon" nntp.el bug (goto-char (point-min)) + ;; Athena IMTEST can output SSL verify errors + (or (while (looking-at "^verify error:num=") + (forward-line)) + t) + (or (while (looking-at "^TLS connection established") + (forward-line)) + t) ;; cyrus 1.6.x (13? < x <= 22) queries capabilities (or (while (looking-at "^C:") (forward-line)) @@ -596,6 +603,10 @@ sure of changing the value of `foo'." (or (not (looking-at "S: ")) (forward-char 3) t) + ;; GNU SASL may print 'Trying ...' first. + (or (not (looking-at "Trying ")) + (forward-line) + t) (not (and (imap-parse-greeting) ;; success in imtest 1.6: (re-search-forward @@ -638,6 +649,10 @@ sure of changing the value of `foo'." (coding-system-for-read imap-coding-system-for-read) (coding-system-for-write imap-coding-system-for-write) (process-connection-type imap-process-connection-type) + (set-process-query-on-exit-flag + (if (fboundp 'set-process-query-on-exit-flag) + 'set-process-query-on-exit-flag + 'process-kill-without-query)) process) (when (progn (setq process (start-process @@ -647,7 +662,7 @@ sure of changing the value of `foo'." (format-spec-make ?s server ?p (number-to-string port))))) - (process-kill-without-query process) + (funcall set-process-query-on-exit-flag process nil) process) (with-current-buffer buffer (goto-char (point-min)) @@ -1087,8 +1102,11 @@ necessary. If nil, the buffer name is generated." stream)) ;; We're done, kill the first connection (imap-close buffer) - (kill-buffer buffer) - (rename-buffer buffer) + (let ((name (if (stringp buffer) + buffer + (buffer-name buffer)))) + (kill-buffer buffer) + (rename-buffer name)) (message "imap: Reconnecting with stream `%s'...done" stream) (setq imap-stream stream) diff --git a/lisp/legacy-gnus-agent.el b/lisp/legacy-gnus-agent.el index 16b0cf6..50675b0 100644 --- a/lisp/legacy-gnus-agent.el +++ b/lisp/legacy-gnus-agent.el @@ -25,7 +25,7 @@ converted to the compressed format." ((file-directory-p member) (push member search-in)) ((equal (file-name-nondirectory member) ".agentview") - (setq converted-something + (setq converted-something (or (gnus-agent-convert-agentview member) converted-something)))))) @@ -175,7 +175,7 @@ converted to the compressed format." (t t)))))) (kill-buffer buffer)) - (error "Change gnus-agent-expire-days to an integer for gnus to start.")))) + (error "Change gnus-agent-expire-days to an integer for gnus to start")))) ;; The gnus-agent-unlist-expire-days has its own conversion prompt. ;; Therefore, hide the default prompt. @@ -198,8 +198,8 @@ possible that the hook was persistently saved." (when (cond ((eq (type-of func) 'compiled-function) ;; Search def. of compiled function for gnus-agent-do-once string - (let* (definition - print-level + (let* (definition + print-level print-length (standard-output (lambda (char) diff --git a/lisp/lpath.el b/lisp/lpath.el index cbeb7a7..500852c 100644 --- a/lisp/lpath.el +++ b/lisp/lpath.el @@ -13,33 +13,29 @@ Info-menu create-image display-graphic-p display-time-event-handler find-coding-system find-image image-size image-type-available-p insert-image - make-mode-line-mouse-map make-temp-file propertize put-image - replace-regexp-in-string rmail-msg-is-pruned - rmail-msg-restore-non-pruned-header sort-coding-systems - tool-bar-add-item tool-bar-add-item-from-menu - tool-bar-local-item-from-menu url-generic-parse-url - url-http-file-exists-p url-insert-file-contents - vcard-pretty-print w32-focus-frame w3m-detect-meta-charset - w3m-region x-focus-frame)) + line-number-at-pos make-mode-line-mouse-map make-temp-file + propertize put-image replace-regexp-in-string + rmail-msg-is-pruned rmail-msg-restore-non-pruned-header + sort-coding-systems tool-bar-add-item + tool-bar-add-item-from-menu tool-bar-local-item-from-menu + url-generic-parse-url url-http-file-exists-p + url-insert-file-contents vcard-pretty-print w32-focus-frame + w3m-detect-meta-charset w3m-region x-focus-frame)) (maybe-bind '(eudc-protocol - filladapt-mode mc-pgp-always-sign - rmail-insert-mime-forwarded-message-function url-current-object - url-package-name url-package-version + filladapt-mode rmail-insert-mime-forwarded-message-function w3-meta-charset-content-type-regexp - w3-meta-content-type-charset-regexp - w3m-cid-retrieve-function-alist w3m-current-buffer - w3m-display-inline-images w3m-minor-mode-map)) + w3-meta-content-type-charset-regexp)) (if (featurep 'xemacs) (progn - (maybe-fbind '(delete-overlay - detect-coding-string eudc-expand-inline event-click-count - event-end event-start find-coding-systems-for-charsets + (maybe-fbind '(codepage-setup + delete-overlay detect-coding-string eudc-expand-inline + event-click-count event-end event-start + find-coding-systems-for-charsets find-coding-systems-region find-coding-systems-string - mail-abbrevs-setup mouse-minibuffer-check - mouse-movement-p mouse-scroll-subr overlay-lists - posn-point posn-window read-event set-buffer-multibyte - track-mouse window-edges)) + mail-abbrevs-setup mouse-minibuffer-check mouse-movement-p + mouse-scroll-subr overlay-lists posn-point posn-window + read-event set-buffer-multibyte track-mouse window-edges)) (maybe-bind '(adaptive-fill-first-line-regexp buffer-display-table buffer-file-coding-system current-language-environment @@ -51,16 +47,17 @@ (maybe-fbind '(bbdb-complete-name delete-annotation delete-extent device-connection dfw-device events-to-keys font-lock-set-defaults frame-device - get-char-table glyph-height glyph-width mail-aliases-setup - make-annotation make-event make-glyph make-network-process - map-extents message-xmas-redefine put-char-table - set-extent-property temp-directory + get-char-table glyph-height glyph-width ldap-search-entries + mail-aliases-setup make-annotation make-event make-glyph + make-network-process map-extents message-xmas-redefine + put-char-table set-extent-property temp-directory valid-image-instantiator-format-p w3-coding-system-for-mime-charset w3-do-setup w3-prepare-buffer w3-region window-pixel-height window-pixel-width)) (maybe-bind '(help-echo-owns-message mail-mode-hook mm-w3m-mode-map - show-nonbreak-escape))) + show-nonbreak-escape + nobreak-char-display))) (when (and (featurep 'xemacs) (not (featurep 'mule))) diff --git a/lisp/mail-parse.el b/lisp/mail-parse.el index 12f9918..8222e2a 100644 --- a/lisp/mail-parse.el +++ b/lisp/mail-parse.el @@ -1,6 +1,7 @@ ;;; mail-parse.el --- Interface functions for parsing mail -;; Copyright (C) 1998, 1999, 2000 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/mail-prsvr.el b/lisp/mail-prsvr.el index fc80459..144d61e 100644 --- a/lisp/mail-prsvr.el +++ b/lisp/mail-prsvr.el @@ -1,5 +1,7 @@ ;;; mail-prsvr.el --- Interface variables for parsing mail -;; Copyright (C) 1999, 2000 Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -16,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/mail-source.el b/lisp/mail-source.el index d8ef71a..d442627 100644 --- a/lisp/mail-source.el +++ b/lisp/mail-source.el @@ -1,6 +1,7 @@ ;;; mail-source.el --- functions for fetching mail -;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -107,7 +108,7 @@ See Info node `(gnus)Mail Source Specifiers'." (const :format "" :value :port) (choice :tag "Port" :value "pop3" - (number :format "%v") + (integer :format "%v") (string :format "%v"))) (group :inline t (const :format "" :value :user) @@ -123,13 +124,15 @@ See Info node `(gnus)Mail Source Specifiers'." (choice :tag "Prescript" :value nil (string :format "%v") - (function :format "%v"))) + (function :format "%v") + (const :tag "None" nil))) (group :inline t (const :format "" :value :postscript) (choice :tag "Postscript" :value nil (string :format "%v") - (function :format "%v"))) + (function :format "%v") + (const :tag "None" nil))) (group :inline t (const :format "" :value :function) (function :tag "Function")) @@ -142,7 +145,14 @@ See Info node `(gnus)Mail Source Specifiers'." (const apop))) (group :inline t (const :format "" :value :plugged) - (boolean :tag "Plugged")))) + (boolean :tag "Plugged")) + (group :inline t + (const :format "" :value :stream) + (choice :tag "Stream" + :value nil + (const :tag "Clear" nil) + (const starttls) + (const :tag "SSL/TLS" ssl))))) (cons :tag "Maildir (qmail, postfix...)" (const :format "" maildir) (checklist :tag "Options" :greedy t @@ -162,7 +172,7 @@ See Info node `(gnus)Mail Source Specifiers'." (const :format "" :value :port) (choice :tag "Port" :value 143 - number string)) + integer string)) (group :inline t (const :format "" :value :user) (string :tag "User")) @@ -346,7 +356,8 @@ Common keywords should be listed here.") (:program) (:function) (:password) - (:authentication password)) + (:authentication password) + (:stream nil)) (maildir (:path (or (getenv "MAILDIR") "~/Maildir/")) (:subdirs ("cur" "new")) @@ -713,6 +724,7 @@ If CONFIRM is non-nil, ask for confirmation before removing a file." (defun mail-source-fetch-pop (source callback) "Fetcher for single-file sources." (mail-source-bind (pop source) + ;; fixme: deal with stream type in format specs (mail-source-run-script prescript (format-spec-make ?p password ?t mail-source-crash-box @@ -741,12 +753,14 @@ If CONFIRM is non-nil, ask for confirmation before removing a file." (funcall function mail-source-crash-box)) ;; The default is to use pop3.el. (t + (require 'pop3) (let ((pop3-password password) (pop3-maildrop user) (pop3-mailhost server) (pop3-port port) (pop3-authentication-scheme - (if (eq authentication 'apop) 'apop 'pass))) + (if (eq authentication 'apop) 'apop 'pass)) + (pop3-stream-type stream)) (if (or debug-on-quit debug-on-error) (save-excursion (pop3-movemail mail-source-crash-box)) (condition-case err @@ -803,6 +817,7 @@ If CONFIRM is non-nil, ask for confirmation before removing a file." (function) ;; The default is to use pop3.el. (t + (require 'pop3) (let ((pop3-password password) (pop3-maildrop user) (pop3-mailhost server) diff --git a/lisp/mailcap.el b/lisp/mailcap.el index 7e457a4..015e253 100644 --- a/lisp/mailcap.el +++ b/lisp/mailcap.el @@ -1,6 +1,7 @@ ;;; mailcap.el --- MIME media types configuration -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: William M. Perry ;; Lars Magne Ingebrigtsen @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -531,7 +532,12 @@ MAILCAPS if set; otherwise (on Unix) use the path from RFC 1524, plus (skip-chars-forward ";")) (setq done t)))) (setq value (buffer-substring val-pos (point)))) - (setq results (cons (cons name value) results)) + ;; `test' as symbol, others like "copiousoutput" and "needsx11" as + ;; strings + (setq results (cons (cons (if (string-equal name "test") + 'test + name) + value) results)) (skip-chars-forward " \";\n\t")) results))) @@ -638,30 +644,31 @@ to supply to the test." (viewer (cdr (assoc 'viewer viewer-info))) (default-directory (expand-file-name "~/")) status parsed-test cache result) - (if (setq cache (assoc test mailcap-viewer-test-cache)) - (cadr cache) - (setq - result - (cond - ((not test-info) t) ; No test clause - ((not test) nil) ; Already failed test - ((eq test t) t) ; Already passed test - ((functionp test) ; Lisp function as test - (funcall test type-info)) - ((and (symbolp test) ; Lisp variable as test - (boundp test)) - (symbol-value test)) - ((and (listp test) ; List to be eval'd - (symbolp (car test))) - (eval test)) - (t - (setq test (mailcap-unescape-mime-test test type-info) - test (list shell-file-name nil nil nil - shell-command-switch test) - status (apply 'call-process test)) - (eq 0 status)))) - (push (list otest result) mailcap-viewer-test-cache) - result))) + (cond ((setq cache (assoc test mailcap-viewer-test-cache)) + (cadr cache)) + ((not test-info) t) ; No test clause + (t + (setq + result + (cond + ((not test) nil) ; Already failed test + ((eq test t) t) ; Already passed test + ((functionp test) ; Lisp function as test + (funcall test type-info)) + ((and (symbolp test) ; Lisp variable as test + (boundp test)) + (symbol-value test)) + ((and (listp test) ; List to be eval'd + (symbolp (car test))) + (eval test)) + (t + (setq test (mailcap-unescape-mime-test test type-info) + test (list shell-file-name nil nil nil + shell-command-switch test) + status (apply 'call-process test)) + (eq 0 status)))) + (push (list otest result) mailcap-viewer-test-cache) + result)))) (defun mailcap-add-mailcap-entry (major minor info) (let ((old-major (assoc major mailcap-mime-data))) diff --git a/lisp/md4.el b/lisp/md4.el index 33d0d32..9e37499 100644 --- a/lisp/md4.el +++ b/lisp/md4.el @@ -21,8 +21,8 @@ ;; ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Code: diff --git a/lisp/message.el b/lisp/message.el index 08777c9..4212edb 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -1,6 +1,7 @@ ;;; message.el --- composing mail and news messages -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail, news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -38,6 +39,7 @@ (require 'canlock) (require 'mailheader) (require 'nnheader) +(require 'gmm-utils) ;; This is apparently necessary even though things are autoloaded. ;; Because we dynamically bind mail-abbrev-mode-regexp, we'd better ;; require mailabbrev here. @@ -59,46 +61,46 @@ (put 'user-full-name 'custom-type 'string) (defgroup message-various nil - "Various Message Variables" + "Various Message Variables." :link '(custom-manual "(message)Various Message Variables") :group 'message) (defgroup message-buffers nil - "Message Buffers" + "Message Buffers." :link '(custom-manual "(message)Message Buffers") :group 'message) (defgroup message-sending nil - "Message Sending" + "Message Sending." :link '(custom-manual "(message)Sending Variables") :group 'message) (defgroup message-interface nil - "Message Interface" + "Message Interface." :link '(custom-manual "(message)Interface") :group 'message) (defgroup message-forwarding nil - "Message Forwarding" + "Message Forwarding." :link '(custom-manual "(message)Forwarding") :group 'message-interface) (defgroup message-insertion nil - "Message Insertion" + "Message Insertion." :link '(custom-manual "(message)Insertion") :group 'message) (defgroup message-headers nil - "Message Headers" + "Message Headers." :link '(custom-manual "(message)Message Headers") :group 'message) (defgroup message-news nil - "Composing News Messages" + "Composing News Messages." :group 'message) (defgroup message-mail nil - "Composing Mail Messages" + "Composing Mail Messages." :group 'message) (defgroup message-faces nil @@ -858,7 +860,8 @@ the signature is inserted." (set-keymap-parent map minibuffer-local-map) map) "Keymap for `message-read-from-minibuffer'." - :version "22.1") + :version "22.1" + :group 'message-various) ;;;###autoload (defcustom message-citation-line-function 'message-insert-citation-line @@ -876,15 +879,23 @@ configuration. See the variable `gnus-cite-attribution-suffix'." (defcustom message-yank-prefix "> " "*Prefix inserted on the lines of yanked messages. Fix `message-cite-prefix-regexp' if it is set to an abnormal value. -See also `message-yank-cited-prefix'." +See also `message-yank-cited-prefix' and `message-yank-empty-prefix'." :type 'string :link '(custom-manual "(message)Insertion Variables") :group 'message-insertion) (defcustom message-yank-cited-prefix ">" - "*Prefix inserted on cited or empty lines of yanked messages. + "*Prefix inserted on cited lines of yanked messages. Fix `message-cite-prefix-regexp' if it is set to an abnormal value. -See also `message-yank-prefix'." +See also `message-yank-prefix' and `message-yank-empty-prefix'." + :version "22.1" + :type 'string + :link '(custom-manual "(message)Insertion Variables") + :group 'message-insertion) + +(defcustom message-yank-empty-prefix ">" + "*Prefix inserted on empty lines of yanked messages. +See also `message-yank-prefix' and `message-yank-cited-prefix'." :version "22.1" :type 'string :link '(custom-manual "(message)Insertion Variables") @@ -902,7 +913,7 @@ Used by `message-yank-original' via `message-yank-cite'." "*Function for citing an original message. Predefined functions include `message-cite-original' and `message-cite-original-without-signature'. -Note that `message-cite-original' uses `mail-citation-hook' if that is non-nil." +Note that these functions use `mail-citation-hook' if that is non-nil." :type '(radio (function-item message-cite-original) (function-item message-cite-original-without-signature) (function-item sc-cite-original) @@ -1152,7 +1163,7 @@ starting with `not' and followed by regexps." table) "Syntax table used while in Message mode.") -(defface message-header-to-face +(defface message-header-to '((((class color) (background dark)) (:foreground "green2" :bold t)) @@ -1163,8 +1174,10 @@ starting with `not' and followed by regexps." (:bold t :italic t))) "Face used for displaying From headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-to-face 'face-alias 'message-header-to) -(defface message-header-cc-face +(defface message-header-cc '((((class color) (background dark)) (:foreground "green4" :bold t)) @@ -1175,8 +1188,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying Cc headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-cc-face 'face-alias 'message-header-cc) -(defface message-header-subject-face +(defface message-header-subject '((((class color) (background dark)) (:foreground "green3")) @@ -1187,8 +1202,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying subject headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-subject-face 'face-alias 'message-header-subject) -(defface message-header-newsgroups-face +(defface message-header-newsgroups '((((class color) (background dark)) (:foreground "yellow" :bold t :italic t)) @@ -1199,8 +1216,10 @@ starting with `not' and followed by regexps." (:bold t :italic t))) "Face used for displaying newsgroups headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-newsgroups-face 'face-alias 'message-header-newsgroups) -(defface message-header-other-face +(defface message-header-other '((((class color) (background dark)) (:foreground "#b00000")) @@ -1211,8 +1230,10 @@ starting with `not' and followed by regexps." (:bold t :italic t))) "Face used for displaying newsgroups headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-other-face 'face-alias 'message-header-other) -(defface message-header-name-face +(defface message-header-name '((((class color) (background dark)) (:foreground "DarkGreen")) @@ -1223,8 +1244,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying header names." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-name-face 'face-alias 'message-header-name) -(defface message-header-xheader-face +(defface message-header-xheader '((((class color) (background dark)) (:foreground "blue")) @@ -1235,8 +1258,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying X-Header headers." :group 'message-faces) +;; backward-compatibility alias +(put 'message-header-xheader-face 'face-alias 'message-header-xheader) -(defface message-separator-face +(defface message-separator '((((class color) (background dark)) (:foreground "blue3")) @@ -1247,8 +1272,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying the separator." :group 'message-faces) +;; backward-compatibility alias +(put 'message-separator-face 'face-alias 'message-separator) -(defface message-cited-text-face +(defface message-cited-text '((((class color) (background dark)) (:foreground "red")) @@ -1259,8 +1286,10 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying cited text names." :group 'message-faces) +;; backward-compatibility alias +(put 'message-cited-text-face 'face-alias 'message-cited-text) -(defface message-mml-face +(defface message-mml '((((class color) (background dark)) (:foreground "ForestGreen")) @@ -1271,6 +1300,8 @@ starting with `not' and followed by regexps." (:bold t))) "Face used for displaying MML." :group 'message-faces) +;; backward-compatibility alias +(put 'message-mml-face 'face-alias 'message-mml) (defun message-font-lock-make-header-matcher (regexp) (let ((form @@ -1294,41 +1325,41 @@ starting with `not' and followed by regexps." (let ((content "[ \t]*\\(.+\\(\n[ \t].*\\)*\\)\n?")) `((,(message-font-lock-make-header-matcher (concat "^\\([Tt]o:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-to-face nil t)) + (1 'message-header-name) + (2 'message-header-to nil t)) (,(message-font-lock-make-header-matcher (concat "^\\(^[GBF]?[Cc][Cc]:\\|^[Rr]eply-[Tt]o:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-cc-face nil t)) + (1 'message-header-name) + (2 'message-header-cc nil t)) (,(message-font-lock-make-header-matcher (concat "^\\([Ss]ubject:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-subject-face nil t)) + (1 'message-header-name) + (2 'message-header-subject nil t)) (,(message-font-lock-make-header-matcher (concat "^\\([Nn]ewsgroups:\\|Followup-[Tt]o:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-newsgroups-face nil t)) + (1 'message-header-name) + (2 'message-header-newsgroups nil t)) (,(message-font-lock-make-header-matcher (concat "^\\([A-Z][^: \n\t]+:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-other-face nil t)) + (1 'message-header-name) + (2 'message-header-other nil t)) (,(message-font-lock-make-header-matcher (concat "^\\(X-[A-Za-z0-9-]+:\\|In-Reply-To:\\)" content)) - (1 'message-header-name-face) - (2 'message-header-name-face)) + (1 'message-header-name) + (2 'message-header-name)) ,@(if (and mail-header-separator (not (equal mail-header-separator ""))) `((,(concat "^\\(" (regexp-quote mail-header-separator) "\\)$") - 1 'message-separator-face)) + 1 'message-separator)) nil) ((lambda (limit) (re-search-forward (concat "^\\(" message-cite-prefix-regexp "\\).*") limit t)) - (0 'message-cited-text-face)) + (0 'message-cited-text)) ("<#/?\\(multipart\\|part\\|external\\|mml\\|secure\\)[^>]*>" - (0 'message-mml-face)))) + (0 'message-mml)))) "Additional expressions to highlight in Message mode.") @@ -1337,10 +1368,10 @@ starting with `not' and followed by regexps." (put 'message-mode 'font-lock-defaults '(message-font-lock-keywords t)) (defvar message-face-alist - '((bold . bold-region) + '((bold . message-bold-region) (underline . underline-region) (default . (lambda (b e) - (unbold-region b e) + (message-unbold-region b e) (ununderline-region b e)))) "Alist of mail and news faces for facemenu. The cdr of each entry is a function for applying the face to a region.") @@ -1395,8 +1426,13 @@ should be sent in several parts. If it is nil, the size is unlimited." (integer 1000000))) (defcustom message-alternative-emails nil - "A regexp to match the alternative email addresses. -The first matched address (not primary one) is used in the From field." + "*Regexp matching alternative email addresses. +The first address in the To, Cc or From headers of the original +article matching this variable is used as the From field of +outgoing messages. + +This variable has precedence over posting styles and anything that runs +off `message-setup-hook'." :group 'message-headers :link '(custom-manual "(message)Message Headers") :type '(choice (const :tag "Always use primary" nil) @@ -1450,7 +1486,7 @@ no, only reply back to the author." :type 'boolean) (defcustom message-user-fqdn nil - "*Domain part of Messsage-Ids." + "*Domain part of Message-Ids." :version "22.1" :group 'message-headers :link '(custom-manual "(message)News Headers") @@ -1461,8 +1497,13 @@ no, only reply back to the author." (file-error)) (mm-coding-system-p 'utf-8) (executable-find idna-program) - 'ask) - "Whether to encode non-ASCII in domain names into ASCII according to IDNA." + (string= (idna-to-ascii "räksmörgås") + "xn--rksmrgs-5wao1o") + t) + "Whether to encode non-ASCII in domain names into ASCII according to IDNA. +GNU Libidn, and in particular the elisp package \"idna.el\" and +the external program \"idn\", must be installed for this +functionality to work." :version "22.1" :group 'message-headers :link '(custom-manual "(message)IDNA") @@ -1830,7 +1871,6 @@ Leading \"Re: \" is not stripped by this function. Use the function ;;; Suggested by Jonas Steverud @ www.dtek.chalmers.se/~d4jonas/ -;;;###autoload (defun message-change-subject (new-subject) "Ask for NEW-SUBJECT header, append (was: )." ;; @@ -1862,32 +1902,31 @@ Leading \"Re: \" is not stripped by this function. Use the function " (was: " old-subject ")\n"))))))))) -;;;###autoload -(defun message-mark-inserted-region (beg end) +(defun message-mark-inserted-region (beg end &optional verbatim) "Mark some region in the current article with enclosing tags. -See `message-mark-insert-begin' and `message-mark-insert-end'." - (interactive "r") +See `message-mark-insert-begin' and `message-mark-insert-end'. +If VERBATIM, use slrn style verbatim marks (\"#v+\" and \"#v-\")." + (interactive "r\nP") (save-excursion ;; add to the end of the region first, otherwise end would be invalid (goto-char end) - (insert message-mark-insert-end) + (insert (if verbatim "#v-\n" message-mark-insert-end)) (goto-char beg) - (insert message-mark-insert-begin))) + (insert (if verbatim "#v+\n" message-mark-insert-begin)))) -;;;###autoload -(defun message-mark-insert-file (file) +(defun message-mark-insert-file (file &optional verbatim) "Insert FILE at point, marking it with enclosing tags. -See `message-mark-insert-begin' and `message-mark-insert-end'." - (interactive "fFile to insert: ") +See `message-mark-insert-begin' and `message-mark-insert-end'. +If VERBATIM, use slrn style verbatim marks (\"#v+\" and \"#v-\")." + (interactive "fFile to insert: \nP") ;; reverse insertion to get correct result. (let ((p (point))) - (insert message-mark-insert-end) + (insert (if verbatim "#v-\n" message-mark-insert-end)) (goto-char p) (insert-file-contents file) (goto-char p) - (insert message-mark-insert-begin))) + (insert (if verbatim "#v+\n" message-mark-insert-begin)))) -;;;###autoload (defun message-add-archive-header () "Insert \"X-No-Archive: Yes\" in the header and a note in the body. The note can be customized using `message-archive-note'. When called with a @@ -1907,7 +1946,6 @@ body, set `message-archive-note' to nil." (message-add-header message-archive-header) (message-sort-headers))) -;;;###autoload (defun message-cross-post-followup-to-header (target-group) "Mangles FollowUp-To and Newsgroups header to point to TARGET-GROUP. With prefix-argument just set Follow-Up, don't cross-post." @@ -1951,7 +1989,6 @@ With prefix-argument just set Follow-Up, don't cross-post." (insert (concat "\nFollowup-To: " target-group))) (setq message-cross-post-old-target target-group)) -;;;###autoload (defun message-cross-post-insert-note (target-group cross-post in-old old-groups) "Insert a in message body note about a set Followup or Crosspost. @@ -1984,7 +2021,6 @@ been made to before the user asked for a Crosspost." (insert (concat message-followup-to-note target-group "\n")) (insert (concat message-cross-post-note target-group "\n"))))) -;;;###autoload (defun message-cross-post-followup-to (target-group) "Crossposts message and set Followup-To to TARGET-GROUP. With prefix-argument just set Follow-Up, don't cross-post." @@ -2026,7 +2062,6 @@ With prefix-argument just set Follow-Up, don't cross-post." ;;; Reduce To: to Cc: or Bcc: header -;;;###autoload (defun message-reduce-to-to-cc () "Replace contents of To: header with contents of Cc: or Bcc: header." (interactive) @@ -2218,6 +2253,17 @@ Point is left at the beginning of the narrowed-to region." (message-skip-to-next-address) (kill-region start (point)))) + +(defun message-info (&optional arg) + "Display the Message manual. + +Prefixed with one \\[universal-argument], display the Emacs MIME manual. +Prefixed with two \\[universal-argument]'s, display the PGG manual." + (interactive "p") + (cond ((eq arg 16) (Info-goto-node "(pgg)Top")) + ((eq arg 4) (Info-goto-node "(emacs-mime)Top")) + (t (Info-goto-node "(message)Top")))) + ;;; @@ -2269,6 +2315,7 @@ Point is left at the beginning of the narrowed-to region." (define-key message-mode-map "\C-c\C-fw" 'message-insert-wide-reply) (define-key message-mode-map "\C-c\C-n" 'message-insert-newsgroups) (define-key message-mode-map "\C-c\C-l" 'message-to-list-only) + (define-key message-mode-map "\C-c\C-f\C-e" 'message-insert-expires) (define-key message-mode-map "\C-c\C-u" 'message-insert-or-toggle-importance) (define-key message-mode-map "\C-c\M-n" @@ -2344,7 +2391,11 @@ Point is left at the beginning of the narrowed-to region." '(:help "Ask, then arrange to send message at that time"))] ["Kill Message" message-kill-buffer ,@(if (featurep 'xemacs) '(t) - '(:help "Delete this message without sending"))])) + '(:help "Delete this message without sending"))] + "----" + ["Message manual" message-info + ,@(if (featurep 'xemacs) '(t) + '(:help "Display the Message manual"))])) (easy-menu-define message-mode-field-menu message-mode-map "" @@ -2377,7 +2428,8 @@ Point is left at the beginning of the narrowed-to region." ;; ["Followup-To (with note in body)" message-cross-post-followup-to t] ["Crosspost / Followup-To..." message-cross-post-followup-to t] ["Distribution" message-goto-distribution t] - ["X-No-Archive:" message-add-archive-header t ] + ["Expires" message-insert-expires t ] + ["X-No-Archive" message-add-archive-header t ] "----" ;; (typical) mailing-lists stuff ["Fetch To" message-insert-to @@ -2397,6 +2449,8 @@ Point is left at the beginning of the narrowed-to region." "----" ["Sort Headers" message-sort-headers t] ["Encode non-ASCII domain names" message-idna-to-ascii-rhs t] + ;; We hide `message-hidden-headers' by narrowing the buffer. + ["Show Hidden Headers" widen t] ["Goto Body" message-goto-body t] ["Goto Signature" message-goto-signature t])) @@ -2480,6 +2534,7 @@ C-c C-f move to a header field (and create it if there isn't): C-c C-f C-o move to From (\"Originator\") 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-e move to Expires C-c C-f C-i cycle through Importance values C-c C-f s change subject and append \"(was: )\" C-c C-f x crossposting with FollowUp-To header and note in body @@ -2539,7 +2594,7 @@ M-RET `message-newline-and-reformat' (break the line and reformat)." (set (make-local-variable 'font-lock-defaults) '(message-font-lock-keywords t)) (if (boundp 'tool-bar-map) - (set (make-local-variable 'tool-bar-map) (message-tool-bar-map)))) + (set (make-local-variable 'tool-bar-map) (message-make-tool-bar)))) (easy-menu-add message-mode-menu message-mode-map) (easy-menu-add message-mode-field-menu message-mode-map) (gnus-make-local-hook 'after-change-functions) @@ -2694,6 +2749,11 @@ M-RET `message-newline-and-reformat' (break the line and reformat)." (message-goto-body) (forward-line -1)) +(defun message-in-body-p () + "Return t if point is in the message body." + (let ((body (save-excursion (message-goto-body) (point)))) + (>= (point) body))) + (defun message-goto-signature () "Move point to the beginning of the message signature. If there is no signature in the article, go to the end and @@ -2759,7 +2819,8 @@ prefix FORCE is given." (message-carefully-insert-headers headers))) (defcustom message-header-synonyms - '((To Cc Bcc)) + '((To Cc Bcc) + (Original-To)) "List of lists of header synonyms. E.g., if this list contains a member list with elements `Cc' and `To', then `message-carefully-insert-headers' will not insert a `To' header @@ -2855,7 +2916,7 @@ or in the synonym headers, defined by `message-header-synonyms'." "Kill all text up to the signature. If a numberic argument or prefix arg is given, leave that number of lines before the signature intact." - (interactive "p") + (interactive "P") (save-excursion (save-restriction (let ((point (point))) @@ -2867,13 +2928,14 @@ of lines before the signature intact." (end-of-line -1))) (unless (= point (point)) (kill-region point (point)) - (insert "\n")))))) + (unless (bolp) + (insert "\n"))))))) (defun message-newline-and-reformat (&optional arg not-break) "Insert four newlines, and then reformat if inside quoted text. Prefix arg means justify as well." (interactive (list (if current-prefix-arg 'full))) - (let (quoted point beg end leading-space bolp) + (let (quoted point beg end leading-space bolp fill-paragraph-function) (setq point (point)) (beginning-of-line) (setq beg (point)) @@ -2958,7 +3020,9 @@ Prefix arg means justify as well." (if point (goto-char point))))) (defun message-fill-paragraph (&optional arg) - "Like `fill-paragraph'." + "Message specific function to fill a paragraph. +This function is used as the value of `fill-paragraph-function' in +Message buffers and is not meant to be called directly." (interactive (list (if current-prefix-arg 'full))) (if (if (boundp 'filladapt-mode) filladapt-mode) nil @@ -3220,9 +3284,12 @@ However, if `message-yank-prefix' is non-nil, insert that prefix on each line." (save-excursion (goto-char start) (while (< (point) (mark t)) - (if (or (looking-at ">") (looking-at "^$")) - (insert message-yank-cited-prefix) - (insert message-yank-prefix)) + (cond ((looking-at ">") + (insert message-yank-cited-prefix)) + ((looking-at "^$") + (insert message-yank-empty-prefix)) + (t + (insert message-yank-prefix))) (forward-line 1)))) (goto-char start))) @@ -3241,7 +3308,9 @@ prefix, and don't delete any headers." (when (and message-reply-buffer message-cite-function) (delete-windows-on message-reply-buffer t) - (insert-buffer message-reply-buffer) + (push-mark (save-excursion + (insert-buffer-substring message-reply-buffer) + (point))) (unless arg (funcall message-cite-function)) (message-exchange-point-and-mark) @@ -3268,53 +3337,14 @@ prefix, and don't delete any headers." (push (buffer-name buffer) buffers)))) (nreverse buffers))) -(defun message-cite-original-without-signature () - "Cite function in the standard Message manner." - (let* ((start (point)) - (end (mark t)) - (functions - (when message-indent-citation-function - (if (listp message-indent-citation-function) - message-indent-citation-function - (list message-indent-citation-function)))) - ;; This function may be called by `gnus-summary-yank-message' and - ;; may insert a different article from the original. So, we will - ;; modify the value of `message-reply-headers' with that article. - (message-reply-headers - (save-restriction - (narrow-to-region start end) - (message-narrow-to-head-1) - (vector 0 - (or (message-fetch-field "subject") "none") - (message-fetch-field "from") - (message-fetch-field "date") - (message-fetch-field "message-id" t) - (message-fetch-field "references") - 0 0 "")))) - (mml-quote-region start end) - ;; Allow undoing. - (undo-boundary) - (goto-char end) - (when (re-search-backward message-signature-separator start t) - ;; Also peel off any blank lines before the signature. - (forward-line -1) - (while (looking-at "^[ \t]*$") - (forward-line -1)) - (forward-line 1) - (delete-region (point) end) - (unless (search-backward "\n\n" start t) - ;; Insert a blank line if it is peeled off. - (insert "\n"))) - (goto-char start) - (mapc 'funcall functions) - (when message-citation-line-function - (unless (bolp) - (insert "\n")) - (funcall message-citation-line-function)))) +(eval-when-compile (defvar mail-citation-hook)) ; Compiler directive -(eval-when-compile (defvar mail-citation-hook)) ;Compiler directive -(defun message-cite-original () - "Cite function in the standard Message manner." +(defun message-cite-original-1 (strip-signature) + "Cite an original message. +If STRIP-SIGNATURE is non-nil, strips off the signature from the +original message. + +This function uses `mail-citation-hook' if that is non-nil." (if (and (boundp 'mail-citation-hook) mail-citation-hook) (run-hooks 'mail-citation-hook) @@ -3342,6 +3372,20 @@ prefix, and don't delete any headers." (message-fetch-field "references") 0 0 "")))) (mml-quote-region start end) + (when strip-signature + ;; Allow undoing. + (undo-boundary) + (goto-char end) + (when (re-search-backward message-signature-separator start t) + ;; Also peel off any blank lines before the signature. + (forward-line -1) + (while (looking-at "^[ \t]*$") + (forward-line -1)) + (forward-line 1) + (delete-region (point) end) + (unless (search-backward "\n\n" start t) + ;; Insert a blank line if it is peeled off. + (insert "\n")))) (goto-char start) (mapc 'funcall functions) (when message-citation-line-function @@ -3356,10 +3400,21 @@ prefix, and don't delete any headers." (insert "> [Quoted text removed due to X-No-Archive]\n") (forward-line -1))))) +(defun message-cite-original () + "Cite function in the standard Message manner." + (message-cite-original-1 nil)) + +(defun message-cite-original-without-signature () + "Cite function in the standard Message manner. +This function strips off the signature from the original message." + (message-cite-original-1 t)) + (defun message-insert-citation-line () "Insert a simple citation line." (when message-reply-headers - (insert (mail-header-from message-reply-headers) " writes:\n\n"))) + (insert (mail-header-from message-reply-headers) " writes:") + (newline) + (newline))) (defun message-position-on-field (header &rest afters) (let ((case-fold-search t)) @@ -3653,8 +3708,8 @@ not have PROP." (when (let ((char (char-after))) (or (< (mm-char-int char) 128) (and (mm-multibyte-p) - ;; Fixme: Wrong for Emacs 22 and for things - ;; like undecable utf-8. Should at least + ;; FIXME: Wrong for Emacs 23 (unicode) and for + ;; things like undecable utf-8. Should at least ;; use find-coding-systems-region. (memq (char-charset char) '(eight-bit-control eight-bit-graphic @@ -4258,7 +4313,7 @@ Otherwise, generate and save a value for `canlock-password' first." (zerop (length (setq to (completing-read - "Followups to (default: no Followup-To header) " + "Followups to (default no Followup-To header): " (mapcar #'list (cons "poster" (message-tokenize-header @@ -4661,6 +4716,22 @@ If NOW, use that time instead." (let ((system-time-locale "C")) (format-time-string "%a, %d %b %Y %T %z" now))) +(defun message-insert-expires (days) + "Insert the Expires header. Expiry in DAYS days." + (interactive "NExpire article in how many days? ") + (save-excursion + (message-position-on-field "Expires" "X-Draft-From") + (insert (message-make-expires-date days)))) + +(defun message-make-expires-date (days) + "Make date string for the Expires header. Expiry in DAYS days. + +In posting styles use `(\"Expires\" (make-expires-date 30))'." + (let* ((cur (decode-time (current-time))) + (nday (+ days (nth 3 cur)))) + (setf (nth 3 cur) nday) + (message-make-date (apply 'encode-time cur)))) + (defun message-make-message-id () "Make a unique Message-ID." (concat "<" (message-unique-id) @@ -4697,7 +4768,9 @@ If NOW, use that time instead." (* 25 25))) (let ((tm (current-time))) (concat - (if (memq system-type '(ms-dos emx vax-vms)) + (if (or (memq system-type '(ms-dos emx vax-vms)) + ;; message-number-base36 doesn't handle bigints. + (floatp (user-uid))) (let ((user (downcase (user-login-name)))) (while (string-match "[^a-z0-9_]" user) (aset user (match-beginning 0) ?_)) @@ -5000,13 +5073,17 @@ subscribed address (and not the additional To and Cc header contents)." (let ((field (message-fetch-field header)) rhs ace address) (when field - (dolist (address (mail-header-parse-addresses field)) - (setq address (car address) - rhs (downcase (or (cadr (split-string address "@")) "")) - ace (downcase (idna-to-ascii rhs))) + (dolist (rhs + (mm-delete-duplicates + (mapcar (lambda (rhs) (or (cadr (split-string rhs "@")) "")) + (mapcar 'downcase + (mapcar + 'car (mail-header-parse-addresses field)))))) + (setq ace (downcase (idna-to-ascii rhs))) (when (and (not (equal rhs ace)) (or (not (eq message-use-idna 'ask)) - (y-or-n-p (format "Replace %s with %s? " rhs ace)))) + (y-or-n-p (format "Replace %s with %s in %s:? " + rhs ace header)))) (goto-char (point-min)) (while (re-search-forward (concat "^" header ":") nil t) (message-narrow-to-field) @@ -5026,6 +5103,8 @@ See `message-idna-encode'." (message-idna-to-ascii-rhs-1 "From") (message-idna-to-ascii-rhs-1 "To") (message-idna-to-ascii-rhs-1 "Reply-To") + (message-idna-to-ascii-rhs-1 "Mail-Reply-To") + (message-idna-to-ascii-rhs-1 "Mail-Followup-To") (message-idna-to-ascii-rhs-1 "Cc"))))) (defun message-generate-headers (headers) @@ -5117,7 +5196,8 @@ Headers already prepared in the buffer are not modified." ;; The element is a symbol. We insert the value ;; of this symbol, if any. (symbol-value header)) - ((not (message-check-element header)) + ((not (message-check-element + (intern (downcase (symbol-name header))))) ;; We couldn't generate a value for this header, ;; so we just ask the user. (read-from-minibuffer @@ -5145,7 +5225,7 @@ Headers already prepared in the buffer are not modified." ;; totally and insert the new value. (delete-region (point) (point-at-eol)) ;; If the header is optional, and the header was - ;; empty, we con't insert it anyway. + ;; empty, we can't insert it anyway. (unless optionalp (push header-string message-inserted-headers) (insert value) @@ -5585,10 +5665,6 @@ are not included." (when message-default-mail-headers (insert message-default-mail-headers) (or (bolp) (insert ?\n))) - (save-restriction - (message-narrow-to-headers) - (if message-alternative-emails - (message-use-alternative-email-as-from))) (when message-generate-headers-first (message-generate-headers (message-headers-to-generate @@ -5607,6 +5683,12 @@ are not included." ;; Generate hashcash headers for recipients already known (mail-add-payment-async)) (run-hooks 'message-setup-hook) + ;; Do this last to give it precedence over posting styles, etc. + (when (message-mail-p) + (save-restriction + (message-narrow-to-headers) + (if message-alternative-emails + (message-use-alternative-email-as-from)))) (message-position-point) (undo-boundary)) @@ -6009,9 +6091,9 @@ want to get rid of this query permanently.")) (defun message-is-yours-p () "Non-nil means current article is yours. -If you have added 'cancel-messages to 'message-shoot-gnksa-feet', all articles +If you have added 'cancel-messages to `message-shoot-gnksa-feet', all articles are yours except those that have Cancel-Lock header not belonging to you. -Instead of shooting GNKSA feet, you should modify 'message-alternative-emails' +Instead of shooting GNKSA feet, you should modify `message-alternative-emails' regexp to match all of yours addresses." ;; Canlock-logic as suggested by Per Abrahamsen ;; @@ -6188,7 +6270,9 @@ news, Source is the list of newsgroups is was posted to." (prefix (if group (gnus-group-decoded-name group) - (or (and from (car (gnus-extract-address-components from))) + (or (and from (or + (car (gnus-extract-address-components from)) + (cadr (gnus-extract-address-components from)))) "(nowhere)")))) (concat "[" (if message-forward-decoded-p @@ -6424,6 +6508,7 @@ Optional DIGEST will use digest to forward." (set-buffer (get-buffer-create " *message resend*")) (erase-buffer)) (let ((message-this-is-mail t) + message-generate-hashcash message-setup-hook) (message-setup `((To . ,address)))) ;; Insert our usual headers. @@ -6461,6 +6546,7 @@ Optional DIGEST will use digest to forward." ;; Send it. (let ((message-inhibit-body-encoding t) message-required-mail-headers + message-generate-hashcash rfc2047-encode-encoded-words) (message-send-mail)) (kill-buffer (current-buffer))) @@ -6575,7 +6661,7 @@ you." ;; This code should be moved to underline.el (from which it is stolen). ;;;###autoload -(defun bold-region (start end) +(defun message-bold-region (start end) "Bold all nonblank characters in the region. Works by overstriking characters. Called from program, takes two arguments START and END @@ -6591,7 +6677,7 @@ which specify the range to operate on." (forward-char 1))))) ;;;###autoload -(defun unbold-region (start end) +(defun message-unbold-region (start end) "Remove all boldness (overstruck characters) in the region. Called from program, takes two arguments START and END which specify the range to operate on." @@ -6621,54 +6707,123 @@ which specify the range to operate on." ;; Support for toolbar (eval-when-compile - (defvar tool-bar-map) (defvar tool-bar-mode)) -(defun message-tool-bar-local-item-from-menu (command icon in-map &optional from-map &rest props) - ;; We need to make tool bar entries in local keymaps with - ;; `tool-bar-local-item-from-menu' in Emacs > 21.3 - (if (fboundp 'tool-bar-local-item-from-menu) - ;; This is for Emacs 21.3 - (tool-bar-local-item-from-menu command icon in-map from-map props) - (tool-bar-add-item-from-menu command icon from-map props))) - -(defun message-tool-bar-map () - (or message-tool-bar-map - (setq message-tool-bar-map - (and - (condition-case nil (require 'tool-bar) (error nil)) - (fboundp 'tool-bar-add-item-from-menu) +;; Note: The :set function in the `message-tool-bar*' variables will only +;; affect _new_ message buffers. We might add a function that walks thru all +;; message-mode buffers and force the update. +(defun message-tool-bar-update (&optional symbol value) + "Update message mode toolbar. +Setter function for custom variables." + (setq-default message-tool-bar-map nil) + (when symbol + ;; When used as ":set" function: + (set-default symbol value))) + +(defcustom message-tool-bar (if (eq gmm-tool-bar-style 'gnome) + 'message-tool-bar-gnome + 'message-tool-bar-retro) + "Specifies the message mode tool bar. + +It can be either a list or a symbol refering to a list. See +`gmm-tool-bar-from-list' for the format of the list. The +default key map is `message-mode-map'. + +Pre-defined symbols include `message-tool-bar-gnome' and +`message-tool-bar-retro'." + :type '(repeat gmm-tool-bar-list-item) + :type '(choice (const :tag "GNOME style" message-tool-bar-gnome) + (const :tag "Retro look" message-tool-bar-retro) + (repeat :tag "User defined list" gmm-tool-bar-item) + (symbol)) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'message-tool-bar-update + :group 'message) + +(defcustom message-tool-bar-gnome + '((ispell-message "spell" nil + :visible (or (not (boundp 'flyspell-mode)) + (not flyspell-mode))) + (flyspell-buffer "spell" t + :visible (and (boundp 'flyspell-mode) + flyspell-mode) + :help "Flyspell whole buffer") + (gmm-ignore "separator") + (message-send-and-exit "mail/send") + (message-dont-send "mail/save-draft") + (message-kill-buffer "close") ;; stock_cancel + (mml-attach-file "attach" mml-mode-map) + (mml-preview "mail/preview" mml-mode-map) + (mml-secure-message-sign-encrypt "lock" mml-mode-map :visible nil) + (message-insert-importance-high "important" nil :visible nil) + (message-insert-importance-low "unimportant" nil :visible nil) + (message-insert-disposition-notification-to "receipt" nil :visible nil) + (gmm-customize-mode "preferences" t :help "Edit mode preferences") + (message-info "help" t :help "Message manual")) + "List of items for the message tool bar (GNOME style). + +See `gmm-tool-bar-from-list' for details on the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'message-tool-bar-update + :group 'message) + +(defcustom message-tool-bar-retro + '(;; Old Emacs 21 icon for consistency. + (message-send-and-exit "gnus/mail_send") + (message-kill-buffer "close") + (message-dont-send "cancel") + (mml-attach-file "attach" mml-mode-map) + (ispell-message "spell") + (mml-preview "preview" mml-mode-map) + (message-insert-importance-high "gnus/important") + (message-insert-importance-low "gnus/unimportant") + (message-insert-disposition-notification-to "gnus/receipt")) + "List of items for the message tool bar (retro style). + +See `gmm-tool-bar-from-list' for details on the format of the list." + :type '(repeat gmm-tool-bar-item) + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'message-tool-bar-update + :group 'message) + +(defcustom message-tool-bar-zap-list + '(new-file open-file dired kill-buffer write-file + print-buffer customize help) + "List of icon items from the global tool bar. +These items are not displayed on the message mode tool bar. + +See `gmm-tool-bar-from-list' for the format of the list." + :type 'gmm-tool-bar-zap-list + :version "23.0" ;; No Gnus + :initialize 'custom-initialize-default + :set 'message-tool-bar-update + :group 'message) + +(defvar image-load-path) + +(defun message-make-tool-bar (&optional force) + "Make a message mode tool bar from `message-tool-bar-list'. +When FORCE, rebuild the tool bar." + (when (and (not (featurep 'xemacs)) + (boundp 'tool-bar-mode) tool-bar-mode - (let ((tool-bar-map (copy-keymap tool-bar-map)) - (load-path (mm-image-load-path))) - ;; Zap some items which aren't so relevant and take - ;; up space. - (dolist (key '(print-buffer kill-buffer save-buffer - write-file dired open-file)) - (define-key tool-bar-map (vector key) nil)) - (message-tool-bar-local-item-from-menu - 'message-send-and-exit "mail_send" tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'message-kill-buffer "close" tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'message-dont-send "cancel" tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'mml-attach-file "attach" tool-bar-map mml-mode-map) - (message-tool-bar-local-item-from-menu - 'ispell-message "spell" tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'mml-preview "preview" - tool-bar-map mml-mode-map) - (message-tool-bar-local-item-from-menu - 'message-insert-importance-high "important" - tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'message-insert-importance-low "unimportant" - tool-bar-map message-mode-map) - (message-tool-bar-local-item-from-menu - 'message-insert-disposition-notification-to "receipt" - tool-bar-map message-mode-map) - tool-bar-map))))) + (or (not message-tool-bar-map) force)) + (setq message-tool-bar-map + (let* ((load-path + (gmm-image-load-path-for-library "message" + "mail/save-draft.xpm" + nil t)) + (image-load-path (cons (car load-path) + (when (boundp 'image-load-path) + image-load-path)))) + (gmm-tool-bar-from-list message-tool-bar + message-tool-bar-zap-list + 'message-mode-map)))) + message-tool-bar-map) ;;; Group name completion. @@ -6703,7 +6858,8 @@ If nil, the function bound in `text-mode-map' or `global-map' is executed." :version "22.1" :group 'message :link '(custom-manual "(message)Various Commands") - :type 'function) + :type '(choice (const nil) + function)) (defun message-tab () "Complete names according to `message-completion-alist'. @@ -6720,6 +6876,17 @@ those headers." (lookup-key global-map "\t") 'indent-relative)))) +(eval-and-compile + (condition-case nil + (with-temp-buffer + (let ((standard-output (current-buffer))) + (eval '(display-completion-list nil ""))) + (defalias 'message-display-completion-list 'display-completion-list)) + (error ;; Don't use `wrong-number-of-arguments' here because of XEmacs. + (defun message-display-completion-list (completions &optional ignore) + "Display the list of completions, COMPLETIONS, using `standard-output'." + (display-completion-list completions))))) + (defun message-expand-group () "Expand the group name under point." (let* ((b (save-excursion @@ -6758,7 +6925,9 @@ those headers." (let ((buffer-read-only nil)) (erase-buffer) (let ((standard-output (current-buffer))) - (display-completion-list (sort completions 'string<))) + (message-display-completion-list (sort completions 'string<) + string)) + (setq buffer-read-only nil) (goto-char (point-min)) (delete-region (point) (progn (forward-line 3) (point)))))))))) @@ -6893,6 +7062,9 @@ regexp VARSTR." (read-string prompt initial-contents)))) (defun message-use-alternative-email-as-from () + "Set From field of the outgoing message to the first matching +address in `message-alternative-emails', looking at To, Cc and +From headers in the original article." (require 'mail-utils) (let* ((fields '("To" "Cc" "From")) (emails @@ -6907,6 +7079,7 @@ regexp VARSTR." emails nil)) (pop emails)) (unless (or (not email) (equal email user-mail-address)) + (message-remove-header "From") (goto-char (point-max)) (insert "From: " (let ((user-mail-address email)) (message-make-from)) "\n")))) diff --git a/lisp/messagexmas.el b/lisp/messagexmas.el index facbf88..831c0fa 100644 --- a/lisp/messagexmas.el +++ b/lisp/messagexmas.el @@ -1,7 +1,7 @@ ;;; messagexmas.el --- XEmacs extensions to message -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2003, 2004, +;; 2005 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail, news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -38,13 +38,20 @@ If this variable is nil, Message will try to locate the directory automatically.") -(defvar message-use-toolbar (if (featurep 'toolbar) - 'default-toolbar - nil) - "*If nil, do not use a toolbar. -If it is non-nil, it must be a toolbar. The five valid values are -`default-toolbar', `top-toolbar', `bottom-toolbar', -`right-toolbar', and `left-toolbar'.") +(defvar message-use-toolbar (if (featurep 'toolbar) 'default) + "*Position to display the toolbar. Nil means do not use a toolbar. +If it is non-nil, it should be one of the symbols `default', `top', +`bottom', `right', and `left'. `default' means to use the default +toolbar, the rest mean to display the toolbar on the place which those +names show.") + +(defvar message-toolbar-thickness + (if (featurep 'toolbar) + (cons (specifier-instance default-toolbar-height) + (specifier-instance default-toolbar-width))) + "*Cons of the height and the width specifying the thickness of a toolbar. +The height is used for the toolbar displayed on the top or the bottom, +the width is used for the toolbar displayed on the right or the left.") (defvar message-toolbar '([message-spell ispell-message t "Spell"] @@ -60,7 +67,8 @@ If it is non-nil, it must be a toolbar. The five valid values are (nnheader-find-etc-directory package)))) (defun message-xmas-setup-toolbar (bar &optional force package) - (let ((dir (message-xmas-find-glyph-directory package)) + (let ((dir (or (message-xmas-find-glyph-directory package) + (message-xmas-find-glyph-directory "gnus"))) (xpm (if (featurep 'xpm) "xpm" "xbm")) icon up down disabled name) (unless package @@ -84,10 +92,48 @@ If it is non-nil, it must be a toolbar. The five valid values are dir)) (defun message-setup-toolbar () - (and message-use-toolbar - (message-xmas-setup-toolbar message-toolbar) - (set-specifier (symbol-value message-use-toolbar) - (cons (current-buffer) message-toolbar)))) + (when (featurep 'toolbar) + (if (and message-use-toolbar + (message-xmas-setup-toolbar message-toolbar)) + (let ((bar (or (intern-soft (format "%s-toolbar" message-use-toolbar)) + 'default-toolbar)) + (height (car message-toolbar-thickness)) + (width (cdr message-toolbar-thickness)) + (cur (current-buffer)) + bars) + (set-specifier (symbol-value bar) message-toolbar cur) + (set-specifier default-toolbar-height height cur) + (set-specifier default-toolbar-width width cur) + (set-specifier top-toolbar-height height cur) + (set-specifier bottom-toolbar-height height cur) + (set-specifier right-toolbar-width width cur) + (set-specifier left-toolbar-width width cur) + (if (eq bar 'default-toolbar) + (progn + (remove-specifier default-toolbar-visible-p cur) + (remove-specifier top-toolbar cur) + (remove-specifier top-toolbar-visible-p cur) + (remove-specifier bottom-toolbar cur) + (remove-specifier bottom-toolbar-visible-p cur) + (remove-specifier right-toolbar cur) + (remove-specifier right-toolbar-visible-p cur) + (remove-specifier left-toolbar cur) + (remove-specifier left-toolbar-visible-p cur)) + (set-specifier (symbol-value (intern (format "%s-visible-p" bar))) + t cur) + (setq bars (delq bar (list 'default-toolbar + 'bottom-toolbar 'top-toolbar + 'right-toolbar 'left-toolbar))) + (while bars + (set-specifier (symbol-value (intern (format "%s-visible-p" + (pop bars)))) + nil cur)))) + (let ((cur (current-buffer))) + (set-specifier default-toolbar-visible-p nil cur) + (set-specifier top-toolbar-visible-p nil cur) + (set-specifier bottom-toolbar-visible-p nil cur) + (set-specifier right-toolbar-visible-p nil cur) + (set-specifier left-toolbar-visible-p nil cur))))) (defun message-xmas-exchange-point-and-mark () "Exchange point and mark, but allow for XEmacs' optional argument." diff --git a/lisp/messcompat.el b/lisp/messcompat.el index bc8be17..f7b06f6 100644 --- a/lisp/messcompat.el +++ b/lisp/messcompat.el @@ -1,7 +1,7 @@ ;;; messcompat.el --- making message mode compatible with mail mode -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail, news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/mm-bodies.el b/lisp/mm-bodies.el index 9847da9..01a7576 100644 --- a/lisp/mm-bodies.el +++ b/lisp/mm-bodies.el @@ -1,7 +1,7 @@ ;;; mm-bodies.el --- Functions for decoding MIME things -;; Copyright (C) 1998, 1999, 2000, 2001, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -93,7 +93,8 @@ If no encoding was done, nil is returned." (save-excursion (if charset (progn - (mm-encode-coding-region (point-min) (point-max) charset) + (mm-encode-coding-region (point-min) (point-max) + (mm-charset-to-coding-system charset)) charset) (goto-char (point-min)) (let ((charsets (mm-find-mime-charset-region (point-min) (point-max) @@ -224,8 +225,9 @@ If TYPE is `text/plain' CRLF->LF translation may occur." (message "Error while decoding: %s" error) nil)) (when (and + type (memq encoding '(base64 x-uuencode x-uue x-binhex x-yenc)) - (equal type "text/plain")) + (string-match "\\`text/" type)) (goto-char (point-min)) (while (search-forward "\r\n" nil t) (replace-match "\n" t t))))) @@ -245,8 +247,12 @@ decoding. If it is nil, default to `mail-parse-charset'." (save-excursion (when encoding (mm-decode-content-transfer-encoding encoding type)) - (when (featurep 'mule) ; Fixme: Wrong test for unibyte session. - (let ((coding-system (mm-charset-to-coding-system charset))) + (when (and (featurep 'mule) ;; Fixme: Wrong test for unibyte session. + (not (eq charset 'gnus-decoded))) + (let ((coding-system (mm-charset-to-coding-system + ;; Allow overwrite using + ;; `mm-charset-override-alist'. + charset nil t))) (if (and (not coding-system) (listp mail-parse-ignored-charsets) (memq 'gnus-unknown mail-parse-ignored-charsets)) @@ -258,8 +264,7 @@ decoding. If it is nil, default to `mail-parse-charset'." ;;in XEmacs (mm-multibyte-p) (or (not (eq coding-system 'ascii)) - (setq coding-system mail-parse-charset)) - (not (eq coding-system 'gnus-decoded))) + (setq coding-system mail-parse-charset))) (mm-decode-coding-region (point-min) (point-max) coding-system)) (setq buffer-file-coding-system @@ -278,7 +283,11 @@ decoding. If it is nil, default to `mail-parse-charset'." (setq charset mail-parse-charset)) (or (when (featurep 'mule) - (let ((coding-system (mm-charset-to-coding-system charset))) + (let ((coding-system (mm-charset-to-coding-system + charset + ;; Allow overwrite using + ;; `mm-charset-override-alist'. + nil t))) (if (and (not coding-system) (listp mail-parse-ignored-charsets) (memq 'gnus-unknown mail-parse-ignored-charsets)) diff --git a/lisp/mm-decode.el b/lisp/mm-decode.el index 767354e..99076cc 100644 --- a/lisp/mm-decode.el +++ b/lisp/mm-decode.el @@ -1,6 +1,7 @@ ;;; mm-decode.el --- Functions for decoding MIME things -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -34,8 +35,11 @@ (eval-and-compile (autoload 'mm-inline-partial "mm-partial") (autoload 'mm-inline-external-body "mm-extern") + (autoload 'mm-extern-cache-contents "mm-extern") (autoload 'mm-insert-inline "mm-view")) +(defvar gnus-current-window-configuration) + (add-hook 'gnus-exit-gnus-hook 'mm-destroy-postponed-undisplay-list) (defgroup mime-display () @@ -218,7 +222,12 @@ before the external MIME handler is invoked." ("text/richtext" mm-inline-text identity) ("text/x-patch" mm-display-patch-inline (lambda (handle) - (locate-library "diff-mode"))) + ;; If the diff-mode.el package is installed, the function is + ;; autoloaded. Checking (locate-library "diff-mode") would be trying + ;; to cater to broken installations. OTOH checking the function + ;; makes it possible to install another package which provides an + ;; alternative implementation of diff-mode. --Stef + (fboundp 'diff-mode))) ("application/emacs-lisp" mm-display-elisp-inline identity) ("application/x-emacs-lisp" mm-display-elisp-inline identity) ("text/dns" mm-display-dns-inline identity) @@ -271,11 +280,13 @@ before the external MIME handler is invoked." "application/x-emacs-lisp" "application/pgp-signature" "application/x-pkcs7-signature" "application/pkcs7-signature" "application/x-pkcs7-mime" - "application/pkcs7-mime") + "application/pkcs7-mime" + ;; Mutt still uses this even though it has already been withdrawn. + "application/pgp") "List of media types that are to be displayed inline. See also `mm-inline-media-tests', which says how to display a media type inline." - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-keep-viewer-alive-types @@ -284,19 +295,21 @@ type inline." "List of media types for which the external viewer will not be killed when selecting a different article." :version "22.1" - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-automatic-display - '("text/plain" "text/enriched" "text/richtext" "text/html" + '("text/plain" "text/enriched" "text/richtext" "text/html" "text/x-verbatim" "text/x-vcard" "image/.*" "message/delivery-status" "multipart/.*" "message/rfc822" "text/x-patch" "text/dns" "application/pgp-signature" "application/emacs-lisp" "application/x-emacs-lisp" "application/x-pkcs7-signature" "application/pkcs7-signature" "application/x-pkcs7-mime" - "application/pkcs7-mime") + "application/pkcs7-mime" + ;; Mutt still uses this even though it has already been withdrawn. + "application/pgp") "A list of MIME types to be displayed automatically." - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-attachment-override-types '("text/x-vcard" @@ -305,17 +318,17 @@ when selecting a different article." "application/pkcs7-signature" "application/x-pkcs7-signature") "Types to have \"attachment\" ignored if they can be displayed inline." - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-inline-override-types nil "Types to be treated as attachments even if they can be displayed inline." - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-automatic-external-display nil "List of MIME type regexps that will be displayed externally automatically." - :type '(repeat string) + :type '(repeat regexp) :group 'mime-display) (defcustom mm-discouraged-alternatives nil @@ -327,8 +340,13 @@ for instance, text/html parts are very unwanted, and text/richtext are somewhat unwanted, then the value of this variable should be set to: - (\"text/html\" \"text/richtext\")" - :type '(repeat string) + (\"text/html\" \"text/richtext\") + +Adding \"image/.*\" might also be useful. Spammers use it as the +prefered part of multipart/alternative messages. See also +`gnus-buttonized-mime-types', to which adding \"multipart/alternative\" +enables you to choose manually one of two types those mails include." + :type '(repeat regexp) ;; See `mm-preferred-alternative-precedence'. :group 'mime-display) (defcustom mm-tmp-directory @@ -448,21 +466,19 @@ If not set, `default-directory' will be used." (defvar mm-viewer-completion-map (let ((map (make-sparse-keymap 'mm-viewer-completion-map))) (set-keymap-parent map minibuffer-local-completion-map) + ;; Should we bind other key to minibuffer-complete-word? + (define-key map " " 'self-insert-command) map) "Keymap for input viewer with completion.") -;; Should we bind other key to minibuffer-complete-word? -(define-key mm-viewer-completion-map " " 'self-insert-command) - (defvar mm-viewer-completion-map (let ((map (make-sparse-keymap 'mm-viewer-completion-map))) (set-keymap-parent map minibuffer-local-completion-map) + ;; Should we bind other key to minibuffer-complete-word? + (define-key map " " 'self-insert-command) map) "Keymap for input viewer with completion.") -;; Should we bind other key to minibuffer-complete-word? -(define-key mm-viewer-completion-map " " 'self-insert-command) - ;;; The functions. (defun mm-alist-to-plist (alist) @@ -519,13 +535,13 @@ Postpone undisplaying of viewers for types in loose-mime (mail-fetch-field "mime-version")) (setq ct (mail-fetch-field "content-type") - ctl (ignore-errors (mail-header-parse-content-type ct)) + ctl (and ct (mail-header-parse-content-type ct)) cte (mail-fetch-field "content-transfer-encoding") cd (mail-fetch-field "content-disposition") description (mail-fetch-field "content-description") id (mail-fetch-field "content-id")) (unless from - (setq from (mail-fetch-field "from"))) + (setq from (mail-fetch-field "from"))) ;; FIXME: In some circumstances, this code is running within ;; an unibyte macro. mail-extract-address-components ;; creates unibyte buffers. This `if', though not a perfect @@ -538,7 +554,7 @@ Postpone undisplaying of viewers for types in (list mm-dissect-default-type) (and cte (intern (downcase (mail-header-strip cte)))) no-strict-mime - (and cd (ignore-errors (mail-header-parse-content-disposition cd))) + (and cd (mail-header-parse-content-disposition cd)) description) (setq type (split-string (car ctl) "/")) (setq subtype (cadr type) @@ -557,7 +573,7 @@ Postpone undisplaying of viewers for types in ;; what really needs to be done here is a way to link a ;; MIME handle back to it's parent MIME handle (in a multilevel ;; MIME article). That would probably require changing - ;; the mm-handle API so we simply store the multipart buffert + ;; the mm-handle API so we simply store the multipart buffer ;; name as a text property of the "multipart/whatever" string. (add-text-properties 0 (length (car ctl)) (list 'buffer (mm-copy-to-buffer) @@ -571,8 +587,7 @@ Postpone undisplaying of viewers for types in ctl (and cte (intern (downcase (mail-header-strip cte)))) no-strict-mime - (and cd (ignore-errors - (mail-header-parse-content-disposition cd))) + (and cd (mail-header-parse-content-disposition cd)) description id) ctl)))) (when id @@ -749,7 +764,18 @@ external if displayed external." (gnus-map-function mm-file-name-rewrite-functions (file-name-nondirectory filename)) dir)) - (setq file (mm-make-temp-file (expand-file-name "mm." dir)))) + ;; Use nametemplate (defined in RFC1524) if it is specified + ;; in mailcap. + (let ((suffix (cdr (assoc "nametemplate" mime-info)))) + (if (and suffix + (string-match "\\`%s\\(\\..+\\)\\'" suffix)) + (setq suffix (match-string 1 suffix)) + ;; Otherwise, use a suffix according to + ;; `mailcap-mime-extensions'. + (setq suffix (car (rassoc (mm-handle-media-type handle) + mailcap-mime-extensions)))) + (setq file (mm-make-temp-file (expand-file-name "mm." dir) + nil suffix)))) (let ((coding-system-for-write mm-binary-coding-system)) (write-region (point-min) (point-max) file nil 'nomesg)) (message "Viewing with %s" method) @@ -798,8 +824,7 @@ external if displayed external." (mm-mailcap-command method file (mm-handle-type handle))) (if (buffer-live-p buffer) - (save-excursion - (set-buffer buffer) + (with-current-buffer buffer (buffer-string)))) (progn (ignore-errors (delete-file file)) @@ -808,14 +833,52 @@ external if displayed external." (ignore-errors (kill-buffer buffer)))))) 'inline) (t + ;; Deleting the temp file should be postponed for some wrappers, + ;; shell scripts, and so on, which might exit right after having + ;; started a viewer command as a background job. (let ((command (mm-mailcap-command method file (mm-handle-type handle)))) (unwind-protect - (start-process "*display*" - (setq buffer - (generate-new-buffer " *mm*")) - shell-file-name - shell-command-switch command) + (progn + (start-process "*display*" + (setq buffer + (generate-new-buffer " *mm*")) + shell-file-name + shell-command-switch command) + (set-process-sentinel + (get-buffer-process buffer) + (lexical-let ;; Don't use `let'. + ;; Function used to remove temp file and directory. + ((fn `(lambda nil + ;; Don't use `ignore-errors'. + (condition-case nil + (delete-file ,file) + (error)) + (condition-case nil + (delete-directory + ,(file-name-directory file)) + (error)))) + ;; Form uses to kill the process buffer and + ;; remove the undisplayer. + (fm `(progn + (kill-buffer ,buffer) + ,(macroexpand + (list 'mm-handle-set-undisplayer + (list 'quote handle) + nil)))) + ;; Message to be issued when the process exits. + (done (format "Displaying %s...done" command)) + ;; In particular, the timer object (which is + ;; a vector in Emacs but is a list in XEmacs) + ;; requires that it is lexically scoped. + (timer (run-at-time 2.0 nil 'ignore))) + (lambda (process state) + (when (eq 'exit (process-status process)) + (if (memq timer timer-list) + (timer-set-function timer fn) + (funcall fn)) + (ignore-errors (eval fm)) + (message "%s" done)))))) (mm-handle-set-external-undisplayer handle (cons file buffer))) (message "Displaying %s..." command)) @@ -1014,23 +1077,54 @@ external if displayed external." ;;; Functions for outputting parts ;;; -(defun mm-get-part (handle) - "Return the contents of HANDLE as a string." - (mm-with-unibyte-buffer - (insert (with-current-buffer (mm-handle-buffer handle) - (mm-with-unibyte-current-buffer - (buffer-string)))) - (mm-decode-content-transfer-encoding - (mm-handle-encoding handle) - (mm-handle-media-type handle)) - (buffer-string))) - -(defun mm-insert-part (handle) - "Insert the contents of HANDLE in the current buffer." +(defmacro mm-with-part (handle &rest forms) + "Run FORMS in the temp buffer containing the contents of HANDLE." + `(let* ((handle ,handle) + ;; The multibyteness of the temp buffer should be turned on + ;; if inserting a multibyte string. Contrarily, the buffer's + ;; multibyteness should be off if inserting a unibyte string, + ;; especially if a string contains 8bit data. + (default-enable-multibyte-characters + (with-current-buffer (mm-handle-buffer handle) + (mm-multibyte-p)))) + (with-temp-buffer + (insert-buffer-substring (mm-handle-buffer handle)) + (mm-disable-multibyte) + (mm-decode-content-transfer-encoding + (mm-handle-encoding handle) + (mm-handle-media-type handle)) + ,@forms))) +(put 'mm-with-part 'lisp-indent-function 1) +(put 'mm-with-part 'edebug-form-spec '(body)) + +(defun mm-get-part (handle &optional no-cache) + "Return the contents of HANDLE as a string. +If NO-CACHE is non-nil, cached contents of a message/external-body part +are ignored." + (if (and (not no-cache) + (equal (mm-handle-media-type handle) "message/external-body")) + (progn + (unless (mm-handle-cache handle) + (mm-extern-cache-contents handle)) + (with-current-buffer (mm-handle-buffer (mm-handle-cache handle)) + (buffer-string))) + (mm-with-part handle + (buffer-string)))) + +(defun mm-insert-part (handle &optional no-cache) + "Insert the contents of HANDLE in the current buffer. +If NO-CACHE is non-nil, cached contents of a message/external-body part +are ignored." (save-excursion - (insert (if (mm-multibyte-p) - (mm-string-as-multibyte (mm-get-part handle)) - (mm-get-part handle))))) + (insert + (cond ((eq (mail-content-type-get (mm-handle-type handle) 'charset) + 'gnus-decoded) + (with-current-buffer (mm-handle-buffer handle) + (buffer-string))) + ((mm-multibyte-p) + (mm-string-as-multibyte (mm-get-part handle no-cache))) + (t + (mm-get-part handle no-cache)))))) (defun mm-file-name-delete-whitespace (file-name) "Remove all whitespace characters from FILE-NAME." @@ -1070,20 +1164,22 @@ string if you do not like underscores." (setq filename (gnus-replace-in-string filename "[<>|]" "")) (gnus-replace-in-string filename "^[.-]+" "")) -(defun mm-save-part (handle) - "Write HANDLE to a file." - (let* ((name (mail-content-type-get (mm-handle-type handle) 'name)) - (filename (mail-content-type-get - (mm-handle-disposition handle) 'filename)) - file) +(defun mm-save-part (handle &optional prompt) + "Write HANDLE to a file. +PROMPT overrides the default one used to ask user for a file name." + (let ((filename (or (mail-content-type-get + (mm-handle-disposition handle) 'filename) + (mail-content-type-get + (mm-handle-type handle) 'name))) + file) (when filename (setq filename (gnus-map-function mm-file-name-rewrite-functions (file-name-nondirectory filename)))) (setq file (mm-with-multibyte - (read-file-name "Save MIME part to: " - (or mm-default-directory default-directory) - nil nil (or filename name "")))) + (read-file-name (or prompt "Save MIME part to: ") + (or mm-default-directory default-directory) + nil nil (or filename "")))) (setq mm-default-directory (file-name-directory file)) (and (or (not (file-exists-p file)) (yes-or-no-p (format "File %s already exists; overwrite? " @@ -1237,8 +1333,8 @@ be determined." ;; out to a file, and then create a file ;; specifier. (let ((file (mm-make-temp-file - (expand-file-name "emm.xbm" - mm-tmp-directory)))) + (expand-file-name "emm" mm-tmp-directory) + nil ".xbm"))) (unwind-protect (progn (write-region (point-min) (point-max) file) @@ -1325,9 +1421,8 @@ If RECURSIVE, search recursively." (save-excursion (save-restriction (narrow-to-region start (1- (point))) - (when (let ((ctl (ignore-errors - (mail-header-parse-content-type - (mail-fetch-field "content-type"))))) + (when (let* ((ct (mail-fetch-field "content-type")) + (ctl (and ct (mail-header-parse-content-type ct)))) (if notp (not (equal (car ctl) type)) (equal (car ctl) type))) @@ -1338,9 +1433,8 @@ If RECURSIVE, search recursively." (save-excursion (save-restriction (narrow-to-region start end) - (when (let ((ctl (ignore-errors - (mail-header-parse-content-type - (mail-fetch-field "content-type"))))) + (when (let* ((ct (mail-fetch-field "content-type")) + (ctl (and ct (mail-header-parse-content-type ct)))) (if notp (not (equal (car ctl) type)) (equal (car ctl) type))) diff --git a/lisp/mm-encode.el b/lisp/mm-encode.el index 63c963b..5ea2d7d 100644 --- a/lisp/mm-encode.el +++ b/lisp/mm-encode.el @@ -1,6 +1,7 @@ ;;; mm-encode.el --- Functions for encoding MIME things -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -117,7 +118,7 @@ ENCODING can be: nil (do nothing); one of `quoted-printable', `base64'; ;; Likewise base64 below. (quoted-printable-encode-region (point-min) (point-max) t)) ((eq encoding 'base64) - (when (equal type "text/plain") + (when (string-match "\\`text/" type) (goto-char (point-min)) (while (search-forward "\n" nil t) (replace-match "\r\n" t t))) diff --git a/lisp/mm-extern.el b/lisp/mm-extern.el index 994dd1d..b736374 100644 --- a/lisp/mm-extern.el +++ b/lisp/mm-extern.el @@ -1,5 +1,7 @@ ;;; mm-extern.el --- showing message/external-body -;; Copyright (C) 2000, 2001, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: message external-body @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,6 +33,8 @@ (require 'mm-decode) (require 'mm-url) +(defvar gnus-article-mime-handles) + (defvar mm-extern-function-alist '((local-file . mm-extern-local-file) (url . mm-extern-url) @@ -52,7 +56,7 @@ (mm-disable-multibyte) (if (file-exists-p name) (mm-insert-file-contents name nil nil nil nil t) - (error (format "File %s is gone" name))))) + (error "File %s is gone" name)))) (defun mm-extern-url (handle) (erase-buffer) @@ -108,11 +112,8 @@ (insert "[" info "]\n\n"))) ;;;###autoload -(defun mm-inline-external-body (handle &optional no-display) - "Show the external-body part of HANDLE. -This function replaces the buffer of HANDLE with a buffer contains -the entire message. -If NO-DISPLAY is nil, display it. Otherwise, do nothing after replacing." +(defun mm-extern-cache-contents (handle) + "Put the external-body part of HANDLE into its cache." (let* ((access-type (cdr (assq 'access-type (cdr (mm-handle-type handle))))) (func (cdr (assq (intern @@ -120,48 +121,61 @@ If NO-DISPLAY is nil, display it. Otherwise, do nothing after replacing." (or access-type (error "Couldn't find access type")))) mm-extern-function-alist))) - gnus-displaying-mime buf - handles) - (unless (mm-handle-cache handle) - (unless func - (error (format "Access type (%s) is not supported" access-type))) - (with-temp-buffer - (mm-insert-part handle) - (goto-char (point-max)) - (insert "\n\n") - (setq handles (mm-dissect-buffer t))) - (unless (bufferp (car handles)) - (mm-destroy-parts handles) - (error "Multipart external body is not supported")) - (save-excursion ;; single part - (set-buffer (setq buf (mm-handle-buffer handles))) - (let (good) - (unwind-protect - (progn - (funcall func handle) - (setq good t)) - (unless good - (mm-destroy-parts handles)))) - (mm-handle-set-cache handle handles)) - (setq gnus-article-mime-handles - (mm-merge-handles gnus-article-mime-handles handles))) - (unless no-display - (save-excursion - (save-restriction - (narrow-to-region (point) (point)) - (gnus-display-mime (mm-handle-cache handle)) - (mm-handle-set-undisplayer - handle - `(lambda () - (let (buffer-read-only) - (condition-case nil - ;; This is only valid on XEmacs. - (mapcar (lambda (prop) - (remove-specifier - (face-property 'default prop) (current-buffer))) - '(background background-pixmap foreground)) - (error nil)) - (delete-region ,(point-min-marker) ,(point-max-marker)))))))))) + buf handles) + (unless func + (error "Access type (%s) is not supported" access-type)) + (mm-with-part handle + (goto-char (point-max)) + (insert "\n\n") + ;; It should be just a single MIME handle. + (setq handles (mm-dissect-buffer t))) + (unless (bufferp (car handles)) + (mm-destroy-parts handles) + (error "Multipart external body is not supported")) + (save-excursion + (set-buffer (setq buf (mm-handle-buffer handles))) + (let (good) + (unwind-protect + (progn + (funcall func handle) + (setq good t)) + (unless good + (mm-destroy-parts handles)))) + (mm-handle-set-cache handle handles)) + (setq gnus-article-mime-handles + (mm-merge-handles gnus-article-mime-handles handles)))) + +;;;###autoload +(defun mm-inline-external-body (handle &optional no-display) + "Show the external-body part of HANDLE. +This function replaces the buffer of HANDLE with a buffer contains +the entire message. +If NO-DISPLAY is nil, display it. Otherwise, do nothing after replacing." + (unless (mm-handle-cache handle) + (mm-extern-cache-contents handle)) + (unless no-display + (save-excursion + (save-restriction + (narrow-to-region (point) (point)) + (let* ((type (regexp-quote + (mm-handle-media-type (mm-handle-cache handle)))) + ;; Force the part to be displayed (but if there is no + ;; method to display, a user will be prompted to save). + ;; See `gnus-mime-display-single'. + (mm-inline-override-types nil) + (mm-attachment-override-types + (cons type mm-attachment-override-types)) + (mm-automatic-display (cons type mm-automatic-display)) + (mm-automatic-external-display + (cons type mm-automatic-external-display)) + ;; Suppress adding of button to the cached part. + (gnus-inhibit-mime-unbuttonizing nil)) + (gnus-display-mime (mm-handle-cache handle))) + ;; Move undisplayer added to the cached handle to the parent. + (mm-handle-set-undisplayer + handle + (mm-handle-undisplayer (mm-handle-cache handle))) + (mm-handle-set-undisplayer (mm-handle-cache handle) nil))))) (provide 'mm-extern) diff --git a/lisp/mm-partial.el b/lisp/mm-partial.el index de003bb..93ba296 100644 --- a/lisp/mm-partial.el +++ b/lisp/mm-partial.el @@ -1,5 +1,7 @@ ;;; mm-partial.el --- showing message/partial -;; Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: message partial @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/mm-url.el b/lisp/mm-url.el index 6dd921a..0b769a6 100644 --- a/lisp/mm-url.el +++ b/lisp/mm-url.el @@ -1,5 +1,7 @@ ;;; mm-url.el --- a wrapper of url functions/commands for Gnus -;; Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu @@ -17,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -39,6 +41,10 @@ (require 'timer-funcs) (require 'timer))) +(defvar url-current-object) +(defvar url-package-name) +(defvar url-package-version) + (defgroup mm-url nil "A wrapper of url package and external url command for Gnus." :group 'gnus) @@ -56,7 +62,7 @@ '((wget "wget" "--user-agent=mm-url" "-q" "-O" "-") (w3m "w3m" "-dump_source") (lynx "lynx" "-source") - (curl "curl" "--silent"))) + (curl "curl" "--silent" "--user-agent mm-url" "--location"))) (defcustom mm-url-program (cond @@ -268,7 +274,10 @@ This is taken from RFC 2396.") (defun mm-url-load-url () "Load `url-insert-file-contents'." (unless (condition-case () - (require 'url-handlers) + (progn + (require 'url-handlers) + (require 'url-parse) + (require 'url-vars)) (error nil)) ;; w3-4.0pre0.46 or earlier version. (require 'w3-vars) @@ -357,7 +366,7 @@ If FOLLOW-REFRESH is non-nil, redirect refresh url in META." (defun mm-url-decode-entities () "Decode all HTML entities." (goto-char (point-min)) - (while (re-search-forward "&\\(#[0-9]+\\|[a-z]+\\);" nil t) + (while (re-search-forward "&\\(#[0-9]+\\|[a-z]+[0-9]*\\);" nil t) (let ((elem (if (eq (aref (match-string 1) 0) ?\#) (let ((c (string-to-number (substring diff --git a/lisp/mm-util.el b/lisp/mm-util.el index 3d7bc25..802ad86 100644 --- a/lisp/mm-util.el +++ b/lisp/mm-util.el @@ -1,6 +1,7 @@ ;;; mm-util.el --- Utility functions for Mule and low level things -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -99,18 +100,23 @@ (lambda (ch) (mm-string-as-multibyte (char-to-string ch))) string ""))) (multibyte-string-p . ignore) - ;; It is not a MIME function, but some MIME functions use it. - (make-temp-file . (lambda (prefix &optional dir-flag) - (let ((file (expand-file-name - (make-temp-name prefix) - (if (fboundp 'temp-directory) - (temp-directory) - temporary-file-directory)))) - (if dir-flag - (make-directory file)) - file))) (insert-byte . insert-char) - (multibyte-char-to-unibyte . identity)))) + (multibyte-char-to-unibyte . identity) + (special-display-p + . (lambda (buffer-name) + "Returns non-nil if a buffer named BUFFER-NAME gets a special frame." + (and special-display-function + (or (and (member buffer-name special-display-buffer-names) t) + (cdr (assoc buffer-name special-display-buffer-names)) + (catch 'return + (dolist (elem special-display-regexps) + (and (stringp elem) + (string-match elem buffer-name) + (throw 'return t)) + (and (consp elem) + (stringp (car elem)) + (string-match (car elem) buffer-name) + (throw 'return (cdr elem)))))))))))) (eval-and-compile (defalias 'mm-char-or-char-int-p @@ -158,9 +164,32 @@ system object in XEmacs." (if (fboundp 'coding-system-p) (when (coding-system-p cs) cs) - ;; Is this branch ever actually useful? + ;; no-MULE XEmacs: (car (memq cs (mm-get-coding-system-list)))))) +(defun mm-codepage-setup (number &optional alias) + "Create a coding system cpNUMBER. +The coding system is created using `codepage-setup'. If ALIAS is +non-nil, an alias is created and added to +`mm-charset-synonym-alist'. If ALIAS is a string, it's used as +the alias. Else windows-NUMBER is used." + (interactive + (let ((completion-ignore-case t) + (candidates (cp-supported-codepages))) + (list (completing-read "Setup DOS Codepage: (default 437) " candidates + nil t nil nil "437")))) + (when alias + (setq alias (if (stringp alias) + (intern alias) + (intern (format "windows-%s" number))))) + (let* ((cp (intern (format "cp%s" number)))) + (unless (mm-coding-system-p cp) + (codepage-setup number)) + (when (and alias + ;; Don't add alias if setup of cp failed. + (mm-coding-system-p cp)) + (add-to-list 'mm-charset-synonym-alist (cons alias cp))))) + (defvar mm-charset-synonym-alist `( ;; Not in XEmacs, but it's not a proper MIME charset anyhow. @@ -194,7 +223,51 @@ system object in XEmacs." '((ks_c_5601-1987 . cp949)) '((ks_c_5601-1987 . euc-kr)))) ) - "A mapping from invalid charset names to the real charset names.") + "A mapping from unknown or invalid charset names to the real charset names.") + +(defcustom mm-charset-override-alist + `((iso-8859-1 . windows-1252)) + "A mapping from undesired charset names to their replacement. + +You may add pairs like (iso-8859-1 . windows-1252) here, +i.e. treat iso-8859-1 as windows-1252. windows-1252 is a +superset of iso-8859-1." + :type '(list (set :inline t + (const (iso-8859-1 . windows-1252)) + (const (undecided . windows-1252))) + (repeat :inline t + :tag "Other options" + (cons (symbol :tag "From charset") + (symbol :tag "To charset")))) + :version "23.0" ;; No Gnus + :group 'mime) + +(defcustom mm-charset-eval-alist + (if (featurep 'xemacs) + nil ;; I don't know what would be useful for XEmacs. + '(;; Emacs 21 offers 1250 1251 1253 1257. Emacs 22 provides autoloads for + ;; 1250-1258 (i.e. `mm-codepage-setup' does nothing). + (windows-1250 . (mm-codepage-setup 1250 t)) + (windows-1251 . (mm-codepage-setup 1251 t)) + (windows-1253 . (mm-codepage-setup 1253 t)) + (windows-1257 . (mm-codepage-setup 1257 t)))) + "An alist of (CHARSET . FORM) pairs. +If an article is encoded in an unknown CHARSET, FORM is +evaluated. This allows to load additional libraries providing +charsets on demand. If supported by your Emacs version, you +could use `autoload-coding-system' here." + :version "23.0" ;; No Gnus + :type '(list (set :inline t + (const (windows-1250 . (mm-codepage-setup 1250 t))) + (const (windows-1251 . (mm-codepage-setup 1251 t))) + (const (windows-1253 . (mm-codepage-setup 1253 t))) + (const (windows-1257 . (mm-codepage-setup 1257 t))) + (const (cp850 . (mm-codepage-setup 850 nil)))) + (repeat :inline t + :tag "Other options" + (cons (symbol :tag "charset") + (symbol :tag "form")))) + :group 'mime) (defvar mm-binary-coding-system (cond @@ -324,7 +397,7 @@ with Mule charsets. It is completely useless for Emacs." cs mime mule alist) (while css (setq cs (pop css) - mime (or (coding-system-get cs :mime-charset) ; Emacs 22 + mime (or (coding-system-get cs :mime-charset) ; Emacs 23 (unicode) (coding-system-get cs 'mime-charset))) (when (and mime (not (eq t (setq mule @@ -419,11 +492,17 @@ mail with multiple parts is preferred to sending a Unicode one.") (pop alist)) out))) -(defun mm-charset-to-coding-system (charset &optional lbt) +(defun mm-charset-to-coding-system (charset &optional lbt + allow-override) "Return coding-system corresponding to CHARSET. CHARSET is a symbol naming a MIME charset. If optional argument LBT (`unix', `dos' or `mac') is specified, it is -used as the line break code type of the coding system." +used as the line break code type of the coding system. + +If ALLOW-OVERRIDE is given, use `mm-charset-override-alist' to +map undesired charset names to their replacement. This should +only be used for decoding, not for encoding." + ;; OVERRIDE is used (only) in `mm-decode-body'. (when (stringp charset) (setq charset (intern (downcase charset)))) (when lbt @@ -435,6 +514,11 @@ used as the line break code type of the coding system." ((or (null (mm-get-coding-system-list)) (not (fboundp 'coding-system-get))) charset) + ;; Check override list quite early. Should only used for decoding, not for + ;; encoding! + ((and allow-override + (let ((cs (cdr (assq charset mm-charset-override-alist)))) + (and cs (mm-coding-system-p cs) cs)))) ;; ascii ((eq charset 'us-ascii) 'ascii) @@ -447,9 +531,27 @@ used as the line break code type of the coding system." ;;; (eq charset (coding-system-get charset 'mime-charset)) ) charset) + ;; Eval expressions from `mm-charset-eval-alist' + ((let* ((el (assq charset mm-charset-eval-alist)) + (cs (car el)) + (form (cdr el))) + (and cs + form + (prog2 + ;; Avoid errors... + (condition-case nil (eval form) (error nil)) + ;; (message "Failed to eval `%s'" form)) + (mm-coding-system-p cs) + (message "Added charset `%s' via `mm-charset-eval-alist'" cs)) + cs))) ;; Translate invalid charsets. ((let ((cs (cdr (assq charset mm-charset-synonym-alist)))) - (and cs (mm-coding-system-p cs) cs))) + (and cs + (mm-coding-system-p cs) + ;; (message + ;; "Using synonym `%s' from `mm-charset-synonym-alist' for `%s'" + ;; cs 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). @@ -461,6 +563,11 @@ used as the line break code type of the coding system." (eq charset (or (coding-system-get c :mime-charset) (coding-system-get c 'mime-charset)))) (setq cs c))) + (unless cs + ;; Warn the user about unknown charset: + (if (fboundp 'gnus-message) + (gnus-message 7 "Unknown charset: %s" charset) + (message "Unknown charset: %s" charset))) cs)))) (eval-and-compile @@ -548,14 +655,21 @@ If the charset is `composition', return the actual one." ;; This is for XEmacs. (mm-mule-charset-to-mime-charset charset))) -(defun mm-delete-duplicates (list) - "Simple substitute for CL `delete-duplicates', testing with `equal'." - (let (result head) - (while list - (setq head (car list)) - (setq list (delete head list)) - (setq result (cons head result))) - (nreverse result))) +(if (fboundp 'delete-dups) + (defalias 'mm-delete-duplicates 'delete-dups) + (defun mm-delete-duplicates (list) + "Destructively remove `equal' duplicates from LIST. +Store the result in LIST and return it. LIST must be a proper list. +Of several `equal' occurrences of an element in LIST, the first +one is kept. + +This is a compatibility function for Emacsen without `delete-dups'." + ;; Code from `subr.el' in Emacs 22: + (let ((tail list)) + (while tail + (setcdr tail (delete (car tail) (cdr tail))) + (setq tail (cdr tail)))) + list)) ;; Fixme: This is used in places when it should be testing the ;; default multibyteness. See mm-default-multibyte-p. @@ -747,6 +861,17 @@ charset, and a longer list means no appropriate charset." (if (and (memq 'iso-2022-jp-2 charsets) (memq 'iso-2022-jp-2 hack-charsets)) (setq charsets (delq 'iso-2022-jp charsets))) + ;; Attempt to reduce the number of charsets if utf-8 is available. + (if (and (featurep 'xemacs) + (> (length charsets) 1) + (mm-coding-system-p 'utf-8)) + (let ((mm-coding-system-priorities + (cons 'utf-8 mm-coding-system-priorities))) + (setq charsets + (mm-delete-duplicates + (mapcar 'mm-mime-charset + (delq 'ascii + (mm-find-charset-region b e))))))) charsets)) (defmacro mm-with-unibyte-buffer (&rest forms) @@ -768,11 +893,18 @@ Use multibyte mode for this." (defmacro mm-with-unibyte-current-buffer (&rest forms) "Evaluate FORMS with current buffer temporarily made unibyte. Also bind `default-enable-multibyte-characters' to nil. -Equivalent to `progn' in XEmacs" +Equivalent to `progn' in XEmacs + +NOTE: Use this macro with caution in multibyte buffers (it is not +worth using this macro in unibyte buffers of course). Use of +`(set-buffer-multibyte t)', which is run finally, is generally +harmful since it is likely to modify existing data in the buffer. +For instance, it converts \"\\300\\255\" into \"\\255\" in +Emacs 23 (unicode)." (let ((multibyte (make-symbol "multibyte")) (buffer (make-symbol "buffer"))) `(if mm-emacs-mule - (let ((,multibyte enable-multibyte-characters) + (let ((,multibyte enable-multibyte-characters) (,buffer (current-buffer))) (unwind-protect (let (default-enable-multibyte-characters) @@ -855,22 +987,28 @@ to advanced Emacs features, such as file-name-handlers, format decoding, `find-file-hooks', etc. If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'. This function ensures that none of these modifications will take place." - (let ((format-alist nil) - (auto-mode-alist (if inhibit nil (mm-auto-mode-alist))) - (default-major-mode 'fundamental-mode) - (enable-local-variables nil) - (after-insert-file-functions nil) - (enable-local-eval nil) - (find-file-hooks nil) - (inhibit-file-name-operation (if inhibit - 'insert-file-contents - inhibit-file-name-operation)) - (inhibit-file-name-handlers - (if inhibit - (append mm-inhibit-file-name-handlers - inhibit-file-name-handlers) - inhibit-file-name-handlers))) - (insert-file-contents filename visit beg end replace))) + (let* ((format-alist nil) + (auto-mode-alist (if inhibit nil (mm-auto-mode-alist))) + (default-major-mode 'fundamental-mode) + (enable-local-variables nil) + (after-insert-file-functions nil) + (enable-local-eval nil) + (inhibit-file-name-operation (if inhibit + 'insert-file-contents + inhibit-file-name-operation)) + (inhibit-file-name-handlers + (if inhibit + (append mm-inhibit-file-name-handlers + inhibit-file-name-handlers) + inhibit-file-name-handlers)) + (ffh (if (boundp 'find-file-hook) + 'find-file-hook + 'find-file-hooks)) + (val (symbol-value ffh))) + (set ffh nil) + (unwind-protect + (insert-file-contents filename visit beg end replace) + (set ffh val)))) (defun mm-append-to-file (start end filename &optional codesys inhibit) "Append the contents of the region to the end of file FILENAME. @@ -912,6 +1050,74 @@ If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'." inhibit-file-name-handlers))) (write-region start end filename append visit lockname))) +;; It is not a MIME function, but some MIME functions use it. +(if (and (fboundp 'make-temp-file) + (ignore-errors + (let ((def (symbol-function 'make-temp-file))) + (and (byte-code-function-p def) + (setq def (if (fboundp 'compiled-function-arglist) + ;; XEmacs + (eval (list 'compiled-function-arglist def)) + (aref def 0))) + (>= (length def) 4) + (eq (nth 3 def) 'suffix))))) + (defalias 'mm-make-temp-file 'make-temp-file) + ;; Stolen (and modified for XEmacs) from Emacs 22. + (defun mm-make-temp-file (prefix &optional dir-flag suffix) + "Create a temporary file. +The returned file name (created by appending some random characters at the end +of PREFIX, and expanding against `temporary-file-directory' if necessary), +is guaranteed to point to a newly created empty file. +You can then use `write-region' to write new data into the file. + +If DIR-FLAG is non-nil, create a new empty directory instead of a file. + +If SUFFIX is non-nil, add that at the end of the file name." + (let ((umask (default-file-modes)) + file) + (unwind-protect + (progn + ;; Create temp files with strict access rights. It's easy to + ;; loosen them later, whereas it's impossible to close the + ;; time-window of loose permissions otherwise. + (set-default-file-modes 448) + (while (condition-case err + (progn + (setq file + (make-temp-name + (expand-file-name + prefix + (if (fboundp 'temp-directory) + ;; XEmacs + (temp-directory) + temporary-file-directory)))) + (if suffix + (setq file (concat file suffix))) + (if dir-flag + (make-directory file) + (if (featurep 'xemacs) + ;; NOTE: This is unsafe if XEmacs users + ;; don't use a secure temp directory. + (if (file-exists-p file) + (signal 'file-already-exists + (list "File exists" file)) + (write-region "" nil file nil 'silent)) + (write-region "" nil file nil 'silent + nil 'excl))) + nil) + (file-already-exists t) + ;; The XEmacs version of `make-directory' issues + ;; `file-error'. + (file-error (or (and (featurep 'xemacs) + (file-exists-p file)) + (signal (car err) (cdr err))))) + ;; the file was somehow created by someone else between + ;; `make-temp-name' and `write-region', let's try again. + nil) + file) + ;; Reset the umask. + (set-default-file-modes umask))))) + (defun mm-image-load-path (&optional package) (let (dir result) (dolist (path load-path (nreverse result)) @@ -1056,7 +1262,12 @@ gzip, bzip2, etc. are allowed." (unless filename (setq filename buffer-file-name)) (save-excursion - (let ((decomp (mm-decompress-buffer filename nil t))) + (let ((decomp (unless ;; No worth to examine charset of tar files. + (and filename + (string-match + "\\.\\(?:tar\\.[^.]+\\|tbz\\|tgz\\)\\'" + filename)) + (mm-decompress-buffer filename nil t)))) (when decomp (set-buffer (let (default-enable-multibyte-characters) (generate-new-buffer " *temp*"))) diff --git a/lisp/mm-uu.el b/lisp/mm-uu.el index 6ad7aba..85df48b 100644 --- a/lisp/mm-uu.el +++ b/lisp/mm-uu.el @@ -1,6 +1,7 @@ ;;; mm-uu.el --- Return uu stuff as mm handles -;; Copyright (c) 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: postscript uudecode binhex shar forward gnatsweb pgp @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -76,28 +77,38 @@ decoder, such as hexbin." "The default disposition of uu parts. This can be either \"inline\" or \"attachment\".") -(defvar mm-uu-emacs-sources-regexp "gnu\\.emacs\\.sources" - "The regexp of Emacs sources groups.") +(defcustom mm-uu-emacs-sources-regexp "\\.emacs\\.sources" + "The regexp of Emacs sources groups." + :version "22.1" + :type 'regexp + :group 'gnus-article-mime) -(defcustom mm-uu-diff-groups-regexp "gnus\\.commits" - "*Regexp matching diff groups." +(defcustom mm-uu-diff-groups-regexp + "\\(gmane\\|gnu\\)\\..*\\(diff\\|commit\\|cvs\\|bug\\|devel\\)" + "Regexp matching diff groups." :version "22.1" :type 'regexp :group 'gnus-article-mime) +(defcustom mm-uu-tex-groups-regexp "\\.tex\\>" + "*Regexp matching TeX groups." + :version "23.0" + :type 'regexp + :group 'gnus-article-mime) + (defvar mm-uu-type-alist '((postscript "^%!PS-" "^%%EOF$" mm-uu-postscript-extract nil) - (uu + (uu ;; Maybe we should have a more strict test here. "^begin[ \t]+0?[0-7][0-7][0-7][ \t]+" "^end[ \t]*$" mm-uu-uu-extract mm-uu-uu-filename) (binhex - "^:...............................................................$" + "^:.\\{63,63\\}$" ":$" mm-uu-binhex-extract nil @@ -112,8 +123,8 @@ This can be either \"inline\" or \"attachment\".") "^exit 0$" mm-uu-shar-extract) (forward -;;; Thanks to Edward J. Sabol and -;;; Peter von der Ah\'e + ;; Thanks to Edward J. Sabol and + ;; Peter von der Ah\'e "^-+ \\(Start of \\)?Forwarded message" "^-+ End \\(of \\)?forwarded message" mm-uu-forward-extract @@ -152,7 +163,40 @@ This can be either \"inline\" or \"attachment\".") nil mm-uu-diff-extract nil - mm-uu-diff-test))) + mm-uu-diff-test) + (message-marks + ;; Text enclosed with tags similar to `message-mark-insert-begin' and + ;; `message-mark-insert-end'. Don't use those variables to avoid + ;; dependency on `message.el'. + "^-+[8<>]*-\\{9,\\}[a-z ]+-\\{9,\\}[a-z ]+-\\{9,\\}[8<>]*-+$" + "^-+[8<>]*-\\{9,\\}[a-z ]+-\\{9,\\}[a-z ]+-\\{9,\\}[8<>]*-+$" + (lambda () (mm-uu-verbatim-marks-extract 0 -1 1 -1)) + nil) + ;; Omitting [a-z8<] leads to false positives (bogus signature separators + ;; and mailing list banners). + (insert-marks + "^ *\\(-\\|_\\)\\{30,\\}.*[a-z8<].*\\(-\\|_\\)\\{30,\\} *$" + "^ *\\(-\\|_\\)\\{30,\\}.*[a-z8<].*\\(-\\|_\\)\\{30,\\} *$" + (lambda () (mm-uu-verbatim-marks-extract 0 0 1 -1)) + nil) + (verbatim-marks + ;; slrn-style verbatim marks, see + ;; http://www.slrn.org/manual/slrn-manual-6.html#ss6.81 + "^#v\\+" + "^#v\\-$" + (lambda () (mm-uu-verbatim-marks-extract 0 0 1 -1)) + nil) + (LaTeX + "^\\([\\\\%][^\n]+\n\\)*\\\\documentclass.*[[{%]" + "^\\\\end{document}" + mm-uu-latex-extract + nil + mm-uu-latex-test)) + "A list of specifications for non-MIME attachments. +Each element consist of the following entries: label, +start-regexp, end-regexp, extract-function, test-function. + +After modifying this list you must run \\[mm-uu-configure].") (defcustom mm-uu-configure-list '((shar . disabled)) "A list of mm-uu configuration. @@ -188,24 +232,66 @@ To disable dissecting shar codes, for instance, add (defsubst mm-uu-function-2 (entry) (nth 5 entry)) -(defun mm-uu-copy-to-buffer (&optional from to) +;; In Emacs 22, we could use `min-colors' in the face definition. But Emacs +;; 21 and XEmacs don't support it. +(defcustom mm-uu-hide-markers + (< 16 (or (and (fboundp 'defined-colors) + (length (defined-colors))) + (and (fboundp 'device-color-cells) + (device-color-cells)) + 0)) + "If non-nil, hide verbatim markers. +The value should be nil on displays where the face +`mm-uu-extract' isn't distinguishable to the face `default'." + :type '(choice (const :tag "Hide" t) + (const :tag "Don't hide" nil)) + :version "23.0" ;; No Gnus + :group 'gnus-article-mime) + +(defface mm-uu-extract '(;; Colors from `gnus-cite-3' plus background: + (((class color) + (background dark)) + (:foreground "light yellow" + :background "dark green")) + (((class color) + (background light)) + (:foreground "dark green" + :background "light yellow")) + (t + ())) + "Face for extracted buffers." + ;; See `mm-uu-verbatim-marks-extract'. + :version "23.0" ;; No Gnus + :group 'gnus-article-mime) + +(defun mm-uu-copy-to-buffer (&optional from to properties) "Copy the contents of the current buffer to a fresh buffer. -Return that buffer." - (save-excursion - (let ((obuf (current-buffer)) - (coding-system - ;; Might not exist in non-MULE XEmacs - (when (boundp 'buffer-file-coding-system) - buffer-file-coding-system))) - (set-buffer (generate-new-buffer " *mm-uu*")) +Return that buffer. + +If PROPERTIES is non-nil, PROPERTIES are applied to the buffer, +see `set-text-properties'. If PROPERTIES equals t, this means to +apply the face `mm-uu-extract'." + (let ((obuf (current-buffer)) + (coding-system + ;; Might not exist in non-MULE XEmacs + (when (boundp 'buffer-file-coding-system) + buffer-file-coding-system))) + (with-current-buffer (generate-new-buffer " *mm-uu*") (setq buffer-file-coding-system coding-system) (insert-buffer-substring obuf from to) + (cond ((eq properties t) + (set-text-properties (point-min) (point-max) + '(face mm-uu-extract))) + (properties + (set-text-properties (point-min) (point-max) properties))) (current-buffer)))) (defun mm-uu-configure-p (key val) (member (cons key val) mm-uu-configure-list)) (defun mm-uu-configure (&optional symbol value) + "Configure detection of non-MIME attachments." + (interactive) (if symbol (set-default symbol value)) (setq mm-uu-beginning-regexp nil) (mapcar (lambda (entry) @@ -253,9 +339,38 @@ Return that buffer." (mm-make-handle (mm-uu-copy-to-buffer start-point end-point) '("application/postscript"))) +(defun mm-uu-verbatim-marks-extract (start-offset end-offset + &optional + start-hide + end-hide) + (let ((start (or (and mm-uu-hide-markers + start-hide) + start-offset + 1)) + (end (or (and mm-uu-hide-markers + end-hide) + end-offset + -1))) + (mm-make-handle + (mm-uu-copy-to-buffer + (progn (goto-char start-point) + (forward-line start) + (point)) + (progn (goto-char end-point) + (forward-line end) + (point)) + t) + '("text/x-verbatim" (charset . gnus-decoded))))) + +(defun mm-uu-latex-extract () + (mm-make-handle + (mm-uu-copy-to-buffer start-point end-point t) + ;; application/x-tex? + '("text/x-verbatim" (charset . gnus-decoded)))) + (defun mm-uu-emacs-sources-extract () (mm-make-handle (mm-uu-copy-to-buffer start-point end-point) - '("application/emacs-lisp") + '("application/emacs-lisp" (charset . gnus-decoded)) nil nil (list mm-dissect-disposition (cons 'filename file-name)))) @@ -271,13 +386,18 @@ Return that buffer." (defun mm-uu-diff-extract () (mm-make-handle (mm-uu-copy-to-buffer start-point end-point) - '("text/x-patch"))) + '("text/x-patch" (charset . gnus-decoded)))) (defun mm-uu-diff-test () (and gnus-newsgroup-name mm-uu-diff-groups-regexp (string-match mm-uu-diff-groups-regexp gnus-newsgroup-name))) +(defun mm-uu-latex-test () + (and gnus-newsgroup-name + mm-uu-tex-groups-regexp + (string-match mm-uu-tex-groups-regexp gnus-newsgroup-name))) + (defun mm-uu-forward-extract () (mm-make-handle (mm-uu-copy-to-buffer (progn (goto-char start-point) (forward-line) (point)) @@ -453,7 +573,8 @@ value of `mm-uu-text-plain-type'." (t (goto-char (point-max)))) (setq text-start (point)) (while (re-search-forward mm-uu-beginning-regexp nil t) - (setq start-point (match-beginning 0)) + (setq start-point (match-beginning 0) + entry nil) (let ((alist mm-uu-type-alist) (beginning-regexp (match-string 0))) (while (not entry) @@ -498,26 +619,69 @@ value of `mm-uu-text-plain-type'." (setq result (cons "multipart/mixed" (nreverse result)))) result))) -(defun mm-uu-dissect-text-parts (handle) - "Dissect text parts and put uu handles into HANDLE." - (let ((buffer (mm-handle-buffer handle)) - type children) +;;;###autoload +(defun mm-uu-dissect-text-parts (handle &optional decoded) + "Dissect text parts and put uu handles into HANDLE. +Assume text has been decoded if DECODED is non-nil." + (let ((buffer (mm-handle-buffer handle))) (cond ((stringp buffer) - (mapc 'mm-uu-dissect-text-parts (cdr handle))) + (dolist (elem (cdr handle)) + (mm-uu-dissect-text-parts elem decoded))) ((bufferp buffer) - (when (and (setq type (mm-handle-media-type handle)) - (stringp type) - (string-match "\\`text/" type) - (with-current-buffer buffer - (setq children - (mm-uu-dissect t (mm-handle-type handle))))) - (kill-buffer buffer) - (setcar handle (car children)) - (setcdr handle (cdr children)))) + (let ((type (mm-handle-media-type handle)) + (case-fold-search t) ;; string-match + children charset encoding) + (when (and + (stringp type) + ;; Mutt still uses application/pgp even though + ;; it has already been withdrawn. + (string-match "\\`text/\\|\\`application/pgp\\'" type) + (setq + children + (with-current-buffer buffer + (cond + ((or decoded + (eq (setq charset (mail-content-type-get + (mm-handle-type handle) + 'charset)) + 'gnus-decoded)) + (setq decoded t) + (mm-uu-dissect + t (cons type '((charset . gnus-decoded))))) + (charset + (setq decoded t) + (mm-with-multibyte-buffer + (insert (mm-decode-string (mm-get-part handle) + charset)) + (mm-uu-dissect + t (cons type '((charset . gnus-decoded)))))) + ((setq encoding (mm-handle-encoding handle)) + (setq decoded nil) + ;; Inherit the multibyteness of the `buffer'. + (with-temp-buffer + (insert-buffer-substring buffer) + (mm-decode-content-transfer-encoding + encoding type) + (mm-uu-dissect t (list type)))) + (t + (setq decoded nil) + (mm-uu-dissect t (list type))))))) + ;; Ignore it if a given part is dissected into a single + ;; part of which the type is the same as the given one. + (if (and (<= (length children) 2) + (string-equal (mm-handle-media-type (cadr children)) + type)) + (kill-buffer (mm-handle-buffer (cadr children))) + (kill-buffer buffer) + (setcdr handle (cdr children)) + (setcar handle (car children)) ;; "multipart/mixed" + (dolist (elem (cdr children)) + (mm-uu-dissect-text-parts elem decoded)))))) (t - (mapc 'mm-uu-dissect-text-parts handle))))) + (dolist (elem handle) + (mm-uu-dissect-text-parts elem decoded)))))) (provide 'mm-uu) -;;; arch-tag: 7db076bf-53db-4320-aa19-ca76a1d2ab2c +;; arch-tag: 7db076bf-53db-4320-aa19-ca76a1d2ab2c ;;; mm-uu.el ends here diff --git a/lisp/mm-view.el b/lisp/mm-view.el index 8d03600..36870af 100644 --- a/lisp/mm-view.el +++ b/lisp/mm-view.el @@ -1,6 +1,7 @@ ;;; mm-view.el --- functions for viewing MIME objects -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -37,11 +38,18 @@ (autoload 'fill-flowed "flow-fill") (autoload 'html2text "html2text")) +(defvar gnus-article-mime-handles) +(defvar gnus-newsgroup-charset) +(defvar smime-keys) +(defvar w3m-cid-retrieve-function-alist) +(defvar w3m-current-buffer) +(defvar w3m-display-inline-images) +(defvar w3m-minor-mode-map) + (defvar mm-text-html-renderer-alist '((w3 . mm-inline-text-html-render-with-w3) (w3m . mm-inline-text-html-render-with-w3m) - (w3m-standalone mm-inline-render-with-stdin nil - "w3m" "-dump" "-T" "text/html") + (w3m-standalone . mm-inline-text-html-render-with-w3m-standalone) (links mm-inline-render-with-file mm-links-remove-leading-blank "links" "-dump" file) @@ -53,8 +61,7 @@ (defvar mm-text-html-washer-alist '((w3 . gnus-article-wash-html-with-w3) (w3m . gnus-article-wash-html-with-w3m) - (w3m-standalone mm-inline-wash-with-stdin nil - "w3m" "-dump" "-T" "text/html") + (w3m-standalone . gnus-article-wash-html-with-w3m-standalone) (links mm-inline-wash-with-file mm-links-remove-leading-blank "links" "-dump" file) @@ -66,6 +73,7 @@ (defcustom mm-fill-flowed t "If non-nil a format=flowed article will be displayed flowed." :type 'boolean + :version "22.1" :group 'mime-display) ;;; Internal variables. @@ -203,21 +211,25 @@ (defun mm-w3m-cid-retrieve-1 (url handle) (dolist (elem handle) - (when (listp elem) - (if (equal url (mm-handle-id elem)) - (progn - (mm-insert-part elem) - (throw 'found-handle (mm-handle-media-type elem)))) - (if (equal "multipart" (mm-handle-media-supertype elem)) - (mm-w3m-cid-retrieve-1 url elem))))) + (when (consp elem) + (when (equal url (mm-handle-id elem)) + (mm-insert-part elem) + (throw 'found-handle (mm-handle-media-type elem))) + (when (and (stringp (car elem)) + (equal "multipart" (mm-handle-media-supertype elem))) + (mm-w3m-cid-retrieve-1 url elem))))) (defun mm-w3m-cid-retrieve (url &rest args) "Insert a content pointed by URL if it has the cid: scheme." (when (string-match "\\`cid:" url) - (catch 'found-handle - (mm-w3m-cid-retrieve-1 (concat "<" (substring url (match-end 0)) ">") - (with-current-buffer w3m-current-buffer - gnus-article-mime-handles))))) + (or (catch 'found-handle + (mm-w3m-cid-retrieve-1 + (setq url (concat "<" (substring url (match-end 0)) ">")) + (with-current-buffer w3m-current-buffer + gnus-article-mime-handles))) + (prog1 + nil + (message "Failed to find \"Content-ID: %s\"" url))))) (defun mm-inline-text-html-render-with-w3m (handle) "Render a text/html part using emacs-w3m." @@ -244,19 +256,71 @@ (point-min) (point-max) (list 'keymap w3m-minor-mode-map ;; Put the mark meaning this part was rendered by emacs-w3m. - 'mm-inline-text-html-with-w3m t)))) - (mm-handle-set-undisplayer - handle - `(lambda () - (let (buffer-read-only) - (if (functionp 'remove-specifier) - (mapcar (lambda (prop) - (remove-specifier - (face-property 'default prop) - (current-buffer))) - '(background background-pixmap foreground))) - (delete-region ,(point-min-marker) - ,(point-max-marker)))))))) + 'mm-inline-text-html-with-w3m t))) + (mm-handle-set-undisplayer + handle + `(lambda () + (let (buffer-read-only) + (if (functionp 'remove-specifier) + (mapcar (lambda (prop) + (remove-specifier + (face-property 'default prop) + (current-buffer))) + '(background background-pixmap foreground))) + (delete-region ,(point-min-marker) + ,(point-max-marker))))))))) + +(defvar mm-w3m-standalone-supports-m17n-p (if (featurep 'mule) 'undecided) + "*T means the w3m command supports the m17n feature.") + +(defun mm-w3m-standalone-supports-m17n-p () + "Say whether the w3m command supports the m17n feature." + (cond ((eq mm-w3m-standalone-supports-m17n-p t) t) + ((eq mm-w3m-standalone-supports-m17n-p nil) nil) + ((not (featurep 'mule)) (setq mm-w3m-standalone-supports-m17n-p nil)) + ((condition-case nil + (let ((coding-system-for-write 'iso-2022-jp) + (coding-system-for-read 'iso-2022-jp) + (str (mm-decode-coding-string "\ +\e$B#D#o#e#s!!#w#3#m!!#s#u#p#p#o#r#t#s!!#m#1#7#n!)\e(B" 'iso-2022-jp))) + (mm-with-multibyte-buffer + (insert str) + (call-process-region + (point-min) (point-max) "w3m" t t nil "-dump" + "-T" "text/html" "-I" "iso-2022-jp" "-O" "iso-2022-jp") + (goto-char (point-min)) + (search-forward str nil t))) + (error nil)) + (setq mm-w3m-standalone-supports-m17n-p t)) + (t + ;;(message "You had better upgrade your w3m command") + (setq mm-w3m-standalone-supports-m17n-p nil)))) + +(defun mm-inline-text-html-render-with-w3m-standalone (handle) + "Render a text/html part using w3m." + (if (mm-w3m-standalone-supports-m17n-p) + (let ((source (mm-get-part handle)) + (charset (mail-content-type-get (mm-handle-type handle) 'charset)) + cs) + (unless (and charset + (setq cs (mm-charset-to-coding-system charset)) + (not (eq cs 'ascii))) + ;; The default. + (setq charset "iso-8859-1" + cs 'iso-8859-1)) + (mm-insert-inline + handle + (mm-with-unibyte-buffer + (insert source) + (mm-enable-multibyte) + (let ((coding-system-for-write 'binary) + (coding-system-for-read cs)) + (call-process-region + (point-min) (point-max) + "w3m" t t nil "-dump" "-T" "text/html" + "-I" charset "-O" charset)) + (buffer-string)))) + (mm-inline-render-with-stdin handle nil "w3m" "-dump" "-T" "text/html"))) (defun mm-links-remove-leading-blank () ;; Delete the annoying three spaces preceding each line of links @@ -362,9 +426,9 @@ (goto-char (point-max)))) (save-restriction (narrow-to-region b (point)) - (set-text-properties (point-min) (point-max) nil) (when (or (equal type "enriched") (equal type "richtext")) + (set-text-properties (point-min) (point-max) nil) (ignore-errors (enriched-decode (point-min) (point-max)))) (mm-handle-set-undisplayer @@ -433,7 +497,8 @@ ;; disable prepare hook gnus-article-prepare-hook (gnus-newsgroup-charset - (or charset gnus-newsgroup-charset))) + (unless (eq charset 'gnus-decoded) ;; mm-uu might set it. + (or charset gnus-newsgroup-charset)))) (let ((gnus-original-article-buffer (mm-handle-buffer handle))) (run-hooks 'gnus-article-decode-hook)) (gnus-article-prepare-display) @@ -481,7 +546,8 @@ (buffer-disable-undo) (mm-enable-multibyte) (insert (cond ((eq charset 'gnus-decoded) - (mm-insert-part handle)) + (with-current-buffer (mm-handle-buffer handle) + (buffer-string))) (coding-system (mm-decode-coding-string text coding-system)) (charset @@ -489,14 +555,16 @@ (t text))) (require 'font-lock) - ;; Inhibit font-lock this time (*-mode-hook might run - ;; `turn-on-font-lock') so that jit-lock may not turn off - ;; font-lock immediately after this. - (let ((font-lock-mode t)) - (funcall mode)) - (let ((font-lock-verbose nil)) - ;; I find font-lock a bit too verbose. - (font-lock-fontify-buffer)) + (let ((font-lock-maximum-size nil) + ;; Disable support modes, e.g., jit-lock, lazy-lock, etc. + (font-lock-mode-hook nil) + (font-lock-support-mode nil) + ;; I find font-lock a bit too verbose. + (font-lock-verbose nil)) + (funcall mode) + ;; The mode function might have already turned on font-lock. + (unless (symbol-value 'font-lock-mode) + (font-lock-fontify-buffer))) ;; By default, XEmacs font-lock uses non-duplicable text ;; properties. This code forces all the text properties ;; to be copied along with the text. @@ -560,19 +628,24 @@ (otherwise (error "Unknown or unimplemented PKCS#7 type")))) (defun mm-view-pkcs7-verify (handle) - ;; A bogus implementation of PKCS#7. FIXME:: - (mm-insert-part handle) - (goto-char (point-min)) - (if (search-forward "Content-Type: " nil t) - (delete-region (point-min) (match-beginning 0))) - (goto-char (point-max)) - (if (re-search-backward "--\r?\n?" nil t) - (delete-region (match-end 0) (point-max))) + (let ((verified nil)) + (with-temp-buffer + (insert "MIME-Version: 1.0\n") + (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m") + (insert-buffer-substring (mm-handle-buffer handle)) + (setq verified (smime-verify-region (point-min) (point-max)))) + (goto-char (point-min)) + (mm-insert-part handle) + (if (search-forward "Content-Type: " nil t) + (delete-region (point-min) (match-beginning 0))) + (goto-char (point-max)) + (if (re-search-backward "--\r?\n?" nil t) + (delete-region (match-end 0) (point-max))) + (unless verified + (insert-buffer-substring smime-details-buffer))) (goto-char (point-min)) (while (search-forward "\r\n" nil t) (replace-match "\n")) - (message "Verify signed PKCS#7 message is unimplemented.") - (sit-for 1) t) (defun mm-view-pkcs7-decrypt (handle) @@ -586,9 +659,9 @@ (cadar smime-keys) (smime-get-key-by-email (completing-read - (concat "Decipher using which key? " - (if smime-keys (concat "(default " (caar smime-keys) ") ") - "")) + (concat "Decipher using key" + (if smime-keys (concat "(default " (caar smime-keys) "): ") + ": ")) smime-keys nil nil nil nil (car-safe (car-safe smime-keys)))))) (goto-char (point-min)) (while (search-forward "\r\n" nil t) diff --git a/lisp/mml-sec.el b/lisp/mml-sec.el index d254a60..42160b5 100644 --- a/lisp/mml-sec.el +++ b/lisp/mml-sec.el @@ -1,5 +1,7 @@ ;;; mml-sec.el --- A package with security functions for MML documents -;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson @@ -17,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -186,6 +188,29 @@ You can also customize or set `mml-signencrypt-style-alist' instead." (cons method tags)))) (t (error "The message is corrupted. No mail header separator")))))) +(defvar mml-secure-method + (if (equal mml-default-encrypt-method mml-default-sign-method) + mml-default-sign-method + "pgpmime") + "Current security method. Internal variable.") + +(defun mml-secure-sign (&optional method) + "Add MML tags to sign this MML part. +Use METHOD if given. Else use `mml-secure-method' or +`mml-default-sign-method'." + (interactive) + (mml-secure-part + (or method mml-secure-method mml-default-sign-method) + 'sign)) + +(defun mml-secure-encrypt (&optional method) + "Add MML tags to encrypt this MML part. +Use METHOD if given. Else use `mml-secure-method' or +`mml-default-sign-method'." + (interactive) + (mml-secure-part + (or method mml-secure-method mml-default-sign-method))) + (defun mml-secure-sign-pgp () "Add MML tags to PGP sign this MML part." (interactive) @@ -254,6 +279,34 @@ You can also customize or set `mml-signencrypt-style-alist' instead." (when (re-search-backward "^<#secure.*>\n" nil t) (delete-region (match-beginning 0) (match-end 0))))) + +(defun mml-secure-message-sign (&optional method) + "Add MML tags to sign this MML part. +Use METHOD if given. Else use `mml-secure-method' or +`mml-default-sign-method'." + (interactive) + (mml-secure-part + (or method mml-secure-method mml-default-sign-method) + 'sign)) + +(defun mml-secure-message-sign-encrypt (&optional method) + "Add MML tag to sign and encrypt the entire message. +Use METHOD if given. Else use `mml-secure-method' or +`mml-default-sign-method'." + (interactive) + (mml-secure-message + (or method mml-secure-method mml-default-sign-method) + 'signencrypt)) + +(defun mml-secure-message-encrypt (&optional method) + "Add MML tag to encrypt the entire message. +Use METHOD if given. Else use `mml-secure-method' or +`mml-default-sign-method'." + (interactive) + (mml-secure-message + (or method mml-secure-method mml-default-sign-method) + 'encrypt)) + (defun mml-secure-message-sign-smime () "Add MML tag to encrypt/sign the entire message." (interactive) diff --git a/lisp/mml-smime.el b/lisp/mml-smime.el index 6febd61..9d9d941 100644 --- a/lisp/mml-smime.el +++ b/lisp/mml-smime.el @@ -1,5 +1,7 @@ ;;; mml-smime.el --- S/MIME support for MML -;; Copyright (c) 2000, 2001, 2003, 2005 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: Gnus, MIME, S/MIME, MML @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -52,7 +54,7 @@ (if (not (and (not (file-exists-p tmp)) (get-buffer tmp))) (push tmp certfiles) - (setq file (mm-make-temp-file (expand-file-name "mml." + (setq file (mm-make-temp-file (expand-file-name "mml." mm-tmp-directory))) (with-current-buffer tmp (write-region (point-min) (point-max) file)) @@ -77,7 +79,10 @@ (list 'keyfile (if (= (length smime-keys) 1) (cadar smime-keys) - (or (let ((from (cadr (funcall gnus-extract-address-components + (or (let ((from (cadr (funcall (if (boundp + 'gnus-extract-address-components) + gnus-extract-address-components + 'mail-extract-address-components) (or (save-excursion (save-restriction (message-narrow-to-headers) @@ -103,7 +108,10 @@ (while (not result) (setq who (read-from-minibuffer (format "%sLookup certificate for: " (or bad "")) - (cadr (funcall gnus-extract-address-components + (cadr (funcall (if (boundp + 'gnus-extract-address-components) + gnus-extract-address-components + 'mail-extract-address-components) (or (save-excursion (save-restriction (message-narrow-to-headers) diff --git a/lisp/mml.el b/lisp/mml.el index 80bb833..157b748 100644 --- a/lisp/mml.el +++ b/lisp/mml.el @@ -1,6 +1,7 @@ ;;; mml.el --- A package for parsing and validating MML documents -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -37,12 +38,23 @@ (autoload 'gnus-make-local-hook "gnus-util") (autoload 'message-fetch-field "message") (autoload 'message-mark-active-p "message") + (autoload 'message-info "message") (autoload 'fill-flowed-encode "flow-fill") (autoload 'message-posting-charset "message")) (eval-when-compile (autoload 'dnd-get-local-file-name "dnd")) +(defvar gnus-article-mime-handles) +(defvar gnus-mouse-2) +(defvar gnus-newsrc-hashtb) +(defvar message-default-charset) +(defvar message-deletable-headers) +(defvar message-options) +(defvar message-posting-charset) +(defvar message-required-mail-headers) +(defvar message-required-news-headers) + (defcustom mml-content-type-parameters '(name access-type expiration size permission format) "*A list of acceptable parameters in MML tag. @@ -126,7 +138,13 @@ unknown encoding; `use-ascii': always use ASCII for those characters with unknown encoding; `multipart': always send messages with more than one charsets.") -(defvar mml-generate-default-type "text/plain") +(defvar mml-generate-default-type "text/plain" + "Content type by which the Content-Type header can be omitted. +The Content-Type header will not be put in the MIME part if the type +equals the value and there's no parameter (e.g. charset, format, etc.) +and `mml-insert-mime-headers-always' is nil. The value will be bound +to \"message/rfc822\" when encoding an article to be forwarded as a MIME +part. This is for the internal use, you should never modify the value.") (defvar mml-buffer-list nil) @@ -404,11 +422,16 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (mml-tweak-part cont) (cond ((or (eq (car cont) 'part) (eq (car cont) 'mml)) - (let ((raw (cdr (assq 'raw cont))) - type charset coding filename encoding flowed coded) - (setq type (or (cdr (assq 'type cont)) "text/plain") - charset (cdr (assq 'charset cont)) - coding (mm-charset-to-coding-system charset)) + (let* ((raw (cdr (assq 'raw cont))) + (filename (cdr (assq 'filename cont))) + (type (or (cdr (assq 'type cont)) + (if filename + (or (mm-default-file-encoding filename) + "application/octet-stream") + "text/plain"))) + (charset (cdr (assq 'charset cont))) + (coding (mm-charset-to-coding-system charset)) + encoding flowed coded) (cond ((eq coding 'ascii) (setq charset nil coding nil)) @@ -421,7 +444,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (cond ((cdr (assq 'buffer cont)) (insert-buffer-substring (cdr (assq 'buffer cont)))) - ((and (setq filename (cdr (assq 'filename cont))) + ((and filename (not (equal (cdr (assq 'nofile cont)) "yes"))) (let ((coding-system-for-read coding)) (mm-insert-file-contents filename))) @@ -441,6 +464,10 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (cond ((eq (car cont) 'mml) (let ((mml-boundary (mml-compute-boundary cont)) + ;; It is necessary for the case where this + ;; function is called recursively since + ;; `m-g-d-t' will be bound to "message/rfc822" + ;; when encoding an article to be forwarded. (mml-generate-default-type "text/plain")) (mml-to-mime)) (let ((mm-7bit-chars (concat mm-7bit-chars "\x1b"))) @@ -482,7 +509,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (insert (with-current-buffer (cdr (assq 'buffer cont)) (mm-with-unibyte-current-buffer (buffer-string))))) - ((and (setq filename (cdr (assq 'filename cont))) + ((and filename (not (equal (cdr (assq 'nofile cont)) "yes"))) (let ((coding-system-for-read mm-binary-coding-system)) (mm-insert-file-contents filename nil nil nil nil t)) @@ -491,7 +518,15 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (mm-find-buffer-file-coding-system filename))))) (t - (insert (cdr (assq 'contents cont))))) + (let ((contents (cdr (assq 'contents cont)))) + (if (if (featurep 'xemacs) + (string-match "[^\000-\377]" contents) + (mm-multibyte-string-p contents)) + (progn + (mm-enable-multibyte) + (insert contents) + (setq charset (mm-encode-body charset))) + (insert contents))))) (setq encoding (mm-encode-buffer type) coded (mm-string-as-multibyte (buffer-string)))) (mml-insert-mime-headers cont type charset encoding nil) @@ -527,15 +562,21 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." "access-type=url")) (when parameters (mml-insert-parameter-string - cont '(expiration size permission)))) - (insert "\n\n") - (insert "Content-Type: " (cdr (assq 'type cont)) "\n") - (insert "Content-ID: " (message-make-message-id) "\n") - (insert "Content-Transfer-Encoding: " - (or (cdr (assq 'encoding cont)) "binary")) - (insert "\n\n") - (insert (or (cdr (assq 'contents cont)))) - (insert "\n")) + cont '(expiration size permission))) + (insert "\n\n") + (insert "Content-Type: " + (or (cdr (assq 'type cont)) + (if name + (or (mm-default-file-encoding name) + "application/octet-stream") + "text/plain")) + "\n") + (insert "Content-ID: " (message-make-message-id) "\n") + (insert "Content-Transfer-Encoding: " + (or (cdr (assq 'encoding cont)) "binary")) + (insert "\n\n") + (insert (or (cdr (assq 'contents cont)))) + (insert "\n"))) ((eq (car cont) 'multipart) (let* ((type (or (cdr (assq 'type cont)) "mixed")) (mml-generate-default-type (if (equal type "digest") @@ -556,7 +597,8 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." ;; Skip `multipart' and attributes. (when (and (consp part) (consp (cdr part))) (insert "\n--" mml-boundary "\n") - (mml-generate-mime-1 part)))) + (mml-generate-mime-1 part) + (goto-char (point-max))))) (insert "\n--" mml-boundary "--\n"))))) (t (error "Invalid element: %S" cont))) @@ -641,10 +683,10 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." "Can't encode a part with several charsets")) (insert "Content-Type: " type) (when charset - (insert "; " (mail-header-encode-parameter - "charset" (symbol-name charset)))) + (mml-insert-parameter + (mail-header-encode-parameter "charset" (symbol-name charset)))) (when flowed - (insert "; format=flowed")) + (mml-insert-parameter "format=flowed")) (when parameters (mml-insert-parameter-string cont mml-content-type-parameters)) @@ -664,8 +706,11 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." (unless (eq encoding '7bit) (insert (format "Content-Transfer-Encoding: %s\n" encoding))) (when (setq description (cdr (assq 'description cont))) - (insert "Content-Description: " - (mail-encode-encoded-word-string description) "\n")))) + (insert "Content-Description: ") + (setq description (prog1 + (point) + (insert description "\n"))) + (mail-encode-encoded-word-region description (point))))) (defun mml-parameter-string (cont types) (let ((string "") @@ -759,7 +804,7 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (unless (setq textp (equal (mm-handle-media-supertype handle) "text")) (save-excursion (set-buffer (setq buffer (mml-generate-new-buffer " *mml*"))) - (mm-insert-part handle) + (mm-insert-part handle 'no-cache) (if (setq mmlp (equal (mm-handle-media-type handle) "message/rfc822")) (mime-to-mml))))) @@ -818,14 +863,20 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (defun mml-insert-parameter (&rest parameters) "Insert PARAMETERS in a nice way." - (dolist (param parameters) - (insert ";") - (let ((point (point))) + (let (start end) + (dolist (param parameters) + (insert ";") + (setq start (point)) (insert " " param) - (when (> (current-column) 71) - (goto-char point) - (insert "\n") - (end-of-line))))) + (setq end (point)) + (goto-char start) + (end-of-line) + (if (> (current-column) 76) + (progn + (goto-char start) + (insert "\n") + (goto-char (1+ end))) + (goto-char end))))) ;;; ;;; Mode for inserting and editing MML forms @@ -838,6 +889,11 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (encryptpart (make-sparse-keymap)) (map (make-sparse-keymap)) (main (make-sparse-keymap))) + (define-key map "\C-s" 'mml-secure-message-sign) + (define-key map "\C-c" 'mml-secure-message-encrypt) + (define-key map "\C-e" 'mml-secure-message-sign-encrypt) + (define-key map "\C-p\C-s" 'mml-secure-sign) + (define-key map "\C-p\C-c" 'mml-secure-encrypt) (define-key sign "p" 'mml-secure-message-sign-pgpmime) (define-key sign "o" 'mml-secure-message-sign-pgp) (define-key sign "s" 'mml-secure-message-sign-smime) @@ -875,31 +931,63 @@ If HANDLES is non-nil, use it instead reparsing the buffer." ["Attach File..." mml-attach-file ,@(if (featurep 'xemacs) '(t) '(:help "Attach a file at point"))] - ["Attach Buffer..." mml-attach-buffer t] - ["Attach External..." mml-attach-external t] - ["Insert Part..." mml-insert-part t] - ["Insert Multipart..." mml-insert-multipart t] - ["PGP/MIME Sign" mml-secure-message-sign-pgpmime t] - ["PGP/MIME Encrypt" mml-secure-message-encrypt-pgpmime t] - ["PGP Sign" mml-secure-message-sign-pgp t] - ["PGP Encrypt" mml-secure-message-encrypt-pgp t] - ["S/MIME Sign" mml-secure-message-sign-smime t] - ["S/MIME Encrypt" mml-secure-message-encrypt-smime t] - ("Secure MIME part" - ["PGP/MIME Sign Part" mml-secure-sign-pgpmime t] - ["PGP/MIME Encrypt Part" mml-secure-encrypt-pgpmime t] - ["PGP Sign Part" mml-secure-sign-pgp t] - ["PGP Encrypt Part" mml-secure-encrypt-pgp t] - ["S/MIME Sign Part" mml-secure-sign-smime t] - ["S/MIME Encrypt Part" mml-secure-encrypt-smime t]) - ["Encrypt/Sign off" mml-unsecure-message t] + ["Attach Buffer..." mml-attach-buffer + ,@(if (featurep 'xemacs) '(t) + '(:help "Attach a buffer to the outgoing MIME message"))] + ["Attach External..." mml-attach-external + ,@(if (featurep 'xemacs) '(t) + '(:help "Attach reference to file"))] + ;; + ("Change Security Method" + ["PGP/MIME" + (lambda () (interactive) (setq mml-secure-method "pgpmime")) + ,@(if (featurep 'xemacs) nil + '(:help "Set Security Method to PGP/MIME")) + :style radio + :selected (equal mml-secure-method "pgpmime") ] + ["S/MIME" + (lambda () (interactive) (setq mml-secure-method "smime")) + ,@(if (featurep 'xemacs) nil + '(:help "Set Security Method to S/MIME")) + :style radio + :selected (equal mml-secure-method "smime") ] + ["Inline PGP" + (lambda () (interactive) (setq mml-secure-method "pgp")) + ,@(if (featurep 'xemacs) nil + '(:help "Set Security Method to inline PGP")) + :style radio + :selected (equal mml-secure-method "pgp") ] ) + ;; + ["Sign Message" mml-secure-message-sign t] + ["Encrypt Message" mml-secure-message-encrypt t] + ["Sign and Encrypt Message" mml-secure-message-sign-encrypt t] + ["Encrypt/Sign off" mml-unsecure-message + ,@(if (featurep 'xemacs) '(t) + '(:help "Don't Encrypt/Sign Message"))] + ;; Maybe we could remove these, because people who write MML most probably + ;; don't use the menu: + ["Insert Part..." mml-insert-part + :active (message-in-body-p)] + ["Insert Multipart..." mml-insert-multipart + :active (message-in-body-p)] + ;; + ;; Do we have separate encrypt and encrypt/sign commands for parts? + ["Sign Part" mml-secure-sign t] + ["Encrypt Part" mml-secure-encrypt t] ;;["Narrow" mml-narrow-to-part t] - ["Quote MML" mml-quote-region + ["Quote MML in region" mml-quote-region :active (message-mark-active-p) ,@(if (featurep 'xemacs) nil '(:help "Quote MML tags in region"))] ["Validate MML" mml-validate t] - ["Preview" mml-preview t])) + ["Preview" mml-preview t] + "----" + ["Emacs MIME manual" (lambda () (interactive) (message-info 4)) + ,@(if (featurep 'xemacs) '(t) + '(:help "Display the Emacs MIME manual"))] + ["PGG manual" (lambda () (interactive) (message-info 16)) + ,@(if (featurep 'xemacs) '(t) + '(:help "Display the PGG manual"))])) (defvar mml-mode nil "Minor mode for editing MML.") @@ -918,9 +1006,8 @@ See Info node `(emacs-mime)Composing'. (easy-menu-add mml-menu mml-mode-map) (when (boundp 'dnd-protocol-alist) (set (make-local-variable 'dnd-protocol-alist) - '(("^file:///" . mml-dnd-attach-file) - ("^file://" . dnd-open-file) - ("^file:" . mml-dnd-attach-file)))) + (append mml-dnd-protocol-alist + (symbol-value 'dnd-protocol-alist)))) (run-hooks 'mml-mode-hook))) ;;; @@ -963,13 +1050,15 @@ See Info node `(emacs-mime)Composing'. description)) (defun mml-minibuffer-read-disposition (type &optional default) - (let* ((default (or default - (if (string-match "^text/.*" type) - "inline" - "attachment"))) - (disposition (completing-read "Disposition: " - '(("attachment") ("inline") ("")) - nil t))) + (unless default (setq default + (if (and (string-match "\\`text/" type) + (not (string-match "\\`text/rtf\\'" type))) + "inline" + "attachment"))) + (let ((disposition (completing-read + (format "Disposition (default %s): " default) + '(("attachment") ("inline") ("")) + nil t nil nil default))) (if (not (equal disposition "")) disposition default))) @@ -1016,33 +1105,83 @@ See Info node `(emacs-mime)Composing'. ;;; Attachment functions. +(defcustom mml-dnd-protocol-alist + '(("^file:///" . mml-dnd-attach-file) + ("^file://" . dnd-open-file) + ("^file:" . mml-dnd-attach-file)) + "The functions to call when a drop in `mml-mode' is made. +See `dnd-protocol-alist' for more information. When nil, behave +as in other buffers." + :type '(choice (repeat (cons (regexp) (function))) + (const :tag "Behave as in other buffers" nil)) + :version "23.0" ;; No Gnus + :group 'message) + +(defcustom mml-dnd-attach-options nil + "Which options should be queried when attaching a file via drag and drop. + +If it is a list, valid members are `type', `description' and +`disposition'. `disposition' implies `type'. If it is nil, +don't ask for options. If it is t, ask the user whether or not +to specify options." + :type '(choice + (const :tag "Non" nil) + (const :tag "Query" t) + (list :value (type description disposition) + (set :inline t + (const type) + (const description) + (const disposition)))) + :version "23.0" ;; No Gnus + :group 'message) + (defun mml-attach-file (file &optional type description disposition) "Attach a file to the outgoing MIME message. The file is not inserted or encoded until you send the message with `\\[message-send-and-exit]' or `\\[message-send]'. -FILE is the name of the file to attach. TYPE is its content-type, a -string of the form \"type/subtype\". DESCRIPTION is a one-line -description of the attachment." +FILE is the name of the file to attach. TYPE is its +content-type, a string of the form \"type/subtype\". DESCRIPTION +is a one-line description of the attachment. The DISPOSITION +specifies how the attachment is intended to be displayed. It can +be either \"inline\" (displayed automatically within the message +body) or \"attachment\" (separate from the body)." (interactive (let* ((file (mml-minibuffer-read-file "Attach file: ")) (type (mml-minibuffer-read-type file)) (description (mml-minibuffer-read-description)) (disposition (mml-minibuffer-read-disposition type))) (list file type description disposition))) - (mml-insert-empty-tag 'part - 'type type - 'filename file - 'disposition (or disposition "attachment") - 'description description)) + (save-excursion + (unless (message-in-body-p) (goto-char (point-max))) + (mml-insert-empty-tag 'part + 'type type + 'filename file + 'disposition (or disposition "attachment") + 'description description))) (defun mml-dnd-attach-file (uri action) - "Attach a drag and drop file." + "Attach a drag and drop file. + +Ask for type, description or disposition according to +`mml-dnd-attach-options'." (let ((file (dnd-get-local-file-name uri t))) (when (and file (file-regular-p file)) - (let* ((type (mml-minibuffer-read-type file)) - (description (mml-minibuffer-read-description)) - (disposition (mml-minibuffer-read-disposition type))) + (let ((mml-dnd-attach-options mml-dnd-attach-options) + type description disposition) + (setq mml-dnd-attach-options + (when (and (eq mml-dnd-attach-options t) + (not + (y-or-n-p + "Use default type, disposition and description? "))) + '(type description disposition))) + (when (or (memq 'type mml-dnd-attach-options) + (memq 'disposition mml-dnd-attach-options)) + (setq type (mml-minibuffer-read-type file))) + (when (memq 'description mml-dnd-attach-options) + (setq description (mml-minibuffer-read-description))) + (when (memq 'disposition mml-dnd-attach-options) + (setq disposition (mml-minibuffer-read-disposition type))) (mml-attach-file file type description disposition))))) (defun mml-attach-buffer (buffer &optional type description) @@ -1053,8 +1192,11 @@ See `mml-attach-file' for details of operation." (type (mml-minibuffer-read-type buffer "text/plain")) (description (mml-minibuffer-read-description))) (list buffer type description))) - (mml-insert-empty-tag 'part 'type type 'buffer buffer - 'disposition "attachment" 'description description)) + (save-excursion + (unless (message-in-body-p) (goto-char (point-max))) + (mml-insert-empty-tag 'part 'type type 'buffer buffer + 'disposition "attachment" + 'description description))) (defun mml-attach-external (file &optional type description) "Attach an external file into the buffer. @@ -1065,8 +1207,10 @@ TYPE is the MIME type to use." (type (mml-minibuffer-read-type file)) (description (mml-minibuffer-read-description))) (list file type description))) - (mml-insert-empty-tag 'external 'type type 'name file - 'disposition "attachment" 'description description)) + (save-excursion + (unless (message-in-body-p) (goto-char (point-max))) + (mml-insert-empty-tag 'external 'type type 'name file + 'disposition "attachment" 'description description))) (defun mml-insert-multipart (&optional type) (interactive (list (completing-read "Multipart type (default mixed): " @@ -1098,7 +1242,12 @@ Should be adopted if code in `message-send-mail' is changed." (defun mml-preview (&optional raw) "Display current buffer with Gnus, in a new buffer. -If RAW, don't highlight the article." +If RAW, display a raw encoded MIME message. + +The window layout for the preview buffer is controled by the variables +`special-display-buffer-names', `special-display-regexps', or +`gnus-buffer-configuration' (the first match made will be used), +or the `pop-to-buffer' function." (interactive "P") (setq mml-preview-buffer (generate-new-buffer (concat (if raw "*Raw MIME preview of " @@ -1166,8 +1315,11 @@ If RAW, don't highlight the article." (lambda (event) (interactive "@e") (widget-button-press (widget-event-point event) event))) + ;; FIXME: Buffer is in article mode, but most tool bar commands won't + ;; work. Maybe only keep the following icons: search, print, quit (goto-char (point-min)))) - (if (and (boundp 'gnus-buffer-configuration) + (if (and (not (mm-special-display-p (buffer-name mml-preview-buffer))) + (boundp 'gnus-buffer-configuration) (assq 'mml-preview gnus-buffer-configuration)) (let ((gnus-message-buffer (current-buffer))) (gnus-configure-windows 'mml-preview)) diff --git a/lisp/mml1991.el b/lisp/mml1991.el index 14d52e4..0c6bb67 100644 --- a/lisp/mml1991.el +++ b/lisp/mml1991.el @@ -1,5 +1,7 @@ ;;; mml1991.el --- Old PGP message format (RFC 1991) support for MML -;; Copyright (C) 1998, 1999, 2000, 2001, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Sascha Lüdecke , ;; Simon Josefsson (Mailcrypt interface, Gnus glue) @@ -19,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -30,6 +32,8 @@ (require 'cl) (require 'mm-util)) +(defvar mc-pgp-always-sign) + (autoload 'quoted-printable-decode-region "qp") (autoload 'quoted-printable-encode-region "qp") @@ -180,7 +184,7 @@ (delete-region (point-min) (point))) (mm-with-unibyte-current-buffer (with-temp-buffer - (flet ((gpg-encrypt-func + (flet ((gpg-encrypt-func (sign plaintext ciphertext result recipients &optional passphrase sign-with-key armor textmode) (if sign @@ -219,11 +223,14 @@ ;; pgg wrapper -(defvar pgg-output-buffer) -(defvar pgg-errors-buffer) +(eval-when-compile + (defvar pgg-default-user-id) + (defvar pgg-errors-buffer) + (defvar pgg-output-buffer)) (defun mml1991-pgg-sign (cont) - (let (headers cte) + (let ((pgg-text-mode t) + headers cte) ;; Don't sign headers. (goto-char (point-min)) (while (not (looking-at "^$")) @@ -255,7 +262,8 @@ t)) (defun mml1991-pgg-encrypt (cont &optional sign) - (let (cte) + (let ((pgg-text-mode t) + cte) ;; Strip MIME Content[^ ]: headers since it will be ASCII ARMOURED (goto-char (point-min)) (while (looking-at "^Content[^ ]+:") @@ -266,7 +274,7 @@ (delete-region (point-min) (point))) (mm-decode-content-transfer-encoding cte) (unless (pgg-encrypt-region - (point-min) (point-max) + (point-min) (point-max) (split-string (or (message-options-get 'message-recipients) diff --git a/lisp/mml2015.el b/lisp/mml2015.el index 9e0311c..69d71ab 100644 --- a/lisp/mml2015.el +++ b/lisp/mml2015.el @@ -1,5 +1,7 @@ ;;; mml2015.el --- MIME Security with Pretty Good Privacy (PGP) -;; Copyright (C) 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: PGP MIME MML @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -33,6 +35,8 @@ (require 'mm-util) (require 'mml) +(defvar mc-pgp-always-sign) + (defvar mml2015-use (or (progn (ignore-errors @@ -636,6 +640,7 @@ Valid packages include `pgg', `gpg' and `mailcrypt'.") ;;; pgg wrapper (eval-when-compile + (defvar pgg-default-user-id) (defvar pgg-errors-buffer) (defvar pgg-output-buffer)) @@ -643,7 +648,8 @@ Valid packages include `pgg', `gpg' and `mailcrypt'.") (autoload 'pgg-decrypt-region "pgg") (autoload 'pgg-verify-region "pgg") (autoload 'pgg-sign-region "pgg") - (autoload 'pgg-encrypt-region "pgg")) + (autoload 'pgg-encrypt-region "pgg") + (autoload 'pgg-parse-armor "pgg-parse")) (defun mml2015-pgg-decrypt (handle ctl) (catch 'error @@ -811,15 +817,24 @@ Valid packages include `pgg', `gpg' and `mailcrypt'.") (let ((pgg-errors-buffer mml2015-result-buffer) (boundary (mml-compute-boundary cont)) (pgg-default-user-id (or (message-options-get 'mml-sender) - pgg-default-user-id))) + pgg-default-user-id)) + (pgg-text-mode t) + entry) (unless (pgg-sign-region (point-min) (point-max)) (pop-to-buffer mml2015-result-buffer) (error "Sign error")) (goto-char (point-min)) (insert (format "Content-Type: multipart/signed; boundary=\"%s\";\n" boundary)) - ;;; FIXME: what is the micalg? - (insert "\tmicalg=pgp-sha1; protocol=\"application/pgp-signature\"\n") + (if (setq entry (assq 2 (pgg-parse-armor + (with-current-buffer pgg-output-buffer + (buffer-string))))) + (setq entry (assq 'hash-algorithm (cdr entry)))) + (insert (format "\tmicalg=%s; " + (if (cdr entry) + (downcase (format "pgp-%s" (cdr entry))) + "pgp-sha1"))) + (insert "protocol=\"application/pgp-signature\"\n") (insert (format "\n--%s\n" boundary)) (goto-char (point-max)) (insert (format "\n--%s\n" boundary)) @@ -831,6 +846,7 @@ Valid packages include `pgg', `gpg' and `mailcrypt'.") (defun mml2015-pgg-encrypt (cont &optional sign) (let ((pgg-errors-buffer mml2015-result-buffer) + (pgg-text-mode t) (boundary (mml-compute-boundary cont))) (unless (pgg-encrypt-region (point-min) (point-max) (split-string @@ -865,7 +881,7 @@ Valid packages include `pgg', `gpg' and `mailcrypt'.") (erase-buffer) t) (setq mml2015-result-buffer - (gnus-get-buffer-create "*MML2015 Result*")) + (gnus-get-buffer-create " *MML2015 Result*")) nil)) (defsubst mml2015-clear-decrypt-function () diff --git a/lisp/netrc.el b/lisp/netrc.el index dd60fc4..a4c57ef 100644 --- a/lisp/netrc.el +++ b/lisp/netrc.el @@ -1,6 +1,6 @@ ;;; netrc.el --- .netrc parsing functionality -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Modularizer: Ted Zlatanov @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -40,7 +40,8 @@ (autoload 'encrypt-insert-file-contents "encrypt")) (defgroup netrc nil - "Netrc configuration.") + "Netrc configuration." + :group 'comm) (defvar netrc-services-file "/etc/services" "The name of the services file.") diff --git a/lisp/nnagent.el b/lisp/nnagent.el index 5d5cd2a..b334151 100644 --- a/lisp/nnagent.el +++ b/lisp/nnagent.el @@ -1,7 +1,7 @@ ;;; nnagent.el --- offline backend for Gnus -;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 -;; Free Software Foundation, Inc. +;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnbabyl.el b/lisp/nnbabyl.el index 076f451..a0a8d8b 100644 --- a/lisp/nnbabyl.el +++ b/lisp/nnbabyl.el @@ -1,7 +1,7 @@ ;;; nnbabyl.el --- rmail mbox access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1099, 2000, 2001 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1099, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -490,7 +490,7 @@ (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " nil t) (cons (buffer-substring (match-beginning 1) (match-end 1)) - (string-to-int + (string-to-number (buffer-substring (match-beginning 2) (match-end 2))))))) (defun nnbabyl-insert-lines () diff --git a/lisp/nndb.el b/lisp/nndb.el index 082f169..16d1481 100644 --- a/lisp/nndb.el +++ b/lisp/nndb.el @@ -1,6 +1,7 @@ ;;; nndb.el --- nndb access for Gnus -;; Copyright (C) 1997, 1998, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1997, 1998, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Kai Grossjohann @@ -22,8 +23,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -50,7 +51,9 @@ ;;- ;; Register nndb with known select methods. -(gnus-declare-backend "nndb" 'mail 'respool 'address 'prompt-address) +(require 'gnus-start) +(unless (assoc "nndb" gnus-valid-select-methods) + (gnus-declare-backend "nndb" 'mail 'respool 'address 'prompt-address)) ;;; Code: @@ -59,14 +62,6 @@ (require 'nntp) (eval-when-compile (require 'cl)) -(eval-and-compile - (autoload 'news-setup "rnewspost") - (autoload 'news-reply-mode "rnewspost") - (autoload 'cancel-timer "timer") - (autoload 'telnet "telnet" nil t) - (autoload 'telnet-send-input "telnet" nil t) - (autoload 'gnus-declare-backend "gnus-start")) - ;; Declare nndb as derived from nntp (nnoo-declare nndb nntp) @@ -201,7 +196,7 @@ article was posted to nndb") ;; otherwise, pull all of the following numbers into the list (re-search-forward "follows\r?\n?" nil t) (while (re-search-forward "^[0-9]+$" nil t) - (push (string-to-int (match-string 0)) list))) + (push (string-to-number (match-string 0)) list))) list)) (defun nndb-request-expire-articles-remote diff --git a/lisp/nndiary.el b/lisp/nndiary.el index 2aeb55f..1fa9684 100644 --- a/lisp/nndiary.el +++ b/lisp/nndiary.el @@ -1,7 +1,7 @@ -;;; nndiary.el --- A diary backend for Gnus +;;; nndiary.el --- A diary back end for Gnus -;; Copyright (C) 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Didier Verna ;; Maintainer: Didier Verna @@ -22,7 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, write to the Free Software -;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +;; MA 02110-1301, USA. ;;; Commentary: @@ -32,127 +33,8 @@ ;; Description: ;; =========== -;; This package implements NNDiary, a diary backend for Gnus. NNDiary is a -;; mail backend, pretty similar to nnml in its functionnning (it has all the -;; features of nnml, actually), but in which messages are treated as event -;; reminders. - -;; Here is a typical scenario: -;; - You've got a date with Andy Mc Dowell or Bruce Willis (select according -;; to your sexual preference) in one month. You don't want to forget it. -;; - Send a (special) diary message to yourself (see below). -;; - Forget all about it and keep on getting and reading new mail, as usual. -;; - From time to time, as you type `g' in the group buffer and as the date -;; is getting closer, the message will pop up again, just like if it were -;; new and unread. -;; - Read your "new" messages, this one included, and start dreaming of the -;; night you're gonna have. -;; - Once the date is over (you actually fell asleep just after dinner), the -;; message will be automatically deleted if it is marked as expirable. - -;; Some more notes on the diary backend: -;; - NNDiary is a *real* mail backend. You *really* send real diary -;; messsages. This means for instance that you can give appointements to -;; anybody (provided they use Gnus and NNDiary) by sending the diary message -;; to them as well. -;; - However, since NNDiary also has a 'request-post method, you can also -;; `C-u a' instead of `C-u m' on a diary group and the message won't actually -;; be sent; just stored in the group. -;; - The events you want to remember need not be punctual. You can set up -;; reminders for regular dates (like once each week, each monday at 13:30 -;; and so on). Diary messages of this kind will never be deleted (unless -;; you do it explicitely). But that, you guessed. - - -;; Usage: -;; ===== - -;; 1/ NNDiary has two modes of operation: traditional (the default) and -;; autonomous. -;; a/ In traditional mode, NNDiary does not get new mail by itself. You -;; have to move mails from your primary mail backend to nndiary -;; groups. -;; b/ In autonomous mode, NNDiary retrieves its own mail and handles it -;; independantly of your primary mail backend. To use NNDiary in -;; autonomous mode, you have several things to do: -;; i/ Put (setq nndiary-get-new-mail t) in your gnusrc file. -;; ii/ Diary messages contain several `X-Diary-*' special headers. -;; You *must* arrange that these messages be split in a private -;; folder *before* Gnus treat them. You need this because Gnus -;; is not able yet to manage multiple backends for mail -;; retrieval. Getting them from a separate source will -;; compensate this misfeature to some extent, as we will see. -;; As an example, here's my procmailrc entry to store diary files -;; in ~/.nndiary (the default nndiary mail source file): -;; -;; :0 HD : -;; * ^X-Diary -;; .nndiary -;; iii/ Customize the variables `nndiary-mail-sources' and -;; `nndiary-split-methods'. These are replacements for the usual -;; mail sources and split methods which, and will be used in -;; autonomous mode. `nndiary-mail-sources' defaults to -;; '(file :path "~/.nndiary"). -;; 2/ Install nndiary somewhere Emacs / Gnus can find it. Normally, you -;; *don't* have to '(require 'nndiary) anywhere. Gnus will do so when -;; appropriate as long as nndiary is somewhere in the load path. -;; 3/ Now, customize the rest of nndiary. In particular, you should -;; customize `nndiary-reminders', the list of times when you want to be -;; reminded of your appointements (e.g. 3 weeks before, then 2 days -;; before, then 1 hour before and that's it). -;; 4/ You *must* use the group timestamp feature of Gnus. This adds a -;; timestamp to each groups' parameters (please refer to the Gnus -;; documentation ("Group Timestamp" info node) to see how it's done. -;; 5/ Once you have done this, you may add a permanent nndiary virtual server -;; (something like '(nndiary "")) to your `gnus-secondary-select-methods'. -;; Yes, this server will be able to retrieve mails and split them when you -;; type `g' in the group buffer, just as if it were your only mail backend. -;; This is the benefit of using a private folder. -;; 6/ Hopefully, almost everything (see the TODO section below) will work as -;; expected when you restart Gnus: in the group buffer, `g' and `M-g' will -;; also get your new diary mails, `F' will find your new diary groups etc. - - -;; How to send diary messages: -;; ========================== - -;; There are 7 special headers in diary messages. These headers are of the -;; form `X-Diary-', the being one of `Minute', `Hour', -;; `Dom', `Month', `Year', `Time-Zone' and `Dow'. `Dom' means "Day of Month", -;; and `dow' means "Day of Week". These headers actually behave like crontab -;; specifications and define the event date(s). - -;; For all headers but the `Time-Zone' one, a header value is either a -;; star (meaning all possible values), or a list of fields (separated by a -;; comma). A field is either an integer, or a range. A range is two integers -;; separated by a dash. Possible integer values are 0-59 for `Minute', 0-23 -;; for `Hour', 1-31 for `Dom', `1-12' for Month, above 1971 for `Year' and 0-6 -;; for `Dow' (0 = sunday). As a special case, a star in either `Dom' or `Dow' -;; doesn't mean "all possible values", but "use only the other field". Note -;; that if both are star'ed, the use of either one gives the same result :-), - -;; The `Time-Zone' header is special in that it can have only one value (you -;; bet ;-). -;; A star doesn't mean "all possible values" (because it has no sense), but -;; "the current local time zone". - -;; As an example, here's how you would say "Each Monday and each 1st of month, -;; at 12:00, 20:00, 21:00, 22:00, 23:00 and 24:00, from 1999 to 2010" (I let -;; you find what to do then): -;; -;; X-Diary-Minute: 0 -;; X-Diary-Hour: 12, 20-24 -;; X-Diary-Dom: 1 -;; X-Diary-Month: * -;; X-Diary-Year: 1999-2010 -;; X-Diary-Dow: 1 -;; X-Diary-Time-Zone: * -;; -;; -;; Sending a diary message is not different from sending any other kind of -;; mail, except that such messages are identified by the presence of these -;; special headers. - +;; nndiary is a mail back end designed to handle mails as diary event +;; reminders. It is now fully documented in the Gnus manual. ;; Bugs / Todo: @@ -160,43 +42,43 @@ ;; * Respooling doesn't work because contrary to the request-scan function, ;; Gnus won't allow me to override the split methods when calling the -;; respooling backend functions. +;; respooling back end functions. ;; * There's a bug in the time zone mechanism with variable TZ locations. ;; * We could allow a keyword like `ask' in X-Diary-* headers, that would mean ;; "ask for value upon reception of the message". ;; * We could add an optional header X-Diary-Reminders to specify a special ;; reminders value for this message. Suggested by Jody Klymak. ;; * We should check messages validity in other circumstances than just -;; moving an article from sonwhere else (request-accept). For instance, when -;; editing / saving and so on. +;; moving an article from somewhere else (request-accept). For instance, +;; when editing / saving and so on. ;; Remarks: ;; ======= -;; * nnoo. -;; NNDiary is very similar to nnml. This makes the idea of using nnoo (to -;; derive nndiary from nnml) natural. However, my experience with nnoo is -;; that for reasonably complex backends like this one, noo is a burden -;; rather than an help. It's tricky to use, not everything can be -;; inherited, what can be inherited and when is not very clear, and you've -;; got to be very careful because a little mistake can fuck up your your -;; other backends, especially because their variables will be use instead of -;; your real ones. Finally, I found it easier to just clone the needed -;; parts of nnml, and tracking nnml updates is not a big deal. +;; * nnoo. NNDiary is very similar to nnml. This makes the idea of using nnoo +;; (to derive nndiary from nnml) natural. However, my experience with nnoo +;; is that for reasonably complex back ends like this one, noo is a burden +;; rather than an help. It's tricky to use, not everything can be inherited, +;; what can be inherited and when is not very clear, and you've got to be +;; very careful because a little mistake can fuck up your other back ends, +;; especially because their variables will be use instead of your real ones. +;; Finally, I found it easier to just clone the needed parts of nnml, and +;; tracking nnml updates is not a big deal. ;; IMHO, nnoo is actually badly designed. A much simpler, and yet more ;; powerful one would be to make *real* functions and variables for a new -;; backend based on another. Lisp is a reflexive language so that's a very +;; back end based on another. Lisp is a reflexive language so that's a very ;; easy thing to do: inspect the function's form, replace occurences of ;; (even in strings) with , and you're done. ;; * nndiary-get-new-mail, nndiary-mail-source and nndiary-split-methods: ;; NNDiary has some experimental parts, in the sense Gnus normally uses only -;; one mail backends for mail retreival and splitting. This backend is also -;; an attempt to make it behave differently. For Gnus developpers: as you -;; can see if you snarf into the code, that was not a very difficult thing -;; to do. Something should be done about the respooling breakage though. +;; one mail back ends for mail retreival and splitting. This back end is +;; also an attempt to make it behave differently. For Gnus developpers: as +;; you can see if you snarf into the code, that was not a very difficult +;; thing to do. Something should be done about the respooling breakage +;; though. ;;; Code: @@ -219,10 +101,10 @@ (apply #'error args)))) -;; Backend behavior customization =========================================== +;; Back End behavior customization =========================================== (defgroup nndiary nil - "The Gnus Diary backend." + "The Gnus Diary back end." :version "22.1" :group 'gnus-diary) @@ -325,27 +207,27 @@ The hooks will be called with the article in the current buffer." :type 'boolean) -;; Backend declaration ====================================================== +;; Back End declaration ====================================================== ;; Well, most of this is nnml clonage. (nnoo-declare nndiary) (defvoo nndiary-directory (nnheader-concat gnus-directory "diary/") - "Spool directory for the nndiary backend.") + "Spool directory for the nndiary back end.") (defvoo nndiary-active-file (expand-file-name "active" nndiary-directory) - "Active file for the nndiary backend.") + "Active file for the nndiary back end.") (defvoo nndiary-newsgroups-file (expand-file-name "newsgroups" nndiary-directory) - "Newsgroups description file for the nndiary backend.") + "Newsgroups description file for the nndiary back end.") (defvoo nndiary-get-new-mail nil "Whether nndiary gets new mail and split it. -Contrary to traditional mail backends, this variable can be set to t -even if your primary mail backend also retreives mail. In such a case, +Contrary to traditional mail back ends, this variable can be set to t +even if your primary mail back end also retreives mail. In such a case, NDiary uses its own mail-sources and split-methods.") (defvoo nndiary-nov-is-evil nil @@ -366,10 +248,10 @@ all. This may very well take some time.") (defconst nndiary-version "0.2-b14" - "Current Diary backend version.") + "Current Diary back end version.") (defun nndiary-version () - "Current Diary backend version." + "Current Diary back end version." (interactive) (message "NNDiary version %s" nndiary-version)) @@ -601,7 +483,7 @@ all. This may very well take some time.") (nnheader-report 'nndiary "Article %s retrieved" id) ;; We return the article number. (cons (if group-num (car group-num) group) - (string-to-int (file-name-nondirectory path))))))) + (string-to-number (file-name-nondirectory path))))))) (deffoo nndiary-request-group (group &optional server dont-check) (let ((file-name-coding-system nnmail-pathname-coding-system)) @@ -630,7 +512,7 @@ all. This may very well take some time.") (deffoo nndiary-request-scan (&optional group server) ;; Use our own mail sources and split methods while Gnus doesn't let us have - ;; multiple backends for retrieving mail. + ;; multiple back ends for retrieving mail. (let ((mail-sources nndiary-mail-sources) (nnmail-split-methods nndiary-split-methods)) (setq nndiary-article-file-alist nil) @@ -820,7 +702,7 @@ all. This may very well take some time.") ;; we should insert it. (This situation should never ;; occur, but one likes to make sure...) (while (and (looking-at "[0-9]+\t") - (< (string-to-int + (< (string-to-number (buffer-substring (match-beginning 0) (match-end 0))) article) @@ -1279,14 +1161,14 @@ all. This may very well take some time.") (nnheader-article-to-file-alist nndiary-current-directory)))) -(defun nndiary-string-to-int (str min &optional max) - ;; Like `string-to-int' but barf if STR is not exactly an integer, and not +(defun nndiary-string-to-number (str min &optional max) + ;; Like `string-to-number' but barf if STR is not exactly an integer, and not ;; within the specified bounds. ;; Signals are caught by `nndiary-schedule'. (if (not (string-match "^[ \t]*[0-9]+[ \t]*$" str)) (nndiary-error "not an integer value") ;; else - (let ((val (string-to-int str))) + (let ((val (string-to-number str))) (and (or (< val min) (and max (> val max))) (nndiary-error "value out of range")) @@ -1313,12 +1195,12 @@ all. This may very well take some time.") (let ((res (split-string val "-"))) (cond ((= (length res) 1) - (nndiary-string-to-int (car res) min-or-values max)) + (nndiary-string-to-number (car res) min-or-values max)) ((= (length res) 2) ;; don't know if crontab accepts this, but ensure ;; that BEG is <= END - (let ((beg (nndiary-string-to-int (car res) min-or-values max)) - (end (nndiary-string-to-int (cadr res) min-or-values max))) + (let ((beg (nndiary-string-to-number (car res) min-or-values max)) + (end (nndiary-string-to-number (cadr res) min-or-values max))) (cond ((< beg end) (cons beg end)) ((= beg end) diff --git a/lisp/nndir.el b/lisp/nndir.el index b72a152..ec47c94 100644 --- a/lisp/nndir.el +++ b/lisp/nndir.el @@ -1,7 +1,7 @@ ;;; nndir.el --- single directory newsgroup access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nndoc.el b/lisp/nndoc.el index 47a3cbd..764f085 100644 --- a/lisp/nndoc.el +++ b/lisp/nndoc.el @@ -1,6 +1,7 @@ ;;; nndoc.el --- single file access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -421,7 +422,7 @@ from the document.") (search-forward "\n\n" beg t) (re-search-backward "^Content-Length:[ \t]*\\([0-9]+\\) *$" end t) - (setq len (string-to-int (match-string 1))) + (setq len (string-to-number (match-string 1))) (search-forward "\n\n" beg t) (unless (= (setq len (+ (point) len)) (point-max)) (and (< len (point-max)) @@ -444,7 +445,7 @@ from the document.") (defun nndoc-rnews-body-end () (and (re-search-backward nndoc-article-begin nil t) (forward-line 1) - (goto-char (+ (point) (string-to-int (match-string 1)))))) + (goto-char (+ (point) (string-to-number (match-string 1)))))) (defun nndoc-babyl-type-p () (when (re-search-forward "\^_\^L *\n" nil t) diff --git a/lisp/nndraft.el b/lisp/nndraft.el index 95ff037..f7ab938 100644 --- a/lisp/nndraft.el +++ b/lisp/nndraft.el @@ -1,7 +1,7 @@ ;;; nndraft.el --- draft article access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -174,8 +174,11 @@ (setq buffer-file-name (expand-file-name file) buffer-auto-save-file-name (make-auto-save-file-name)) (clear-visited-file-modtime) - (make-local-variable 'write-contents-hooks) - (push 'nndraft-generate-headers write-contents-hooks) + (let ((hook (if (boundp 'write-contents-functions) + 'write-contents-functions + 'write-contents-hooks))) + (gnus-make-local-hook hook) + (add-hook hook 'nndraft-generate-headers nil t)) article)) (deffoo nndraft-request-group (group &optional server dont-check) @@ -185,7 +188,7 @@ (file-name-coding-system nnmail-pathname-coding-system) dir file) (nnheader-re-read-dir pathname) - (setq dir (mapcar (lambda (name) (string-to-int (substring name 1))) + (setq dir (mapcar (lambda (name) (string-to-number (substring name 1))) (ignore-errors (directory-files pathname nil "^#[0-9]+#$" t)))) (dolist (n dir) @@ -293,7 +296,7 @@ "Return the list of messages in the group." (gnus-make-directory nndraft-current-directory) (sort - (mapcar 'string-to-int + (mapcar 'string-to-number (directory-files nndraft-current-directory nil "\\`[0-9]+\\'" t)) '<)) diff --git a/lisp/nneething.el b/lisp/nneething.el index e3b3d34..844b03b 100644 --- a/lisp/nneething.el +++ b/lisp/nneething.el @@ -1,7 +1,7 @@ ;;; nneething.el --- arbitrary file access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -329,7 +329,7 @@ included.") (when (re-search-forward "<[a-zA-Z0-9_]@[-a-zA-Z0-9_]>" 1000 t) (concat "From: " (match-string 0) "\n")))) (nneething-from-line (nth 2 atts) file)) - (if (> (string-to-int (int-to-string (nth 7 atts))) 0) + (if (> (string-to-number (int-to-string (nth 7 atts))) 0) (concat "Chars: " (int-to-string (nth 7 atts)) "\n") "") (if buffer diff --git a/lisp/nnfolder.el b/lisp/nnfolder.el index 9b25ea1..b4019d9 100644 --- a/lisp/nnfolder.el +++ b/lisp/nnfolder.el @@ -1,6 +1,7 @@ ;;; nnfolder.el --- mail folder access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson (adding MARKS) ;; ShengHuo Zhu (adding NOV) @@ -23,8 +24,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -200,7 +201,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") ((search-backward (concat "\n" nnfolder-article-marker) nil t) (goto-char (match-end 0)) - (setq num (string-to-int + (setq num (string-to-number (buffer-substring (point) (point-at-eol)))) (goto-char start) @@ -210,7 +211,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") (search-forward (concat "\n" nnfolder-article-marker) nil t) (progn - (setq num (string-to-int + (setq num (string-to-number (buffer-substring (point) (point-at-eol)))) (> num article)) @@ -285,7 +286,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") (cons nnfolder-current-group (if (search-forward (concat "\n" nnfolder-article-marker) nil t) - (string-to-int (buffer-substring + (string-to-number (buffer-substring (point) (point-at-eol))) -1)))))))) @@ -825,7 +826,7 @@ deleted. Point is left where the deleted region was." (insert "\n")) (forward-char -1) (insert (format (concat nnfolder-article-marker "%d %s\n") - (cdr group-art) (current-time-string))))) + (cdr group-art) (message-make-date))))) (defun nnfolder-active-number (group) ;; Find the next article number in GROUP. @@ -875,6 +876,7 @@ deleted. Point is left where the deleted region was." nnfolder-file-coding-system)) (nnheader-find-file-noselect file t))))) (mm-enable-multibyte) ;; Use multibyte buffer for future copying. + (buffer-disable-undo) (if (equal (cadr (assoc group nnfolder-scantime-alist)) (nth 5 (file-attributes file))) ;; This looks up-to-date, so we don't do any scanning. @@ -901,7 +903,6 @@ deleted. Point is left where the deleted region was." maxid start end newscantime novbuf articles newnum buffer-read-only) - (buffer-disable-undo) (setq maxid (cdr active)) (unless (or gnus-nov-is-evil nnfolder-nov-is-evil @@ -1070,7 +1071,8 @@ This command does not work if you use short group names." (gnus-make-directory (file-name-directory (buffer-file-name))) (let ((coding-system-for-write (or nnfolder-file-coding-system-for-write - nnfolder-file-coding-system))) + nnfolder-file-coding-system)) + (copyright-update nil)) (save-buffer))) (unless (or gnus-nov-is-evil nnfolder-nov-is-evil) (nnfolder-save-nov))) diff --git a/lisp/nngateway.el b/lisp/nngateway.el index f690369..2f4e33d 100644 --- a/lisp/nngateway.el +++ b/lisp/nngateway.el @@ -1,7 +1,7 @@ ;;; nngateway.el --- posting news via mail gateways -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnheader.el b/lisp/nnheader.el index e4b7746..dc1f090 100644 --- a/lisp/nnheader.el +++ b/lisp/nnheader.el @@ -1,8 +1,8 @@ ;;; nnheader.el --- header access macros for Gnus and its backends -;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, -;; 1997, 1998, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, +;; 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -22,8 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,6 +31,8 @@ (eval-when-compile (require 'cl)) +(defvar nnmail-extra-headers) + ;; Requiring `gnus-util' at compile time creates a circular ;; dependency between nnheader.el and gnus-util.el. ;;(eval-when-compile (require 'gnus-util)) @@ -206,9 +208,9 @@ on your system, you could say something like: "Return the extra headers in HEADER." `(aref ,header 9)) -(defmacro mail-header-set-extra (header extra) +(defun mail-header-set-extra (header extra) "Set the extra headers in HEADER to EXTRA." - `(aset ,header 9 ',extra)) + (aset header 9 extra)) (defsubst make-mail-header (&optional init) "Create a new mail header structure initialized with INIT." @@ -702,9 +704,9 @@ the line could be found." (defsubst nnheader-file-to-number (file) "Take a FILE name and return the article number." (if (string= nnheader-numerical-short-files "^[0-9]+$") - (string-to-int file) + (string-to-number file) (string-match nnheader-numerical-short-files file) - (string-to-int (match-string 0 file)))) + (string-to-number (match-string 0 file)))) (defvar nnheader-directory-files-is-safe (or (eq system-type 'windows-nt) @@ -971,15 +973,21 @@ find-file-hooks, etc. (defun nnheader-find-file-noselect (&rest args) "Open a file with some variables bound. See `find-file-noselect' for the arguments." - (let ((format-alist nil) - (auto-mode-alist (mm-auto-mode-alist)) - (default-major-mode 'fundamental-mode) - (enable-local-variables nil) - (after-insert-file-functions nil) - (enable-local-eval nil) - (find-file-hooks nil) - (coding-system-for-read nnheader-file-coding-system)) - (apply 'find-file-noselect args))) + (let* ((format-alist nil) + (auto-mode-alist (mm-auto-mode-alist)) + (default-major-mode 'fundamental-mode) + (enable-local-variables nil) + (after-insert-file-functions nil) + (enable-local-eval nil) + (coding-system-for-read nnheader-file-coding-system) + (ffh (if (boundp 'find-file-hook) + 'find-file-hook + 'find-file-hooks)) + (val (symbol-value ffh))) + (set ffh nil) + (unwind-protect + (apply 'find-file-noselect args) + (set ffh val)))) (defun nnheader-directory-regular-files (dir) "Return a list of all regular files in DIR." diff --git a/lisp/nnheaderxm.el b/lisp/nnheaderxm.el index 34ecb84..2cd0916 100644 --- a/lisp/nnheaderxm.el +++ b/lisp/nnheaderxm.el @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnimap.el b/lisp/nnimap.el index 12f9ef8..6144f14 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -1,6 +1,7 @@ ;;; nnimap.el --- imap backend for Gnus -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Jim Radford @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -205,7 +206,7 @@ RFC2060 section 6.4.4." "Whether to download entire articles during splitting. This is generally not required, and will slow things down considerably. You may need it if you want to use an advanced splitting function that -analyses the body before splitting the article. +analyzes the body before splitting the article. If this variable is nil, bodies will not be downloaded; if this variable is the symbol `default' the default behaviour is used (which currently is nil, unless you use a statistical @@ -316,6 +317,11 @@ every message in the group, thus making it quite slow. Unlike other backends, you do not need to take special care if you flip this variable.") +(defvoo nnimap-search-uids-not-since-is-evil nil + "If non-nil, avoid \"UID SEARCH UID ... NOT SINCE\" queries when expiring. +Instead, use \"UID SEARCH SINCE\" to prune the list of expirable +articles within Gnus. This seems to be faster on Courier in some cases.") + (defvoo nnimap-expunge-on-close 'always ; 'ask, 'never "Whether to expunge a group when it is closed. When a IMAP group with articles marked for deletion is closed, this @@ -779,7 +785,7 @@ If EXAMINE is non-nil the group is selected read-only." (port (if nnimap-server-port (int-to-string nnimap-server-port) "imap")) - (user (netrc-machine-user-or-password + (user (netrc-machine-user-or-password "login" list (list server @@ -787,7 +793,7 @@ If EXAMINE is non-nil the group is selected read-only." nnimap-address)) (list port) (list "imap" "imaps"))) - (passwd (netrc-machine-user-or-password + (passwd (netrc-machine-user-or-password "password" list (list server @@ -798,7 +804,7 @@ If EXAMINE is non-nil the group is selected read-only." (if (imap-authenticate user passwd nnimap-server-buffer) (prog2 (setq nnimap-server-buffer-alist - (nnimap-remove-server-from-buffer-alist + (nnimap-remove-server-from-buffer-alist server nnimap-server-buffer-alist)) (push (list server nnimap-server-buffer) @@ -857,7 +863,7 @@ Return nil if the server couldn't be closed for some reason." (setq nnimap-server-buffer nil nnimap-current-server nil nnimap-server-buffer-alist - (nnimap-remove-server-from-buffer-alist + (nnimap-remove-server-from-buffer-alist server nnimap-server-buffer-alist))) (nnoo-close-server 'nnimap server))) @@ -1177,18 +1183,12 @@ function is generally only called when Gnus is shutting down." (let (seen unseen) ;; read info could contain articles marked unread by other ;; imap clients! we correct this - (setq seen (gnus-uncompress-range (gnus-info-read info)) - unseen (imap-search "UNSEEN UNDELETED") - seen (gnus-set-difference seen unseen) - ;; seen might lack articles marked as read by other - ;; imap clients! we correct this - seen (append seen (imap-search "SEEN")) - ;; remove dupes - seen (sort seen '<) - seen (gnus-compress-sequence seen t) - ;; we can't return '(1) since this isn't a "list of ranges", - ;; and we can't return '((1)) since g-list-of-unread-articles - ;; is buggy so we return '((1 . 1)). + (setq unseen (gnus-compress-sequence + (imap-search "UNSEEN UNDELETED")) + seen (gnus-range-difference (gnus-info-read info) unseen) + seen (gnus-range-add seen + (gnus-compress-sequence + (imap-search "SEEN"))) seen (if (and (integerp (car seen)) (null (cdr seen))) (list (cons (car seen) (car seen))) @@ -1493,6 +1493,21 @@ function is generally only called when Gnus is shutting down." (gnus-compress-sequence oldarts)) "\\Deleted") (setq articles (gnus-set-difference articles oldarts)))))) + ((and nnimap-search-uids-not-since-is-evil (numberp days)) + (let* ((all-new-articles + (gnus-compress-sequence + (imap-search (format "SINCE %s" + (nnimap-date-days-ago days))))) + (oldartseq + (gnus-range-difference artseq all-new-articles)) + (oldarts (gnus-uncompress-range oldartseq))) + (when oldarts + (nnimap-expiry-target oldarts group server) + (when (imap-message-flags-add + (imap-range-to-message-set oldartseq) + "\\Deleted") + (setq articles (gnus-set-difference + articles oldarts)))))) ((numberp days) (let ((oldarts (imap-search (format nnimap-expunge-search-string @@ -1510,7 +1525,7 @@ function is generally only called when Gnus is shutting down." ;; return articles not deleted articles) -(deffoo nnimap-request-move-article (article group server accept-form +(deffoo nnimap-request-move-article (article group server accept-form &optional last move-is-internal) (when (nnimap-possibly-change-server server) (save-excursion @@ -1533,6 +1548,7 @@ function is generally only called when Gnus is shutting down." (setq result (eval accept-form)) (kill-buffer buf) result) + (nnimap-possibly-change-group group server) (imap-message-flags-add (imap-range-to-message-set (list article)) "\\Deleted" 'silent nnimap-server-buffer)) diff --git a/lisp/nnkiboze.el b/lisp/nnkiboze.el index f14f6ca..9e176f3 100644 --- a/lisp/nnkiboze.el +++ b/lisp/nnkiboze.el @@ -1,7 +1,7 @@ ;;; nnkiboze.el --- select virtual news access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -106,7 +106,7 @@ (error "nnkiboze: No xref")) (unless (string-match " \\([^ ]+\\):\\([0-9]+\\)" xref) (error "nnkiboze: Malformed xref")) - (setq num (string-to-int (match-string 2 xref)) + (setq num (string-to-number (match-string 2 xref)) group (match-string 1 xref)) (or (with-current-buffer buffer (or (and gnus-use-cache (gnus-cache-request-article num group)) diff --git a/lisp/nnlistserv.el b/lisp/nnlistserv.el index 770bb02..3ee8f42 100644 --- a/lisp/nnlistserv.el +++ b/lisp/nnlistserv.el @@ -1,6 +1,7 @@ ;;; nnlistserv.el --- retrieving articles via web mailing list archives -;; Copyright (C) 1997, 1998, 1999, 2000, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1997, 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnmail.el b/lisp/nnmail.el index b522c1c..65349ea 100644 --- a/lisp/nnmail.el +++ b/lisp/nnmail.el @@ -1,6 +1,7 @@ ;;; nnmail.el --- mail support functions for the Gnus mail backends -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -48,7 +49,7 @@ :group 'nnmail) (defgroup nnmail-prepare nil - "Preparing (or mangling) new mail after retrival." + "Preparing (or mangling) new mail after retrieval." :group 'nnmail) (defgroup nnmail-duplicate nil @@ -768,7 +769,7 @@ If SOURCE is a directory spec, try to return the group name component." (if (not (save-excursion (and (re-search-backward "^Content-Length:[ \t]*\\([0-9]+\\)" start t) - (setq content-length (string-to-int + (setq content-length (string-to-number (buffer-substring (match-beginning 1) (match-end 1)))) @@ -905,7 +906,7 @@ If SOURCE is a directory spec, try to return the group name component." (if (not (re-search-forward "^Content-Length:[ \t]*\\([0-9]+\\)" nil t)) (setq content-length nil) - (setq content-length (string-to-int (match-string 1))) + (setq content-length (string-to-number (match-string 1))) ;; We destroy the header, since none of the backends ever ;; use it, and we do not want to confuse other mailers by ;; having a (possibly) faulty header. @@ -1140,7 +1141,7 @@ FUNC will be called with the group name to determine the article number." 5 "Error in `nnmail-split-methods'; using `bogus' mail group") (sit-for 1) '("bogus"))))) - (setq split (gnus-remove-duplicates split)) + (setq split (mm-delete-duplicates split)) ;; The article may be "cross-posted" to `junk'. What ;; to do? Just remove the `junk' spec. Don't really ;; see anything else to do... @@ -1419,11 +1420,12 @@ See the documentation for the variable `nnmail-split-fancy' for details." ;; Not in cache, compute a regexp for the field/value pair. (t - (let* ((field (nth 0 split)) - (value (nth 1 split)) - partial-front - partial-rear - regexp) + (let ((field (nth 0 split)) + (value (nth 1 split)) + (split-rest (cddr split)) + partial-front + partial-rear + regexp) (if (symbolp value) (setq value (cdr (assq value nnmail-split-abbrev-alist)))) (if (and (>= (length value) 2) @@ -1435,7 +1437,13 @@ See the documentation for the variable `nnmail-split-fancy' for details." (string= ".*" (substring value -2))) (setq value (substring value 0 -2) partial-rear "")) - (when nnmail-split-fancy-match-partial-words + ;; Invert the match-partial-words behavior if the optional + ;; last element is specified. + (while (eq (car split-rest) '-) + (setq split-rest (cddr split-rest))) + (when (if (cadr split-rest) + (not nnmail-split-fancy-match-partial-words) + nnmail-split-fancy-match-partial-words) (setq partial-front "" partial-rear "")) (setq regexp (concat "^\\(\\(" @@ -1450,7 +1458,7 @@ See the documentation for the variable `nnmail-split-fancy' for details." (or partial-rear "\\>"))) (push (cons split regexp) nnmail-split-cache) ;; Now that it's in the cache, just call nnmail-split-it again - ;; on the same split, which will find it immediately in the cache. + ;; on the same split, which will find it immediately in the cache. (nnmail-split-it split)))))) (defun nnmail-expand-newtext (newtext) @@ -1866,9 +1874,15 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (case-fold-search nil) (from (or (message-fetch-field "from") "")) (to (or (message-fetch-field "to") "")) - (date (date-to-time - (or (message-fetch-field "date") (current-time-string)))) + (date (message-fetch-field "date")) (target 'delete)) + (setq date (if date + (condition-case err + (date-to-time date) + (error + (message "%s" (error-message-string err)) + (current-time))) + (current-time))) (dolist (regexp-target-pair (reverse nnmail-fancy-expiry-targets) target) (setq header (car regexp-target-pair)) (cond diff --git a/lisp/nnmaildir.el b/lisp/nnmaildir.el index b4c799e..2a8f885 100644 --- a/lisp/nnmaildir.el +++ b/lisp/nnmaildir.el @@ -17,8 +17,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnmbox.el b/lisp/nnmbox.el index 93172b7..b0905f3 100644 --- a/lisp/nnmbox.el +++ b/lisp/nnmbox.el @@ -1,7 +1,7 @@ ;;; nnmbox.el --- mail mbox access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -16,8 +16,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -475,7 +475,7 @@ (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " nil t) (cons (buffer-substring (match-beginning 1) (match-end 1)) - (string-to-int + (string-to-number (buffer-substring (match-beginning 2) (match-end 2))))))) (defun nnmbox-in-header-p (pos) @@ -681,7 +681,7 @@ (let (alist) (while (re-search-forward " \\([^:]+\\):\\([0-9]+\\)" end-header t) (push (cons (match-string 1) - (string-to-int (match-string 2))) alist)) + (string-to-number (match-string 2))) alist)) (nnmbox-insert-newsgroup-line alist)) ;; this is really a new article (nnmbox-save-mail diff --git a/lisp/nnmh.el b/lisp/nnmh.el index 7bc5221..c631d87 100644 --- a/lisp/nnmh.el +++ b/lisp/nnmh.el @@ -1,7 +1,7 @@ ;;; nnmh.el --- mhspool access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -150,7 +150,7 @@ as unread by Gnus.") (file-exists-p file) (not (file-directory-p file)) (save-excursion (nnmail-find-file file)) - (string-to-int (file-name-nondirectory file))))) + (string-to-number (file-name-nondirectory file))))) (deffoo nnmh-request-group (group &optional server dont-check) (nnheader-init-server-buffer) @@ -176,7 +176,7 @@ as unread by Gnus.") (nnheader-re-read-dir pathname) (setq dir (sort - (mapcar 'string-to-int + (mapcar 'string-to-number (directory-files pathname nil "^[0-9]+$" t)) '<)) (cond @@ -222,7 +222,7 @@ as unread by Gnus.") (nnmh-request-list-1 rdir)))) ;; For each directory, generate an active file line. (unless (string= (expand-file-name nnmh-toplev) dir) - (let ((files (mapcar 'string-to-int + (let ((files (mapcar 'string-to-number (directory-files dir nil "^[0-9]+$" t)))) (when files (save-excursion @@ -354,7 +354,7 @@ as unread by Gnus.") nnmh-group-alist) (nnmh-possibly-create-directory group) (nnmh-possibly-change-directory group server) - (let ((articles (mapcar 'string-to-int + (let ((articles (mapcar 'string-to-number (directory-files nnmh-current-directory nil "^[0-9]+$")))) (when articles @@ -480,7 +480,7 @@ as unread by Gnus.") (gnus-make-directory dir)) ;; Find the highest number in the group. (let ((files (sort - (mapcar 'string-to-int + (mapcar 'string-to-number (directory-files dir nil "^[0-9]+$")) '>))) (when files @@ -503,7 +503,7 @@ as unread by Gnus.") ;; articles in this folder. The articles that are "new" will be ;; marked as unread by Gnus. (let* ((dir nnmh-current-directory) - (files (sort (mapcar 'string-to-int + (files (sort (mapcar 'string-to-number (directory-files nnmh-current-directory nil "^[0-9]+$" t)) '<)) diff --git a/lisp/nnml.el b/lisp/nnml.el index b99f47b..f189361 100644 --- a/lisp/nnml.el +++ b/lisp/nnml.el @@ -1,9 +1,11 @@ ;;; nnml.el --- mail spool access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 -;; Free Software Foundation, Inc. -;; Author: Simon Josefsson (adding MARKS) -;; Lars Magne Ingebrigtsen +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. + +;; Authors: Didier Verna (adding compaction) +;; Simon Josefsson (adding MARKS) +;; Lars Magne Ingebrigtsen ;; Masanobu UMEDA ;; Keywords: news, mail @@ -21,8 +23,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -39,7 +41,8 @@ (eval-when-compile (require 'cl)) (eval-and-compile - (autoload 'gnus-article-unpropagatable-p "gnus-sum")) + (autoload 'gnus-article-unpropagatable-p "gnus-sum") + (autoload 'gnus-backlog-remove-article "gnus-bcklg")) (nnoo-declare nnml) @@ -82,7 +85,18 @@ marks file will be regenerated properly by Gnus.") "If non-nil, inhibit expiry.") (defvoo nnml-use-compressed-files nil - "If non-nil, allow using compressed message files.") + "If non-nil, allow using compressed message files. + +If it is a string, use it as the file extension which specifies +the comression program. You can set it to \".bz2\" if your Emacs +supports auto-compression using the bzip2 program. A value of t +is equivalent to \".gz\".") + +(defvoo nnml-compressed-files-size-threshold 1000 + "Default size threshold for compressed message files. +Message files with bodies larger than that many characters will +be automatically compressed if `nnml-use-compressed-files' is +non-nil.") @@ -212,7 +226,7 @@ marks file will be regenerated properly by Gnus.") (nnheader-report 'nnml "Article %s retrieved" id) ;; We return the article number. (cons (if group-num (car group-num) group) - (string-to-int (file-name-nondirectory path))))))) + (string-to-number (file-name-nondirectory path))))))) (deffoo nnml-request-group (group &optional server dont-check) (let ((file-name-coding-system nnmail-pathname-coding-system)) @@ -369,7 +383,7 @@ marks file will be regenerated properly by Gnus.") (nnmail-check-syntax) (let (result) (when nnmail-cache-accepted-message-ids - (nnmail-cache-insert (nnmail-fetch-field "message-id") + (nnmail-cache-insert (nnmail-fetch-field "message-id") group (nnmail-fetch-field "subject") (nnmail-fetch-field "from"))) @@ -426,7 +440,7 @@ marks file will be regenerated properly by Gnus.") ;; we should insert it. (This situation should never ;; occur, but one likes to make sure...) (while (and (looking-at "[0-9]+\t") - (< (string-to-int + (< (string-to-number (buffer-substring (match-beginning 0) (match-end 0))) article) @@ -621,8 +635,10 @@ marks file will be regenerated properly by Gnus.") (setq chars (nnmail-insert-lines)) (setq extension (and nnml-use-compressed-files - (> chars 1000) - ".gz")) + (> chars nnml-compressed-files-size-threshold) + (if (stringp nnml-use-compressed-files) + nnml-use-compressed-files + ".gz"))) (nnmail-insert-xref group-art) (run-hooks 'nnmail-prepare-save-mail-hook) (run-hooks 'nnml-prepare-save-mail-hook) @@ -754,12 +770,14 @@ marks file will be regenerated properly by Gnus.") (nnml-open-server server)) (setq nnml-directory (expand-file-name nnml-directory)) ;; Recurse down the directories. - (nnml-generate-nov-databases-1 nnml-directory nil t) + (nnml-generate-nov-databases-directory nnml-directory nil t) ;; Save the active file. (nnmail-save-active nnml-group-alist nnml-active-file)) -(defun nnml-generate-nov-databases-1 (dir &optional seen no-active) - "Regenerate the NOV database in DIR." +(defun nnml-generate-nov-databases-directory (dir &optional seen no-active) + "Regenerate the NOV database in DIR. + +Unless no-active is non-nil, update the active file too." (interactive "DRegenerate NOV in: ") (setq dir (file-name-as-directory dir)) ;; Only scan this sub-tree if we haven't been here yet. @@ -769,7 +787,7 @@ marks file will be regenerated properly by Gnus.") (dolist (dir (directory-files dir t nil t)) (when (and (not (string-match "^\\." (file-name-nondirectory dir))) (file-directory-p dir)) - (nnml-generate-nov-databases-1 dir seen))) + (nnml-generate-nov-databases-directory dir seen))) ;; Do this directory. (let ((files (sort (nnheader-article-to-file-alist dir) 'car-less-than-car))) @@ -1008,6 +1026,193 @@ Use the nov database for the current group if available." (nnml-save-marks group server) (nnheader-message 7 "Bootstrapping marks for %s...done" group))))) + +;;; +;;; Group and server compaction. -- dvl +;;; + +;; #### FIXME: this function handles self Xref: entry correctly, but I don't +;; #### know how to handle external cross-references. I actually don't know if +;; #### this is handled correctly elsewhere. For instance, what happens if you +;; #### move all articles to a new group (that's what people do for manual +;; #### compaction) ? + +;; #### NOTE: the function below handles the article backlog. This is +;; #### conceptually the wrong place to do it because the backend is at a +;; #### lower level. However, this is the only place where we have the needed +;; #### information to do the job. Ideally, this function should not handle +;; #### the backlog by itself, but return a list of moved groups / articles to +;; #### the caller. This will become important to avoid code duplication when +;; #### other backends get a compaction feature. Also, note that invalidating +;; #### the "original article buffer" is already done at an upper level. + +;; Shouldn't `nnml-request-compact-group' be interactive? --rsteib + +(defun nnml-request-compact-group (group &optional server save) + (nnml-possibly-change-directory group server) + (unless nnml-article-file-alist + (setq nnml-article-file-alist + (sort (nnml-current-group-article-to-file-alist) + 'car-less-than-car))) + (if (not nnml-article-file-alist) + ;; The group is empty: do nothing but return t + t + ;; The group is not empty: + (let* ((group-full-name + (gnus-group-prefixed-name + group + (gnus-server-to-method (format "nnml:%s" server)))) + (info (gnus-get-info group-full-name)) + (new-number 1) + compacted) + (let ((articles nnml-article-file-alist) + article) + (while (setq article (pop articles)) + (let ((old-number (car article))) + (when (> old-number new-number) + ;; There is a gap here: + (let ((old-number-string (int-to-string old-number)) + (new-number-string (int-to-string new-number))) + (setq compacted t) + ;; #### NOTE: `nnml-article-to-file' calls + ;; #### `nnml-update-file-alist' (which in turn calls + ;; #### `nnml-current-group-article-to-file-alist', which + ;; #### might use the NOV database). This might turn out to be + ;; #### inefficient. In that case, we will do the work + ;; #### manually. + ;; 1/ Move the article to a new file: + (let* ((oldfile (nnml-article-to-file old-number)) + (newfile + (gnus-replace-in-string + oldfile (concat "\\(" + old-number-string + "\\)\\(\\(\\.gz\\)?\\)$") + (concat new-number-string "\\2")))) + (with-current-buffer nntp-server-buffer + (nnmail-find-file oldfile) + ;; Update the Xref header in the article itself: + (when (and (re-search-forward "^Xref: [^ ]+ " nil t) + (re-search-forward + (concat "\\<" + (regexp-quote + (concat group ":" old-number-string)) + "\\>") + (point-at-eol) t)) + (replace-match + (concat group ":" new-number-string))) + ;; Save to the new file: + (nnmail-write-region (point-min) (point-max) newfile)) + (funcall nnmail-delete-file-function oldfile)) + ;; 2/ Update all marks for this article: + ;; #### NOTE: it is possible that the new article number + ;; #### already belongs to a range, whereas the corresponding + ;; #### article doesn't exist (for example, if you delete an + ;; #### article). For that reason, it is important to update + ;; #### the ranges (meaning remove inexistant articles) before + ;; #### doing anything on them. + ;; 2 a/ read articles: + (let ((read (gnus-info-read info))) + (setq read (gnus-remove-from-range read (list new-number))) + (when (gnus-member-of-range old-number read) + (setq read (gnus-remove-from-range read (list old-number))) + (setq read (gnus-add-to-range read (list new-number)))) + (gnus-info-set-read info read)) + ;; 2 b/ marked articles: + (let ((oldmarks (gnus-info-marks info)) + mark newmarks) + (while (setq mark (pop oldmarks)) + (setcdr mark (gnus-remove-from-range (cdr mark) + (list new-number))) + (when (gnus-member-of-range old-number (cdr mark)) + (setcdr mark (gnus-remove-from-range (cdr mark) + (list old-number))) + (setcdr mark (gnus-add-to-range (cdr mark) + (list new-number)))) + (push mark newmarks)) + (gnus-info-set-marks info newmarks)) + ;; 3/ Update the NOV entry for this article: + (unless nnml-nov-is-evil + (save-excursion + (set-buffer (nnml-open-nov group)) + (when (nnheader-find-nov-line old-number) + ;; Replace the article number: + (looking-at old-number-string) + (replace-match new-number-string nil t) + ;; Update the Xref header: + (when (re-search-forward + (concat "\\(Xref:[^\t\n]* \\)\\<" + (regexp-quote + (concat group ":" old-number-string)) + "\\>") + (point-at-eol) t) + (replace-match + (concat "\\1" group ":" new-number-string)))))) + ;; 4/ Possibly remove the article from the backlog: + (when gnus-keep-backlog + ;; #### NOTE: instead of removing the article, we could + ;; #### modify the backlog to reflect the numbering change, + ;; #### but I don't think it's worth it. + (gnus-backlog-remove-article group-full-name old-number) + (gnus-backlog-remove-article group-full-name new-number)))) + (setq new-number (1+ new-number))))) + (if (not compacted) + ;; No compaction had to be done: + t + ;; Some articles have actually been renamed: + ;; 1/ Rebuild active information: + (let ((entry (assoc group nnml-group-alist)) + (active (cons 1 (1- new-number)))) + (setq nnml-group-alist (delq entry nnml-group-alist)) + (push (list group active) nnml-group-alist) + ;; Update the active hashtable to let the *Group* buffer display + ;; up-to-date lines. I don't think that either gnus-newsrc-hashtb or + ;; gnus-newwrc-alist are out of date, since all we did is to modify + ;; the info of the group internally. + (gnus-set-active group-full-name active)) + ;; 1 bis/ + ;; #### NOTE: normally, we should save the overview (NOV) file + ;; #### here, just like we save the marks file. However, there is no + ;; #### such function as nnml-save-nov for a single group. Only for + ;; #### all groups. Gnus inconsistency is getting worse every day... + ;; 2/ Rebuild marks file: + (unless nnml-marks-is-evil + ;; #### NOTE: this constant use of global variables everywhere is + ;; #### truly disgusting. Gnus really needs a *major* cleanup. + (setq nnml-marks (gnus-info-marks info)) + (push (cons 'read (gnus-info-read info)) nnml-marks) + (dolist (el gnus-article-unpropagated-mark-lists) + (setq nnml-marks (gnus-remassoc el nnml-marks))) + (nnml-save-marks group server)) + ;; 3/ Save everything if this was not part of a bigger operation: + (if (not save) + ;; Nothing to save (yet): + t + ;; Something to save: + ;; a/ Save the NOV databases: + ;; #### NOTE: this should be done directory per directory in 1bis + ;; #### above. See comment there. + (nnml-save-nov) + ;; b/ Save the active file: + (nnmail-save-active nnml-group-alist nnml-active-file) + t))))) + +(defun nnml-request-compact (&optional server) + "Request compaction of all SERVER nnml groups." + (interactive (list (or (nnoo-current-server 'nnml) ""))) + (nnmail-activate 'nnml) + (unless (nnml-server-opened server) + (nnml-open-server server)) + (setq nnml-directory (expand-file-name nnml-directory)) + (let* ((groups (gnus-groups-from-server + (gnus-server-to-method (format "nnml:%s" server)))) + (first (pop groups)) + group) + (when first + (while (setq group (pop groups)) + (nnml-request-compact-group (gnus-group-real-name group) server)) + (nnml-request-compact-group (gnus-group-real-name first) server t)))) + + (provide 'nnml) ;;; arch-tag: 52c97dc3-9735-45de-b439-9e4d23b52004 diff --git a/lisp/nnnil.el b/lisp/nnnil.el index 88e471f..ac8d5e6 100644 --- a/lisp/nnnil.el +++ b/lisp/nnnil.el @@ -15,8 +15,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnoo.el b/lisp/nnoo.el index 0fd980e..1221830 100644 --- a/lisp/nnoo.el +++ b/lisp/nnoo.el @@ -1,7 +1,7 @@ ;;; nnoo.el --- OO Gnus Backends -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -61,12 +61,16 @@ (defmacro nnoo-declare (backend &rest parents) `(eval-and-compile - (push (list ',backend - (mapcar (lambda (p) (list p)) ',parents) - nil nil) - nnoo-definition-alist) - (push (list ',backend "*internal-non-initialized-backend*") - nnoo-state-alist))) + (if (assq ',backend nnoo-definition-alist) + (setcar (cdr (assq ',backend nnoo-definition-alist)) + (mapcar 'list ',parents)) + (push (list ',backend + (mapcar 'list ',parents) + nil nil) + nnoo-definition-alist)) + (unless (assq ',backend nnoo-state-alist) + (push (list ',backend "*internal-non-initialized-backend*") + nnoo-state-alist)))) (put 'nnoo-declare 'lisp-indent-function 1) (defun nnoo-parents (backend) @@ -254,7 +258,7 @@ (setcdr bstate (delq defs (cdr bstate))) (pop defs) (while defs - (set (car (pop defs)) nil))))) + (set (car (pop defs)) nil))))) t) (defun nnoo-close (backend) diff --git a/lisp/nnrss.el b/lisp/nnrss.el index cfe0e4b..f405687 100644 --- a/lisp/nnrss.el +++ b/lisp/nnrss.el @@ -1,5 +1,7 @@ ;;; nnrss.el --- interfacing with RSS -;; Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: RSS @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -86,9 +88,14 @@ ARTICLE is the article number of the current headline.") (defvar nnrss-compatible-encoding-alist '((iso-8859-1 . windows-1252)) "Alist of encodings and those supersets. The cdr of each element is used to decode data if it is available when -the car is what the data specify as the encoding. Or, the car is used +the car is what the data specify as the encoding. Or, the car is used for decoding when the cdr that the data specify is not available.") +(defvar nnrss-wash-html-in-text-plain-parts nil + "*Non-nil means render text in text/plain parts as HTML. +The function specified by the `mm-text-html-renderer' variable will be +used to render text. If it is nil, text will simply be folded.") + (nnoo-define-basics nnrss) ;;; Interface functions @@ -168,6 +175,10 @@ for decoding when the cdr that the data specify is not available.") (deffoo nnrss-close-group (group &optional server) t) +(eval-when-compile + (defvar mm-text-html-renderer) + (defvar mm-text-html-washer-alist)) + (deffoo nnrss-request-article (article &optional group server buffer) (setq group (nnrss-decode-group-name group)) (when (stringp article) @@ -190,12 +201,10 @@ for decoding when the cdr that the data specify is not available.") (if (nth 5 e) (insert "Date: " (nnrss-format-string (nth 5 e)) "\n")) (let ((header (buffer-string)) - (text (if (nth 6 e) - (mapconcat 'identity - (delete "" (split-string (nth 6 e) "\n+")) - " "))) + (text (nth 6 e)) (link (nth 2 e)) (enclosure (nth 7 e)) + (comments (nth 8 e)) ;; Enable encoding of Newsgroups header in XEmacs. (default-enable-multibyte-characters t) (rfc2047-header-encoding-alist @@ -203,14 +212,55 @@ for decoding when the cdr that the data specify is not available.") (cons '("Newsgroups" . utf-8) rfc2047-header-encoding-alist) rfc2047-header-encoding-alist)) - rfc2047-encode-encoded-words body) - (when (or text link enclosure) + rfc2047-encode-encoded-words body fn) + (when (or text link enclosure comments) (insert "\n") (insert "<#multipart type=alternative>\n" "<#part type=\"text/plain\">\n") (setq body (point)) (when text - (insert text "\n") + (insert text) + (goto-char body) + (if (and nnrss-wash-html-in-text-plain-parts + (progn + (require 'mm-view) + (setq fn (or (cdr (assq mm-text-html-renderer + mm-text-html-washer-alist)) + mm-text-html-renderer)))) + (progn + (narrow-to-region body (point-max)) + (if (functionp fn) + (funcall fn) + (apply (car fn) (cdr fn))) + (widen) + (goto-char body) + (re-search-forward "[^\t\n ]" nil t) + (beginning-of-line) + (delete-region body (point)) + (goto-char (point-max)) + (skip-chars-backward "\t\n ") + (end-of-line) + (delete-region (point) (point-max)) + (insert "\n")) + (while (re-search-forward "\n+" nil t) + (replace-match " ")) + (goto-char body) + ;; See `nnrss-check-group', which inserts "

". + (when (search-forward "

" nil t) + (if (eobp) + (replace-match "\n") + (replace-match "\n\n"))) + (unless (eobp) + (let ((fill-column default-fill-column) + (window (get-buffer-window nntp-server-buffer))) + (when window + (setq fill-column + (max 1 (/ (* (window-width window) 7) 8)))) + (fill-region (point) (point-max)) + (goto-char (point-max)) + ;; XEmacs version of `fill-region' inserts newline. + (unless (bolp) + (insert "\n"))))) (when (or link enclosure) (insert "\n"))) (when link @@ -219,6 +269,8 @@ for decoding when the cdr that the data specify is not available.") (insert (car enclosure) " " (nth 2 enclosure) " " (nth 3 enclosure) "\n")) + (when comments + (insert comments "\n")) (setq body (buffer-substring body (point))) (insert "<#/part>\n" "<#part type=\"text/html\">\n" @@ -231,6 +283,8 @@ for decoding when the cdr that the data specify is not available.") (insert "

" (cadr enclosure) " " (nth 2 enclosure) " " (nth 3 enclosure) "

\n")) + (when comments + (insert "

comments

\n")) (insert "\n" "<#/part>\n" "<#/multipart>\n")) @@ -356,7 +410,11 @@ otherwise return nil." ;; FIXME: shouldn't binding `coding-system-for-read' be moved ;; to `mm-url-insert'? (let ((coding-system-for-read 'binary)) - (mm-url-insert url))) + (condition-case err + (mm-url-insert url) + (error (if (or debug-on-quit debug-on-error) + (signal (car err) (cdr err)) + (message "nnrss: Failed to fetch %s" url)))))) (nnheader-remove-cr-followed-by-lf) ;; Decode text according to the encoding attribute. (when (setq cs (nnrss-get-encoding)) @@ -407,6 +465,74 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" (unless (assoc (car elem) nnrss-group-alist) (insert (prin1-to-string (car elem)) " 0 1 y\n"))))) +(eval-and-compile (autoload 'timezone-parse-date "timezone")) + +(defun nnrss-normalize-date (date) + "Return a date string of DATE in the RFC822 style. +This function handles the ISO 8601 date format described in +, and also the RFC822 style +which RSS 2.0 allows." + (let (case-fold-search vector year month day time zone cts) + (cond ((null date)) + ;; RFC822 + ((string-match " [0-9]+ " date) + (setq vector (timezone-parse-date date) + year (string-to-number (aref vector 0))) + (when (>= year 1969) + (setq month (string-to-number (aref vector 1)) + day (string-to-number (aref vector 2))) + (unless (>= (length (setq time (aref vector 3))) 3) + (setq time "00:00:00")) + (when (and (setq zone (aref vector 4)) + (not (string-match "\\`[A-Z+-]" zone))) + (setq zone nil)))) + ;; ISO 8601 + ((string-match + (eval-when-compile + (concat + ;; 1. year + "\\(199[0-9]\\|20[0-9][0-9]\\)" + "\\(?:-" + ;; 2. month + "\\([01][0-9]\\)" + "\\(?:-" + ;; 3. day + "\\([0-3][0-9]\\)" + "\\)?\\)?\\(?:T" + ;; 4. hh:mm + "\\([012][0-9]:[0-5][0-9]\\)" + "\\(?:" + ;; 5. :ss + "\\(:[0-5][0-9]\\)" + "\\(?:\\.[0-9]+\\)?\\)?\\)?" + ;; 6+7,8,9. zone + "\\(?:\\(?:\\([+-][012][0-9]\\):\\([0-5][0-9]\\)\\)" + "\\|\\([+-][012][0-9][0-5][0-9]\\)" + "\\|\\(Z\\)\\)?")) + date) + (setq year (string-to-number (match-string 1 date)) + month (string-to-number (or (match-string 2 date) "1")) + day (string-to-number (or (match-string 3 date) "1")) + time (if (match-beginning 5) + (substring date (match-beginning 4) (match-end 5)) + (concat (or (match-string 4 date) "00:00") ":00")) + zone (cond ((match-beginning 6) + (concat (match-string 6 date) + (match-string 7 date))) + ((match-beginning 9) ;; Z + "+0000") + (t ;; nil if zone is not provided. + (match-string 8 date)))))) + (if month + (progn + (setq cts (current-time-string (encode-time 0 0 0 day month year))) + (format "%s, %02d %s %04d %s%s" + (substring cts 0 3) day (substring cts 4 7) year time + (if zone + (concat " " zone) + ""))) + (message-make-date)))) + ;;; data functions (defun nnrss-read-server-data (server) @@ -492,7 +618,11 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" (defun nnrss-insert-w3 (url) (mm-with-unibyte-current-buffer - (mm-url-insert url))) + (condition-case err + (mm-url-insert url) + (error (if (or debug-on-quit debug-on-error) + (signal (car err) (cdr err)) + (message "nnrss: Failed to fetch %s" url)))))) (defun nnrss-decode-entities-string (string) (if string @@ -527,8 +657,8 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" ;;; Snarf functions (defun nnrss-check-group (group server) - (let (file xml subject url extra changed author date - enclosure rss-ns rdf-ns content-ns dc-ns) + (let (file xml subject url extra changed author date feed-subject + enclosure comments rss-ns rdf-ns content-ns dc-ns) (if (and nnrss-use-local (file-exists-p (setq file (expand-file-name (nnrss-translate-file-chars @@ -570,12 +700,15 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" (setq extra (or extra (nnrss-node-text content-ns 'encoded item) (nnrss-node-text rss-ns 'description item))) + (if (setq feed-subject (nnrss-node-text dc-ns 'subject item)) + (setq extra (concat feed-subject "

" extra))) (setq author (or (nnrss-node-text rss-ns 'author item) (nnrss-node-text dc-ns 'creator item) (nnrss-node-text dc-ns 'contributor item))) - (setq date (or (nnrss-node-text dc-ns 'date item) - (nnrss-node-text rss-ns 'pubDate item) - (message-make-date))) + (setq date (nnrss-normalize-date + (or (nnrss-node-text dc-ns 'date item) + (nnrss-node-text rss-ns 'pubDate item)))) + (setq comments (nnrss-node-text rss-ns 'comments item)) (when (setq enclosure (cadr (assq (intern (concat rss-ns "enclosure")) item))) (let ((url (cdr (assq 'url enclosure))) (len (cdr (assq 'length enclosure))) @@ -606,7 +739,8 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" (and author (nnrss-mime-encode-string author)) date (and extra (nnrss-decode-entities-string extra)) - enclosure) + enclosure + comments) nnrss-group-data) (puthash (or url extra) t nnrss-group-hashtb) (setq changed t)) @@ -623,14 +757,29 @@ nnrss: %s: Not valid XML %s and w3-parse doesn't work %s" "OPML subscriptions import. Read the file and attempt to subscribe to each Feed in the file." (interactive "fImport file: ") - (mapcar - (lambda (node) (gnus-group-make-rss-group - (cdr (assq 'xmlUrl (cadr node))))) + (mapc + (lambda (node) + (let ((xmlurl (cdr (assq 'xmlUrl (cadr node))))) + (when (and xmlurl + (not (string-match "\\`[\t ]*\\'" xmlurl)) + (prog1 + (y-or-n-p (format "Subscribe to %s " xmlurl)) + (message ""))) + (condition-case err + (progn + (gnus-group-make-rss-group xmlurl) + (forward-line 1)) + (error + (message + "Failed to subscribe to %s (%s); type any key to continue: " + xmlurl + (error-message-string err)) + (let ((echo-keystrokes 0)) + (read-char))))))) (nnrss-find-el 'outline - (progn - (find-file opml-file) - (xml-parse-region (point-min) - (point-max)))))) + (mm-with-multibyte-buffer + (insert-file-contents opml-file) + (xml-parse-region (point-min) (point-max)))))) (defun nnrss-opml-export () "OPML subscription export. @@ -900,7 +1049,7 @@ whether they are `offsite' or `onsite'." (selection (mapcar (lambda (listinfo) (cons (cdr (assoc "sitename" listinfo)) - (string-to-int + (string-to-number (cdr (assoc "feedid" listinfo))))) feedinfo))) (cdr (assoc diff --git a/lisp/nnslashdot.el b/lisp/nnslashdot.el index e203de4..95ce44b 100644 --- a/lisp/nnslashdot.el +++ b/lisp/nnslashdot.el @@ -1,6 +1,7 @@ ;;; nnslashdot.el --- interfacing with Slashdot -;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -86,7 +87,7 @@ (nnslashdot-possibly-change-server group server) (condition-case why (unless gnus-nov-is-evil - (nnslashdot-retrieve-headers-1 articles group)) + (nnslashdot-retrieve-headers-1 articles group)) (search-failed (nnslashdot-lose why)))) (deffoo nnslashdot-retrieve-headers-1 (articles group) @@ -141,41 +142,30 @@ (setq article (if (and article (< start article)) article start)) (goto-char point) (while (re-search-forward - "<\\(b\\|H4\\)>\\([^<]+\\).*score:\\([^)]+\\))" + "\\([^<]+\\).*\n.*\n.*score:\\([^)]+\\))" nil t) (setq cid (match-string 1) - subject (match-string 3) - score (match-string 5)) + subject (match-string 2) + score (match-string 3)) (unless (assq article (nth 4 entry)) (setcar (nthcdr 4 entry) (cons (cons article cid) (nth 4 entry))) (setq changed t)) (when (string-match "^Re: *" subject) (setq subject (concat "Re: " (substring subject (match-end 0))))) - (setq subject (mm-url-decode-entities-string subject)) - (search-forward "
") - (cond - ((looking-at - "by[ \t\n]+]+>\\([^<]+\\)[ \t\n]*(\\(<[^>]+>\\)*\\([^<>)]+\\))") - (goto-char (- (match-end 0) 5)) - (setq from (concat - (mm-url-decode-entities-string (match-string 1)) - " <" (match-string 3) ">"))) - ((looking-at "by[ \t\n]+]+>\\([^<(]+\\) (\\([0-9]+\\))") - (goto-char (- (match-end 0) 5)) - (setq from (concat - (mm-url-decode-entities-string (match-string 1)) - " <" (match-string 2) ">"))) - ((looking-at "by \\([^<>]*\\)[\t\n\r ]+on ") - (goto-char (- (match-end 0) 5)) - (setq from (mm-url-decode-entities-string (match-string 1)))) - (t - (setq from ""))) + (setq subject (mm-url-decode-entities-string subject) + from "") + (when (re-search-forward "by[ \t\n]+<[^>]+>\\([^<(]+\\)" nil t) + (setq from + (concat + (mm-url-decode-entities-string (match-string 1)) + " "))) (search-forward "on ") (setq date (nnslashdot-date-to-date - (buffer-substring (point) (progn (skip-chars-forward "^()<>\n\r") (point))))) - (setq lines (/ (abs (- (search-forward ""))) + (buffer-substring + (point) (progn (skip-chars-forward "^()<>\n\r") (point))))) + (setq lines (/ (abs (- (search-forward ""))) 70)) (if (not (re-search-forward ".*cid=\\([0-9]+\\)\">Parent" nil t)) @@ -255,21 +245,20 @@ (if (= article 1) (progn (search-forward "Posted by") - (search-forward "
") + (search-forward "
") (setq contents (buffer-substring (point) (progn - (re-search-forward - "\\|\\|< [ \t\r\n]*" cid)) (setq contents (buffer-substring - (re-search-forward "]*>") - (search-forward ""))))))) + (search-forward "
") + (search-forward "
"))))))) (search-failed (nnslashdot-lose why))) (when contents diff --git a/lisp/nnsoup.el b/lisp/nnsoup.el index fa24abe..3068343 100644 --- a/lisp/nnsoup.el +++ b/lisp/nnsoup.el @@ -1,7 +1,7 @@ ;;; nnsoup.el --- SOUP access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu UMEDA @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -749,9 +749,9 @@ backend for the messages.") (let ((files (sort (directory-files nnsoup-directory t "IDX$") (lambda (f1 f2) (< (progn (string-match "/\\([0-9]+\\)\\." f1) - (string-to-int (match-string 1 f1))) + (string-to-number (match-string 1 f1))) (progn (string-match "/\\([0-9]+\\)\\." f2) - (string-to-int (match-string 1 f2))))))) + (string-to-number (match-string 1 f2))))))) active group lines ident elem min) (set-buffer (get-buffer-create " *nnsoup work*")) (dolist (file files) diff --git a/lisp/nnspool.el b/lisp/nnspool.el index 004b875..33ed7f8 100644 --- a/lisp/nnspool.el +++ b/lisp/nnspool.el @@ -1,8 +1,7 @@ ;;; nnspool.el --- spool access for GNU Emacs ;; Copyright (C) 1988, 1989, 1990, 1993, 1994, 1995, 1996, 1997, 1998, -;; 2000, 2002, 2003 -;; Free Software Foundation, Inc. +;; 2000, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Masanobu UMEDA ;; Lars Magne Ingebrigtsen @@ -22,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -247,7 +246,7 @@ there.") ;; Yes, completely empty spool directories *are* possible. ;; Fix by Sudish Joseph (when (setq dir (directory-files pathname nil "^[0-9]+$" t)) - (setq dir (sort (mapcar 'string-to-int dir) '<))) + (setq dir (sort (mapcar 'string-to-number dir) '<))) (if dir (nnheader-insert "211 %d %d %d %s\n" (length dir) (car dir) @@ -432,7 +431,7 @@ there.") (call-process "grep" nil t nil (regexp-quote id) nnspool-history-file)) (goto-char (point-min)) (when (looking-at "<[^>]+>[ \t]+[-0-9~]+[ \t]+\\([^ /\t\n]+\\)/\\([0-9]+\\)[ \t\n]") - (cons (match-string 1) (string-to-int (match-string 2)))))) + (cons (match-string 1) (string-to-number (match-string 2)))))) (defun nnspool-find-file (file) "Insert FILE in server buffer safely." diff --git a/lisp/nntp.el b/lisp/nntp.el index bd8591c..46294af 100644 --- a/lisp/nntp.el +++ b/lisp/nntp.el @@ -1,7 +1,8 @@ ;;; nntp.el --- nntp access for Gnus -;; Copyright (C) 1987, 1988, 1989, 1990, 1992, 1993, 1994, 1995, 1996, -;; 1997, 1998, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1987, 1988, 1989, 1990, 1992, 1993, +;; 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002, +;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -20,7 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. +;; Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, +;; MA 02110-1301, USA. ;;; Commentary: @@ -102,8 +104,8 @@ This command is used by the methods `nntp-open-telnet-stream', (defvoo nntp-end-of-line "\r\n" "*String to use on the end of lines when talking to the NNTP server. -This is \"\\r\\n\" by default, but should be \"\\n\" when using and -indirect telnet connection method (nntp-open-via-*-and-telnet).") +This is \"\\r\\n\" by default, but should be \"\\n\" when using an indirect +connection method (nntp-open-via-*).") (defvoo nntp-via-rlogin-command "rsh" "*Rlogin command used to connect to an intermediate host. @@ -185,9 +187,6 @@ then use this hook to rsh to the remote machine and start a proxy NNTP server there that you can connect to. See also `nntp-open-connection-function'") -(defvoo nntp-warn-about-losing-connection t - "*If non-nil, beep when a server closes connection.") - (defvoo nntp-coding-system-for-read 'binary "*Coding system to read from NNTP.") @@ -206,7 +205,7 @@ See `nnml-marks-is-evil' for more information.") (defcustom nntp-marks-directory (nnheader-concat gnus-directory "marks/") "*The directory where marks for nntp groups will be stored." - :group 'gnus + :group 'nntp :type 'directory) (defcustom nntp-authinfo-file "~/.authinfo" @@ -278,13 +277,20 @@ noticing asynchronous data.") (defvar nntp-async-timer nil) (defvar nntp-async-process-list nil) -(defvar nntp-ssl-program +(defvar nntp-ssl-program "openssl s_client -quiet -ssl3 -connect %s:%p" "A string containing commands for SSL connections. Within a string, %s is replaced with the server address and %p with port number on server. The program should accept IMAP commands on stdin and return responses to stdout.") +(defvar nntp-authinfo-rejected nil +"A custom error condition used to report 'Authentication Rejected' errors. +Condition handlers that match just this condition ensure that the nntp +backend doesn't catch this error.") +(put 'nntp-authinfo-rejected 'error-conditions '(error nntp-authinfo-rejected)) +(put 'nntp-authinfo-rejected 'error-message "Authorization Rejected") + ;;; Internal functions. @@ -335,16 +341,21 @@ be restored and the command retried." (defsubst nntp-wait-for (process wait-for buffer &optional decode discard) "Wait for WAIT-FOR to arrive from PROCESS." + (save-excursion (set-buffer (process-buffer process)) (goto-char (point-min)) + (while (and (or (not (memq (char-after (point)) '(?2 ?3 ?4 ?5))) - (looking-at "480")) + (looking-at "48[02]")) (memq (process-status process) '(open run))) - (when (looking-at "480") - (nntp-handle-authinfo process)) - (when (looking-at "^.*\n") - (delete-region (point) (progn (forward-line 1) (point)))) + (cond ((looking-at "480") + (nntp-handle-authinfo process)) + ((looking-at "482") + (nnheader-report 'nntp (get 'nntp-authinfo-rejected 'error-message)) + (signal 'nntp-authinfo-rejected nil)) + ((looking-at "^.*\n") + (delete-region (point) (progn (forward-line 1) (point))))) (nntp-accept-process-output process) (goto-char (point-min))) (prog1 @@ -440,6 +451,8 @@ be restored and the command retried." (wait-for (nntp-wait-for process wait-for buffer decode)) (t t))) + (nntp-authinfo-rejected + (signal 'nntp-authinfo-rejected (cdr err))) (error (nnheader-report 'nntp "Couldn't open connection to %s: %s" address err)) @@ -560,7 +573,12 @@ be restored and the command retried." ;; a line with only a "." on it. ((eq (char-after) ?2) (if (re-search-forward "\n\\.\r?\n" nil t) - t + (progn + ;; Some broken news servers add another dot at the end. + ;; Protect against inflooping there. + (while (looking-at "^\\.\r?\n") + (forward-line 1)) + t) nil)) ;; A result that starts with a 3xx or 4xx code is terminated ;; by a newline. @@ -622,7 +640,8 @@ command whose response triggered the error." (condition-case nil (progn ,@forms) (quit - (nntp-close-server) + (unless debug-on-quit + (nntp-close-server)) (signal 'quit nil)))) (when timer (nnheader-cancel-timer timer))) @@ -909,7 +928,7 @@ command whose response triggered the error." (if (numberp article) (int-to-string article) article)))) (deffoo nntp-request-group (group &optional server dont-check) - (nntp-with-open-group + (nntp-with-open-group nil server (when (nntp-send-command "^[245].*\n" "GROUP" group) (let ((entry (nntp-find-connection-entry nntp-server-buffer))) @@ -1195,7 +1214,7 @@ password contained in '~/.nntp-authinfo'." (nntp-kill-buffer pbuffer)) (when (and (buffer-name pbuffer) process) - (process-kill-without-query process) + (gnus-set-process-query-on-exit-flag process nil) (if (and (nntp-wait-for process "^2.*\n" buffer nil t) (memq (process-status process) '(open run))) (prog1 @@ -1215,20 +1234,21 @@ password contained in '~/.nntp-authinfo'." (defun nntp-open-network-stream (buffer) (open-network-stream "nntpd" buffer nntp-address nntp-port-number)) -(autoload 'format-spec "format") -(autoload 'format-spec-make "format") -(autoload 'open-tls-stream "tls") +(eval-and-compile + (autoload 'format-spec "format-spec") + (autoload 'format-spec-make "format-spec") + (autoload 'open-tls-stream "tls")) (defun nntp-open-ssl-stream (buffer) (let* ((process-connection-type nil) - (proc (start-process "nntpd" buffer + (proc (start-process "nntpd" buffer shell-file-name shell-command-switch - (format-spec nntp-ssl-program + (format-spec nntp-ssl-program (format-spec-make ?s nntp-address ?p nntp-port-number))))) - (process-kill-without-query proc) + (gnus-set-process-query-on-exit-flag proc nil) (save-excursion (set-buffer buffer) (let ((nntp-connection-alist (list proc buffer nil))) @@ -1239,7 +1259,7 @@ password contained in '~/.nntp-authinfo'." (defun nntp-open-tls-stream (buffer) (let ((proc (open-tls-stream "nntpd" buffer nntp-address nntp-port-number))) - (process-kill-without-query proc) + (gnus-set-process-query-on-exit-flag proc nil) (save-excursion (set-buffer buffer) (let ((nntp-connection-alist (list proc buffer nil))) @@ -1379,7 +1399,7 @@ password contained in '~/.nntp-authinfo'." ;; that the server has closed the connection. This MUST be ;; handled here as the buffer restored by the save-excursion may ;; be the process's former output buffer (i.e. now killed) - (or (and process + (or (and process (memq (process-status process) '(open run))) (nntp-report "Server closed connection")))) @@ -1560,8 +1580,8 @@ password contained in '~/.nntp-authinfo'." (when (<= count 1) (goto-char (point-min)) (when (re-search-forward "^[0-9][0-9][0-9] .*\n\\([0-9]+\\)" nil t) - (let ((low-limit (string-to-int - (buffer-substring (match-beginning 1) + (let ((low-limit (string-to-number + (buffer-substring (match-beginning 1) (match-end 1))))) (while (and articles (<= (car articles) low-limit)) (setq articles (cdr articles)))))) @@ -1630,7 +1650,7 @@ password contained in '~/.nntp-authinfo'." (goto-char (point-min)) ;; We first find the number by looking at the status line. (let ((number (and (looking-at "2[0-9][0-9] +\\([0-9]+\\) ") - (string-to-int + (string-to-number (buffer-substring (match-beginning 1) (match-end 1))))) newsgroups xref) @@ -1668,7 +1688,7 @@ password contained in '~/.nntp-authinfo'." "\\([^ :]+\\):\\([0-9]+\\)") xref)) (setq group (match-string 1 xref) - number (string-to-int (match-string 2 xref)))) + number (string-to-number (match-string 2 xref)))) ((and (setq newsgroups (mail-fetch-field "newsgroups")) (not (string-match "," newsgroups))) @@ -1984,7 +2004,8 @@ Please refer to the following variables to customize the connection: (make-directory (directory-file-name dir) t) (nnheader-message 5 "Creating nntp marks directory %s" dir)))) -(autoload 'time-less-p "time-date") +(eval-and-compile + (autoload 'time-less-p "time-date")) (defun nntp-marks-changed-p (group server) (let ((file (expand-file-name diff --git a/lisp/nnultimate.el b/lisp/nnultimate.el index 42fbc13..53522c0 100644 --- a/lisp/nnultimate.el +++ b/lisp/nnultimate.el @@ -1,6 +1,7 @@ ;;; nnultimate.el --- interfacing with the Ultimate Bulletin Board system -;; Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnvirtual.el b/lisp/nnvirtual.el index c63ab8b..751e6be 100644 --- a/lisp/nnvirtual.el +++ b/lisp/nnvirtual.el @@ -1,6 +1,7 @@ ;;; nnvirtual.el --- virtual newsgroups access for Gnus -;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: David Moore ;; Lars Magne Ingebrigtsen @@ -21,8 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnwarchive.el b/lisp/nnwarchive.el index a9d0d51..13a2241 100644 --- a/lisp/nnwarchive.el +++ b/lisp/nnwarchive.el @@ -1,5 +1,7 @@ ;;; nnwarchive.el --- interfacing with web archives -;; Copyright (C) 1999, 2000, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: news egroups mail-archive @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/nnweb.el b/lisp/nnweb.el index d5f7f13..37cf7a3 100644 --- a/lisp/nnweb.el +++ b/lisp/nnweb.el @@ -1,6 +1,7 @@ ;;; nnweb.el --- retrieving articles via web search engines -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -53,17 +54,19 @@ Valid types include `google', `dejanews', and `gmane'.") (defvar nnweb-type-definition '((google - (article . ignore) - (id . "http://groups.google.de/groups?selm=%s&output=gplain") + (id . "http://www.google.com/groups?as_umsgid=%s&hl=en&dmode=source") + (result . "http://groups.google.com/group/%s/msg/%s?dmode=source") + (article . nnweb-google-wash-article) (reference . identity) (map . nnweb-google-create-mapping) (search . nnweb-google-search) - (address . "http://groups.google.de/groups") - (base . "http://groups.google.de") + (address . "http://groups.google.com/groups") + (base . "http://groups.google.com") (identifier . nnweb-google-identity)) (dejanews ;; alias of google - (article . ignore) - (id . "http://groups.google.com/groups?selm=%s&output=gplain") + (id . "http://www.google.com/groups?as_umsgid=%s&hl=en&dmode=source") + (result . "http://groups.google.com/group/%s/msg/%s?dmode=source") + (article . nnweb-google-wash-article) (reference . identity) (map . nnweb-google-create-mapping) (search . nnweb-google-search) @@ -76,7 +79,7 @@ Valid types include `google', `dejanews', and `gmane'.") (reference . identity) (map . nnweb-gmane-create-mapping) (search . nnweb-gmane-search) - (address . "http://gmane.org/") + (address . "http://search.gmane.org/nov.php") (identifier . nnweb-gmane-identity))) "Type-definition alist.") @@ -116,25 +119,20 @@ Valid types include `google', `dejanews', and `gmane'.") (deffoo nnweb-request-scan (&optional group server) (nnweb-possibly-change-server group server) (if nnweb-ephemeral-p - (setq nnweb-hashtb (gnus-make-hashtable 4095))) + (setq nnweb-hashtb (gnus-make-hashtable 4095)) + (unless nnweb-articles + (nnweb-read-overview group))) (funcall (nnweb-definition 'map)) (unless nnweb-ephemeral-p (nnweb-write-active) (nnweb-write-overview group))) (deffoo nnweb-request-group (group &optional server dont-check) - (nnweb-possibly-change-server nil server) - (when (and group - (not (equal group nnweb-group)) - (not nnweb-ephemeral-p)) - (setq nnweb-group group - nnweb-articles nil) - (let ((info (assoc group nnweb-group-alist))) - (when info - (setq nnweb-type (nth 2 info)) - (setq nnweb-search (nth 3 info)) - (unless dont-check - (nnweb-read-overview group))))) + (nnweb-possibly-change-server group server) + (unless (or nnweb-ephemeral-p + dont-check + nnweb-articles) + (nnweb-read-overview group)) (cond ((not nnweb-articles) (nnheader-report 'nnweb "No matching articles")) @@ -198,7 +196,7 @@ Valid types include `google', `dejanews', and `gmane'.") (nnweb-possibly-change-server nil server) (save-excursion (set-buffer nntp-server-buffer) - (nnmail-generate-active nnweb-group-alist) + (nnmail-generate-active (list (assoc server nnweb-group-alist))) t)) (deffoo nnweb-request-update-info (group info &optional server) @@ -210,7 +208,7 @@ Valid types include `google', `dejanews', and `gmane'.") (deffoo nnweb-request-create-group (group &optional server args) (nnweb-possibly-change-server nil server) (nnweb-request-delete-group group) - (push `(,group ,(cons 1 0) ,@args) nnweb-group-alist) + (push `(,group ,(cons 1 0)) nnweb-group-alist) (nnweb-write-active) t) @@ -280,18 +278,16 @@ Valid types include `google', `dejanews', and `gmane'.") def)) (defun nnweb-possibly-change-server (&optional group server) - (nnweb-init server) (when server (unless (nnweb-server-opened server) - (nnweb-open-server server))) + (nnweb-open-server server)) + (nnweb-init server)) (unless nnweb-group-alist (nnweb-read-active)) (unless nnweb-hashtb (setq nnweb-hashtb (gnus-make-hashtable 4095))) (when group - (when (and (not nnweb-ephemeral-p) - (equal group nnweb-group)) - (nnweb-request-group group nil t)))) + (setq nnweb-group group))) (defun nnweb-init (server) "Initialize buffers and such." @@ -305,53 +301,56 @@ Valid types include `google', `dejanews', and `gmane'.") (current-buffer)))))) ;;; -;;; Deja bought by google.com +;;; groups.google.com ;;; (defun nnweb-google-wash-article () - (let ((case-fold-search t) url) + ;; We have Google's masked e-mail addresses here. :-/ + (let ((case-fold-search t) + (start-re "
\n *")
+	(end-re "\n *
")) (goto-char (point-min)) - (re-search-forward "^
" nil t)
-    (narrow-to-region (point-min) (point))
-    (search-backward "" nil t)
-      (replace-match "\n"))
-    (mm-url-remove-markup)
-    (goto-char (point-min))
-    (while (re-search-forward "^[ \t]*\n" nil t)
-      (replace-match ""))
-    (goto-char (point-max))
-    (insert "\n")
-    (widen)
-    (narrow-to-region (point) (point-max))
-    (search-forward "" nil t)
-    (delete-region (point) (point-max))
-    (mm-url-remove-markup)
-    (widen)))
+    (if (save-excursion
+	  (or (re-search-forward "The requested message.*could not be found."
+				 nil t)
+	      (not (and (re-search-forward start-re nil t)
+			(re-search-forward end-re nil t)))))
+	;; FIXME: Don't know how to indicate "not found".
+	;; Should this function throw an error?  --rsteib
+	(progn
+	  (gnus-message 3 "Requested article not found")
+	  (erase-buffer))
+      (delete-region (point-min)
+		     (re-search-forward start-re))
+      (goto-char (point-min))
+      (delete-region (progn
+		       (re-search-forward end-re)
+		       (match-beginning 0))
+		     (point-max))
+      (mm-url-decode-entities))))
 
 (defun nnweb-google-parse-1 (&optional Message-ID)
+  "Parse search result in current buffer."
   (let ((i 0)
 	(case-fold-search t)
 	(active (cadr (assoc nnweb-group nnweb-group-alist)))
 	Subject Score Date Newsgroups From
 	map url mid)
     (unless active
-      (push (list nnweb-group (setq active (cons 1 0))
-		  nnweb-type nnweb-search)
+      (push (list nnweb-group (setq active (cons 1 0)))
 	    nnweb-group-alist))
     ;; Go through all the article hits on this page.
     (goto-char (point-min))
-    (while (re-search-forward
-	    "a href=/groups\\(\\?[^ \">]*selm=\\([^ &\">]+\\)\\)" nil t)
-      (setq mid (match-string 2)
+    (while
+	(re-search-forward
+	 "a +href=\"/group/\\([^>\"]+\\)/browse_thread/[^>]+#\\([0-9a-f]+\\)"
+	 nil t)
+      (setq Newsgroups (match-string-no-properties 1)
+	    ;; Note: Starting with Google Groups 2, `mid' is a Google-internal
+	    ;; ID, not a proper Message-ID.
+	    mid (match-string-no-properties 2)
 	    url (format
-		 (nnweb-definition 'id) mid))
+		 (nnweb-definition 'result) Newsgroups mid))
       (narrow-to-region (search-forward ">" nil t)
 			(search-forward "" nil t))
       (mm-url-remove-markup)
@@ -359,25 +358,22 @@ Valid types include `google', `dejanews', and `gmane'.")
       (setq Subject (buffer-string))
       (goto-char (point-max))
       (widen)
-      (forward-line 2)
-      (when (looking-at "
]+>") - (goto-char (match-end 0))) - (if (not (looking-at "]+>")) - (skip-chars-forward " \t") - (narrow-to-region (point) - (search-forward "" nil t)) - (mm-url-remove-markup) - (mm-url-decode-entities) - (setq Newsgroups (buffer-string)) - (goto-char (point-max)) - (widen) - (skip-chars-forward "- \t")) + (narrow-to-region (point) + (search-forward "]+\\).*Next" nil t)) + "\" \n\t]+\\)[^<]*]+next" + nil t)) (>= i nnweb-max-hits)) (setq more nil) ;; Yup, there are more articles (setq more (concat (nnweb-definition 'base) (match-string 1))) (when more (erase-buffer) + (nnheader-message 7 "Searching google...(%d)" i) (mm-url-insert more)))) ;; Return the articles in the right order. + (nnheader-message 7 "Searching google...done") (setq nnweb-articles (sort nnweb-articles 'car-less-than-car)))))) @@ -442,7 +442,8 @@ Valid types include `google', `dejanews', and `gmane'.") ("hl" . "en") ("lr" . "") ("safe" . "off") - ("sites" . "groups"))))) + ("sites" . "groups") + ("filter" . "0"))))) t) (defun nnweb-google-identity (url) @@ -458,46 +459,61 @@ Valid types include `google', `dejanews', and `gmane'.") "Perform the search and create a number-to-url alist." (save-excursion (set-buffer nnweb-buffer) - (erase-buffer) - (when (funcall (nnweb-definition 'search) nnweb-search) - (let ((more t) - (case-fold-search t) - (active (or (cadr (assoc nnweb-group nnweb-group-alist)) - (cons 1 0))) - subject group url - map) - ;; Remove stuff from the beginning of results + (let ((case-fold-search t) + (active (or (cadr (assoc nnweb-group nnweb-group-alist)) + (cons 1 0))) + map) + (erase-buffer) + (nnheader-message 7 "Searching Gmane..." ) + (when (funcall (nnweb-definition 'search) nnweb-search) (goto-char (point-min)) - (search-forward "Search Results
    " nil t) - (delete-region (point-min) (point)) - (goto-char (point-min)) - ;; Iterate over the actual hits - (while (re-search-forward ".*href=\"\\([^\"]+\\)\">\\(.*\\)" nil t) - (setq url (concat "http://gmane.org/" (match-string 1))) - (setq subject (match-string 2)) - (unless (nnweb-get-hashtb url) - (push - (list - (incf (cdr active)) - (make-full-mail-header - (cdr active) (concat "(" group ") " subject) nil nil - nil nil 0 0 url)) - map) - (nnweb-set-hashtb (cadar map) (car map)))) - ;; Return the articles in the right order. - (setq nnweb-articles - (sort (nconc nnweb-articles map) 'car-less-than-car)))))) + ;; Skip the status line + (forward-line 1) + ;; Thanks to Olly Betts we now have NOV lines in our buffer! + (while (not (eobp)) + (unless (or (eolp) (looking-at "\x0d")) + (let ((header (nnheader-parse-nov))) + (let ((xref (mail-header-xref header)) + (from (mail-header-from header)) + (subject (mail-header-subject header)) + (rfc2047-encoding-type 'mime)) + (when (string-match " \\([^:]+\\):\\([0-9]+\\)" xref) + (mail-header-set-xref + header + (format "http://article.gmane.org/%s/%s/raw" + (match-string 1 xref) + (match-string 2 xref)))) + + ;; Add host part to gmane-encrypted addresses + (when (string-match "@$" from) + (mail-header-set-from header + (concat from "public.gmane.org"))) + + (mail-header-set-subject header + (rfc2047-encode-string subject)) + + (unless (nnweb-get-hashtb (mail-header-xref header)) + (push + (list + (incf (cdr active)) + header) + map) + (nnweb-set-hashtb (cadar map) (car map)))))) + (forward-line 1))) + (nnheader-message 7 "Searching Gmane...done") + (setq nnweb-articles + (sort (nconc nnweb-articles map) 'car-less-than-car))))) (defun nnweb-gmane-wash-article () (let ((case-fold-search t)) (goto-char (point-min)) - (search-forward "" nil t) - (delete-region (point-min) (point)) - (goto-char (point-min)) - (while (looking-at "^
  • \\([^ ]+\\).*
  • ") - (replace-match "\\1\\2" t) - (forward-line 1)) - (mm-url-remove-markup))) + (when (search-forward "" nil t) + (delete-region (point-min) (point)) + (goto-char (point-min)) + (while (looking-at "^
  • \\([^ ]+\\).*
  • ") + (replace-match "\\1\\2" t) + (forward-line 1)) + (mm-url-remove-markup)))) (defun nnweb-gmane-search (search) (mm-url-insert @@ -505,11 +521,13 @@ Valid types include `google', `dejanews', and `gmane'.") (nnweb-definition 'address) "?" (mm-url-encode-www-form-urlencoded - `(("query" . ,search))))) + `(("query" . ,search) + ("HITSPERPAGE" . ,(number-to-string nnweb-max-hits)))))) (setq buffer-file-name nil) + (set-buffer-multibyte t) + (mm-decode-coding-region (point-min) (point-max) 'utf-8) t) - (defun nnweb-gmane-identity (url) "Return a unique identifier based on URL." (if (string-match "group=\\(.+\\)" url) diff --git a/lisp/nnwfm.el b/lisp/nnwfm.el index d42730c..90bf4e9 100644 --- a/lisp/nnwfm.el +++ b/lisp/nnwfm.el @@ -1,5 +1,7 @@ ;;; nnwfm.el --- interfacing with a web forum -;; Copyright (C) 2000 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/ntlm.el b/lisp/ntlm.el index e57d3b6..1082a82 100644 --- a/lisp/ntlm.el +++ b/lisp/ntlm.el @@ -18,8 +18,8 @@ ;; ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/parse-time.el b/lisp/parse-time.el index b847048..693f0fc 100644 --- a/lisp/parse-time.el +++ b/lisp/parse-time.el @@ -1,6 +1,7 @@ ;;; parse-time.el --- Parsing time strings -;; Copyright (C) 1996, 2000, 2002 by Free Software Foundation, Inc. +;; Copyright (C) 1996, 2000, 2001, 2002, 2003, 2004, 2005, 2006 +;; Free Software Foundation, Inc. ;; Author: Erik Naggum ;; Keywords: util @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/password.el b/lisp/password.el index 7d10192..9444262 100644 --- a/lisp/password.el +++ b/lisp/password.el @@ -1,6 +1,6 @@ ;;; password.el --- Read passwords from user, possibly using a password cache. -;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Created: 2003-12-21 @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -79,21 +79,29 @@ Whether passwords are cached at all is controlled by `password-cache'." (defvar password-data (make-vector 7 0)) +(defun password-read-from-cache (key) + "Obtain passphrase for KEY from time-limited passphrase cache. +Custom variables `password-cache' and `password-cache-expiry' +regulate cache behavior." + (and password-cache + key + (symbol-value (intern-soft key password-data)))) + (defun password-read (prompt &optional key) "Read password, for use with KEY, from user, or from cache if wanted. KEY indicate the purpose of the password, so the cache can separate passwords. The cache is not used if KEY is nil. It is typically a string. The variable `password-cache' control whether the cache is used." - (or (and password-cache - key - (symbol-value (intern-soft key password-data))) + (or (password-read-from-cache key) (read-passwd prompt))) (defun password-read-and-add (prompt &optional key) "Read password, for use with KEY, from user, or from cache if wanted. Then store the password in the cache. Uses `password-read' and -`password-cache-add'." +`password-cache-add'. +Custom variables `password-cache' and `password-cache-expiry' +regulate cache behavior." (let ((password (password-read prompt key))) (when (and password key) (password-cache-add key password)) @@ -122,6 +130,11 @@ seconds." (set (intern key password-data) password) nil) +(defun password-reset () + "Clear the password cache." + (interactive) + (fillarray password-data 0)) + (provide 'password) ;;; arch-tag: ab160494-16c8-4c68-a4a1-73eebf6686e5 diff --git a/lisp/pgg-def.el b/lisp/pgg-def.el index d6cce0d..058dca4 100644 --- a/lisp/pgg-def.el +++ b/lisp/pgg-def.el @@ -1,6 +1,7 @@ ;;; pgg-def.el --- functions/macros for defining PGG functions -;; Copyright (C) 1999, 2003 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Created: 1999/11/02 @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Code: @@ -82,6 +83,9 @@ Whether the passphrase is cached at all is controlled by (defvar pgg-scheme nil "Current scheme of PGP implementation.") +(defvar pgg-text-mode nil + "If t, inform the recipient that the input is text.") + (defmacro pgg-truncate-key-identifier (key) `(if (> (length ,key) 8) (substring ,key 8) ,key)) diff --git a/lisp/pgg-gpg.el b/lisp/pgg-gpg.el index 2b3e521..5cc48c5 100644 --- a/lisp/pgg-gpg.el +++ b/lisp/pgg-gpg.el @@ -1,8 +1,10 @@ ;;; pgg-gpg.el --- GnuPG support for PGG. -;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno +;; Symmetric encryption support added by: Sascha Wilde ;; Created: 1999/10/28 ;; Keywords: PGP, OpenPGP, GnuPG @@ -20,17 +22,16 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Code: (eval-when-compile - (require 'cl) ; for gpg macros (require 'pgg)) (defgroup pgg-gpg () - "GnuPG interface" + "GnuPG interface." :group 'pgg) (defcustom pgg-gpg-program "gpg" @@ -49,82 +50,178 @@ :type '(choice (const :tag "New `--recipient' option" "--recipient") (const :tag "Old `--remote-user' option" "--remote-user"))) +(defcustom pgg-gpg-use-agent nil + "Whether to use gnupg agent for key caching." + :group 'pgg-gpg + :type 'boolean) + (defvar pgg-gpg-user-id nil "GnuPG ID of your default identity.") -(defun pgg-gpg-process-region (start end passphrase program args) +(defvar pgg-gpg-user-id-alist nil + "An alist mapping from key ID to user ID.") + +(defvar pgg-gpg-read-point nil) +(defvar pgg-gpg-output-file-name nil) +(defvar pgg-gpg-pending-status-list nil) +(defvar pgg-gpg-key-id nil) +(defvar pgg-gpg-passphrase nil) +(defvar pgg-gpg-debug nil) + +(defun pgg-gpg-start-process (args) (let* ((output-file-name (pgg-make-temp-file "pgg-output")) (args - `("--status-fd" "2" - ,@(if passphrase '("--passphrase-fd" "0")) - "--yes" ; overwrite - "--output" ,output-file-name - ,@pgg-gpg-extra-args ,@args)) - (output-buffer pgg-output-buffer) - (errors-buffer pgg-errors-buffer) - (orig-mode (default-file-modes)) + (append (list "--no-tty" + "--status-fd" "1" + "--command-fd" "0" + "--yes" ; overwrite + "--output" output-file-name) + (if pgg-gpg-use-agent '("--use-agent")) + pgg-gpg-extra-args + args)) + (coding-system-for-write 'binary) (process-connection-type nil) - exit-status) - (with-current-buffer (get-buffer-create errors-buffer) - (buffer-disable-undo) - (erase-buffer)) + (orig-mode (default-file-modes)) + (buffer (generate-new-buffer " *pgg-gpg*")) + process) + (with-current-buffer buffer + (make-local-variable 'pgg-gpg-read-point) + (setq pgg-gpg-read-point (point-min)) + (make-local-variable 'pgg-gpg-output-file-name) + (setq pgg-gpg-output-file-name output-file-name) + (make-local-variable 'pgg-gpg-pending-status-list) + (setq pgg-gpg-pending-status-list nil) + (make-local-variable 'pgg-gpg-key-id) + (setq pgg-gpg-key-id nil) + (make-local-variable 'pgg-gpg-passphrase) + (setq pgg-gpg-passphrase nil)) (unwind-protect (progn (set-default-file-modes 448) - (let ((coding-system-for-write 'binary) - (input (buffer-substring-no-properties start end)) - (default-enable-multibyte-characters nil)) - (with-temp-buffer - (when passphrase - (insert passphrase "\n")) - (insert input) - (setq exit-status - (apply #'call-process-region (point-min) (point-max) program - nil errors-buffer nil args)))) - (with-current-buffer (get-buffer-create output-buffer) - (buffer-disable-undo) - (erase-buffer) - (if (file-exists-p output-file-name) - (let ((coding-system-for-read 'raw-text-dos)) - (insert-file-contents output-file-name))) - (set-buffer errors-buffer) - (if (not (equal exit-status 0)) - (insert (format "\n%s exited abnormally: '%s'\n" - program exit-status))))) - (if (file-exists-p output-file-name) - (delete-file output-file-name)) - (set-default-file-modes orig-mode)))) - -(defun pgg-gpg-possibly-cache-passphrase (passphrase &optional key) - (if (and pgg-cache-passphrase - (progn - (goto-char (point-min)) - (re-search-forward "^\\[GNUPG:] GOOD_PASSPHRASE\\>" nil t))) - (pgg-add-passphrase-cache - (or key - (progn - (goto-char (point-min)) - (if (re-search-forward - "^\\[GNUPG:] NEED_PASSPHRASE \\w+ ?\\w*" nil t) - (substring (match-string 0) -8)))) - passphrase))) - -(defvar pgg-gpg-all-secret-keys 'unknown) - -(defun pgg-gpg-lookup-all-secret-keys () - "Return all secret keys present in secret key ring." - (when (eq pgg-gpg-all-secret-keys 'unknown) - (setq pgg-gpg-all-secret-keys '()) - (let ((args (list "--with-colons" "--no-greeting" "--batch" - "--list-secret-keys"))) - (with-temp-buffer - (apply #'call-process pgg-gpg-program nil t nil args) - (goto-char (point-min)) - (while (re-search-forward - "^\\(sec\\|pub\\):[^:]*:[^:]*:[^:]*:\\([^:]*\\)" nil t) - (push (substring (match-string 2) 8) - pgg-gpg-all-secret-keys))))) - pgg-gpg-all-secret-keys) + (setq process + (apply #'start-process "pgg-gpg" buffer pgg-gpg-program args))) + (set-default-file-modes orig-mode)) + (set-process-filter process #'pgg-gpg-process-filter) + (set-process-sentinel process #'pgg-gpg-process-sentinel) + process)) + +(defun pgg-gpg-process-filter (process input) + (if pgg-gpg-debug + (save-excursion + (set-buffer (get-buffer-create " *pgg-gpg-debug*")) + (goto-char (point-max)) + (insert input))) + (if (buffer-live-p (process-buffer process)) + (save-excursion + (set-buffer (process-buffer process)) + (goto-char (point-max)) + (insert input) + (goto-char pgg-gpg-read-point) + (beginning-of-line) + (while (looking-at ".*\n") ;the input line is finished + (save-excursion + (if (looking-at "\\[GNUPG:] \\([A-Z_]+\\)\\>.*") + (let* ((status (match-string 1)) + (symbol (intern-soft (concat "pgg-gpg-status-" + status)))) + (if (member status pgg-gpg-pending-status-list) + (setq pgg-gpg-pending-status-list nil)) + (if (and symbol + (fboundp symbol)) + (funcall symbol process (buffer-substring + (match-beginning 1) + (match-end 0))))))) + (forward-line)) + (setq pgg-gpg-read-point (point))))) + +(defun pgg-gpg-process-sentinel (process status) + (if (buffer-live-p (process-buffer process)) + (save-excursion + (set-buffer (process-buffer process)) + (when pgg-gpg-passphrase + (fillarray pgg-gpg-passphrase 0) + (setq pgg-gpg-passphrase nil)) + ;; Copy the contents of process-buffer to pgg-errors-buffer. + (set-buffer (get-buffer-create pgg-errors-buffer)) + (buffer-disable-undo) + (erase-buffer) + (insert-buffer-substring (process-buffer process)) + ;; Read the contents of the output file to pgg-output-buffer. + (set-buffer (get-buffer-create pgg-output-buffer)) + (buffer-disable-undo) + (erase-buffer) + (if (equal status "finished\n") + (let ((output-file-name + (with-current-buffer (process-buffer process) + pgg-gpg-output-file-name))) + (when (file-exists-p output-file-name) + (let ((coding-system-for-read (if pgg-text-mode + 'raw-text + 'binary))) + (insert-file-contents output-file-name)) + (delete-file output-file-name)))) + (kill-buffer (process-buffer process))))) + +(defun pgg-gpg-wait-for-status (process status-list) + (with-current-buffer (process-buffer process) + (setq pgg-gpg-pending-status-list status-list) + (while (and (eq (process-status process) 'run) + pgg-gpg-pending-status-list) + (accept-process-output process 1)))) + +(defun pgg-gpg-wait-for-completion (process) + (process-send-eof process) + (while (eq (process-status process) 'run) + ;; We can't use accept-process-output instead of sit-for here + ;; because it may cause an interrupt during the sentinel execution. + (sit-for 0.1))) + +(defun pgg-gpg-status-USERID_HINT (process line) + (if (string-match "\\`USERID_HINT \\([^ ]+\\) \\(.*\\)" line) + (let* ((key-id (match-string 1 line)) + (user-id (match-string 2 line)) + (entry (assoc key-id pgg-gpg-user-id-alist))) + (if entry + (setcdr entry user-id) + (setq pgg-gpg-user-id-alist (cons (cons key-id user-id) + pgg-gpg-user-id-alist)))))) + +(defun pgg-gpg-status-NEED_PASSPHRASE (process line) + (if (string-match "\\`NEED_PASSPHRASE \\([^ ]+\\)" line) + (setq pgg-gpg-key-id (match-string 1 line)))) + +(defun pgg-gpg-status-NEED_PASSPHRASE_SYM (process line) + (setq pgg-gpg-key-id 'SYM)) + +(defun pgg-gpg-status-NEED_PASSPHRASE_PIN (process line) + (setq pgg-gpg-key-id 'PIN)) + +(defun pgg-gpg-status-GET_HIDDEN (process line) + (let ((entry (assoc pgg-gpg-key-id pgg-gpg-user-id-alist))) + (if (setq pgg-gpg-passphrase + (if (eq pgg-gpg-key-id 'SYM) + (pgg-read-passphrase + "GnuPG passphrase for symmetric encryption: ") + (pgg-read-passphrase + (format "GnuPG passphrase for %s: " + (if entry + (cdr entry) + pgg-gpg-key-id)) + (if (eq pgg-gpg-key-id 'PIN) + "PIN" + pgg-gpg-key-id)))) + (process-send-string process (concat pgg-gpg-passphrase "\n"))))) + +(defun pgg-gpg-status-GOOD_PASSPHRASE (process line) + (when (and pgg-gpg-passphrase + (stringp pgg-gpg-key-id)) + (pgg-add-passphrase-to-cache pgg-gpg-key-id pgg-gpg-passphrase) + (setq pgg-gpg-passphrase nil))) + +(defun pgg-gpg-status-BAD_PASSPHRASE (process line) + (when pgg-gpg-passphrase + (fillarray pgg-gpg-passphrase 0) + (setq pgg-gpg-passphrase nil))) (defun pgg-gpg-lookup-key (string &optional type) "Search keys associated with STRING." @@ -138,18 +235,15 @@ nil t) (substring (match-string 2) 8))))) -(defun pgg-gpg-encrypt-region (start end recipients &optional sign) +(defun pgg-gpg-encrypt-region (start end recipients &optional sign passphrase) "Encrypt the current region between START and END. + If optional argument SIGN is non-nil, do a combined sign and encrypt." (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) - (passphrase - (when sign - (pgg-read-passphrase - (format "GnuPG passphrase for %s: " pgg-gpg-user-id) - pgg-gpg-user-id))) (args (append - (list "--batch" "--armor" "--always-trust" "--encrypt") + '("--armor" "--always-trust" "--encrypt") + (if pgg-text-mode '("--textmode")) (if sign (list "--sign" "--local-user" pgg-gpg-user-id)) (if recipients (apply #'nconc @@ -157,116 +251,101 @@ If optional argument SIGN is non-nil, do a combined sign and encrypt." (list pgg-gpg-recipient-argument rcpt)) (append recipients (if pgg-encrypt-for-me - (list pgg-gpg-user-id))))))))) - (pgg-as-lbt start end 'CRLF - (pgg-gpg-process-region start end passphrase pgg-gpg-program args)) - (when sign - (with-current-buffer pgg-errors-buffer - ;; Possibly cache passphrase under, e.g. "jas", for future sign. - (pgg-gpg-possibly-cache-passphrase passphrase pgg-gpg-user-id) - ;; Possibly cache passphrase under, e.g. B565716F, for future decrypt. - (pgg-gpg-possibly-cache-passphrase passphrase))) - (pgg-process-when-success))) - -(defun pgg-gpg-decrypt-region (start end) - "Decrypt the current region between START and END." - (let* ((current-buffer (current-buffer)) - (message-keys (with-temp-buffer - (insert-buffer-substring current-buffer) - (pgg-decode-armor-region (point-min) (point-max)))) - (secret-keys (pgg-gpg-lookup-all-secret-keys)) - (key (pgg-gpg-select-matching-key message-keys secret-keys)) - (pgg-gpg-user-id (or key pgg-gpg-user-id pgg-default-user-id)) - (passphrase - (pgg-read-passphrase - (format "GnuPG passphrase for %s: " pgg-gpg-user-id) - pgg-gpg-user-id)) - (args '("--batch" "--decrypt"))) - (pgg-gpg-process-region start end passphrase pgg-gpg-program args) - (with-current-buffer pgg-errors-buffer - (pgg-gpg-possibly-cache-passphrase passphrase pgg-gpg-user-id) - (goto-char (point-min)) - (re-search-forward "^\\[GNUPG:] DECRYPTION_OKAY\\>" nil t)))) + (list pgg-gpg-user-id)))))))) + (process (pgg-gpg-start-process args))) + (if (and sign (not pgg-gpg-use-agent)) + (pgg-gpg-wait-for-status process '("BEGIN_SIGNING" "GOOD_PASSPHRASE"))) + (process-send-region process start end) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] END_ENCRYPTION\\>" + nil t)))))) + +(defun pgg-gpg-encrypt-symmetric-region (start end &optional passphrase) + "Encrypt the current region between START and END with symmetric cipher." + (let* ((args + (append '("--armor" "--symmetric") + (if pgg-text-mode '("--textmode")))) + (process (pgg-gpg-start-process args))) + (pgg-gpg-wait-for-status process '("BEGIN_ENCRYPTION")) + (process-send-region process start end) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] END_ENCRYPTION\\>" + nil t)))))) -(defun pgg-gpg-select-matching-key (message-keys secret-keys) - "Choose a key from MESSAGE-KEYS that matches one of the keys in SECRET-KEYS." - (loop for message-key in message-keys - for message-key-id = (and (equal (car message-key) 1) - (cdr (assq 'key-identifier message-key))) - for key = (and message-key-id (pgg-lookup-key message-key-id 'encrypt)) - when (and key (member key secret-keys)) return key)) +(defun pgg-gpg-decrypt-region (start end &optional passphrase) + "Decrypt the current region between START and END." + (let* ((args '("--decrypt")) + (process (pgg-gpg-start-process args))) + (process-send-region process start end) + (pgg-gpg-wait-for-status process '("BEGIN_DECRYPTION")) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] DECRYPTION_OKAY\\>" + nil t)))))) -(defun pgg-gpg-sign-region (start end &optional cleartext) +(defun pgg-gpg-sign-region (start end &optional cleartext passphrase) "Make detached signature from text between START and END." (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) - (passphrase - (pgg-read-passphrase - (format "GnuPG passphrase for %s: " pgg-gpg-user-id) - pgg-gpg-user-id)) (args - (list (if cleartext "--clearsign" "--detach-sign") - "--armor" "--batch" "--verbose" - "--local-user" pgg-gpg-user-id)) - (inhibit-read-only t) - buffer-read-only) - (pgg-as-lbt start end 'CRLF - (pgg-gpg-process-region start end passphrase pgg-gpg-program args)) - (with-current-buffer pgg-errors-buffer - ;; Possibly cache passphrase under, e.g. "jas", for future sign. - (pgg-gpg-possibly-cache-passphrase passphrase pgg-gpg-user-id) - ;; Possibly cache passphrase under, e.g. B565716F, for future decrypt. - (pgg-gpg-possibly-cache-passphrase passphrase)) - (pgg-process-when-success))) + (append (list (if cleartext "--clearsign" "--detach-sign") + "--armor" "--verbose" + "--local-user" pgg-gpg-user-id) + (if pgg-text-mode '("--textmode")))) + (process (pgg-gpg-start-process args))) + (unless pgg-gpg-use-agent + (pgg-gpg-wait-for-status process '("BEGIN_SIGNING" "GOOD_PASSPHRASE"))) + (process-send-region process start end) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] SIG_CREATED\\>" + nil t)))))) (defun pgg-gpg-verify-region (start end &optional signature) "Verify region between START and END as the detached signature SIGNATURE." - (let ((args '("--batch" "--verify"))) + (let ((args '("--verify")) + process) (when (stringp signature) (setq args (append args (list signature)))) - (setq args (append args '("-"))) - (pgg-gpg-process-region start end nil pgg-gpg-program args) - (with-current-buffer pgg-errors-buffer - (goto-char (point-min)) - (while (re-search-forward "^gpg: \\(.*\\)\n" nil t) - (with-current-buffer pgg-output-buffer - (insert-buffer-substring pgg-errors-buffer - (match-beginning 1) (match-end 0))) - (delete-region (match-beginning 0) (match-end 0))) - (goto-char (point-min)) - (re-search-forward "^\\[GNUPG:] GOODSIG\\>" nil t)))) + (setq process (pgg-gpg-start-process (append args '("-")))) + (process-send-region process start end) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] GOODSIG\\>" + nil t)))))) (defun pgg-gpg-insert-key () "Insert public key at point." (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) - (args (list "--batch" "--export" "--armor" - pgg-gpg-user-id))) - (pgg-gpg-process-region (point)(point) nil pgg-gpg-program args) + (args (list "--export" "--armor" + pgg-gpg-user-id)) + (process (pgg-gpg-start-process args))) + (pgg-gpg-wait-for-completion process) (insert-buffer-substring pgg-output-buffer))) (defun pgg-gpg-snarf-keys-region (start end) "Add all public keys in region between START and END to the keyring." - (let ((args '("--import" "--batch" "-")) status) - (pgg-gpg-process-region start end nil pgg-gpg-program args) - (set-buffer pgg-errors-buffer) - (goto-char (point-min)) - (when (re-search-forward "^\\[GNUPG:] IMPORT_RES\\>" nil t) - (setq status (buffer-substring (match-end 0) - (progn (end-of-line)(point))) - status (vconcat (mapcar #'string-to-int (split-string status)))) - (erase-buffer) - (insert (format "Imported %d key(s). -\tArmor contains %d key(s) [%d bad, %d old].\n" - (+ (aref status 2) - (aref status 10)) - (aref status 0) - (aref status 1) - (+ (aref status 4) - (aref status 11))) - (if (zerop (aref status 9)) - "" - "\tSecret keys are imported.\n"))) - (append-to-buffer pgg-output-buffer (point-min)(point-max)) - (pgg-process-when-success))) + (let* ((args '("--import" "-")) + (process (pgg-gpg-start-process args)) + status) + (process-send-region process start end) + (pgg-gpg-wait-for-completion process) + (save-excursion + (set-buffer (get-buffer-create pgg-errors-buffer)) + (goto-char (point-max)) + (not (null (re-search-backward "^\\[GNUPG:] IMPORT_RES\\>" + nil t)))))) (provide 'pgg-gpg) diff --git a/lisp/pgg-parse.el b/lisp/pgg-parse.el index dbdb0cb..40ebcd9 100644 --- a/lisp/pgg-parse.el +++ b/lisp/pgg-parse.el @@ -1,6 +1,7 @@ ;;; pgg-parse.el --- OpenPGP packet parsing -;; Copyright (C) 1999, 2003 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Created: 1999/10/28 @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -38,7 +39,7 @@ (eval-when-compile (require 'cl)) (defgroup pgg-parse () - "OpenPGP packet parsing" + "OpenPGP packet parsing." :group 'pgg) (defcustom pgg-parse-public-key-algorithm-alist @@ -56,7 +57,8 @@ (cons (sexp :tag "Number") (sexp :tag "Type")))) (defcustom pgg-parse-hash-algorithm-alist - '((1 . MD5) (2 . SHA1) (3 . RIPEMD160) (5 . MD2)) + '((1 . MD5) (2 . SHA1) (3 . RIPEMD160) (5 . MD2) (8 . SHA256) (9 . SHA384) + (10 . SHA512)) "Alist of the assigned number to the cryptographic hash algorithm." :group 'pgg-parse :type '(repeat @@ -111,7 +113,7 @@ `(mapconcat (lambda (c) (format "%02X" (pgg-char-int c))) ,string "") ;; `(upcase (apply #'format "%02x%02x%02x%02x%02x%02x%02x%02x" - ;; (string-to-int-list ,string))) + ;; (string-to-number-list ,string))) ) (defmacro pgg-parse-time-field (bytes) @@ -134,7 +136,7 @@ (defmacro pgg-read-bytes (nbytes) `(mapcar #'pgg-char-int (pgg-read-bytes-string ,nbytes)) - ;; `(string-to-int-list (pgg-read-bytes-string ,nbytes)) + ;; `(string-to-number-list (pgg-read-bytes-string ,nbytes)) ) (defmacro pgg-read-body-string (ptag) @@ -144,7 +146,7 @@ (defmacro pgg-read-body (ptag) `(mapcar #'pgg-char-int (pgg-read-body-string ,ptag)) - ;; `(string-to-int-list (pgg-read-body-string ,ptag)) + ;; `(string-to-number-list (pgg-read-body-string ,ptag)) ) (defalias 'pgg-skip-bytes 'forward-char) diff --git a/lisp/pgg-pgp.el b/lisp/pgg-pgp.el index 0d7dfac..d4bfb7b 100644 --- a/lisp/pgg-pgp.el +++ b/lisp/pgg-pgp.el @@ -1,6 +1,7 @@ ;;; pgg-pgp.el --- PGP 2.* and 6.* support for PGG. -;; Copyright (C) 1999, 2000, 2003 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Created: 1999/11/02 @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Code: @@ -30,7 +31,7 @@ (require 'pgg)) (defgroup pgg-pgp () - "PGP 2.* and 6.* interface" + "PGP 2.* and 6.* interface." :group 'pgg) (defcustom pgg-pgp-program "pgp" @@ -131,41 +132,57 @@ Bourne shell or its equivalent \(not tcsh) is needed for \"2>\"." (buffer-substring (point)(progn (end-of-line) (point))))) 2)))))) -(defun pgg-pgp-encrypt-region (start end recipients) +(defun pgg-pgp-encrypt-region (start end recipients &optional sign passphrase) "Encrypt the current region between START and END." (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) + (passphrase (or passphrase + (when sign + (pgg-read-passphrase + (format "PGP passphrase for %s: " + pgg-pgp-user-id) + pgg-pgp-user-id)))) (args - `("+encrypttoself=off +verbose=1" "+batchmode" - "+language=us" "-fate" - ,@(if recipients - (mapcar (lambda (rcpt) (concat "\"" rcpt "\"")) - (append recipients - (if pgg-encrypt-for-me - (list pgg-pgp-user-id)))))))) + (append + `("+encrypttoself=off +verbose=1" "+batchmode" + "+language=us" "-fate" + ,@(if recipients + (mapcar (lambda (rcpt) (concat "\"" rcpt "\"")) + (append recipients + (if pgg-encrypt-for-me + (list pgg-pgp-user-id)))))) + (if sign '("-s" "-u" pgg-pgp-user-id))))) (pgg-pgp-process-region start end nil pgg-pgp-program args) (pgg-process-when-success nil))) -(defun pgg-pgp-decrypt-region (start end) - "Decrypt the current region between START and END." +(defun pgg-pgp-decrypt-region (start end &optional passphrase) + "Decrypt the current region between START and END. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (key (pgg-pgp-lookup-key pgg-pgp-user-id 'encrypt)) (passphrase - (pgg-read-passphrase - (format "PGP passphrase for %s: " pgg-pgp-user-id) key)) + (or passphrase + (pgg-read-passphrase + (format "PGP passphrase for %s: " pgg-pgp-user-id) key))) (args - '("+verbose=1" "+batchmode" "+language=us" "-f"))) + '("+verbose=1" "+batchmode" "+language=us" "-f"))) (pgg-pgp-process-region start end passphrase pgg-pgp-program args) (pgg-process-when-success (if pgg-cache-passphrase - (pgg-add-passphrase-cache key passphrase))))) + (pgg-add-passphrase-to-cache key passphrase))))) + +(defun pgg-pgp-sign-region (start end &optional clearsign passphrase) + "Make detached signature from text between START and END. -(defun pgg-pgp-sign-region (start end &optional clearsign) - "Make detached signature from text between START and END." +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (passphrase - (pgg-read-passphrase - (format "PGP passphrase for %s: " pgg-pgp-user-id) - (pgg-pgp-lookup-key pgg-pgp-user-id 'sign))) + (or passphrase + (pgg-read-passphrase + (format "PGP passphrase for %s: " pgg-pgp-user-id) + (pgg-pgp-lookup-key pgg-pgp-user-id 'sign)))) (args (list (if clearsign "-fast" "-fbast") "+verbose=1" "+language=us" "+batchmode" @@ -180,7 +197,7 @@ Bourne shell or its equivalent \(not tcsh) is needed for \"2>\"." (point)) (point-max)))))) (if pgg-cache-passphrase - (pgg-add-passphrase-cache + (pgg-add-passphrase-to-cache (cdr (assq 'key-identifier packet)) passphrase))))))) diff --git a/lisp/pgg-pgp5.el b/lisp/pgg-pgp5.el index 372cf48..75c96e5 100644 --- a/lisp/pgg-pgp5.el +++ b/lisp/pgg-pgp5.el @@ -1,6 +1,7 @@ ;;; pgg-pgp5.el --- PGP 5.* support for PGG. -;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Created: 1999/11/02 @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Code: @@ -30,7 +31,7 @@ (require 'pgg)) (defgroup pgg-pgp5 () - "PGP 5.* interface" + "PGP 5.* interface." :group 'pgg) (defcustom pgg-pgp5-pgpe-program "pgpe" @@ -142,41 +143,51 @@ Bourne shell or its equivalent \(not tcsh) is needed for \"2>\"." (buffer-substring (match-end 0)(progn (end-of-line)(point))))) 2))))) -(defun pgg-pgp5-encrypt-region (start end recipients &optional sign) +(defun pgg-pgp5-encrypt-region (start end recipients &optional sign passphrase) "Encrypt the current region between START and END." (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) + (passphrase (or passphrase + (when sign + (pgg-read-passphrase + (format "PGP passphrase for %s: " + pgg-pgp5-user-id) + pgg-pgp5-user-id)))) (args - `("+NoBatchInvalidKeys=off" "-fat" "+batchmode=1" - ,@(if recipients - (apply #'append - (mapcar (lambda (rcpt) - (list "-r" - (concat "\"" rcpt "\""))) - (append recipients - (if pgg-encrypt-for-me - (list pgg-pgp5-user-id))))))))) + (append + `("+NoBatchInvalidKeys=off" "-fat" "+batchmode=1" + ,@(if recipients + (apply #'append + (mapcar (lambda (rcpt) + (list "-r" + (concat "\"" rcpt "\""))) + (append recipients + (if pgg-encrypt-for-me + (list pgg-pgp5-user-id))))))) + (if sign '("-s" "-u" pgg-pgp5-user-id))))) (pgg-pgp5-process-region start end nil pgg-pgp5-pgpe-program args) (pgg-process-when-success nil))) -(defun pgg-pgp5-decrypt-region (start end) +(defun pgg-pgp5-decrypt-region (start end &optional passphrase) "Decrypt the current region between START and END." (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (passphrase - (pgg-read-passphrase - (format "PGP passphrase for %s: " pgg-pgp5-user-id) - (pgg-pgp5-lookup-key pgg-pgp5-user-id 'encrypt))) + (or passphrase + (pgg-read-passphrase + (format "PGP passphrase for %s: " pgg-pgp5-user-id) + (pgg-pgp5-lookup-key pgg-pgp5-user-id 'encrypt)))) (args '("+verbose=1" "+batchmode=1" "+language=us" "-f"))) (pgg-pgp5-process-region start end passphrase pgg-pgp5-pgpv-program args) (pgg-process-when-success nil))) -(defun pgg-pgp5-sign-region (start end &optional clearsign) +(defun pgg-pgp5-sign-region (start end &optional clearsign passphrase) "Make detached signature from text between START and END." (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (passphrase - (pgg-read-passphrase - (format "PGP passphrase for %s: " pgg-pgp5-user-id) - (pgg-pgp5-lookup-key pgg-pgp5-user-id 'sign))) + (or passphrase + (pgg-read-passphrase + (format "PGP passphrase for %s: " pgg-pgp5-user-id) + (pgg-pgp5-lookup-key pgg-pgp5-user-id 'sign)))) (args (list (if clearsign "-fat" "-fbat") "+verbose=1" "+language=us" "+batchmode=1" @@ -190,7 +201,7 @@ Bourne shell or its equivalent \(not tcsh) is needed for \"2>\"." (point)) (point-max)))))) (if pgg-cache-passphrase - (pgg-add-passphrase-cache + (pgg-add-passphrase-to-cache (cdr (assq 'key-identifier packet)) passphrase))))))) diff --git a/lisp/pgg.el b/lisp/pgg.el index abb49a9..468fbc6 100644 --- a/lisp/pgg.el +++ b/lisp/pgg.el @@ -1,8 +1,10 @@ ;;; pgg.el --- glue for the various PGP implementations. -;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno +;; Symmetric encryption added by: Sascha Wilde ;; Created: 1999/10/28 ;; Keywords: PGP @@ -20,8 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -34,20 +36,10 @@ ;; Don't merge these two `eval-when-compile's. (eval-when-compile (require 'cl)) -;; Fixme: This would be better done with an autoload for -;; `url-insert-file-contents', and the url stuff rationalized. -;; (`locate-library' can say whether the url code is available.) -(eval-when-compile - (ignore-errors - (require 'w3) - (require 'url))) ;;; @ utility functions ;;; -(defvar pgg-fetch-key-function (if (fboundp 'url-insert-file-contents) - (function pgg-fetch-key-with-w3))) - (defun pgg-invoke (func scheme &rest args) (progn (require (intern (format "pgg-%s" scheme))) @@ -76,29 +68,73 @@ (set-window-buffer window buffer) (shrink-window-if-larger-than-buffer window))) +;; XXX `pgg-display-output-buffer' is a horrible name for this function. +;; It should be something like `pgg-situate-output-or-display-error'. (defun pgg-display-output-buffer (start end status) + "Situate en/decryption results or pop up an error buffer. + +Text from START to END is replaced by contents of output buffer if STATUS +is true, or else the output buffer is displayed." (if status - (progn - (delete-region start end) - (insert-buffer-substring pgg-output-buffer) - (decode-coding-region start (point) buffer-file-coding-system)) - (let ((temp-buffer-show-function - (function pgg-temp-buffer-show-function))) - (with-output-to-temp-buffer pgg-echo-buffer - (set-buffer standard-output) - (insert-buffer-substring pgg-errors-buffer))))) - -(defun pgg-read-passphrase (prompt &optional key) - (when pgg-cache-passphrase - (password-read prompt (setq key (pgg-truncate-key-identifier key))))) - -(defun pgg-add-passphrase-cache (key passphrase) + (pgg-situate-output start end) + (pgg-display-error-buffer))) + +(defun pgg-situate-output (start end) + "Place en/decryption result in place of current text from START to END." + (delete-region start end) + (insert-buffer-substring pgg-output-buffer) + (decode-coding-region start (point) buffer-file-coding-system)) + +(defun pgg-display-error-buffer () + "Pop up an error buffer indicating the reason for an en/decryption failure." + (let ((temp-buffer-show-function + (function pgg-temp-buffer-show-function))) + (with-output-to-temp-buffer pgg-echo-buffer + (set-buffer standard-output) + (insert-buffer-substring pgg-errors-buffer)))) + +(defun pgg-read-passphrase (prompt &optional key notruncate) + "Using PROMPT, obtain passphrase for KEY from cache or user. + +Truncate the key to 8 trailing characters unless NOTRUNCATE is true +\(default false). + +Custom variables `pgg-cache-passphrase' and `pgg-passphrase-cache-expiry' +regulate cache behavior." + (password-read prompt (if notruncate + key + (pgg-truncate-key-identifier key)))) + +(defun pgg-add-passphrase-to-cache (key passphrase &optional notruncate) + "Associate KEY with PASSPHRASE in time-limited passphrase cache. + +Truncate the key to 8 trailing characters unless NOTRUNCATE is true +\(default false). + +Custom variables `pgg-cache-passphrase' and `pgg-passphrase-cache-expiry' +regulate cache behavior." (let ((password-cache-expiry pgg-passphrase-cache-expiry)) - (password-cache-add (setq key (pgg-truncate-key-identifier key)) + (password-cache-add (if notruncate + key + (pgg-truncate-key-identifier key)) passphrase))) -(defun pgg-remove-passphrase-cache (key) - (password-cache-remove key)) +(defun pgg-remove-passphrase-from-cache (key &optional notruncate) + "Omit passphrase associated with KEY in time-limited passphrase cache. + +Truncate the key to 8 trailing characters unless NOTRUNCATE is true +\(default false). + +This is a no-op if there is not entry for KEY (eg, it's already expired. + +The memory for the passphrase is filled with underscores to clear any +references to it. + +Custom variables `pgg-cache-passphrase' and `pgg-passphrase-cache-expiry' +regulate cache behavior." + (password-cache-remove (if notruncate + key + (pgg-truncate-key-identifier key)))) (defmacro pgg-convert-lbt-region (start end lbt) `(let ((pgg-conversion-end (set-marker (make-marker) ,end))) @@ -149,93 +185,156 @@ ;;; ;;;###autoload -(defun pgg-encrypt-region (start end rcpts &optional sign) +(defun pgg-encrypt-region (start end rcpts &optional sign passphrase) "Encrypt the current region between START and END for RCPTS. -If optional argument SIGN is non-nil, do a combined sign and encrypt." + +If optional argument SIGN is non-nil, do a combined sign and encrypt. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive (list (region-beginning)(region-end) (split-string (read-string "Recipients: ") "[ \t,]+"))) (let ((status (pgg-save-coding-system start end (pgg-invoke "encrypt-region" (or pgg-scheme pgg-default-scheme) - (point-min) (point-max) rcpts sign)))) + (point-min) (point-max) rcpts sign passphrase)))) + (when (interactive-p) + (pgg-display-output-buffer start end status)) + status)) + +;;;###autoload +(defun pgg-encrypt-symmetric-region (start end &optional passphrase) + "Encrypt the current region between START and END symmetric with passphrase. + +If optional PASSPHRASE is not specified, it will be obtained from the +cache or user." + (interactive "r") + (let ((status + (pgg-save-coding-system start end + (pgg-invoke "encrypt-symmetric-region" + (or pgg-scheme pgg-default-scheme) + (point-min) (point-max) passphrase)))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) ;;;###autoload -(defun pgg-encrypt (rcpts &optional sign start end) +(defun pgg-encrypt-symmetric (&optional start end passphrase) + "Encrypt the current buffer using a symmetric, rather than key-pair, cipher. + +If optional arguments START and END are specified, only encrypt within +the region. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." + (interactive) + (let* ((start (or start (point-min))) + (end (or end (point-max))) + (status (pgg-encrypt-symmetric-region start end passphrase))) + (when (interactive-p) + (pgg-display-output-buffer start end status)) + status)) + +;;;###autoload +(defun pgg-encrypt (rcpts &optional sign start end passphrase) "Encrypt the current buffer for RCPTS. + If optional argument SIGN is non-nil, do a combined sign and encrypt. + If optional arguments START and END are specified, only encrypt within -the region." +the region. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive (list (split-string (read-string "Recipients: ") "[ \t,]+"))) (let* ((start (or start (point-min))) (end (or end (point-max))) - (status (pgg-encrypt-region start end rcpts sign))) + (status (pgg-encrypt-region start end rcpts sign passphrase))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) ;;;###autoload -(defun pgg-decrypt-region (start end) - "Decrypt the current region between START and END." +(defun pgg-decrypt-region (start end &optional passphrase) + "Decrypt the current region between START and END. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive "r") (let* ((buf (current-buffer)) (status (pgg-save-coding-system start end (pgg-invoke "decrypt-region" (or pgg-scheme pgg-default-scheme) - (point-min) (point-max))))) + (point-min) (point-max) passphrase)))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) ;;;###autoload -(defun pgg-decrypt (&optional start end) +(defun pgg-decrypt (&optional start end passphrase) "Decrypt the current buffer. + If optional arguments START and END are specified, only decrypt within -the region." +the region. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive "") (let* ((start (or start (point-min))) (end (or end (point-max))) - (status (pgg-decrypt-region start end))) + (status (pgg-decrypt-region start end passphrase))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) ;;;###autoload -(defun pgg-sign-region (start end &optional cleartext) +(defun pgg-sign-region (start end &optional cleartext passphrase) "Make the signature from text between START and END. + If the optional 3rd argument CLEARTEXT is non-nil, it does not create a detached signature. + If this function is called interactively, CLEARTEXT is enabled -and the the output is displayed." +and the the output is displayed. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive "r") (let ((status (pgg-save-coding-system start end (pgg-invoke "sign-region" (or pgg-scheme pgg-default-scheme) (point-min) (point-max) - (or (interactive-p) cleartext))))) + (or (interactive-p) cleartext) + passphrase)))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) ;;;###autoload -(defun pgg-sign (&optional cleartext start end) +(defun pgg-sign (&optional cleartext start end passphrase) "Sign the current buffer. + If the optional argument CLEARTEXT is non-nil, it does not create a detached signature. + If optional arguments START and END are specified, only sign data within the region. + If this function is called interactively, CLEARTEXT is enabled -and the the output is displayed." +and the the output is displayed. + +If optional PASSPHRASE is not specified, it will be obtained from the +passphrase cache or user." (interactive "") (let* ((start (or start (point-min))) (end (or end (point-max))) - (status (pgg-sign-region start end (or (interactive-p) cleartext)))) + (status (pgg-sign-region start end + (or (interactive-p) cleartext) + passphrase))) (when (interactive-p) (pgg-display-output-buffer start end status)) status)) - + ;;;###autoload (defun pgg-verify-region (start end &optional signature fetch) "Verify the current region between START and END. @@ -266,7 +365,7 @@ signer's public key from `pgg-default-keyserver-address'." (or (cdr (assq 'preferred-key-server packet)) pgg-default-keyserver-address)) (pgg-fetch-key keyserver key)) - (setq status + (setq status (pgg-save-coding-system start end (pgg-invoke "verify-region" (or pgg-scheme pgg-default-scheme) (point-min) (point-max) signature))) @@ -298,7 +397,8 @@ within the region." (with-output-to-temp-buffer pgg-echo-buffer (set-buffer standard-output) (insert-buffer-substring (if status pgg-output-buffer - pgg-errors-buffer))))))) + pgg-errors-buffer))))) + status)) ;;;###autoload (defun pgg-insert-key () @@ -327,7 +427,6 @@ within the region." (defun pgg-insert-url-with-w3 (url) (ignore-errors - (require 'w3) (require 'url) (let (buffer-file-name) (url-insert-file-contents url)))) diff --git a/lisp/pop3.el b/lisp/pop3.el index d3e6fea..8282f9c 100644 --- a/lisp/pop3.el +++ b/lisp/pop3.el @@ -1,7 +1,7 @@ ;;; pop3.el --- Post Office Protocol (RFC 1460) interface -;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +;; 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Richard L. Pieri ;; Maintainer: FSF @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -38,7 +38,7 @@ (require 'mail-utils) (defgroup pop3 nil - "Post Office Protocol" + "Post Office Protocol." :group 'mail :group 'mail-source) @@ -75,11 +75,11 @@ (defcustom pop3-authentication-scheme 'pass "*POP3 authentication scheme. -Defaults to 'pass, for the standard USER/PASS authentication. Other valid -values are 'apop." - :version "22.1" ;; Oort Gnus - :type '(choice (const :tag "USER/PASS" pass) +Defaults to `pass', for the standard USER/PASS authentication. The other +valid value is 'apop'." + :type '(choice (const :tag "Normal user/password" pass) (const :tag "APOP" apop)) + :version "22.1" ;; Oort Gnus :group 'pop3) (defcustom pop3-leave-mail-on-server nil @@ -166,11 +166,9 @@ Shorter values mean quicker response, but are more CPU intensive.") (unless pop3-leave-mail-on-server (pop3-dele process n)) (setq n (+ 1 n)) - (if pop3-debug (sit-for 1) (sit-for 0.1)) - ) + (if pop3-debug (sit-for 1) (sit-for 0.1))) ; why? (pop3-quit process)) - (kill-buffer crashbuf) - ) + (kill-buffer crashbuf)) t) (defun pop3-get-message-count () @@ -194,6 +192,23 @@ Shorter values mean quicker response, but are more CPU intensive.") (pop3-quit process) message-count)) +(autoload 'open-tls-stream "tls") +(autoload 'starttls-open-stream "starttls") +(autoload 'starttls-negotiate "starttls") ; avoid warning + +(defcustom pop3-stream-type nil + "*Transport security type for POP3 connexions. +This may be either nil (plain connexion), `ssl' (use an +SSL/TSL-secured stream) or `starttls' (use the starttls mechanism +to turn on TLS security after opening the stream). However, if +this is nil, `ssl' is assumed for connexions to port +995 (pop3s)." + :version "23.0" ;; No Gnus + :group 'pop3 + :type '(choice (const :tag "Plain" nil) + (const :tag "SSL/TLS" ssl) + (const starttls))) + (defun pop3-open-server (mailhost port) "Open TCP connection to MAILHOST on PORT. Returns the process associated with the connection." @@ -205,7 +220,44 @@ Returns the process associated with the connection." mailhost))) (erase-buffer) (setq pop3-read-point (point-min)) - (setq process (open-network-stream "POP" (current-buffer) mailhost port)) + (setq process + (cond + ((or (eq pop3-stream-type 'ssl) + (and (not pop3-stream-type) (member port '(995 "pop3s")))) + ;; gnutls-cli, openssl don't accept service names + (if (or (equal port "pop3s") + (null port)) + (setq port 995)) + (let ((process (open-tls-stream "POP" (current-buffer) + mailhost port))) + (when process + ;; There's a load of info printed that needs deleting. + (while (when (memq (process-status process) '(open run)) + (pop3-accept-process-output process) + (goto-char (point-max)) + (forward-line -1) + (if (looking-at "\\+OK") + (progn + (delete-region (point-min) (point)) + nil) + (pop3-quit process) + (error "POP SSL connexion failed")))) + process))) + ((eq pop3-stream-type 'starttls) + ;; gnutls-cli, openssl don't accept service names + (if (equal port "pop3") + (setq port 110)) + (let ((process (starttls-open-stream "POP" (current-buffer) + mailhost (or port 110)))) + (pop3-send-command process "STLS") + (let ((response (pop3-read-response process t))) + (if (and response (string-match "+OK" response)) + (starttls-negotiate process) + (pop3-quit process) + (error "POP server doesn't support starttls"))) + process)) + (t + (open-network-stream "POP" (current-buffer) mailhost port)))) (let ((response (pop3-read-response process t))) (setq pop3-timestamp (substring response (or (string-match "<" response) 0) @@ -312,6 +364,8 @@ If NOW, use that time instead." ;; Date: 08 Jul 1996 23:22:24 -0400 ;; should be ;; Tue Jul 9 09:04:21 1996 + + ;; Fixme: This should use timezone on the date field contents. (setq date (cond ((not date) "Tue Jan 1 00:00:0 1900") @@ -353,7 +407,7 @@ If NOW, use that time instead." (pop3-send-command process (format "USER %s" user)) (let ((response (pop3-read-response process t))) (if (not (and response (string-match "+OK" response))) - (error (format "USER %s not valid" user))))) + (error "USER %s not valid" user)))) (defun pop3-pass (process) "Send authentication information to the server." @@ -369,7 +423,7 @@ If NOW, use that time instead." (setq pass (read-passwd (format "Password for %s: " pop3-maildrop)))) (if pass - (let ((hash (md5 (concat pop3-timestamp pass)))) + (let ((hash (md5 (concat pop3-timestamp pass) nil nil 'binary))) (pop3-send-command process (format "APOP %s %s" user hash)) (let ((response (pop3-read-response process t))) (if (not (and response (string-match "+OK" response))) @@ -382,8 +436,8 @@ If NOW, use that time instead." "Return the number of messages in the maildrop and the maildrop's size." (pop3-send-command process "STAT") (let ((response (pop3-read-response process t))) - (list (string-to-int (nth 1 (split-string response " "))) - (string-to-int (nth 2 (split-string response " ")))) + (list (string-to-number (nth 1 (split-string response " "))) + (string-to-number (nth 2 (split-string response " ")))) )) (defun pop3-list (process &optional msg) @@ -433,7 +487,7 @@ This function currently does nothing.") "Return highest accessed message-id number for the session." (pop3-send-command process "LAST") (let ((response (pop3-read-response process t))) - (string-to-int (nth 1 (split-string response " "))) + (string-to-number (nth 1 (split-string response " "))) )) (defun pop3-rset (process) @@ -480,6 +534,13 @@ and close the connection." ;; -ERR [invalid password] ;; -ERR [unable to lock maildrop] +;; STLS (RFC 2595) +;; Arguments: none +;; Restrictions: Only permitted in AUTHORIZATION state. +;; Possible responses: +;; +OK +;; -ERR + ;;; TRANSACTION STATE ;; STAT diff --git a/lisp/qp.el b/lisp/qp.el index 1004abe..7ae1412 100644 --- a/lisp/qp.el +++ b/lisp/qp.el @@ -1,7 +1,7 @@ ;;; qp.el --- Quoted-Printable functions -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2005 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail, extensions @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -69,7 +69,7 @@ them into characters should be done separately." (cond ((eq (char-after (1+ (point))) ?\n) (delete-char 2)) ((looking-at "=[0-9A-F][0-9A-F]") - (let ((byte (string-to-int (buffer-substring (1+ (point)) + (let ((byte (string-to-number (buffer-substring (1+ (point)) (+ 3 (point))) 16))) (mm-insert-byte byte 1) @@ -118,7 +118,7 @@ encode lines starting with \"From\"." (not (eobp))) (insert (prog1 - ;; To unibyte in case of Emacs 22 eight-bit. + ;; To unibyte in case of Emacs 23 (unicode) eight-bit. (format "=%02X" (mm-multibyte-char-to-unibyte (char-after))) (delete-char 1)))) ;; Encode white space at the end of lines. diff --git a/lisp/rfc1843.el b/lisp/rfc1843.el index f43bfc0..aac7575 100644 --- a/lisp/rfc1843.el +++ b/lisp/rfc1843.el @@ -1,5 +1,7 @@ ;;; rfc1843.el --- HZ (rfc1843) decoding -;; Copyright (c) 1998, 1999, 2000, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: news HZ HZ+ mail i18n @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -35,6 +37,10 @@ (eval-when-compile (require 'cl)) (require 'mm-util) +(defvar gnus-decode-encoded-word-function) +(defvar gnus-decode-header-function) +(defvar gnus-newsgroup-name) + (defvar rfc1843-word-regexp "~\\({\\([\041-\167][\041-\176]\\| \\)+\\)\\(~}\\|$\\)") @@ -143,8 +149,7 @@ ftp://ftp.math.psu.edu/pub/simpson/chinese/hzp/hzp.doc" (let* ((inhibit-point-motion-hooks t) (case-fold-search t) (ct (message-fetch-field "Content-Type" t)) - (ctl (and ct (ignore-errors - (mail-header-parse-content-type ct))))) + (ctl (and ct (mail-header-parse-content-type ct)))) (if (and ctl (not (string-match "/" (car ctl)))) (setq ctl nil)) (goto-char (point-max)) diff --git a/lisp/rfc2045.el b/lisp/rfc2045.el index cd7cc4b..f38ec05 100644 --- a/lisp/rfc2045.el +++ b/lisp/rfc2045.el @@ -1,6 +1,7 @@ ;;; rfc2045.el --- Functions for decoding rfc2045 headers -;; Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;; RFC 2045 is: "Multipurpose Internet Mail Extensions (MIME) Part ;; One: Format of Internet Message Bodies". diff --git a/lisp/rfc2047.el b/lisp/rfc2047.el index c768ae0..37b654f 100644 --- a/lisp/rfc2047.el +++ b/lisp/rfc2047.el @@ -1,7 +1,7 @@ ;;; rfc2047.el --- functions for encoding and decoding rfc2047 messages -;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; MORIOKA Tomohiko @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -783,6 +783,82 @@ it, put the following line in your ~/.gnus.el file: (defvar rfc2047-quote-decoded-words-containing-tspecials nil "If non-nil, quote decoded words containing special characters.") +(defvar rfc2047-allow-incomplete-encoded-text t + "*Non-nil means allow incomplete encoded-text in successive encoded-words. +Dividing of encoded-text in the place other than character boundaries +violates RFC2047 section 5, while we have a capability to decode it. +If it is non-nil, the decoder will decode B- or Q-encoding in each +encoded-word, concatenate them, and decode it by charset. Otherwise, +the decoder will fully decode each encoded-word before concatenating +them.") + +(defun rfc2047-charset-to-coding-system (charset) + "Return coding-system corresponding to MIME CHARSET. +If your Emacs implementation can't decode CHARSET, return nil." + (when (stringp charset) + (setq charset (intern (downcase charset)))) + (when (or (not charset) + (eq 'gnus-all mail-parse-ignored-charsets) + (memq 'gnus-all mail-parse-ignored-charsets) + (memq charset mail-parse-ignored-charsets)) + (setq charset mail-parse-charset)) + (let ((cs (mm-charset-to-coding-system charset))) + (cond ((eq cs 'ascii) + (setq cs (or (mm-charset-to-coding-system mail-parse-charset) + 'raw-text))) + ((mm-coding-system-p cs)) + ((and charset + (listp mail-parse-ignored-charsets) + (memq 'gnus-unknown mail-parse-ignored-charsets)) + (setq cs (mm-charset-to-coding-system mail-parse-charset)))) + (if (eq cs 'ascii) + 'raw-text + cs))) + +(defun rfc2047-decode-encoded-words (words) + "Decode successive encoded-words in WORDS and return a decoded string. +Each element of WORDS looks like (CHARSET ENCODING ENCODED-TEXT +ENCODED-WORD)." + (let (word charset cs encoding text rest) + (while words + (setq word (pop words)) + (if (and (setq cs (rfc2047-charset-to-coding-system + (setq charset (car word)))) + (condition-case code + (cond ((char-equal ?B (nth 1 word)) + (setq text (base64-decode-string + (rfc2047-pad-base64 (nth 2 word))))) + ((char-equal ?Q (nth 1 word)) + (setq text (quoted-printable-decode-string + (mm-subst-char-in-string + ?_ ? (nth 2 word) t))))) + (error + (message "%s" (error-message-string code)) + nil))) + (if (and rfc2047-allow-incomplete-encoded-text + (eq cs (caar rest))) + ;; Concatenate text of which the charset is the same. + (setcdr (car rest) (concat (cdar rest) text)) + (push (cons cs text) rest)) + ;; Don't decode encoded-word. + (push (cons nil (nth 3 word)) rest))) + (while rest + (setq words (concat + (or (and (setq cs (caar rest)) + (condition-case code + (mm-decode-coding-string (cdar rest) cs) + (error + (message "%s" (error-message-string code)) + nil))) + (concat (when (cdr rest) " ") + (cdar rest) + (when (and words + (not (eq (string-to-char words) ? ))) + " "))) + words) + rest (cdr rest))) + words)) + ;; Fixme: This should decode in place, not cons intermediate strings. ;; Also check whether it needs to worry about delimiting fields like ;; encoding. @@ -797,32 +873,32 @@ it, put the following line in your ~/.gnus.el file: "Decode MIME-encoded words in region between START and END." (interactive "r") (let ((case-fold-search t) - b e) + (eword-regexp (eval-when-compile + ;; Ignore whitespace between encoded-words. + (concat "[\n\t ]*\\(" rfc2047-encoded-word-regexp + "\\)"))) + b e match words) (save-excursion (save-restriction (narrow-to-region start end) - (goto-char (point-min)) - ;; Remove whitespace between encoded words. - (while (re-search-forward - (eval-when-compile - (concat "\\(" rfc2047-encoded-word-regexp "\\)" - "\\(\n?[ \t]\\)+" - "\\(" rfc2047-encoded-word-regexp "\\)")) - nil t) - (delete-region (goto-char (match-end 1)) (match-beginning 6))) - ;; Decode the encoded words. - (setq b (goto-char (point-min))) - (while (re-search-forward rfc2047-encoded-word-regexp nil t) - (setq e (match-beginning 0)) - (insert (rfc2047-parse-and-decode - (prog1 - (match-string 0) - (delete-region e (match-end 0))))) - (while (looking-at rfc2047-encoded-word-regexp) - (insert (rfc2047-parse-and-decode - (prog1 - (match-string 0) - (delete-region (point) (match-end 0)))))) + (goto-char (setq b start)) + ;; Look for the encoded-words. + (while (setq match (re-search-forward eword-regexp nil t)) + (setq e (match-beginning 1) + end (match-end 0) + words nil) + (while match + (push (list (match-string 2) ;; charset + (char-after (match-beginning 3)) ;; encoding + (match-string 4) ;; encoded-text + (match-string 1)) ;; encoded-word + words) + ;; Look for the subsequent encoded-words. + (when (setq match (looking-at eword-regexp)) + (goto-char (setq end (match-end 0))))) + ;; Replace the encoded-words with the decoded one. + (delete-region e end) + (insert (rfc2047-decode-encoded-words (nreverse words))) (save-restriction (narrow-to-region e (point)) (goto-char e) @@ -928,21 +1004,6 @@ it, put the following line in your ~/.gnus.el file: (mm-decode-coding-string string mail-parse-charset)) (mm-string-as-multibyte string))))) -(defun rfc2047-parse-and-decode (word) - "Decode WORD and return it if it is an encoded word. -Return WORD if it is not not an encoded word or if the charset isn't -decodable." - (if (not (string-match rfc2047-encoded-word-regexp word)) - word - (or - (condition-case nil - (rfc2047-decode - (match-string 1 word) - (string-to-char (match-string 2 word)) - (match-string 3 word)) - (error word)) - word))) ; un-decodable - (defun rfc2047-pad-base64 (string) "Pad STRING to quartets." ;; Be more liberal to accept buggy base64 strings. If @@ -958,36 +1019,6 @@ decodable." (2 (concat string "==")) (3 (concat string "="))))) -(defun rfc2047-decode (charset encoding string) - "Decode STRING from the given MIME CHARSET in the given ENCODING. -Valid ENCODINGs are the characters \"B\" and \"Q\". -If your Emacs implementation can't decode CHARSET, return nil." - (if (stringp charset) - (setq charset (intern (downcase charset)))) - (if (or (not charset) - (eq 'gnus-all mail-parse-ignored-charsets) - (memq 'gnus-all mail-parse-ignored-charsets) - (memq charset mail-parse-ignored-charsets)) - (setq charset mail-parse-charset)) - (let ((cs (mm-charset-to-coding-system charset))) - (if (and (not cs) charset - (listp mail-parse-ignored-charsets) - (memq 'gnus-unknown mail-parse-ignored-charsets)) - (setq cs (mm-charset-to-coding-system mail-parse-charset))) - (when cs - (when (eq cs 'ascii) - (setq cs (or mail-parse-charset 'raw-text))) - (mm-decode-coding-string - (cond - ((char-equal ?B encoding) - (base64-decode-string - (rfc2047-pad-base64 string))) - ((char-equal ?Q encoding) - (quoted-printable-decode-string - (mm-subst-char-in-string ?_ ? string t))) - (t (error "Invalid encoding: %c" encoding))) - cs)))) - (provide 'rfc2047) ;;; arch-tag: a07fe3d4-22b5-4c4a-bd89-b1f82d5d36f6 diff --git a/lisp/rfc2104.el b/lisp/rfc2104.el index a70ba16..87a2167 100644 --- a/lisp/rfc2104.el +++ b/lisp/rfc2104.el @@ -1,5 +1,7 @@ ;;; rfc2104.el --- RFC2104 Hashed Message Authentication Codes -;; Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: mail @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/rfc2231.el b/lisp/rfc2231.el index 8a20e19..3728b78 100644 --- a/lisp/rfc2231.el +++ b/lisp/rfc2231.el @@ -1,7 +1,7 @@ ;;; rfc2231.el --- Functions for decoding rfc2231 headers -;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; This file is part of GNU Emacs. @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -41,20 +41,51 @@ N.B. This is in violation with RFC2047, but it seem to be in common use." (rfc2231-parse-string (rfc2047-decode-string string))) -(defun rfc2231-parse-string (string) +(defun rfc2231-parse-string (string &optional signal-error) "Parse STRING and return a list. The list will be on the form - `(name (attribute . value) (attribute . value)...)" + `(name (attribute . value) (attribute . value)...)'. + +If the optional SIGNAL-ERROR is non-nil, signal an error when this +function fails in parsing of parameters. Otherwise, this function +must never cause a Lisp error." (with-temp-buffer (let ((ttoken (ietf-drums-token-to-list ietf-drums-text-token)) (stoken (ietf-drums-token-to-list ietf-drums-tspecials)) (ntoken (ietf-drums-token-to-list "0-9")) - (prev-value "") - display-name mailbox c display-string parameters - attribute value type subtype number encoded - prev-attribute) - (ietf-drums-init (mail-header-remove-whitespace - (mail-header-remove-comments string))) + c type attribute encoded number prev-attribute vals + prev-encoded parameters value) + (ietf-drums-init + (condition-case nil + (mail-header-remove-whitespace + (mail-header-remove-comments string)) + ;; The most likely cause of an error is unbalanced parentheses + ;; or double-quotes. If all parentheses and double-quotes are + ;; quoted meaninglessly with backslashes, removing them might + ;; make it parseable. Let's try... + (error + (let (mod) + (when (and (string-match "\\\\\"" string) + (not (string-match "\\`\"\\|[^\\]\"" string))) + (setq string (mm-replace-in-string string "\\\\\"" "\"") + mod t)) + (when (and (string-match "\\\\(" string) + (string-match "\\\\)" string) + (not (string-match "\\`(\\|[^\\][()]" string))) + (setq string (mm-replace-in-string string "\\\\\\([()]\\)" "\\1") + mod t)) + (or (and mod + (ignore-errors + (mail-header-remove-whitespace + (mail-header-remove-comments string)))) + ;; Finally, attempt to extract only type. + (if (string-match + (concat "\\`[\t\n ]*\\([^" ietf-drums-tspecials "\t\n ]+" + "\\(?:/[^" ietf-drums-tspecials + "\t\n ]+\\)?\\)\\(?:[\t\n ;]\\|\\'\\)") + string) + (match-string 1 string) + "")))))) (let ((table (copy-syntax-table ietf-drums-syntax-table))) (modify-syntax-entry ?\' "w" table) (modify-syntax-entry ?* " " table) @@ -66,115 +97,160 @@ The list will be on the form (set-syntax-table table)) (setq c (char-after)) (when (and (memq c ttoken) - (not (memq c stoken))) - (setq type (downcase (buffer-substring - (point) (progn (forward-sexp 1) (point))))) + (not (memq c stoken)) + (setq type (ignore-errors + (downcase + (buffer-substring (point) (progn + (forward-sexp 1) + (point))))))) ;; Do the params - (while (not (eobp)) - (setq c (char-after)) - (unless (eq c ?\;) - (error "Invalid header: %s" string)) - (forward-char 1) - ;; If c in nil, then this is an invalid header, but - ;; since elm generates invalid headers on this form, - ;; we allow it. - (when (setq c (char-after)) - (if (and (memq c ttoken) - (not (memq c stoken))) - (setq attribute - (intern - (downcase - (buffer-substring - (point) (progn (forward-sexp 1) (point)))))) - (error "Invalid header: %s" string)) - (setq c (char-after)) - (when (eq c ?*) - (forward-char 1) - (setq c (char-after)) - (if (not (memq c ntoken)) - (setq encoded t - number nil) - (setq number - (string-to-number - (buffer-substring - (point) (progn (forward-sexp 1) (point))))) + (condition-case err + (progn + (while (not (eobp)) (setq c (char-after)) - (when (eq c ?*) - (setq encoded t) + (unless (eq c ?\;) + (error "Invalid header: %s" string)) + (forward-char 1) + ;; If c in nil, then this is an invalid header, but + ;; since elm generates invalid headers on this form, + ;; we allow it. + (when (setq c (char-after)) + (if (and (memq c ttoken) + (not (memq c stoken))) + (setq attribute + (intern + (downcase + (buffer-substring + (point) (progn (forward-sexp 1) (point)))))) + (error "Invalid header: %s" string)) + (setq c (char-after)) + (if (eq c ?*) + (progn + (forward-char 1) + (setq c (char-after)) + (if (not (memq c ntoken)) + (setq encoded t + number nil) + (setq number + (string-to-number + (buffer-substring + (point) (progn (forward-sexp 1) (point))))) + (setq c (char-after)) + (when (eq c ?*) + (setq encoded t) + (forward-char 1) + (setq c (char-after))))) + (setq number nil + encoded nil)) + ;; See if we have any previous continuations. + (when (and prev-attribute + (not (eq prev-attribute attribute))) + (setq vals + (mapconcat 'cdr (sort vals 'car-less-than-car) "")) + (push (cons prev-attribute + (if prev-encoded + (rfc2231-decode-encoded-string vals) + vals)) + parameters) + (setq prev-attribute nil + vals nil + prev-encoded nil)) + (unless (eq c ?=) + (error "Invalid header: %s" string)) (forward-char 1) - (setq c (char-after))))) - ;; See if we have any previous continuations. - (when (and prev-attribute - (not (eq prev-attribute attribute))) - (push (cons prev-attribute prev-value) parameters) - (setq prev-attribute nil - prev-value "")) - (unless (eq c ?=) - (error "Invalid header: %s" string)) - (forward-char 1) - (setq c (char-after)) - (cond - ((eq c ?\") - (setq value - (buffer-substring (1+ (point)) - (progn (forward-sexp 1) (1- (point)))))) - ((and (or (memq c ttoken) - (> c ?\177)) ;; EXTENSION: Support non-ascii chars. - (not (memq c stoken))) - (setq value (buffer-substring - (point) (progn (forward-sexp) (point))))) - (t - (error "Invalid header: %s" string))) - (if number - (setq prev-attribute attribute - prev-value (concat prev-value value)) - (push (cons attribute - (if encoded - (rfc2231-decode-encoded-string value) - value)) - parameters)))) - - ;; Take care of any final continuations. - (when prev-attribute - (push (cons prev-attribute - (if encoded - (rfc2231-decode-encoded-string prev-value) - prev-value)) - parameters)) - - (when type - `(,type ,@(nreverse parameters))))))) + (setq c (char-after)) + (cond + ((eq c ?\") + (setq value (buffer-substring (1+ (point)) + (progn + (forward-sexp 1) + (1- (point))))) + (when encoded + (setq value (mapconcat (lambda (c) (format "%%%02x" c)) + value "")))) + ((and (or (memq c ttoken) + ;; EXTENSION: Support non-ascii chars. + (> c ?\177)) + (not (memq c stoken))) + (setq value + (buffer-substring + (point) + (progn + (forward-sexp) + ;; We might not have reached at the end of + ;; the value because of non-ascii chars, + ;; so we should jump over them if any. + (while (and (not (eobp)) + (> (char-after) ?\177)) + (forward-char 1) + (forward-sexp)) + (point))))) + (t + (error "Invalid header: %s" string))) + (if number + (progn + (push (cons number value) vals) + (setq prev-attribute attribute + prev-encoded encoded)) + (push (cons attribute + (if encoded + (rfc2231-decode-encoded-string value) + value)) + parameters)))) + + ;; Take care of any final continuations. + (when prev-attribute + (setq vals (mapconcat 'cdr (sort vals 'car-less-than-car) "")) + (push (cons prev-attribute + (if prev-encoded + (rfc2231-decode-encoded-string vals) + vals)) + parameters))) + (error + (setq parameters nil) + (if signal-error + (signal (car err) (cdr err)) + ;;(message "%s" (error-message-string err)) + ))) + + (cons type (nreverse parameters)))))) (defun rfc2231-decode-encoded-string (string) "Decode an RFC2231-encoded string. -These look like \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\"." - (with-temp-buffer - (let ((elems (split-string string "'"))) - ;; The encoded string may contain zero to two single-quote - ;; marks. This should give us the encoded word stripped - ;; of any preceding values. - (insert (car (last elems))) +These look like: + \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\", + \"us-ascii''This%20is%20%2A%2A%2Afun%2A%2A%2A\", + \"'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\", + \"''This%20is%20%2A%2A%2Afun%2A%2A%2A\", or + \"This is ***fun***\"." + (string-match "\\`\\(?:\\([^']+\\)?'\\([^']+\\)?'\\)?\\(.+\\)" string) + (let ((coding-system (mm-charset-to-coding-system (match-string 1 string))) + ;;(language (match-string 2 string)) + (value (match-string 3 string))) + (mm-with-multibyte-buffer + (insert value) (goto-char (point-min)) (while (search-forward "%" nil t) (insert (prog1 (string-to-number (buffer-substring (point) (+ (point) 2)) 16) (delete-region (1- (point)) (+ (point) 2))))) - ;; Encode using the charset, if any. - (when (and (mm-multibyte-p) - (> (length elems) 1) - (not (equal (intern (downcase (car elems))) 'us-ascii))) - (mm-decode-coding-region (point-min) (point-max) - (intern (downcase (car elems))))) + ;; Decode using the charset, if any. + (unless (memq coding-system '(nil ascii)) + (mm-decode-coding-region (point-min) (point-max) coding-system)) (buffer-string)))) (defun rfc2231-encode-string (param value) - "Return and PARAM=VALUE string encoded according to RFC2231." + "Return and PARAM=VALUE string encoded according to RFC2231. +Use `mml-insert-parameter' or `mml-insert-parameter-string' to insert +the result of this function." (let ((control (ietf-drums-token-to-list ietf-drums-no-ws-ctl-token)) (tspecial (ietf-drums-token-to-list ietf-drums-tspecials)) (special (ietf-drums-token-to-list "*'%\n\t")) (ascii (ietf-drums-token-to-list ietf-drums-text-token)) (num -1) + ;; Don't make lines exceeding 76 column. + (limit (- 74 (length param))) spacep encodep charsetp charset broken) (with-temp-buffer (insert value) @@ -193,28 +269,34 @@ These look like \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\"." (when charsetp (setq charset (mm-encode-body))) (cond - ((or encodep charsetp) + ((or encodep charsetp + (progn + (end-of-line) + (> (current-column) (if spacep (- limit 2) limit)))) + (setq limit (- limit 6)) (goto-char (point-min)) + (insert (symbol-name (or charset 'us-ascii)) "''") (while (not (eobp)) - (when (> (current-column) 60) - (insert ";\n") - (setq broken t)) (if (or (not (memq (following-char) ascii)) (memq (following-char) control) (memq (following-char) tspecial) (memq (following-char) special) (eq (following-char) ? )) (progn + (when (>= (current-column) (1- limit)) + (insert ";\n") + (setq broken t)) (insert "%" (format "%02x" (following-char))) (delete-char 1)) + (when (> (current-column) limit) + (insert ";\n") + (setq broken t)) (forward-char 1))) (goto-char (point-min)) - (insert (symbol-name (or charset 'us-ascii)) "''") - (goto-char (point-min)) (if (not broken) (insert param "*=") (while (not (eobp)) - (insert (if (>= num 0) " " "\n ") + (insert (if (>= num 0) " " "") param "*" (format "%d" (incf num)) "*=") (forward-line 1)))) (spacep diff --git a/lisp/sasl-cram.el b/lisp/sasl-cram.el index 219e5e8..17c08a0 100644 --- a/lisp/sasl-cram.el +++ b/lisp/sasl-cram.el @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/sasl-digest.el b/lisp/sasl-digest.el index f6d455e..2c4d217 100644 --- a/lisp/sasl-digest.el +++ b/lisp/sasl-digest.el @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;; This program is implemented from draft-leach-digest-sasl-05.txt. ;; diff --git a/lisp/sasl-ntlm.el b/lisp/sasl-ntlm.el index 6554ee3..ead5409 100644 --- a/lisp/sasl-ntlm.el +++ b/lisp/sasl-ntlm.el @@ -19,8 +19,8 @@ ;; ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/sasl.el b/lisp/sasl.el index 9fe5e49..37dac1c 100644 --- a/lisp/sasl.el +++ b/lisp/sasl.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/score-mode.el b/lisp/score-mode.el index a54b57f..ddf17d2 100644 --- a/lisp/score-mode.el +++ b/lisp/score-mode.el @@ -1,6 +1,7 @@ ;;; score-mode.el --- mode for editing Gnus score files -;; Copyright (C) 1996, 2001, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1996, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -28,7 +29,10 @@ (eval-when-compile (require 'cl)) (require 'mm-util) ; for mm-universal-coding-system -(require 'gnus-util) ; for gnus-pp +(require 'gnus-util) ; for gnus-pp, gnus-run-mode-hooks + +(defvar gnus-score-edit-done-hook nil + "*Hook run at the end of closing the score buffer.") (defvar gnus-score-mode-hook nil "*Hook run in score mode buffers.") @@ -71,7 +75,7 @@ This mode is an extended emacs-lisp mode. (setq mode-name "Score") (lisp-mode-variables nil) (make-local-variable 'gnus-score-edit-exit-function) - (run-hooks 'emacs-lisp-mode-hook 'gnus-score-mode-hook)) + (gnus-run-mode-hooks 'emacs-lisp-mode-hook 'gnus-score-mode-hook)) (defun gnus-score-make-menu-bar () (unless (boundp 'gnus-score-menu) diff --git a/lisp/sha1.el b/lisp/sha1.el index 346bf9a..664933b 100644 --- a/lisp/sha1.el +++ b/lisp/sha1.el @@ -1,6 +1,7 @@ ;;; sha1.el --- SHA1 Secure Hash Algorithm in Emacs-Lisp -;; Copyright (C) 1999, 2001, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shuhei KOBAYASHI ;; Keywords: SHA1, FIPS 180-1 @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/sieve-manage.el b/lisp/sieve-manage.el index 72e6ade..a27afbd 100644 --- a/lisp/sieve-manage.el +++ b/lisp/sieve-manage.el @@ -1,5 +1,7 @@ ;;; sieve-manage.el --- Implementation of the managesive protocol in elisp -;; Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson @@ -17,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -91,22 +93,27 @@ (defcustom sieve-manage-log "*sieve-manage-log*" "Name of buffer for managesieve session trace." - :type 'string) + :type 'string + :group 'sieve-manage) (defcustom sieve-manage-default-user (user-login-name) "Default username to use." - :type 'string) + :type 'string + :group 'sieve-manage) (defcustom sieve-manage-server-eol "\r\n" "The EOL string sent from the server." - :type 'string) + :type 'string + :group 'sieve-manage) (defcustom sieve-manage-client-eol "\r\n" "The EOL string we send to the server." - :type 'string) + :type 'string + :group 'sieve-manage) (defcustom sieve-manage-streams '(network starttls shell) - "Priority of streams to consider when opening connection to server.") + "Priority of streams to consider when opening connection to server." + :group 'sieve-manage) (defcustom sieve-manage-stream-alist '((network sieve-manage-network-p sieve-manage-network-open) @@ -118,7 +125,8 @@ NAME names the stream, CHECK is a function returning non-nil if the server support the stream and OPEN is a function for opening the -stream.") +stream." + :group 'sieve-manage) (defcustom sieve-manage-authenticators '(digest-md5 cram-md5 @@ -126,7 +134,8 @@ stream.") ntlm plain login) - "Priority of authenticators to consider when authenticating to server.") + "Priority of authenticators to consider when authenticating to server." + :group 'sieve-manage) (defcustom sieve-manage-authenticator-alist '((cram-md5 sieve-manage-cram-md5-p sieve-manage-cram-md5-auth) @@ -141,11 +150,13 @@ stream.") NAME names the authenticator. CHECK is a function returning non-nil if the server support the authenticator and AUTHENTICATE is a function -for doing the actual authentication.") +for doing the actual authentication." + :group 'sieve-manage) (defcustom sieve-manage-default-port 2000 "Default port number for managesieve protocol." - :type 'integer) + :type 'integer + :group 'sieve-manage) ;; Internal variables: @@ -189,8 +200,8 @@ LOGINFUNC is passed a username and a password, it should return t if it where sucessful authenticating itself to the server, nil otherwise. Returns t if login was successful, nil otherwise." (with-current-buffer buffer - (make-variable-buffer-local 'sieve-manage-username) - (make-variable-buffer-local 'sieve-manage-password) + (make-local-variable 'sieve-manage-username) + (make-local-variable 'sieve-manage-password) (let (user passwd ret reason passwd-key) (condition-case () (while (or (not user) (not passwd)) @@ -433,7 +444,7 @@ Optional variable BUFFER is buffer (buffer, or string naming buffer) to work in." (setq buffer (or buffer (format " *sieve* %s:%d" server (or port 2000)))) (with-current-buffer (get-buffer-create buffer) - (mapc 'make-variable-buffer-local sieve-manage-local-variables) + (mapc 'make-local-variable sieve-manage-local-variables) (sieve-manage-disable-multibyte) (buffer-disable-undo) (setq sieve-manage-server (or server sieve-manage-server)) @@ -521,8 +532,8 @@ password is remembered in the buffer." (with-current-buffer (or buffer (current-buffer)) (if (not (eq sieve-manage-state 'nonauth)) (eq sieve-manage-state 'auth) - (make-variable-buffer-local 'sieve-manage-username) - (make-variable-buffer-local 'sieve-manage-password) + (make-local-variable 'sieve-manage-username) + (make-local-variable 'sieve-manage-password) (if user (setq sieve-manage-username user)) (if passwd (setq sieve-manage-password passwd)) (if (funcall (nth 2 (assq sieve-manage-auth diff --git a/lisp/sieve-mode.el b/lisp/sieve-mode.el index 68fd60c..efc4559 100644 --- a/lisp/sieve-mode.el +++ b/lisp/sieve-mode.el @@ -1,5 +1,7 @@ ;;; sieve-mode.el --- Sieve code editing commands for Emacs -;; Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, +;; 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson @@ -17,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -64,32 +66,38 @@ ;; Font-lock -(defvar sieve-control-commands-face 'sieve-control-commands-face +(defvar sieve-control-commands-face 'sieve-control-commands "Face name used for Sieve Control Commands.") -(defface sieve-control-commands-face +(defface sieve-control-commands '((((type tty) (class color)) (:foreground "blue" :weight light)) (((class grayscale) (background light)) (:foreground "LightGray" :bold t)) (((class grayscale) (background dark)) (:foreground "DimGray" :bold t)) (((class color) (background light)) (:foreground "Orchid")) (((class color) (background dark)) (:foreground "LightSteelBlue")) (t (:bold t))) - "Face used for Sieve Control Commands.") + "Face used for Sieve Control Commands." + :group 'sieve) +;; backward-compatibility alias +(put 'sieve-control-commands-face 'face-alias 'sieve-control-commands) -(defvar sieve-action-commands-face 'sieve-action-commands-face +(defvar sieve-action-commands-face 'sieve-action-commands "Face name used for Sieve Action Commands.") -(defface sieve-action-commands-face +(defface sieve-action-commands '((((type tty) (class color)) (:foreground "blue" :weight bold)) (((class color) (background light)) (:foreground "Blue")) (((class color) (background dark)) (:foreground "LightSkyBlue")) (t (:inverse-video t :bold t))) - "Face used for Sieve Action Commands.") + "Face used for Sieve Action Commands." + :group 'sieve) +;; backward-compatibility alias +(put 'sieve-action-commands-face 'face-alias 'sieve-action-commands) -(defvar sieve-test-commands-face 'sieve-test-commands-face +(defvar sieve-test-commands-face 'sieve-test-commands "Face name used for Sieve Test Commands.") -(defface sieve-test-commands-face +(defface sieve-test-commands '((((type tty) (class color)) (:foreground "magenta")) (((class grayscale) (background light)) (:foreground "LightGray" :bold t :underline t)) @@ -98,19 +106,25 @@ (((class color) (background light)) (:foreground "CadetBlue")) (((class color) (background dark)) (:foreground "Aquamarine")) (t (:bold t :underline t))) - "Face used for Sieve Test Commands.") + "Face used for Sieve Test Commands." + :group 'sieve) +;; backward-compatibility alias +(put 'sieve-test-commands-face 'face-alias 'sieve-test-commands) -(defvar sieve-tagged-arguments-face 'sieve-tagged-arguments-face +(defvar sieve-tagged-arguments-face 'sieve-tagged-arguments "Face name used for Sieve Tagged Arguments.") -(defface sieve-tagged-arguments-face +(defface sieve-tagged-arguments '((((type tty) (class color)) (:foreground "cyan" :weight bold)) (((class grayscale) (background light)) (:foreground "LightGray" :bold t)) (((class grayscale) (background dark)) (:foreground "DimGray" :bold t)) (((class color) (background light)) (:foreground "Purple")) (((class color) (background dark)) (:foreground "Cyan")) (t (:bold t))) - "Face used for Sieve Tagged Arguments.") + "Face used for Sieve Tagged Arguments." + :group 'sieve) +;; backward-compatibility alias +(put 'sieve-tagged-arguments-face 'face-alias 'sieve-tagged-arguments) (defconst sieve-font-lock-keywords diff --git a/lisp/sieve.el b/lisp/sieve.el index ffaaa07..2b9bc63 100644 --- a/lisp/sieve.el +++ b/lisp/sieve.el @@ -1,5 +1,6 @@ ;;; sieve.el --- Utilities to manage sieve scripts -;; Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson @@ -17,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -244,7 +245,7 @@ Used to bracket operations which move point in the sieve-buffer." (if (eq last-command 'sieve-help) ;; would need minor-mode for log-edit-mode (describe-function 'sieve-mode) - (message (substitute-command-keys + (message "%s" (substitute-command-keys "`\\[sieve-edit-script]':edit `\\[sieve-activate]':activate `\\[sieve-deactivate]':deactivate `\\[sieve-remove]':remove")))) (defun sieve-bury-buffer (buf &optional mainbuf) diff --git a/lisp/smiley.el b/lisp/smiley.el index 27a5482..6476340 100644 --- a/lisp/smiley.el +++ b/lisp/smiley.el @@ -1,6 +1,7 @@ ;;; smiley.el --- displaying smiley faces -;; Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Dave Love ;; Keywords: news mail multimedia @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -30,8 +31,22 @@ ;; I'm not sure we need that degree of rococoness and defaults like a ;; yellow background. Also, using PBM means we can display the images ;; more generally. -- fx - -;;; Test smileys: :-) :-\ :-( :-/ +;; `smiley.el' was replaced by `smiley-ems.el' on 2002-01-26 (after fx' +;; comment). + +;; Test smileys: +;; smile ^:-) ^:) +;; blink ;-) ;) +;; forced :-] +;; braindamaged 8-) +;; indifferent :-| +;; wry :-/ :-\ +;; sad :-( +;; frown :-{ +;; evil >:-) +;; cry ;-( +;; dead X-) +;; grin :-D ;;; Code: @@ -44,8 +59,9 @@ :group 'gnus-visual) ;; Maybe this should go. -(defcustom smiley-data-directory (nnheader-find-etc-directory "images/smilies") - "*Location of the smiley faces files." +(defcustom smiley-data-directory + (nnheader-find-etc-directory "images/smilies") + "Location of the smiley faces files." :type 'directory :group 'smiley) @@ -60,8 +76,8 @@ ("\\(:-(\\)\\W" 1 "sad") ("\\(:-{\\)\\W" 1 "frown")) "*A list of regexps to map smilies to images. -The elements are (REGEXP MATCH FILE), where MATCH is the submatch in -regexp to replace with IMAGE. IMAGE is the name of a PBM file in +The elements are (REGEXP MATCH IMAGE), where MATCH is the submatch in +regexp to replace with IMAGE. IMAGE is the name of an image file in `smiley-data-directory'." :type '(repeat (list regexp (integer :tag "Regexp match number") @@ -77,7 +93,7 @@ regexp to replace with IMAGE. IMAGE is the name of a PBM file in (when (gnus-image-type-available-p 'xpm) (push "xpm" types)) types) - "*List of suffixes on picon file names to try." + "*List of suffixes on smiley file names to try." :version "22.1" :type '(repeat string) :group 'smiley) @@ -85,6 +101,7 @@ regexp to replace with IMAGE. IMAGE is the name of a PBM file in (defvar smiley-cached-regexp-alist nil) (defun smiley-update-cache () + (setq smiley-cached-regexp-alist nil) (dolist (elt (if (symbolp smiley-regexp-alist) (symbol-value smiley-regexp-alist) smiley-regexp-alist)) @@ -103,12 +120,13 @@ regexp to replace with IMAGE. IMAGE is the name of a PBM file in (push (list (car elt) (cadr elt) image) smiley-cached-regexp-alist))))))) -(defvar smiley-mouse-map - (let ((map (make-sparse-keymap))) - (define-key map [down-mouse-2] 'ignore) ; override widget - (define-key map [mouse-2] - 'smiley-mouse-toggle-buffer) - map)) +;; Not implemented: +;; (defvar smiley-mouse-map +;; (let ((map (make-sparse-keymap))) +;; (define-key map [down-mouse-2] 'ignore) ; override widget +;; (define-key map [mouse-2] +;; 'smiley-mouse-toggle-buffer) +;; map)) ;;;###autoload (defun smiley-region (start end) diff --git a/lisp/smime-ldap.el b/lisp/smime-ldap.el index 24d3e4c..d363250 100644 --- a/lisp/smime-ldap.el +++ b/lisp/smime-ldap.el @@ -21,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,14 +31,7 @@ ;; made to achieve compatibility with OpenLDAP v2 and to make it ;; possible to retrieve LDAP attributes that are tagged ie ";binary". -;; When Gnus drops support for Emacs 21.x this file can be removed and -;; smime.el changed to - -;; - (require 'smime-ldap) => (require 'ldap) -;; - (smime-ldap-search ...) => (ldap-search ...) - -;; If we are running in Emacs 22 or newer it just uses the build-in -;; version of ldap-search. +;; The file also adds a compatibility layer for Emacs and XEmacs. ;;; Code: @@ -57,26 +50,31 @@ its distinguished name WITHDN. Additional search parameters can be specified through `ldap-host-parameters-alist', which see." (interactive "sFilter:") - (if (>= emacs-major-version 22) - (ldap-search filter host attributes attrsonly) - (or host - (setq host ldap-default-host) - (error "No LDAP host specified")) - (let ((host-plist (cdr (assoc host ldap-host-parameters-alist))) - result) - (setq result (smime-ldap-search-internal - (append host-plist - (list 'host host - 'filter filter - 'attributes attributes - 'attrsonly attrsonly - 'withdn withdn)))) - (if ldap-ignore-attribute-codings - result - (mapcar (function - (lambda (record) - (mapcar 'ldap-decode-attribute record))) - result))))) + ;; for XEmacs + (if (fboundp 'ldap-search-entries) + (ldap-search-entries filter host attributes attrsonly) + ;; for Emacs 22 + (if (>= emacs-major-version 22) + (cdr (ldap-search filter host attributes attrsonly)) + ;; for Emacs 21.x + (or host + (setq host ldap-default-host) + (error "No LDAP host specified")) + (let ((host-plist (cdr (assoc host ldap-host-parameters-alist))) + result) + (setq result (smime-ldap-search-internal + (append host-plist + (list 'host host + 'filter filter + 'attributes attributes + 'attrsonly attrsonly + 'withdn withdn)))) + (cdr (if ldap-ignore-attribute-codings + result + (mapcar (function + (lambda (record) + (mapcar 'ldap-decode-attribute record))) + result))))))) (defun smime-ldap-search-internal (search-plist) "Perform a search on a LDAP server. diff --git a/lisp/smime.el b/lisp/smime.el index 7b2308f..cb53418 100644 --- a/lisp/smime.el +++ b/lisp/smime.el @@ -1,5 +1,7 @@ ;;; smime.el --- S/MIME support library -;; Copyright (c) 2000, 2001, 2003, 2005 Free Software Foundation, Inc. + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: SMIME X.509 PEM OpenSSL @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -124,8 +126,22 @@ (require 'password) (eval-when-compile (require 'cl)) +(eval-and-compile + (cond + ((fboundp 'replace-in-string) + (defalias 'smime-replace-in-string 'replace-in-string)) + ((fboundp 'replace-regexp-in-string) + (defun smime-replace-in-string (string regexp newtext &optional literal) + "Replace all matches for REGEXP with NEWTEXT in STRING. +If LITERAL is non-nil, insert NEWTEXT literally. Return a new +string containing the replacements. + +This is a compatibility function for different Emacsen." + (replace-regexp-in-string regexp newtext string nil literal))))) + (defgroup smime nil - "S/MIME configuration.") + "S/MIME configuration." + :group 'mime) (defcustom smime-keys nil "*Map mail addresses to a file containing Certificate (and private key). @@ -351,9 +367,10 @@ KEYFILE should contain a PEM encoded key and certificate." keyfile (smime-get-key-with-certs-by-email (completing-read - (concat "Sign using which key? " - (if smime-keys (concat "(default " (caar smime-keys) ") ") - "")) + (concat "Sign using key" + (if smime-keys + (concat " (default " (caar smime-keys) "): ") + ": ")) smime-keys nil nil (car-safe (car-safe smime-keys)))))) (error "Signing failed")))) @@ -482,9 +499,9 @@ in the buffer specified by `smime-details-buffer'." (or keyfile (smime-get-key-by-email (completing-read - (concat "Decipher using which key? " - (if smime-keys (concat "(default " (caar smime-keys) ") ") - "")) + (concat "Decipher using key" + (if smime-keys (concat " (default " (caar smime-keys) "): ") + ": ")) smime-keys nil nil (car-safe (car-safe smime-keys))))))))) ;; Various operations @@ -577,9 +594,24 @@ A string or a list of strings is returned." host '("userCertificate") nil)) (retbuf (generate-new-buffer (format "*certificate for %s*" mail))) cert) - (if (> (length ldapresult) 1) + (if (and (>= (length ldapresult) 1) + (> (length (cadaar ldapresult)) 0)) (with-current-buffer retbuf - (setq cert (base64-encode-string (nth 1 (car (nth 1 ldapresult))) t)) + ;; Certificates on LDAP servers _should_ be in DER format, + ;; but there are some servers out there that distributes the + ;; certificates in PEM format (with or without + ;; header/footer) so we try to handle them anyway. + (if (or (string= (substring (cadaar ldapresult) 0 27) + "-----BEGIN CERTIFICATE-----") + (string= (substring (cadaar ldapresult) 0 3) + "MII")) + (setq cert + (smime-replace-in-string + (cadaar ldapresult) + (concat "\\(\n\\|\r\\|-----BEGIN CERTIFICATE-----\\|" + "-----END CERTIFICATE-----\\)") + "" t)) + (setq cert (base64-encode-string (cadaar ldapresult) t))) (insert "-----BEGIN CERTIFICATE-----\n") (let ((i 0) (len (length cert))) (while (> (- len 64) i) @@ -631,7 +663,8 @@ The following commands are available: (use-local-map smime-mode-map) (buffer-disable-undo) (setq truncate-lines t) - (setq buffer-read-only t)) + (setq buffer-read-only t) + (gnus-run-mode-hooks 'smime-mode-hook)) (defun smime-certificate-info (certfile) (interactive "fCertificate file: ") diff --git a/lisp/spam-report.el b/lisp/spam-report.el index b331164..557dd8f 100644 --- a/lisp/spam-report.el +++ b/lisp/spam-report.el @@ -1,8 +1,9 @@ ;;; spam-report.el --- Reporting spam -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. -;; Author: Teodor Zlatanov -;; Keywords: network +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. + +;; Author: Ted Zlatanov +;; Keywords: network, spam, mail, gmane, report ;; This file is part of GNU Emacs. @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -35,7 +36,9 @@ (autoload 'mm-url-insert "mm-url")) (defgroup spam-report nil - "Spam reporting configuration.") + "Spam reporting configuration." + :group 'mail + :group 'news) (defcustom spam-report-gmane-regex nil "Regexp matching Gmane newsgroups, e.g. \"^nntp\\+.*:gmane\\.\" @@ -46,14 +49,12 @@ instead." (regexp :value "^nntp\+.*:gmane\.")) :group 'spam-report) -(defcustom spam-report-gmane-spam-header - "^X-Report-Spam: http://\\([^/]+\\)\\(.*\\)$" - "String matching Gmane spam-reporting header. Two match groups are needed." - :type 'regexp - :group 'spam-report) - (defcustom spam-report-gmane-use-article-number t - "Whether the article number (faster!) or the header should be used." + "Whether the article number (faster!) or the header should be used. + +You must set this to nil if you don't read Gmane groups directly +from news.gmane.org, e.g. when using local newsserver such as +leafnode." :type 'boolean :group 'spam-report) @@ -118,38 +119,96 @@ Reports is as ham when HAM is set." "Report an article as ham by resending via email." (spam-report-resend articles t)) -(defun spam-report-gmane (&rest articles) - "Report an article as spam through Gmane." +(defun spam-report-gmane-ham (&rest articles) + "Report ARTICLES as ham (unregister) through Gmane." (interactive (gnus-summary-work-articles current-prefix-arg)) (dolist (article articles) - (when (and gnus-newsgroup-name - (or (null spam-report-gmane-regex) - (string-match spam-report-gmane-regex gnus-newsgroup-name))) - (gnus-message 6 "Reporting spam article %d to spam.gmane.org..." article) + (spam-report-gmane-internal t article))) + +(defun spam-report-gmane-spam (&rest articles) + "Report ARTICLES as spam through Gmane." + (interactive (gnus-summary-work-articles current-prefix-arg)) + (dolist (article articles) + (spam-report-gmane-internal nil article))) + +;; `spam-report-gmane' was an interactive entry point, so we should provide an +;; alias. +(defalias 'spam-report-gmane 'spam-report-gmane-spam) + +(defun spam-report-gmane-internal (unspam article) + "Report ARTICLE as spam or not-spam through Gmane, depending on UNSPAM." + (when (and gnus-newsgroup-name + (or (null spam-report-gmane-regex) + (string-match spam-report-gmane-regex gnus-newsgroup-name))) + (let ((rpt-host (if unspam "unspam.gmane.org" "spam.gmane.org"))) + (gnus-message 6 "Reporting article %d to %s..." article rpt-host) (if spam-report-gmane-use-article-number - (spam-report-url-ping - "spam.gmane.org" + (spam-report-url-ping + rpt-host (format "/%s:%d" (gnus-group-real-name gnus-newsgroup-name) article)) (with-current-buffer nntp-server-buffer (gnus-request-head article gnus-newsgroup-name) - (goto-char (point-min)) - (if (re-search-forward spam-report-gmane-spam-header nil t) - (let* ((host (match-string 1)) - (report (match-string 2)) - (url (format "http://%s%s" host report))) - (gnus-message 7 "Reporting spam through URL %s..." url) - (spam-report-url-ping host report)) - (gnus-message 3 "Could not find X-Report-Spam in article %d..." - article))))))) - + (let ((case-fold-search t) + field host report url) + ;; First check for X-Report-Spam because it's more specific to + ;; spam reporting than Archived-At. OTOH, all new articles on + ;; Gmane don't have X-Report-Spam anymore (unless Lars changes his + ;; mind :-)). + ;; + ;; There might be more than one Archived-At header so we need to + ;; find (and transform) the one related to Gmane. + (setq field (or (gnus-fetch-field "X-Report-Spam") + (gnus-fetch-field "X-Report-Unspam") + (gnus-fetch-field "Archived-At"))) + (when (stringp field) + (setq host + (progn + (string-match + (concat "http://\\([a-z]+\\.gmane\\.org\\)" + "\\(/[^:/]+[:/][0-9]+\\)") + field) + (match-string 1 field))) + (setq report (match-string 2 field)) + (when (string-equal "permalink.gmane.org" host) + (setq host rpt-host) + (setq report (gnus-replace-in-string + report "/\\([0-9]+\\)$" ":\\1"))) + (setq url (format "http://%s%s" host report))) + (if (not (and host report url)) + (gnus-message + 3 "Could not find a spam report header in article %d..." + article) + (gnus-message 7 "Reporting article through URL %s..." url) + (spam-report-url-ping host report)))))))) (defun spam-report-url-ping (host report) "Ping a host through HTTP, addressing a specific GET resource using the function specified by `spam-report-url-ping-function'." + ;; Example: + ;; host: "spam.gmane.org" + ;; report: "/gmane.some.group:123456" (funcall spam-report-url-ping-function host report)) +(defcustom spam-report-user-mail-address + (and (stringp user-mail-address) + (gnus-replace-in-string user-mail-address "@" "")) + "Mail address of this user used for spam reports to Gmane. +This is initialized based on `user-mail-address'." + :type '(choice string + (const :tag "Don't expose address" nil)) + :version "23.0" ;; No Gnus + :group 'spam-report) + +(defvar spam-report-user-agent + (if spam-report-user-mail-address + (format "%s (%s) %s" "spam-report.el" + spam-report-user-mail-address + (gnus-extended-version)) + (format "%s %s" "spam-report.el" + (gnus-extended-version)))) + (defun spam-report-url-ping-plain (host report) "Ping a host through HTTP, addressing a specific GET resource." (let ((tcp-connection)) @@ -164,8 +223,8 @@ the function specified by `spam-report-url-ping-function'." (set-marker (process-mark tcp-connection) (point-min)) (process-send-string tcp-connection - (format "GET %s HTTP/1.1\nUser-Agent: %s (spam-report.el)\nHost: %s\n\n" - report (gnus-emacs-version) host))))) + (format "GET %s HTTP/1.1\nUser-Agent: %s\nHost: %s\n\n" + report spam-report-user-agent host))))) ;;;###autoload (defun spam-report-process-queue (&optional file keep) @@ -216,14 +275,14 @@ symbol `ask', query before flushing the queue file." the external program specified in `mm-url-program' to connect to server." (with-temp-buffer - (let ((url (concat "http://" host report))) + (let ((url (format "http://%s%s" host report))) (mm-url-insert url t)))) ;;;###autoload (defun spam-report-url-to-file (host report) "Collect spam report requests in `spam-report-requests-file'. Customize `spam-report-url-ping-function' to use this function." - (let ((url (concat "http://" host report)) + (let ((url (format "http://%s%s" host report)) (file spam-report-requests-file)) (gnus-make-directory (file-name-directory file)) (gnus-message 9 "Writing URL `%s' to file `%s'" url file) diff --git a/lisp/spam-stat.el b/lisp/spam-stat.el index 1b1530d..2e7cee6 100644 --- a/lisp/spam-stat.el +++ b/lisp/spam-stat.el @@ -1,6 +1,6 @@ ;;; spam-stat.el --- detecting spam based on statistics -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Alex Schroeder ;; Keywords: network @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -124,6 +124,8 @@ ;;; Code: (require 'mail-parse) +(defvar gnus-original-article-buffer) + (defgroup spam-stat nil "Statistical spam detection for Emacs. Use the functions to build a dictionary of words and their statistical diff --git a/lisp/spam-wash.el b/lisp/spam-wash.el index 821da9e..23aed08 100644 --- a/lisp/spam-wash.el +++ b/lisp/spam-wash.el @@ -19,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/spam.el b/lisp/spam.el index ee57514..a9d0ac4 100644 --- a/lisp/spam.el +++ b/lisp/spam.el @@ -1,8 +1,10 @@ ;;; spam.el --- Identifying spam -;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen -;; Keywords: network +;; Maintainer: Ted Zlatanov +;; Keywords: network, spam, mail, bogofilter, BBDB, dspam, dig, whitelist, blacklist, gmane, hashcash, spamassassin, bsfilter, ifile, stat, crm114, spamoracle ;; This file is part of GNU Emacs. @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -40,6 +42,7 @@ (eval-when-compile (require 'cl)) (eval-when-compile (require 'spam-report)) +(eval-when-compile (require 'hashcash)) (require 'gnus-sum) @@ -58,6 +61,8 @@ ;; autoload spam-report (eval-and-compile (autoload 'spam-report-gmane "spam-report") + (autoload 'spam-report-gmane-spam "spam-report") + (autoload 'spam-report-gmane-ham "spam-report") (autoload 'spam-report-resend "spam-report")) ;; autoload gnus-registry @@ -80,7 +85,9 @@ Populated by spam-install-backend-super.") (defgroup spam nil "Spam configuration." - :version "22.1") + :version "22.1" + :group 'mail + :group 'news) (defcustom spam-summary-exit-behavior 'default "Exit behavior at the time of summary exit. @@ -102,6 +109,7 @@ a group through group/topic parameters overrides this mechanism." (defcustom spam-mark-new-messages-in-spam-group-as-spam t "Whether new messages in a spam group should get the spam-mark." :type 'boolean + ;; :version "22.1" ;; Gnus 5.10.8 / No Gnus 0.3 :group 'spam) (defcustom spam-log-to-registry nil @@ -350,7 +358,7 @@ Only meaningful if you enable `spam-use-blackholes'." :type '(radio (const nil) regexp) :group 'spam) -(defface spam-face +(defface spam '((((class color) (type tty) (background dark)) (:foreground "gray80" :background "gray50")) (((class color) (type tty) (background light)) @@ -360,9 +368,12 @@ Only meaningful if you enable `spam-use-blackholes'." (((class color) (background light)) (:foreground "ivory4")) (t :inverse-video t)) - "Face for spam-marked articles.") + "Face for spam-marked articles." + :group 'spam) +;; backward-compatibility alias +(put 'spam-face 'face-alias 'spam) -(defcustom spam-face 'spam-face +(defcustom spam-face 'spam "Face for spam-marked articles." :type 'face :group 'spam) @@ -1049,11 +1060,10 @@ backends)." nil) (spam-install-nocheck-backend 'spam-use-gmane - nil + 'spam-report-gmane-unregister-routine 'spam-report-gmane-register-routine - ;; does Gmane support unregistration? - nil - nil) + 'spam-report-gmane-register-routine + 'spam-report-gmane-unregister-routine) (spam-install-nocheck-backend 'spam-use-resend 'spam-report-resend-register-ham-routine @@ -1164,6 +1174,15 @@ backends)." (return)))) result)) +(defvar spam-spamassassin-score-regexp + ".*\\b\\(?:score\\|hits\\)=\\(-?[0-9.]+\\)" + "Regexp matching SpamAssassin score header. +The first group must match the number.") +;; "score" for Spamassassin 3.0 or later: +;; X-Spam-Status: Yes, score=13.1 required=5.0 tests=DNS_FROM_RFC_ABUSE, +;; [...],UNDISC_RECIPS autolearn=disabled version=3.0.3 + + (defun spam-extra-header-to-number (header headers) "Transform an extra HEADER to a number, using list of HEADERS. Note this has to be fast." @@ -1172,7 +1191,8 @@ Note this has to be fast." ((eq header 'X-Spam-Status) (string-to-number (gnus-replace-in-string (gnus-extra-header header headers) - ".*hits=" ""))) + spam-spamassassin-score-regexp + "\\1"))) ;; for CRM checking, it's probably faster to just do the string match ((and spam-use-crm114 (string-match "( pR: \\([0-9.-]+\\)" header)) (match-string 1 header)) @@ -1238,6 +1258,7 @@ Will not return a nil score." (gnus-group-spam-exit-processor-stat spam spam-use-stat) (gnus-group-spam-exit-processor-spamoracle spam spam-use-spamoracle) (gnus-group-spam-exit-processor-spamassassin spam spam-use-spamassassin) + (gnus-group-spam-exit-processor-report-gmane spam spam-use-gmane) ;; Buggy? (gnus-group-ham-exit-processor-ifile ham spam-use-ifile) (gnus-group-ham-exit-processor-bogofilter ham spam-use-bogofilter) (gnus-group-ham-exit-processor-bsfilter ham spam-use-bsfilter) @@ -2015,18 +2036,10 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." ;;{{{ Hashcash. -(eval-when-compile - (autoload 'mail-check-payment "hashcash")) - -(condition-case nil - (progn - (require 'hashcash) +(defun spam-check-hashcash () + "Check the headers for hashcash payments." + (ignore-errors (mail-check-payment))) ;mail-check-payment returns a boolean - (defun spam-check-hashcash () - "Check the headers for hashcash payments." - (mail-check-payment))) ;mail-check-payment returns a boolean - - (file-error)) ;;}}} ;;{{{ BBDB @@ -2429,7 +2442,11 @@ REMOVE not nil, remove the ADDRESSES." ;;{{{ Spam-report glue (gmane and resend reporting) (defun spam-report-gmane-register-routine (articles) (when articles - (apply 'spam-report-gmane articles))) + (apply 'spam-report-gmane-spam articles))) + +(defun spam-report-gmane-unregister-routine (articles) + (when articles + (apply 'spam-report-gmane-ham articles))) (defun spam-report-resend-register-ham-routine (articles) (spam-report-resend-register-routine articles t)) @@ -2498,7 +2515,7 @@ REMOVE not nil, remove the ADDRESSES." (if db `("-d" ,db "-v") `("-v")))) (setq return (spam-check-bogofilter-headers score)))) return) - (gnus-error "`spam.el' doesnt support obsolete bogofilter versions"))) + (gnus-error 5 "`spam.el' doesn't support obsolete bogofilter versions"))) (defun spam-bogofilter-register-with-bogofilter (articles spam @@ -2524,7 +2541,7 @@ REMOVE not nil, remove the ADDRESSES." spam-bogofilter-path nil nil nil switch (if db `("-d" ,db "-v") `("-v"))))))) - (gnus-error "`spam.el' doesnt support obsolete bogofilter versions"))) + (gnus-error 5 "`spam.el' doesn't support obsolete bogofilter versions"))) (defun spam-bogofilter-register-spam-routine (articles &optional unregister) (spam-bogofilter-register-with-bogofilter articles t unregister)) @@ -2609,7 +2626,7 @@ REMOVE not nil, remove the ADDRESSES." (if score ; scoring mode (let ((header (message-fetch-field spam-spamassassin-spam-status-header))) (when header - (if (string-match "hits=\\(-?[0-9.]+\\)" header) + (if (string-match spam-spamassassin-score-regexp header) (match-string 1 header) "0"))) ;; spam detection mode @@ -2878,8 +2895,8 @@ installed through spam-necessary-extra-headers." (add-to-list 'gnus-extra-headers header)) (setq spam-install-hooks t) - ;; TODO: How do we redo this every time spam-face is customized? - (push '((eq mark gnus-spam-mark) . spam-face) + ;; TODO: How do we redo this every time the `spam' face is customized? + (push '((eq mark gnus-spam-mark) . spam) gnus-summary-highlight) ;; Add hooks for loading and saving the spam stats (add-hook 'gnus-save-newsrc-hook 'spam-maybe-spam-stat-save) diff --git a/lisp/starttls.el b/lisp/starttls.el index f2b72fb..a9b64b4 100644 --- a/lisp/starttls.el +++ b/lisp/starttls.el @@ -1,6 +1,7 @@ ;;; starttls.el --- STARTTLS functions -;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Author: Simon Josefsson @@ -21,8 +22,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -31,7 +32,7 @@ ;; [RFC 2595] "Using TLS with IMAP, POP3 and ACAP" ;; by Chris Newman (1999/06) -;; This file now contain a combination of the two previous +;; This file now contains a combination of the two previous ;; implementations both called "starttls.el". The first one is Daiki ;; Ueno's starttls.el which uses his own "starttls" command line tool, ;; and the second one is Simon Josefsson's starttls.el which uses @@ -43,7 +44,7 @@ ;; both tools installed. It is recommended to use GNUTLS, though, as ;; it performs more verification of the certificates. -;; The GNUTLS support require GNUTLS 0.9.90 (released 2003-10-08) or +;; The GNUTLS support requires GNUTLS 0.9.90 (released 2003-10-08) or ;; later, from , or "starttls" ;; from . @@ -57,7 +58,7 @@ ;; (message "STARTTLS output:\n%s" (starttls-negotiate tmp)) ;; (process-send-string tmp "EHLO foo\n")) -;; An example run yield the following output: +;; An example run yields the following output: ;; ;; 220 yxa.extundo.com ESMTP Sendmail 8.12.11/8.12.11/Debian-3; Wed, 26 May 2004 19:12:29 +0200; (No UCE/UBE) logging access from: c494102a.s-bi.bostream.se(OK)-c494102a.s-bi.bostream.se [217.215.27.65] ;; 220 2.0.0 Ready to start TLS @@ -145,15 +146,14 @@ i.e. when `starttls-use-gnutls' is nil." (defcustom starttls-extra-args nil "Extra arguments to `starttls-program'. -This program is used when the `starttls' command is used, -i.e. when `starttls-use-gnutls' is nil." +These apply when the `starttls' command is used, i.e. when +`starttls-use-gnutls' is nil." :type '(repeat string) :group 'starttls) (defcustom starttls-extra-arguments nil "Extra arguments to `starttls-program'. -This program is used when GNUTLS is used, i.e. when -`starttls-use-gnutls' is non-nil. +These apply when GNUTLS is used, i.e. when `starttls-use-gnutls' is non-nil. For example, non-TLS compliant servers may require '(\"--protocols\" \"ssl3\"). Invoke \"gnutls-cli --help\" to @@ -171,7 +171,7 @@ find out which parameters are available." (defcustom starttls-connect "- Simple Client Mode:\n\n" "*Regular expression indicating successful connection. The default is what GNUTLS's \"gnutls-cli\" outputs." - ;; GNUTLS cli.c:main() print this string when it is starting to run + ;; GNUTLS cli.c:main() prints this string when it is starting to run ;; in the application read/write phase. If the logic, or the string ;; itself, is modified, this must be updated. :version "22.1" @@ -181,7 +181,7 @@ The default is what GNUTLS's \"gnutls-cli\" outputs." (defcustom starttls-failure "\\*\\*\\* Handshake has failed" "*Regular expression indicating failed TLS handshake. The default is what GNUTLS's \"gnutls-cli\" outputs." - ;; GNUTLS cli.c:do_handshake() print this string on failure. If the + ;; GNUTLS cli.c:do_handshake() prints this string on failure. If the ;; logic, or the string itself, is modified, this must be updated. :version "22.1" :type 'regexp @@ -199,10 +199,10 @@ The default is what GNUTLS's \"gnutls-cli\" outputs." :group 'starttls) (defun starttls-negotiate-gnutls (process) - "Negotiate TLS on process opened by `open-starttls-stream'. -This should typically only be done once. It typically return a + "Negotiate TLS on PROCESS opened by `open-starttls-stream'. +This should typically only be done once. It typically returns a multi-line informational message with information about the -handshake, or NIL on failure." +handshake, or nil on failure." (let (buffer info old-max done-ok done-bad) (if (null (setq buffer (process-buffer process))) ;; XXX How to remove/extract the TLS negotiation junk? @@ -235,18 +235,25 @@ handshake, or NIL on failure." (starttls-negotiate-gnutls process) (signal-process (process-id process) 'SIGALRM))) -(defun starttls-open-stream-gnutls (name buffer host service) +(eval-and-compile + (if (fboundp 'set-process-query-on-exit-flag) + (defalias 'starttls-set-process-query-on-exit-flag + 'set-process-query-on-exit-flag) + (defalias 'starttls-set-process-query-on-exit-flag + 'process-kill-without-query))) + +(defun starttls-open-stream-gnutls (name buffer host port) (message "Opening STARTTLS connection to `%s'..." host) (let* (done (old-max (with-current-buffer buffer (point-max))) (process-connection-type starttls-process-connection-type) (process (apply #'start-process name buffer starttls-gnutls-program "-s" host - "-p" (if (integerp service) - (int-to-string service) - service) + "-p" (if (integerp port) + (int-to-string port) + port) starttls-extra-arguments))) - (process-kill-without-query process) + (starttls-set-process-query-on-exit-flag process nil) (while (and (processp process) (eq (process-status process) 'run) (save-excursion @@ -265,11 +272,11 @@ handshake, or NIL on failure." host (if done "done" "failed")) process)) -(defun starttls-open-stream (name buffer host service) - "Open a TLS connection for a service to a host. -Returns a subprocess-object to represent the connection. +(defun starttls-open-stream (name buffer host port) + "Open a TLS connection for a port to a host. +Returns a subprocess object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. -Args are NAME BUFFER HOST SERVICE. +Args are NAME BUFFER HOST PORT. NAME is name for process. It is modified if necessary to make it unique. BUFFER is the buffer (or `buffer-name') to associate with the process. Process output goes at end of that buffer, unless you specify @@ -277,16 +284,17 @@ BUFFER is the buffer (or `buffer-name') to associate with the process. BUFFER may be also nil, meaning that this process is not associated with any buffer Third arg is name of the host to connect to, or its IP address. -Fourth arg SERVICE is name of the service desired, or an integer -specifying a port number to connect to." +Fourth arg PORT is an integer specifying a port to connect to. +If `starttls-use-gnutls' is nil, this may also be a service name, but +GNUTLS requires a port number." (if starttls-use-gnutls - (starttls-open-stream-gnutls name buffer host service) + (starttls-open-stream-gnutls name buffer host port) (let* ((process-connection-type starttls-process-connection-type) (process (apply #'start-process name buffer starttls-program - host (format "%s" service) + host (format "%s" port) starttls-extra-args))) - (process-kill-without-query process) + (starttls-set-process-query-on-exit-flag process nil) process))) (provide 'starttls) diff --git a/lisp/time-date.el b/lisp/time-date.el index 06701cc..d8e8480 100644 --- a/lisp/time-date.el +++ b/lisp/time-date.el @@ -1,6 +1,7 @@ ;;; time-date.el --- Date and time handling functions -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005 -;; Free Software Foundation, Inc. + +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 +;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Masanobu Umeda @@ -20,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -91,6 +92,7 @@ and type 3 is the list (HIGH LOW MICRO)." ((eq type 1) (list high low)) ((eq type 2) (list high low micro)))) +(autoload 'parse-time-string "parse-time") (autoload 'timezone-make-date-arpa-standard "timezone") ;;;###autoload diff --git a/lisp/tls.el b/lisp/tls.el index fd74738..fe089de 100644 --- a/lisp/tls.el +++ b/lisp/tls.el @@ -1,6 +1,7 @@ ;;; tls.el --- TLS/SSL support via wrapper around GnuTLS -;; Copyright (C) 1996-1999, 2003, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1996, 1997, 1998, 1999, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Simon Josefsson ;; Keywords: comm, tls, gnutls, ssl @@ -19,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -55,7 +56,8 @@ :group 'comm) (defcustom tls-program '("gnutls-cli -p %p %h" - "gnutls-cli -p %p %h --protocols ssl3") + "gnutls-cli -p %p %h --protocols ssl3" + "openssl s_client -connect %h:%p -no_ssl2") "List of strings containing commands to start TLS stream to a host. Each entry in the list is tried until a connection is successful. %s is replaced with server hostname, %p with port to connect to. @@ -63,6 +65,7 @@ The program should read input on stdin and write output to stdout. Also see `tls-success' for what the program should output after successful negotiation." :type '(repeat string) + :version "22.1" :group 'tls) (defcustom tls-process-connection-type nil @@ -71,9 +74,10 @@ after successful negotiation." :type 'boolean :group 'tls) -(defcustom tls-success "- Handshake was completed" +(defcustom tls-success "- Handshake was completed\\|SSL handshake has read " "*Regular expression indicating completed TLS handshakes. -The default is what GNUTLS's \"gnutls-cli\" outputs." +The default is what GNUTLS's \"gnutls-cli\" or OpenSSL's +\"openssl s_client\" outputs." :version "22.1" :type 'regexp :group 'tls) @@ -108,11 +112,11 @@ Used by `tls-certificate-information'." (push (cons (match-string 1) (match-string 2)) vals)) (nreverse vals)))))) -(defun open-tls-stream (name buffer host service) - "Open a TLS connection for a service to a host. +(defun open-tls-stream (name buffer host port) + "Open a TLS connection for a port to a host. Returns a subprocess-object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. -Args are NAME BUFFER HOST SERVICE. +Args are NAME BUFFER HOST PORT. NAME is name for process. It is modified if necessary to make it unique. BUFFER is the buffer (or buffer-name) to associate with the process. Process output goes at end of that buffer, unless you specify @@ -120,8 +124,7 @@ BUFFER is the buffer (or buffer-name) to associate with the process. BUFFER may be also nil, meaning that this process is not associated with any buffer Third arg is name of the host to connect to, or its IP address. -Fourth arg SERVICE is name of the service desired, or an integer -specifying a port number to connect to." +Fourth arg PORT is an integer specifying a port to connect to." (let ((cmds tls-program) cmd done) (message "Opening TLS connection to `%s'..." host) (while (and (not done) (setq cmd (pop cmds))) @@ -133,9 +136,9 @@ specifying a port number to connect to." cmd (format-spec-make ?h host - ?p (if (integerp service) - (int-to-string service) - service))))) + ?p (if (integerp port) + (int-to-string port) + port))))) response) (while (and process (memq (process-status process) '(open run)) diff --git a/lisp/utf7.el b/lisp/utf7.el index 65f364a..a1b7fdc 100644 --- a/lisp/utf7.el +++ b/lisp/utf7.el @@ -1,5 +1,7 @@ ;;; utf7.el --- UTF-7 encoding/decoding for Emacs -*-coding: iso-8859-1;-*- -;; Copyright (C) 1999, 2000, 2003 Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Jon K Hellan ;; Maintainer: bugs@gnus.org @@ -19,8 +21,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -78,7 +80,7 @@ (defconst utf7-utf-16-coding-system (cond ((mm-coding-system-p 'utf-16-be-no-signature) ; Mule-UCS 'utf-16-be-no-signature) - ((and (mm-coding-system-p 'utf-16-be) ; Emacs 22.1 + ((and (mm-coding-system-p 'utf-16-be) ; Emacs 21.3, Emacs 22 ;; Avoid versions with BOM. (= 2 (length (encode-coding-string "a" 'utf-16-be)))) 'utf-16-be) diff --git a/lisp/uudecode.el b/lisp/uudecode.el index 01c2db3..53ed51d 100644 --- a/lisp/uudecode.el +++ b/lisp/uudecode.el @@ -1,7 +1,7 @@ ;;; uudecode.el -- elisp native uudecode -;; Copyright (c) 1998, 1999, 2000, 2001, 2003, 2004 -;; Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: uudecode news @@ -20,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/lisp/webmail.el b/lisp/webmail.el index b967013..304a206 100644 --- a/lisp/webmail.el +++ b/lisp/webmail.el @@ -1,5 +1,7 @@ ;;; webmail.el --- interface of web mail -;; Copyright (C) 1999, 2000, 2001, 2004 Free Software Foundation, Inc. + +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: hotmail netaddress my-deja netscape @@ -18,8 +20,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -635,7 +637,7 @@ (goto-char (point-min)) (delete-blank-lines) (setq ct (mail-fetch-field "content-type") - ctl (ignore-errors (mail-header-parse-content-type ct)) + ctl (and ct (mail-header-parse-content-type ct)) ;;cte (mail-fetch-field "content-transfer-encoding") cd (mail-fetch-field "content-disposition") description (mail-fetch-field "content-description") diff --git a/lisp/yenc.el b/lisp/yenc.el index ed0d950..767d262 100644 --- a/lisp/yenc.el +++ b/lisp/yenc.el @@ -1,5 +1,6 @@ ;;; yenc.el --- elisp native yenc decoder -;; Copyright (c) 2002 Free Software Foundation, Inc. + +;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Jesper Harder ;; Keywords: yenc news @@ -18,8 +19,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/make.bat b/make.bat index 672284b..653d827 100755 --- a/make.bat +++ b/make.bat @@ -3,6 +3,16 @@ rem Written by Frank Schmitt (ich@frank-schmitt.net) rem based on the work by David Charlap (shamino@writeme.com) rem . +rem . +rem From http://my.gnus.org/node/343: +rem A comment on installing Gnus on Windows 98 SE that might help others: When +rem I ran the "make.bat" file in the 5.10.6 tarball I got a bunch of "Out of +rem environment space" messages. The solution was to (1) make a shortcut to +rem the make.bat file, and (2) right-click on the shortcut, setting "Cmd line" +rem in the "Program" tab in "properties" to include the parameters make.bat +rem requires, and "initial environment" in the "memories" tab, to the maximum +rem (in my case, anyway, 2560). +rem . rem Clear PWD so emacs doesn't get confused set GNUS_PWD_SAVE=%PWD% set PWD= @@ -21,8 +31,8 @@ goto noemacs set EMACS=emacs.bat echo. echo *************************************************************************** -echo * Using emacs.bat (If you've got en Emacs >= 20.3 please remove Emacs.bat, -echo * it isn't needed anymore. +echo * Using emacs.bat (If you've got Emacs 20.3 or higher please remove +echo * Emacs.bat, it isn't needed anymore.) echo *************************************************************************** echo. goto emacs @@ -187,9 +197,14 @@ if not exist %GNUS_ETC_DIR%\gnus\nul mkdir %GNUS_ETC_DIR%\gnus xcopy /R /Q /Y .\gnus\* %GNUS_ETC_DIR%\gnus\ if ErrorLevel 1 set ERROR=%ERROR%,copy-etc-gnus-* if not exist %GNUS_ETC_DIR%\images\nul mkdir %GNUS_ETC_DIR%\images +xcopy /R /Q /Y .\images\*.??? %GNUS_ETC_DIR%\images +if ErrorLevel 1 set ERROR=%ERROR%,copy-etc-images-* if not exist %GNUS_ETC_DIR%\images\gnus\nul mkdir %GNUS_ETC_DIR%\images\gnus xcopy /R /Q /Y .\images\gnus\* %GNUS_ETC_DIR%\images\gnus\ if ErrorLevel 1 set ERROR=%ERROR%,copy-etc-images-gnus-* +if not exist %GNUS_ETC_DIR%\images\mail\nul mkdir %GNUS_ETC_DIR%\images\mail +xcopy /R /Q /Y .\images\mail\* %GNUS_ETC_DIR%\images\mail\ +if ErrorLevel 1 set ERROR=%ERROR%,copy-etc-images-mail-* if not exist %GNUS_ETC_DIR%\images\smilies\nul mkdir %GNUS_ETC_DIR%\images\smilies xcopy /R /Q /Y .\images\smilies\* %GNUS_ETC_DIR%\images\smilies\ if ErrorLevel 1 set ERROR=%ERROR%,copy-etc-images-smilies-* diff --git a/texi/ChangeLog b/texi/ChangeLog index 83df189..323eff3 100644 --- a/texi/ChangeLog +++ b/texi/ChangeLog @@ -1,3 +1,549 @@ +2006-04-11 Reiner Steib + + * gnus.texi, gnus-faq.texi, message.texi: No Gnus v0.4 is released. + +2006-04-10 Reiner Steib + + * gnus.texi (Misc Group Stuff, Summary Buffer, Article Keymap) + (Server Commands): Key `v' is reserved for users. + +2006-04-07 Reiner Steib + + * gnus.texi (Summary Buffer Lines): Add `*'. + +2006-04-07 Jochen K,A|(Bpper + + * gnus.texi (Group Parameters): Mention + gnus-permanently-visible-groups. + +2006-04-06 Katsumi Yamaoka + + * gnus.texi (Face): Restore xref to gnus-face-properties-alist; + fix typo. + +2006-04-05 Reiner Steib + + * gnus.texi (X-Face): Clarify. + (Face): Need Emacs with PNG support. + +2006-04-04 Reiner Steib + + * gnus.texi, message.texi: Bump version. + +2006-04-04 Simon Josefsson + + * gnus.texi (Security): Improve. + +2006-03-31 Reiner Steib + + * gnus-news.texi: Restore customizable tool bar item. Markup + fixes. Minor rewording. Add "New packages and libraries", + "summary and article", "Appearance" and "Miscellaneous". Remove + "Major new features" and "Other changes". Add some @xref-s. + +2006-03-31 Romain Francoise + + * gnus.texi (Virtual Groups): `nnvirtual-always-rescan' defaults + to t, not nil (and has for the past eight years). + +2006-03-30 Romain Francoise + + * gnus-news.texi: Reorder entries in sections. Fix typos. + Add local variables section. + + * gnus-news.el (gnus-news-header-disclaimer): Delete top section. + (gnus-news-fill-column): Increment to 80. + (gnus-news-translate-file): Support nested list items. + +2006-03-30 Reiner Steib + + * gnus-news.texi: Add gnus-group-update-tool-bar. + +2006-03-29 Reiner Steib + + * gnus.texi (Top): Add comment about version line. + + * message.texi (Top): Ditto. Change to take named versions into + account. + + * gnus-news.texi: Add customizable tool bar. + +2006-03-28 Reiner Steib + + * gnus.texi (Posting Styles): Add x-face-file to example. + (X-Face): Refer to posting styles. + + * gnus-faq.texi ([5.8]): Add x-face-file. + ([8.4]): Add links to gmane.emacs.gnus.user and + gmane.emacs.gnus.general. + +2006-03-27 Reiner Steib + + * sasl.texi: Use @copyright{} instead of (C). Update copyright. + +2006-03-27 Karl Berry + + * gnus.texi, message.texi, emacs-mime.texi, sieve.texi, pgg.texi: + Do not indent copyright year list. + +2006-03-27 Reiner Steib + + * gnus-faq.texi: Use .invalid. + ([5.4]): Fix gnus-posting-styles example. + +2006-03-20 Romain Francoise + + * gnus.texi (Mail Folders, Mail Spool): Grammar fixes. + +2006-03-10 Katsumi Yamaoka + + * gnus.texi (NoCeM): Mention gnus-use-nocem can also be a number. + +2006-03-10 Reiner Steib + + * gnus.texi (Fancy Mail Splitting): Improve sentences so as to be + easy to understand. + +2006-03-09 Katsumi Yamaoka + + * gnus.texi: Markup fix. + (Fancy Mail Splitting): Specify new feature. + +2006-03-08 Katsumi Yamaoka + + * gnus.texi (Fancy Mail Splitting): Improve descriptions about + partial-words matching. + +2006-03-07 Reiner Steib + + * emacs-mime.texi (Display Customization): Reword image/.* stuff. + + * gnus.texi (Oort Gnus): Add note about `gnus-load'. + (MIME Commands): Fix mm-discouraged-alternatives. + +2006-03-06 Reiner Steib + + * gnus-news.el, gnus-news.texi: Update copyright. + +2006-03-03 Reiner Steib + + * xemacs.mak: Remove outdated file. Use make.bat instead. + + * gnus.texi (Oort Gnus): Add `mm-fill-flowed'. + +2006-02-09 Reiner Steib + + * gnus.texi (Mail Spool): nnml-use-compressed-files can be a + string. + (Gnus Versions): Add history beyond start of Oort. + + * gnus-news.texi: Add nnml-use-compressed-files. + +2006-01-31 Romain Francoise + + * message.texi: Update copyright year. + +2006-01-26 Katsumi Yamaoka + + * ps/Makefile.in (distclean): Remove Makefile. + + * Makefile.in (almost-clean): Rename from clean. + (clean): Rename from veryclean. + (distclean): Use clean. + (pspackage): Use almost-clean. + +2006-01-16 Katsumi Yamaoka + + * gnus.texi: Update copyright. + +2006-01-13 Katsumi Yamaoka + + * gnus.texi (Article Washing): Additions. + +2006-01-08 Alex Schroeder + + * pgg.texi (Caching passphrase): Rewording. + +2006-01-10 Katsumi Yamaoka + + * gnus.texi (RSS): Document nnrss-wash-html-in-text-plain-parts. + +2006-01-06 Katsumi Yamaoka + + * gnus.texi (Group Parameters): Fix description. + (RSS): Addition. + +2005-12-22 Katsumi Yamaoka + + * gnus.texi (Summary Post Commands): Fix function bound to `S O p'. + +2005-12-19 Katsumi Yamaoka + + * emacs-mime.texi (Display Customization): Add setting example to + mm-discouraged-alternatives. + +2005-12-15 Reiner Steib + + * gnus.texi (Gmane Spam Reporting): Fix + spam-report-gmane-use-article-number. Add + spam-report-user-mail-address. + +2005-12-13 Reiner Steib + + * gnus-news.el (gnus-news-translate-file): Fix previous commit. + + * gnus-coding.texi (Gnus Coding Style): Add `uudecode.el'. + (Gnus Maintainance Guide): Add ref to "Gnus Development". Add + conventions about custom versions. + +2005-12-12 Katsumi Yamaoka + + * gnus.texi (MIME Commands): Mention addition of + multipart/alternative to gnus-buttonized-mime-types and add xref + to mm-discouraged-alternatives. + + * emacs-mime.texi (Display Customization): Mention addition of + "image/.*" and add xref to gnus-buttonized-mime-types in the + mm-discouraged-alternatives section. + +2005-12-06 Katsumi Yamaoka + + * gnus-news.el: Markup and description fixes and additions. + +2005-12-05 Katsumi Yamaoka + + * pgg.texi (User Commands): Fix description of pgg-verify-region. + (Selecting an implementation): Fix descriptions. + +2005-12-02 Reiner Steib + + * gnus-news.el: Update Copyright. + (gnus-news-translate-file): Avoid "*Note" at beginning of line. + +2005-12-01 Katsumi Yamaoka + + * emacs-mime.texi (Non-MIME): x-gnus-verbatim -> x-verbatim. + +2005-11-30 Katsumi Yamaoka + + * message.texi (Various Message Variables): Addition. + +2005-11-29 Katsumi Yamaoka + + * message.texi: Fix default values. + +2005-11-25 Katsumi Yamaoka + + * message.texi (Header Commands): Clarify descriptions of + message-cross-post-followup-to, message-reduce-to-to-cc, and + message-insert-wide-reply. + (Various Commands): Fix kindex for message-kill-to-signature; + clarify description of message-tab. + +2005-11-22 Katsumi Yamaoka + + * message.texi (Mailing Lists): Fix description about MFT. + + * gnus.texi (Emacs Lisp): Use ~/.gnus.el instead of ~/.emacs. + +2005-11-17 Katsumi Yamaoka + + * gnus.texi (Slow Terminal Connection): Replace old description + with new one. + +2005-11-16 Katsumi Yamaoka + + * gnus.texi (Oort Gnus): Use ~/.gnus.el instead of ~/.emacs; + replace X-Draft-Headers with X-Draft-From. + +2005-11-14 Katsumi Yamaoka + + * gnus.texi (Various Various): Fix the default value of + nnheader-max-head-length. + (Gnus Versions): Fix typo. + +2005-11-10 Reiner Steib + + * gnus-coding.texi (Gnus Coding Style): Add MIME subsection. + (Gnus Maintainance Guide): Improvements. + + * gnus.texi (Sorting the Summary Buffer): Replace 2005-10-29 + change by a reference to `Group Parameters'. Use `(not ...)' in + example instead of `lambda' expression. + (Group Parameters): Add simplified sorting example based on + example for `Sorting the Summary Buffer' from Jari Aalto + . + (Example Methods): Add example for an indirect connection. + +2005-11-10 Katsumi Yamaoka + + * gnus.texi (XVarious): Fix description of gnus-use-toolbar; add + new variable gnus-toolbar-thickness. + +2005-11-09 Katsumi Yamaoka + + * gnus.texi (Agent and flags): Add it to the detailmenu. + +2005-11-08 Kevin Greiner + + * gnus.texi (nntp-open-via-telnet-and-telnet): Fixed grammar. + (Agent Parameters): Updated parameter names to match code. + (Group Agent Commands): Corrected 'gnus-agent-fetch-series' as + 'gnus-agent-summary-fetch-series'. + (Agent and flags): New section providing a generalized discussion + of flag handling. + (Agent and IMAP): Removed flag discussion. + (Agent Variables): Added 'gnus-agent-synchronize-flags' + +2005-11-08 Romain Francoise + + * gnus.texi (Exiting the Summary Buffer): Add new function + `gnus-summary-catchup-and-goto-prev-group', bound to `Z p'. + +2005-11-08 Katsumi Yamaoka + + * gnus.texi (XVarious): Revert description of gnus-use-toolbar. + +2005-11-07 Katsumi Yamaoka + + * gnus.texi (X-Face): Fix description. + (XVarious): Remove gnus-xmas-logo-color-alist and + gnus-xmas-logo-color-style; fix description of gnus-use-toolbar. + +2005-11-04 Ken Manheimer + + * pgg.texi (User Commands): Document additional passphrase + argument for pgg-encrypt-*, pgg-decrypt-*, and pgg-sign-* functions. + (Backend methods): Likewise for corresponding pgg-scheme-* functions. + +2005-11-02 Reiner Steib + + * gnus.texi (Conformity): Fix typo. + (Customizing Articles): Document `first'. + +2005-11-01 Katsumi Yamaoka + + * gnus.texi (Group Parameters): Mention new variable + gnus-parameters-case-fold-search. + (Home Score File): Addition. + +2005-10-29 Sascha Wilde + + * pgg.texi (How to use): Update the example to add autoload of + pgg-encrypt-symmetric-region. + (User Commands): Document pgg-encrypt-symmetric-region. + (Backend methods): Document pgg-scheme-encrypt-symmetric-region. + +2005-10-29 Jari Aalto + + * gnus.texi (Sorting the Summary Buffer): + Add `gnus-thread-sort-by-date-reverse'. Add example + host to different sorting in NNTP and RSS groups. + +2005-10-28 Reiner Steib + + * gnus-coding.texi: Split into nodes. + (Gnus Coding Style): Add flow-fill.el. + +2005-10-25 Reiner Steib + + * gnus-coding.texi (Dependencies): Add some text. + (Dependencies): Update encrypt.el. + +2005-10-17 Katsumi Yamaoka + + * gnus.texi (Document Groups): Remove duplicate item. + +2005-10-14 Katsumi Yamaoka + + * gnus.texi (Document Server Internals): Addition. + +2005-10-13 Katsumi Yamaoka + + * gnus.texi (A note on namespaces): Fix RFC reference. + +2005-10-12 Katsumi Yamaoka + + * gnus.texi (RSS): Fix key description. + +2005-10-11 Katsumi Yamaoka + + * gnus.texi: Emacs/w3 -> Emacs/W3. + (Browsing the Web): Fix description. + (Web Searches): Ditto. + (Customizing W3): Ditto. + +2005-10-07 Katsumi Yamaoka + + * gnus.texi (Maildir): Clarify expire-age and expire-group. + +2005-10-04 Katsumi Yamaoka + + * gnus-news.texi: Mention that the Lisp files are now installed in + .../site-lisp/gnus/ by default. + +2005-10-03 Simon Josefsson + + * gnus-news.texi: Fix typo. + +2005-09-28 Reiner Steib + + * gnus-coding.texi: Added some comments. + + * message.texi (Insertion): Describe prefix for + message-mark-inserted-region and message-mark-insert-file. + +2005-09-28 Simon Josefsson + + * message.texi (IDNA): Fix. + +2005-09-28 Katsumi Yamaoka + + * gnus.texi (NNTP): Remove nntp-buggy-select, nntp-read-timeout, + nntp-server-hook, and nntp-warn-about-losing-connection; fix + description of nntp-open-connection-function. + (Common Variables): Fix descriptions. + +2005-09-27 Reiner Steib + + * emacs-mime.texi (Non-MIME): Add Slrn-style verbatim marks and + LaTeX documents. Describe "text/x-gnus-verbatim". + +2005-09-26 Katsumi Yamaoka + + * gnus.texi (Server Buffer Format): Document the %a format spec. + +2005-09-22 Katsumi Yamaoka + + * gnus.texi (Mail): Fix gnus-confirm-mail-reply-to-news entry. + +2005-09-21 Teodor Zlatanov + + * gnus.texi (Blacklists and Whitelists) + (Blacklists and Whitelists, BBDB Whitelists) + (Gmane Spam Reporting, Bogofilter, spam-stat spam filtering) + (spam-stat spam filtering, SpamOracle) + (Extending the Spam ELisp package): Removed extra quote symbol for + clarity. + +2005-09-20 Reiner Steib + + * gnus.texi (MIME Commands): Add gnus-article-save-part-and-strip, + gnus-article-delete-part and gnus-article-replace-part. + (Using MIME): Add gnus-mime-replace-part. + + * gnus-news.texi: Add gnus-mime-replace-part and + gnus-article-replace-part. Use @xref. + +2005-09-20 Simon Josefsson + + * gnus-coding.texi: New file, from Reiner Steib + . + +2005-09-17 Romain Francoise + + Update all files to specify GFDL version 1.2. + + * doclicense.texi (GNU Free Documentation License): Update to + version 1.2. + +2005-09-15 Katsumi Yamaoka + + * gnus.texi (Finding the Parent): Fix description of how Gnus + finds article. + +2005-09-14 Jari Aalto + + * gnus.texi (Advanced Scoring Examples): New exmples to teach how + to drop off non-answered articles. + +2005-09-11 Romain Francoise + + * message.texi (Message Headers): Explain what + `message-alternative-emails' does in more detail. + + * gnus.texi (Mail Spool): Mention that `nnml-use-compressed-files' + requires `auto-compression-mode' to be enabled. Add new nnml + variable `nnml-compressed-files-size-threshold'. + +2005-09-07 Reiner Steib + + * gnus.texi (Sorting the Summary Buffer): Added + gnus-thread-sort-by-recipient. + +2005-09-05 Katsumi Yamaoka + + * gnus-news.texi: Fix reference. + +2005-09-04 Reiner Steib + + * gnus.texi (Mail Source Customization): Fix descriptions of + mail-source-incoming-file-prefix. + + * message.texi (MIME): Describe mml-dnd-protocol-alist and + mml-dnd-attach-options. + + * gnus-news.texi: Added reference. + +2005-09-02 Katsumi Yamaoka + + * gnus.texi (Choosing Variables): Fix descriptions. + +2005-08-19 Katsumi Yamaoka + + * emacs-mime.texi (time-date): Fix description of safe-date-to-time. + +2005-08-18 Katsumi Yamaoka + + * emacs-mime.texi (Handles): Remove duplicate item. + (Encoding Customization): Fix the default value for + mm-coding-system-priorities. + (Charset Translation): Emacs doesn't use mm-mime-mule-charset-alist. + (Basic Functions): Fix reference. + +2005-08-10 Romain Francoise + + * gnus-news.texi: Mention new variable `message-yank-empty-prefix'. + +2005-08-09 Katsumi Yamaoka + + * gnus.texi (Charsets): Fj hierarchy uses iso-2022-jp. + +2005-08-08 Romain Francoise + + * message.texi (Insertion Variables): Mention new variable + `message-yank-empty-prefix'. Change `message-yank-cited-prefix' + documentation accordingly. + +2005-07-27 Reiner Steib + + * gnus.texi (Startup Files): Fix name of gnus-site-init-file. + Mention that gnus-init-file is not read when Emacs is invoked with + --no-init-file or -q. + +2005-07-20 Didier Verna + + * gnus.texi (Email Based Diary): New. Proper documentation for the + nndiary back end and the gnus-diary library. + +2005-07-18 Romain Francoise + + * gnus.texi (To From Newsgroups): Mention new variables + `gnus-summary-to-prefix' and `gnus-summary-newsgroup-prefix'. + + * gnus-news.texi: Ditto. + +2005-06-29 Katsumi Yamaoka + + * gnus.texi (NoCeM): gnus-nocem-verifyer defaults to pgg-verify. + +2005-06-23 Juanma Barranquero + + * gnus.texi (MIME Commands, Fancy Mail Splitting, Agent Visuals) + (Agent Variables): + * message.texi (Message Headers): + Texinfo usage fix. + 2005-03-30 Reiner Steib * Makefile.in (gnus-booklet.dvi, gnus-booklet.pdf): Simplify. @@ -101,7 +647,7 @@ * gnus-news.texi: Ditto. -2005-01-16 Xavier Maillard (tiny change) +2005-01-16 Xavier Maillard (tiny change) * gnus-faq.texi ([4.1]): Typo. @@ -165,7 +711,7 @@ 2004-12-08 Reiner Steib - * gnusref.tex: Mention `gnus-summary-limit-to-recipient' and + * gnusref.tex: Mention `gnus-summary-limit-to-recipient' and `gnus-summary-sort-by-recipient'. 2004-12-08 Reiner Steib @@ -187,7 +733,7 @@ 2004-12-06 Reiner Steib - * gnus-news.texi: Mention `gnus-summary-limit-to-recipient' and + * gnus-news.texi: Mention `gnus-summary-limit-to-recipient' and `gnus-summary-sort-by-recipient'. * gnus.texi (Filtering Spam Using The Spam ELisp Package): Index @@ -363,7 +909,7 @@ 2004-08-31 Reiner Steib * emacs-mime.texi, gnus-faq.texi, gnus.texi, message.texi, - pgg.texi, sieve.texi: Use @copying and @insertcopying. + * pgg.texi, sieve.texi: Use @copying and @insertcopying. 2004-08-22 Reiner Steib @@ -372,8 +918,8 @@ 2004-08-17 Teodor Zlatanov - * gnus.texi (IMAP): add comments about imaps synonym to imap in - netrc syntax + * gnus.texi (IMAP): Add comments about imaps synonym to imap in + netrc syntax. 2004-08-15 Simon Josefsson @@ -434,7 +980,7 @@ 2004-05-28 Reiner Steib * gnus-faq.texi: Untabify. - ([6.3]): nnir.el is in contrib directory. + ([6.3]): nnir.el is in contrib directory. * message.texi (News Headers): Clarify how a unique ID is created. @@ -443,7 +989,7 @@ 2004-05-19 Andre Srinivasan * gnus.texi (Group Parameters): Added more on hooks. (Small - change.) + change.) 2004-05-19 Reiner Steib @@ -470,7 +1016,7 @@ * gnus.texi (Charsets): Point to relevant section in emacs-mime. -2004-04-14 Kevin Greiner +2004-04-14 Kevin Greiner * gnus.texi (Agent Visuals): Referenced new F(etched) group line format. @@ -504,9 +1050,8 @@ 2004-03-29 Teodor Zlatanov - * gnus.texi (Spam ELisp Package Sequence of Events): some clarifications - (Spam ELisp Package Global Variables) - (Spam ELisp Package Global Variables): more clarifications + * gnus.texi (Spam ELisp Package Sequence of Events): Some clarifications. + (Spam ELisp Package Global Variables): More clarifications. 2004-03-18 Helmut Waitzmann (tiny change) @@ -580,7 +1125,7 @@ * emacs-mime.texi: Enclose the iflatex section with iftex. -2004-03-02 Kevin Greiner +2004-03-02 Kevin Greiner * emacs-mime.texi: Wrapped documentencoding inside of iflatex as documentencoding is not supported by infohack. @@ -591,7 +1136,7 @@ characters that can not be encoded using iso-8859-1. (Gnus Unplugged): Reference gnus-agent variable. (Agent Variables): Added gnus-agent. - + 2004-02-17 Katsumi Yamaoka @@ -622,7 +1167,7 @@ 2004-01-23 Teodor Zlatanov * gnus.texi (Spam ELisp Package Filtering of Incoming Mail): - mention spam-split does not modify incoming mail + Mention spam-split does not modify incoming mail. 2004-01-23 Jesper Harder @@ -630,9 +1175,9 @@ 2004-01-22 Teodor Zlatanov - * gnus.texi (Spam ELisp Package Sequence of Events): fix typo + * gnus.texi (Spam ELisp Package Sequence of Events): Fix typo. -2004-01-21 Kevin Greiner +2004-01-21 Kevin Greiner * gnus.texi (Outgoing Messages, Agent Variables): Add gnus-agent-queue-mail and gnus-agent-prompt-send-queue. @@ -661,7 +1206,7 @@ * gnus.texi (The problem of spam): Fix, reported by Cheng Gao and suggested by Richard Hoskins - (tiny change). + (tiny change). 2004-01-07 Jesper Harder @@ -766,7 +1311,7 @@ (Blacklists and Whitelists, BBDB Whitelists) (Gmane Spam Reporting, Bogofilter, spam-stat spam filtering) (SpamOracle): mention that spam/ham processor variables are being - obsoleted + obsoleted (Extending the Spam ELisp package): add some new documentation for adding a new backend to spam.el @@ -790,7 +1335,7 @@ 2003-12-31 Steve Youngs * gnus.texi (XEmacs): Update list of Gnus XEmacs package - requirements. + requirements. 2003-12-30 Reiner Steib @@ -817,7 +1362,7 @@ * gnus.texi (Group Parameters): Clarify. -2003-12-11 Kevin Greiner +2003-12-11 Kevin Greiner * gnus.texi (Agent Parameters): Added references in Topic and Group Parameters. Added gnus-agent-cat-disable-undownloaded-faces @@ -1064,11 +1609,13 @@ * gnus.texi (Filtering Spam Using The Spam ELisp Package): mentioned the spam-install-hooks mess +2003-07-11 Matthias Andree (tiny change) + + * gnus.texi (Splitting in IMAP): Typos. + 2003-07-11 Simon Josefsson - * gnus.texi (Splitting in IMAP): Typos, tiny patch from Matthias - Andree . - (Splitting in IMAP): Mention Sieve. + * gnus.texi (Splitting in IMAP): Mention Sieve. 2003-07-10 Simon Josefsson @@ -1084,7 +1631,7 @@ 2003-06-24 Lars Magne Ingebrigtsen * gnus.texi (Summary Mail Commands): Make note of - Mail-Followup-To. + Mail-Followup-To. 2003-06-23 Jesper Harder @@ -1194,12 +1741,11 @@ * message.texi (Insertion Variables): do. -2003-05-13 Simon Josefsson +2003-05-13 Niklas Morberg (tiny change) - * gnus.texi (IMAP, Agent and IMAP, Oort Gnus): s/a/an/. Tiny - patch from Niklas Morberg . + * gnus.texi (IMAP, Agent and IMAP, Oort Gnus): s/a/an/. -2003-05-12 Kevin Greiner +2003-05-12 Kevin Greiner * gnus.texi (Agent Visuals): Add. @@ -1454,7 +2000,7 @@ * message.texi (IDNA): New. -2003-03-18 Kevin Greiner +2003-03-18 Kevin Greiner * gnus.texi (Gnus Unplugged): Refer to new agent Group/Topic parameters. @@ -1492,10 +2038,9 @@ * gnus.texi (Required Back End Functions): Add. -2003-03-17 Simon Josefsson +2003-03-17 Frank Haun (tiny change) - * pgg.texi: Fix setfilename. Tiny patch by Frank Haun - . + * pgg.texi: Fix setfilename. 2003-03-09 Paul Jarc @@ -1531,7 +2076,7 @@ (Document Server Internals, Score Variables, Adaptive Scoring) (X-Face, Hashcash): do. -2003-02-28 Vasily Korytov +2003-02-28 Vasily Korytov * gnus.texi: New values, 'to-list and 'cc-list, for gnus-boring-article-headers. @@ -2413,7 +2958,7 @@ * gnus.texi (Mail Spool): Add cindex for marks. (Mail Folders): Add cindex for marks. -2002-03-24 Raymond Scholz +2002-03-24 Raymond Scholz * gnus.texi (Summary Buffer Lines): Fix doc. @@ -2421,7 +2966,7 @@ * Makefile.in (booklet.dvi, booklet.pdf): Support booklet. -2002-03-24 Felix Natter +2002-03-24 Felix Natter * booklet.tex, bk-at.tex, bk-lt.tex, gnuslog-booklet.eps: New file. * gnusref.tex, refcard.tex: Support booklet. @@ -2451,7 +2996,7 @@ * message.texi (Security): Add mml-unsecure-message. (Mailing Lists): Index message-goto-mail-followup-to. -2002-03-23 Jesper Harder +2002-03-23 Jesper Harder * gnusref.tex, refcard.tex: Addition. @@ -2530,7 +3075,7 @@ * gnus.texi (Mail Source Specifiers): Use @uref. -2002-02-13 Jesper Harder +2002-02-13 Jesper Harder * message.texi, gnus.texi, emacs-mime.texi: Use small caps consistently. MIME, NOV, NNTP, HTML, IMAP are written with @sc @@ -3600,11 +4145,11 @@ * gnus.texi (Sorting Groups): Note `C-k' and `C-y' for manually moving groups around. -2001-04-07 Ryan Yeske +2001-04-07 Ryan Yeske * gnus.texi (Splitting in IMAP): Fix. -2001-04-07 Jesper Harder +2001-04-07 Jesper Harder * gnus.texi (More Threading): Fix. @@ -3727,7 +4272,7 @@ * gnus.texi (Top): Add Using GPG. -2001-02-02 David Masterson +2001-02-02 David Masterson * gnus.texi (The Server is Down): Add link to Group Levels. @@ -3746,7 +4291,7 @@ * message.texi (message-ignored-news-headers): Add "X-Draft-From:". (message-ignored-mail-headers): Ditto. -2001-01-21 Raymond Scholz +2001-01-21 Raymond Scholz * message.texi: Rename X-Mailer and X-Newsreader to User-Agent. @@ -3762,7 +4307,7 @@ * emacs-mime.texi: Set dircategory to Emacs. -2001-01-16 Jesper Harder +2001-01-16 Jesper Harder * gnus.texi (Group Line Specification): Add. @@ -3931,7 +4476,7 @@ group names as target, where `gnus-split-methods' uses file names. Suggested by Nevin Kapur. -2000-11-07 Martin Buchholz +2000-11-07 Martin Buchholz * gnus.texi: Doc fix. @@ -3944,7 +4489,7 @@ * gnus.texi (Finding the News): @env is not supported in texinfo 3.12. -2000-10-31 Jorge Godoy +2000-10-31 Jorge Godoy * gnus.texi: gnus-gpg document. @@ -4083,7 +4628,7 @@ Explain interaction between these. Add Lisp example for setting `nnmail-expiry-target'. -2000-08-04 Andreas Oeldenberger +2000-08-04 Andreas Oeldenberger * message.texi (Forwarding): Fix. @@ -4240,7 +4785,7 @@ * gnus.texi (MIME Commands): Fix. -2000-01-03 Karl Kleinpaste +2000-01-03 Karl Kleinpaste * gnus.texi (Splitting in IMAP): Add '.' after @xref. diff --git a/texi/Makefile.in b/texi/Makefile.in index bad289c..15b89e3 100644 --- a/texi/Makefile.in +++ b/texi/Makefile.in @@ -49,7 +49,7 @@ dvi: gnus.dvi message.dvi $(REFCARD).dvi emacs-mime.dvi sieve.dvi pgg.dvi sasl.d pdf: gnus.pdf message.pdf $(REFCARD).pdf emacs-mime.pdf sieve.pdf pgg.pdf sasl.pdf .texi.dvi : - sed -e '/@iflatex/,/@end iflatex/d' $< > gnustmp.texi + sed -e '/@iflatex/,/@end iflatex/d' $< > gnustmp.texi $(TEXI2DVI) -I $(srcdir) gnustmp.texi cp gnustmp.dvi $*.dvi rm -f gnustmp.* @@ -58,7 +58,7 @@ pdf: gnus.pdf message.pdf $(REFCARD).pdf emacs-mime.pdf sieve.pdf pgg.pdf sasl.p TEXPICTS=$(srcdir) $(DVIPS) -t $(PAPERTYPE) -f $< > $@ .texi.pdf : - sed -e '/@iflatex/,/@end iflatex/d' $< > gnustmp.texi + sed -e '/@iflatex/,/@end iflatex/d' $< > gnustmp.texi $(TEXI2PDF) -I $(srcdir) gnustmp.texi cp gnustmp.pdf $*.pdf rm -f gnustmp.* @@ -90,9 +90,9 @@ gnus-booklet.pdf: $(REFCARD).tex $(LOGO).pdf TEXINPUTS=$(srcdir):$$TEXINPUTS:: \ $(PDFLATEX) '\def\booklettrue{}\def\letterpapertrue{}\input{$(REFCARD)}' ;\ fi - mv $(REFCARD).pdf $@ + mv $(REFCARD).pdf $@ -gnus-faq-full-update: gnus-faq-clean gnus-faq-texi +gnus-faq-full-update: gnus-faq-clean gnus-faq-texi gnus-faq.xml: cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/gnus \ @@ -111,7 +111,7 @@ gnus-faq-texi: gnus-faq.xml xml2texi.sh xml2texi.scm gnus-faq-clean: rm -f gnus-faq.xml gnus-faq.*.tmp gnus-faq.texi -clean: +almost-clean: 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 \ @@ -202,11 +202,11 @@ latexboth: gnus-manual-a4.ps.gz gnus-manual-standard.ps.gz out: scp gnus-manual-*.ps.gz gnus-manual-*.pdf www@quimby:html/gnus/documents -veryclean: clean +clean: almost-clean rm -f gnus.dvi gnus.ps texi2latex.elc rm -f gnus-manual-a4.* gnus-manual-standard.* -distclean: veryclean +distclean: clean rm -f *.orig *.rej *.elc *~ gnus-[0-9] gnus-[0-9][0-9] Makefile rm -f message-[0-9] rm -f $(INFO_DEPS) @@ -247,7 +247,7 @@ uninstall: done; \ else : ; fi -tmps: +tmps: cd ps; make all for j in ps/picons-*.ps; do \ i=ps/`basename $$j .ps`; \ @@ -263,7 +263,7 @@ tmps: a="h"; echo -n "\\gnussmiley{$$i}"; fi done > smiley.tex; \ if [ -n "$$a" ]; then echo "{$$i}" >> smiley.tex; fi pspackage: - cd ps; make clean + cd ps; make almost-clean tar czvf pspackage.tar.gz gnus-faq.texi gnus.texi herds misc pagestyle.sty picons pixidx.sty postamble.tex ps screen smilies splitindex texi2latex.el xface Makefile README etc Makefile: $(srcdir)/Makefile.in ../config.status diff --git a/texi/doclicense.texi b/texi/doclicense.texi index 963bb05..1c8c9ad 100644 --- a/texi/doclicense.texi +++ b/texi/doclicense.texi @@ -2,11 +2,11 @@ @node GNU Free Documentation License, Intro, Copying, Top @appendix GNU Free Documentation License -@center Version 1.1, March 2000 +@center Version 1.2, November 2002 @display -Copyright (C) 2000 Free Software Foundation, Inc. -59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +Copyright (C) 2000,2001,2002 Free Software Foundation, Inc. +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. @@ -17,12 +17,12 @@ of this license document, but changing it is not allowed. PREAMBLE The purpose of this License is to make a manual, textbook, or other -written document ``free'' in the sense of freedom: to assure everyone -the effective freedom to copy and redistribute it, with or without -modifying it, either commercially or noncommercially. Secondarily, -this License preserves for the author and publisher a way to get -credit for their work, while not being considered responsible for -modifications made by others. +functional and useful document ``free'' in the sense of freedom: to +assure everyone the effective freedom to copy and redistribute it, +with or without modifying it, either commercially or noncommercially. +Secondarily, this License preserves for the author and publisher a way +to get credit for their work, while not being considered responsible +for modifications made by others. This License is a kind of ``copyleft'', which means that derivative works of the document must themselves be free in the same sense. It @@ -41,11 +41,15 @@ principally for works whose purpose is instruction or reference. @item APPLICABILITY AND DEFINITIONS -This License applies to any manual or other work that contains a -notice placed by the copyright holder saying it can be distributed -under the terms of this License. The ``Document'', below, refers to any -such manual or work. Any member of the public is a licensee, and is -addressed as ``you''. +This License applies to any manual or other work, in any medium, that +contains a notice placed by the copyright holder saying it can be +distributed under the terms of this License. Such a notice grants a +world-wide, royalty-free license, unlimited in duration, to use that +work under the conditions stated herein. The ``Document'', below, +refers to any such manual or work. Any member of the public is a +licensee, and is addressed as ``you''. You accept the license if you +copy, modify or distribute the work in a way requiring permission +under copyright law. A ``Modified Version'' of the Document means any work containing the Document or a portion of it, either copied verbatim, or with @@ -55,7 +59,7 @@ A ``Secondary Section'' is a named appendix or a front-matter section of the Document that deals exclusively with the relationship of the publishers or authors of the Document to the Document's overall subject (or to related matters) and contains nothing that could fall directly -within that overall subject. (For example, if the Document is in part a +within that overall subject. (Thus, if the Document is in part a textbook of mathematics, a Secondary Section may not explain any mathematics.) The relationship could be a matter of historical connection with the subject or with related matters, or of legal, @@ -64,33 +68,41 @@ them. The ``Invariant Sections'' are certain Secondary Sections whose titles are designated, as being those of Invariant Sections, in the notice -that says that the Document is released under this License. +that says that the Document is released under this License. If a +section does not fit the above definition of Secondary then it is not +allowed to be designated as Invariant. The Document may contain zero +Invariant Sections. If the Document does not identify any Invariant +Sections then there are none. The ``Cover Texts'' are certain short passages of text that are listed, as Front-Cover Texts or Back-Cover Texts, in the notice that says that -the Document is released under this License. +the Document is released under this License. A Front-Cover Text may +be at most 5 words, and a Back-Cover Text may be at most 25 words. A ``Transparent'' copy of the Document means a machine-readable copy, represented in a format whose specification is available to the -general public, whose contents can be viewed and edited directly and +general public, that is suitable for revising the document straightforwardly with generic text editors or (for images composed of pixels) generic paint programs or (for drawings) some widely available drawing editor, and that is suitable for input to text formatters or for automatic translation to a variety of formats suitable for input to text formatters. A copy made in an otherwise Transparent file -format whose markup has been designed to thwart or discourage -subsequent modification by readers is not Transparent. A copy that is -not ``Transparent'' is called ``Opaque''. +format whose markup, or absence of markup, has been arranged to thwart +or discourage subsequent modification by readers is not Transparent. +An image format is not Transparent if used for any substantial amount +of text. A copy that is not ``Transparent'' is called ``Opaque.'' + Examples of suitable formats for Transparent copies include plain ASCII without markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly available DTD, and standard-conforming simple -HTML designed for human modification. Opaque formats include -PostScript, PDF, proprietary formats that can be read and edited only -by proprietary word processors, SGML or XML for which the DTD and/or +HTML, PostScript or PDF designed for human modification. Examples of +transparent image formats include PNG, XCF and JPG. Opaque formats +include proprietary formats that can be read and edited only by +proprietary word processors, SGML or XML for which the DTD and/or processing tools are not generally available, and the -machine-generated HTML produced by some word processors for output -purposes only. +machine-generated HTML, PostScript or PDF produced by some word +processors for output purposes only. The ``Title Page'' means, for a printed book, the title page itself, plus such following pages as are needed to hold, legibly, the material @@ -98,6 +110,21 @@ this License requires to appear in the title page. For works in formats which do not have any title page as such, ``Title Page'' means the text near the most prominent appearance of the work's title, preceding the beginning of the body of the text. + +A section ``Entitled XYZ'' means a named subunit of the Document whose +title either is precisely XYZ or contains XYZ in parentheses following +text that translates XYZ in another language. (Here XYZ stands for a +specific section name mentioned below, such as ``Acknowledgements'', +``Dedications'', ``Endorsements'', or ``History''.) To ``Preserve the Title'' +of such a section when you modify the Document means that it remains a +section ``Entitled XYZ'' according to this definition. + +The Document may include Warranty Disclaimers next to the notice which +states that this License applies to the Document. These Warranty +Disclaimers are considered to be included by reference in this +License, but only as regards disclaiming warranties: any other +implication that these Warranty Disclaimers may have is void and has +no effect on the meaning of this License. @sp 1 @item VERBATIM COPYING @@ -118,9 +145,10 @@ you may publicly display copies. @item COPYING IN QUANTITY -If you publish printed copies of the Document numbering more than 100, -and the Document's license notice requires Cover Texts, you must enclose -the copies in covers that carry, clearly and legibly, all these Cover +If you publish printed copies (or copies in media that commonly have +printed covers) of the Document, numbering more than 100, and the +Document's license notice requires Cover Texts, you must enclose the +copies in covers that carry, clearly and legibly, all these Cover Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on the back cover. Both covers must also clearly and legibly identify you as the publisher of these copies. The front cover must present @@ -138,16 +166,15 @@ pages. If you publish or distribute Opaque copies of the Document numbering more than 100, you must either include a machine-readable Transparent copy along with each Opaque copy, or state in or with each Opaque copy -a publicly-accessible computer-network location containing a complete -Transparent copy of the Document, free of added material, which the -general network-using public has access to download anonymously at no -charge using public-standard network protocols. If you use the latter -option, you must take reasonably prudent steps, when you begin -distribution of Opaque copies in quantity, to ensure that this -Transparent copy will remain thus accessible at the stated location -until at least one year after the last time you distribute an Opaque -copy (directly or through your agents or retailers) of that edition to -the public. +a computer-network location from which the general network-using +public has access to download using public-standard network protocols +a complete Transparent copy of the Document, free of added material. +If you use the latter option, you must take reasonably prudent steps, +when you begin distribution of Opaque copies in quantity, to ensure +that this Transparent copy will remain thus accessible at the stated +location until at least one year after the last time you distribute an +Opaque copy (directly or through your agents or retailers) of that +edition to the public. It is requested, but not required, that you contact the authors of the Document well before redistributing any large number of copies, to give @@ -171,7 +198,8 @@ A. Use in the Title Page (and on the covers, if any) a title distinct B. List on the Title Page, as authors, one or more persons or entities responsible for authorship of the modifications in the Modified Version, together with at least five of the principal authors of the - Document (all of its principal authors, if it has less than five).@* + Document (all of its principal authors, if it has fewer than five), + unless they release you from this requirement.@* C. State on the Title page the name of the publisher of the Modified Version, as the publisher.@* D. Preserve all the copyright notices of the Document.@* @@ -183,10 +211,10 @@ F. Include, immediately after the copyright notices, a license notice G. Preserve in that license notice the full lists of Invariant Sections and required Cover Texts given in the Document's license notice.@* H. Include an unaltered copy of this License.@* -I. Preserve the section entitled ``History'', and its title, and add to - it an item stating at least the title, year, new authors, and +I. Preserve the section Entitled ``History'', Preserve its Title, and add + to it an item stating at least the title, year, new authors, and publisher of the Modified Version as given on the Title Page. If - there is no section entitled ``History'' in the Document, create one + there is no section Entitled ``History'' in the Document, create one stating the title, year, authors, and publisher of the Document as given on its Title Page, then add an item describing the Modified Version as stated in the previous sentence.@* @@ -197,17 +225,18 @@ J. Preserve the network location, if any, given in the Document for You may omit a network location for a work that was published at least four years before the Document itself, or if the original publisher of the version it refers to gives permission.@* -K. In any section entitled ``Acknowledgements'' or ``Dedications'', - preserve the section's title, and preserve in the section all the - substance and tone of each of the contributor acknowledgements +K. For any section Entitled ``Acknowledgements'' or ``Dedications'', + Preserve the Title of the section, and preserve in the section all + the substance and tone of each of the contributor acknowledgements and/or dedications given therein.@* L. Preserve all the Invariant Sections of the Document, unaltered in their text and in their titles. Section numbers or the equivalent are not considered part of the section titles.@* -M. Delete any section entitled ``Endorsements''. Such a section +M. Delete any section Entitled ``Endorsements.'' Such a section may not be included in the Modified Version.@* -N. Do not retitle any existing section as ``Endorsements'' +N. Do not retitle any existing section to be Entitled ``Endorsements'' or to conflict in title with any Invariant Section.@* +O. Preserve any Warranty Disclaimers.@* @sp 1 If the Modified Version includes new front-matter sections or appendices that qualify as Secondary Sections and contain no material @@ -216,7 +245,7 @@ of these sections as invariant. To do this, add their titles to the list of Invariant Sections in the Modified Version's license notice. These titles must be distinct from any other section titles. -You may add a section entitled ``Endorsements'', provided it contains +You may add a section Entitled ``Endorsements'', provided it contains nothing but endorsements of your Modified Version by various parties--for example, statements of peer review or that the text has been approved by an organization as the authoritative definition of a @@ -244,7 +273,7 @@ License, under the terms defined in section 4 above for modified versions, provided that you include in the combination all of the Invariant Sections of all of the original documents, unmodified, and list them all as Invariant Sections of your combined work in its -license notice. +license notice, and that you preserve all their Warranty Disclaimers. The combined work need only contain one copy of this License, and multiple identical Invariant Sections may be replaced with a single @@ -255,11 +284,11 @@ author or publisher of that section if known, or else a unique number. Make the same adjustment to the section titles in the list of Invariant Sections in the license notice of the combined work. -In the combination, you must combine any sections entitled ``History'' -in the various original documents, forming one section entitled -``History''; likewise combine any sections entitled ``Acknowledgements'', -and any sections entitled ``Dedications''. You must delete all sections -entitled ``Endorsements.'' +In the combination, you must combine any sections Entitled ``History'' +in the various original documents, forming one section Entitled +``History''; likewise combine any sections Entitled ``Acknowledgements'', +and any sections Entitled ``Dedications.'' You must delete all sections +Entitled ``Endorsements.'' @sp 1 @item COLLECTIONS OF DOCUMENTS @@ -280,18 +309,20 @@ AGGREGATION WITH INDEPENDENT WORKS A compilation of the Document or its derivatives with other separate and independent documents or works, in or on a volume of a storage or -distribution medium, does not as a whole count as a Modified Version -of the Document, provided no compilation copyright is claimed for the -compilation. Such a compilation is called an ``aggregate'', and this -License does not apply to the other self-contained works thus compiled -with the Document, on account of their being thus compiled, if they -are not themselves derivative works of the Document. +distribution medium, is called an ``aggregate'' if the copyright +resulting from the compilation is not used to limit the legal rights +of the compilation's users beyond what the individual works permit. +When the Document is included in an aggregate, this License does not +apply to the other works in the aggregate which are not themselves +derivative works of the Document. If the Cover Text requirement of section 3 is applicable to these -copies of the Document, then if the Document is less than one quarter -of the entire aggregate, the Document's Cover Texts may be placed on -covers that surround only the Document within the aggregate. -Otherwise they must appear on covers around the whole aggregate. +copies of the Document, then if the Document is less than one half of +the entire aggregate, the Document's Cover Texts may be placed on +covers that bracket the Document within the aggregate, or the +electronic equivalent of covers if the Document is in electronic form. +Otherwise they must appear on printed covers that bracket the whole +aggregate. @sp 1 @item TRANSLATION @@ -302,10 +333,17 @@ Replacing Invariant Sections with translations requires special permission from their copyright holders, but you may include translations of some or all Invariant Sections in addition to the original versions of these Invariant Sections. You may include a -translation of this License provided that you also include the -original English version of this License. In case of a disagreement -between the translation and the original English version of this -License, the original English version will prevail. +translation of this License, and all the license notices in the +Document, and any Warranty Disclaimers, provided that you also include +the original English version of this License and the original versions +of those notices and disclaimers. In case of a disagreement between +the translation and the original version of this License or a notice +or disclaimer, the original version will prevail. + +If a section in the Document is Entitled ``Acknowledgements'', +``Dedications'', or ``History'', the requirement (section 4) to Preserve +its Title (section 1) will typically require changing the actual +title. @sp 1 @item TERMINATION @@ -346,21 +384,30 @@ license notices just after the title page: @smallexample @group +Copyright (C) @var{year} @var{your name}. +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.2 +or any later version published by the Free Software Foundation; +with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. +A copy of the license is included in the section entitled ``GNU +Free Documentation License''. +@end group +@end smallexample - Copyright (C) @var{year} @var{your name}. - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.1 - or any later version published by the Free Software Foundation; - with the Invariant Sections being @var{list their titles}, with the - Front-Cover Texts being @var{list}, and with the Back-Cover Texts being @var{list}. - A copy of the license is included in the section entitled ``GNU - Free Documentation License''. +If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts, +replace the ``with...Texts.'' line with this: + +@smallexample +@group +with the Invariant Sections being @var{list their titles}, with the +Front-Cover Texts being @var{list}, and with the Back-Cover Texts being +@var{list}. @end group @end smallexample -If you have no Invariant Sections, write ``with no Invariant Sections'' -instead of saying which ones are invariant. If you have no -Front-Cover Texts, write ``no Front-Cover Texts'' instead of -``Front-Cover Texts being @var{list}''; likewise for Back-Cover Texts. + +If you have Invariant Sections without Cover Texts, or some other +combination of the three, merge those two alternatives to suit the +situation. If your document contains nontrivial examples of program code, we recommend releasing these examples in parallel under your choice of diff --git a/texi/emacs-mime.texi b/texi/emacs-mime.texi index 3316f25..e96cbde 100644 --- a/texi/emacs-mime.texi +++ b/texi/emacs-mime.texi @@ -9,12 +9,12 @@ @copying This file documents the Emacs MIME interface functionality. -Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 - Free Software Foundation, Inc. +Copyright @copyright{} 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, +2006 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with the Front-Cover texts being ``A GNU Manual'', and with the Back-Cover Texts as in (a) below. A copy of the @@ -56,7 +56,7 @@ license to the document, as described in section 6 of the license. This manual documents the libraries used to compose and display @acronym{MIME} messages. -This manual is directed at users who want to modify the behaviour of +This manual is directed at users who want to modify the behavior of the @acronym{MIME} encoding/decoding process or want a more detailed picture of how the Emacs @acronym{MIME} library works, and people who want to write functions and commands that manipulate @acronym{MIME} elements. @@ -176,8 +176,27 @@ Patches. This is intended for groups where diffs of committed files are automatically sent to. It only works in groups matching @code{mm-uu-diff-groups-regexp}. +@item verbatim-marks +@cindex verbatim-marks +Slrn-style verbatim marks. + +@item LaTeX +@cindex LaTeX +LaTeX documents. It only works in groups matching +@code{mm-uu-tex-groups-regexp}. + @end table +@cindex text/x-verbatim +@c Is @vindex suitable for a face? +@vindex mm-uu-extract +Some inlined non-@acronym{MIME} attachments are displayed using the face +@code{mm-uu-extract}. By default, no @acronym{MIME} button for these +parts is displayed. You can force displaying a button using @kbd{K b} +(@code{gnus-summary-display-buttonized}) or add @code{text/x-verbatim} +to @code{gnus-buttonized-mime-types}, @xref{MIME Commands, ,MIME +Commands, gnus, Gnus Manual}. + @node Handles @section Handles @@ -213,10 +232,6 @@ Set the undisplayer object. @findex mm-handle-disposition Return the parsed @code{Content-Disposition} of the part. -@item mm-handle-disposition -@findex mm-handle-disposition -Return the description of the part. - @item mm-get-content-id Returns the handle(s) referred to by @code{Content-ID}. @@ -326,6 +341,31 @@ you could say something like: (remove "text/html" mm-automatic-display)) @end lisp +Adding @code{"image/.*"} might also be useful. Spammers use images as +the prefered part of @samp{multipart/alternative} messages, so you might +not notice there are other parts. See also +@code{gnus-buttonized-mime-types}, @ref{MIME Commands, ,MIME Commands, +gnus, Gnus Manual}. After adding @code{"multipart/alternative"} to +@code{gnus-buttonized-mime-types} you can choose manually which +alternative you'd like to view. For example, you can set those +variables like: + +@lisp +(setq gnus-buttonized-mime-types + '("multipart/alternative" "multipart/signed") + mm-discouraged-alternatives + '("text/html" "image/.*")) +@end lisp + +In this case, Gnus will display radio buttons for such a kind of spam +message as follows: + +@example +1. (*) multipart/alternative ( ) image/gif + +2. (*) text/plain ( ) text/html +@end example + @item mm-inline-large-images @vindex mm-inline-large-images When displaying inline images that are larger than the window, Emacs @@ -795,7 +835,7 @@ This plain text part is an attachment. Mapping from @acronym{MIME} charset to encoding to use. This variable is usually used except, e.g., when other requirements force a specific encoding (digitally signed messages require 7bit encodings). The -default is +default is @lisp ((iso-2022-jp . 7bit) @@ -813,7 +853,9 @@ by using the @code{encoding} @acronym{MML} tag (@pxref{MML Definition}). @item mm-coding-system-priorities @vindex mm-coding-system-priorities Prioritize coding systems to use for outgoing messages. The default -is @code{nil}, which means to use the defaults in Emacs. It is a list of +is @code{nil}, which means to use the defaults in Emacs, but is +@code{(iso-8859-1 iso-2022-jp iso-2022-jp-2 shift_jis utf-8)} when +running Emacs in the Japanese language environment. It is a list of coding system symbols (aliases of coding systems are also allowed, use @kbd{M-x describe-coding-system} to make sure you are specifying correct coding system names). For example, if you have configured Emacs @@ -880,8 +922,9 @@ used, of course. @vindex mm-mime-mule-charset-alist Things are slightly more complicated when running Emacs with @sc{mule} support. In this case, a list of the @sc{mule} charsets used in the -part is obtained, and the @sc{mule} charsets are translated to @acronym{MIME} -charsets by consulting the variable @code{mm-mime-mule-charset-alist}. +part is obtained, and the @sc{mule} charsets are translated to +@acronym{MIME} charsets by consulting the table provided by Emacs itself +or the variable @code{mm-mime-mule-charset-alist} for XEmacs. If this results in a single @acronym{MIME} charset, this is used to encode the part. But if the resulting list of @acronym{MIME} charsets contains more than one element, two things can happen: If it is possible to encode the @@ -1172,7 +1215,7 @@ in the subsequent sections. This chapter describes the basic, ground-level functions for parsing and handling. Covered here is parsing @code{From} lines, removing comments from header lines, decoding encoded words, parsing date headers and so -on. High-level functionality is dealt with in the next chapter +on. High-level functionality is dealt with in the first chapter (@pxref{Decoding and Viewing}). @menu @@ -1508,7 +1551,7 @@ Take a time and return the number of days that represents. @item safe-date-to-time Take a date and return a time. If the date is not syntactically valid, -return a ``zero'' date. +return a ``zero'' time. @item time-less-p Take two times and say whether the first time is less (i. e., earlier) diff --git a/texi/gnus-coding.texi b/texi/gnus-coding.texi new file mode 100644 index 0000000..0c561b2 --- /dev/null +++ b/texi/gnus-coding.texi @@ -0,0 +1,361 @@ +\input texinfo + +@setfilename gnus-coding +@settitle Gnus Coding Style and Maintainance Guide +@syncodeindex fn cp +@syncodeindex vr cp +@syncodeindex pg cp + +@copying +Copyright (c) 2004, 2005 Free Software Foundation, Inc. + +@quotation +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.1 or +any later version published by the Free Software Foundation; with no +Invariant Sections, with the Front-Cover texts being ``A GNU +Manual'', and with the Back-Cover Texts as in (a) below. A copy of the +license is included in the section entitled ``GNU Free Documentation +License'' in the Emacs manual. + +(a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify +this GNU Manual, like GNU software. Copies published by the Free +Software Foundation raise funds for GNU development.'' + +This document is part of a collection distributed under the GNU Free +Documentation License. If you want to distribute this document +separately from the collection, you can do so by adding a copy of the +license to the document, as described in section 6 of the license. +@end quotation +@end copying + + +@titlepage +@title Gnus Coding Style and Maintainance Guide + +@author by Reiner Steib + +@insertcopying +@end titlepage + +@c Obviously this is only a very rudimentary draft. We put it in CVS +@c anyway hoping that it might annoy someone enough to fix it. ;-) +@c Fixing only a paragraph also is appreciated. + +@node Top +@top Gnus Coding Style and Maintainance Guide +This manual describes @dots{} +@menu +* Gnus Coding Style:: Gnus Coding Style +* Gnus Maintainance Guide:: Gnus Maintainance Guide +@end menu + +@c @ref{Gnus Reference Guide, ,Gnus Reference Guide, gnus, The Gnus Newsreader} + +@node Gnus Coding Style +@chapter Gnus Coding Style +@section Dependencies + +The Gnus distribution contains a lot of libraries that have been written +for Gnus and used intensively for Gnus. But many of those libraries are +useful on their own. E.g. other Emacs Lisp packages might use the +@acronym{MIME} library @xref{Top, ,Top, emacs-mime, The Emacs MIME +Manual}. + +@subsection General purpose libraries + +@table @file + +@item netrc.el +@file{.netrc} parsing functionality. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item format-spec.el +Functions for formatting arbitrary formatting strings. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@end table + +@subsection Encryption and security + +@table @file +@item encrypt.el +File encryption routines +@c As of 2005-10-25... +There are no Gnus dependencies in this file. + +@item password.el +Read passwords from user, possibly using a password cache. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item tls.el +TLS/SSL support via wrapper around GnuTLS +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item pgg*.el +Glue for the various PGP implementations. +@c As of 2005-10-21... +There are no Gnus dependencies in these files. + +@end table + +@subsection Networking + +@table @file +@item dig.el +Domain Name System dig interface. +@c As of 2005-10-21... +There are no serious Gnus dependencies in this file. Uses +@code{gnus-run-mode-hooks} (a wrapper function). + +@item dns*.el +Domain Name Service lookups. +@c As of 2005-10-21... +There are no Gnus dependencies in these files. +@end table + +@subsection Mail and News related RFCs + +@table @file +@item pop3.el +Post Office Protocol (RFC 1460) interface. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item imap.el +@acronym{IMAP} library. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item ietf-drums.el +Functions for parsing RFC822bis headers. +@c As of 2005-10-21... +There are no Gnus dependencies in this file. + +@item rfc1843.el +HZ (rfc1843) decoding. HZ is a data format for exchanging files of +arbitrarily mixed Chinese and @acronym{ASCII} characters. +@c As of 2005-10-21... +@code{rfc1843-gnus-setup} seem to be useful only for Gnus. Maybe this +function should be relocated to remove dependencies on Gnus. Other +minor dependencies: @code{gnus-newsgroup-name} could be eliminated by +using an optional argument to @code{rfc1843-decode-article-body}. + +@item rfc2045.el +Functions for decoding rfc2045 headers + +@item rfc2047.el +Functions for encoding and decoding rfc2047 messages + +@item rfc2104.el +RFC2104 Hashed Message Authentication Codes + +@item rfc2231.el +Functions for decoding rfc2231 headers + +@item flow-fill.el +Interpret RFC2646 "flowed" text. +@c As of 2005-10-27... +There are no Gnus dependencies in this file. + +@item uudecode.el +Elisp native uudecode. +@c As of 2005-12-06... +There are no Gnus dependencies in this file. +@c ... but the custom group is gnus-extract. +@end table + +@subsection message + +All message composition from Gnus (both mail and news) takes place in +Message mode buffers. Message mode is intended to be a replacement for +Emacs mail mode. There should be no Gnus dependencies in +@file{message.el}. + +@subsection Emacs @acronym{MIME} + +The files @file{mml*.el} and @file{mm-*.el} provide @acronym{MIME} +functionality for Emacs. + +@acronym{MML} (@acronym{MIME} Meta Language) is supposed to be +independent from Gnus. Alas it is not anymore. + + +@subsection Gnus backends + +The files @file{nn*.el} provide functionality for accessing NNTP +(@file{nntp.el}), IMAP (@file{nnimap.el}) and several other Mail back +ends (probably @file{nnml.el}, @file{nnfolder.el} and +@file{nnmaildir.el} are the most widely used mail back ends). + + + +@c mm-uu requires nnheader which requires gnus-util. message.el also +@c requires nnheader. + +@c message / gnus +@c +@c nn* +@c +@c mm* +@c +@c rfc* +@c +@c pgg* +@c tla netrc pop3 dig dns ... +@c format-spec.el + + +@section Compatibility + +No Gnus should work on: +@itemize @bullet +@item +Emacs 21.1 and up. +@item +XEmacs 21.4 and up. +@end itemize + +Gnus 5.10 should work on: +@itemize @bullet +@item +Emacs 20.7 and up. +@item +XEmacs 21.1 and up. +@end itemize + +@node Gnus Maintainance Guide +@chapter Gnus Maintainance Guide + +@section Stable and development versions + +The development of Gnus normally is done on the CVS trunk, i.e. there +are no separate branches to develop and test new features. Most of the +time, the trunk is developed quite actively with more or less daily +changes. Only after a new major release, e.g. 5.10.1, there's usually a +feature period of several months. After the release of Gnus 5.10.6 the +development of new features started again on the trunk while the 5.10 +series is continued on the stable branch (v5-10) from which more stable +releases will be done when needed (5.10.7, @dots{}). +@ref{Gnus Development, ,Gnus Development, gnus, The Gnus Newsreader} + +Stable releases of Gnus finally become part of Emacs. E.g. Gnus 5.8 +became a part of Emacs 21 (relabeled to Gnus 5.9). The 5.10 series will +become part of Emacs 22 (as Gnus 5.11). + +@section Syncing + +@c Some MIDs related to this follow. Use http://thread.gmane.org/MID +@c (and click on the subject) to get the thread on Gmane. + +@c Some quotes from Miles Bader follow... + +@c +@c + +In the past, the inclusion of Gnus into Emacs was quite cumbersome. For +each change made to Gnus in Emacs repository, it had to be checked that +it was applied to the new Gnus version, too. Else, bug fixes done in +Emacs repository might have been lost. + +With the inclusion of Gnus 5.10, Miles Bader has set up an Emacs-Gnus +gateway to ensure the bug fixes from Emacs CVS are propagated to Gnus +CVS semi-automatically. These bug fixes are installed on the stable +branch and on the trunk. Basically the idea is that the gateway will +cause all common files in Emacs and Gnus v5-10 to be identical except +when there's a very good reason (e.g., the Gnus version string in Emacs +says @samp{5.11}, but the v5-10 version string remains @samp{5.10.x}). +Furthermore, all changes in these files in either Emacs or the v5-10 +branch will be installed into the Gnus CVS trunk, again except where +there's a good reason. +@c (typically so far the only exception has been that the changes +@c already exist in the trunk in modified form). +Because of this, when the next major version of Gnus will be included in +Emacs, it should be very easy -- just plonk in the files from the Gnus +trunk without worrying about lost changes from the Emacs tree. + +The effect of this is that as hacker, you should generally only have to +make changes in one place: + +@itemize +@item +If it's a file which is thought of as being outside of Gnus (e.g., the +new @file{encrypt.el}), you should probably make the change in the Emacs +tree, and it will show up in the Gnus tree a few days later. + +If you don't have Emacs CVS access (or it's inconvenient), you can +change such a file in the v5-10 branch, and it should propagate to Emacs +CVS -- however, it will get some extra scrutiny (by Miles) to see if the +changes are possibly controversial and need discussion on the mailing +list. Many changes are obvious bug-fixes however, so often there won't +be any problem. + +@item +If it's to a Gnus file, and it's important enough that it should be part +of Emacs and the v5-10 branch, then you can make the change on the v5-10 +branch, and it will go into Emacs CVS and the Gnus CVS trunk (a few days +later). The most prominent examples for such changes are bug-fixed +including improvements on the documentation. + +If you know that there will be conflicts (perhaps because the affected +source code is different in v5-10 and the Gnus CVS trunk), then you can +install your change in both places, and when I try to sync them, there +will be a conflict -- however, since in most such cases there would be a +conflict @emph{anyway}, it's often easier for me to resolve it simply if +I see two @samp{identical} changes, and can just choose the proper one, +rather than having to actually fix the code. + +@item +For general Gnus development changes, of course you just make the +change on the Gnus CVS trunk and it goes into Emacs a few years +later... :-) +@end itemize + +Of course in any case, if you just can't wait for me to sync your +change, you can commit it in more than one place and probably there will +be no problem; usually the changes are textually identical anyway, so +can be easily resolved automatically (sometimes I notice silly things in +such multiple commits, like whitespace differences, and unify those ;-). + + +@c I do Emacs->Gnus less often (than Gnus->Emacs) because it tends to +@c require more manual work. + +@c By default I sync about once a week. I also try to follow any Gnus +@c threads on the mailing lists and make sure any changes being discussed +@c are kept more up-to-date (so say 1-2 days delay for "topical" changes). + +@c + +@c BTW, just to add even more verbose explanation about the syncing thing: + +@section Miscellanea + +@heading @file{GNUS-NEWS} + +Starting from No Gnus, the @file{GNUS-NEWS} is created from +@file{texi/gnus-news.texi}. Don't edit @file{GNUS-NEWS}. Edit +@file{texi/gnus-news.texi}, type @command{make GNUS-NEWS} in the +@file{texi} directory and commit @file{GNUS-NEWS} and +@file{texi/gnus-news.texi}. + +@heading Conventions for version information in defcustoms + +For new customizable variables introduced in Oort Gnus (including the +v5-10 branch) use @code{:version "22.1" ;; Oort Gnus} including the +comment. +@c +If the variable is new in No Gnus use @code{:version "23.0" ;; No Gnus}. + +@c Local Variables: +@c mode: texinfo +@c coding: iso-8859-1 +@c End: + +@ignore + arch-tag: ab15234c-2c8a-4cbd-8111-1811bcc6f931 +@end ignore diff --git a/texi/gnus-faq.texi b/texi/gnus-faq.texi index 742227b..7fa00c3 100644 --- a/texi/gnus-faq.texi +++ b/texi/gnus-faq.texi @@ -52,7 +52,7 @@ a subscriber, your submissions will automatically pass. You can also subscribe to the list by sending a blank email to @email{faq-discuss-subscribe@@my.gnus.org, faq-discuss-subscribe@@my.gnus.org} and @uref{http://mail1.kens.com/cgi-bin/ezmlm-browse?command=monthbythread%26list=faq-discuss, browse -the archive}. +the archive (BROKEN)}. @node FAQ - Changes @subheading Changes @@ -233,10 +233,10 @@ Which version of Emacs do I need? @subsubheading Answer -Gnus 5.10 requires an Emacs version that is greater -than or equal to Emacs 20.7 or XEmacs 21.1. The -development versions of Gnus (aka No Gnus) require Emacs -21 or XEmacs 21.4. +Gnus 5.10 requires an Emacs version that is greater than or equal +to Emacs 20.7 or XEmacs 21.1. +The development versions of Gnus (aka No Gnus) requires Emacs 21 +or XEmacs 21.4. @node [1.7] @subsubheading Question 1.7 @@ -1197,26 +1197,26 @@ from using them): @example (setq nnmail-split-methods '(("duplicates" "^Gnus-Warning:.*duplicate") - ("XEmacs-NT" "^\\(To:\\|CC:\\).*localpart@@xemacs.bla.*") - ("Gnus-Tut" "^\\(To:\\|CC:\\).*localpart@@socha.bla.*") - ("tcsh" "^\\(To:\\|CC:\\).*localpart@@mx.gw.bla.*") - ("BAfH" "^\\(To:\\|CC:\\).*localpart@@.*uni-muenchen.bla.*") + ("XEmacs-NT" "^\\(To:\\|CC:\\).*localpart@@xemacs.invalid.*") + ("Gnus-Tut" "^\\(To:\\|CC:\\).*localpart@@socha.invalid.*") + ("tcsh" "^\\(To:\\|CC:\\).*localpart@@mx.gw.invalid.*") + ("BAfH" "^\\(To:\\|CC:\\).*localpart@@.*uni-muenchen.invalid.*") ("Hamster-src" "^\\(CC:\\|To:\\).*hamster-sourcen@@yahoogroups.\\(de\\|com\\).*") - ("Tagesschau" "^From: tagesschau $") - ("Replies" "^\\(CC:\\|To:\\).*localpart@@Frank-Schmitt.bla.*") - ("EK" "^From:.*\\(localpart@@privateprovider.bla\\|localpart@@workplace.bla\\).*") + ("Tagesschau" "^From: tagesschau $") + ("Replies" "^\\(CC:\\|To:\\).*localpart@@Frank-Schmitt.invalid.*") + ("EK" "^From:.*\\(localpart@@privateprovider.invalid\\|localpart@@workplace.invalid\\).*") ("Spam" "^Content-Type:.*\\(ks_c_5601-1987\\|EUC-KR\\|big5\\|iso-2022-jp\\).*") ("Spam" "^Subject:.*\\(This really work\\|XINGA\\|ADV:\\|XXX\\|adult\\|sex\\).*") ("Spam" "^Subject:.*\\(\=\?ks_c_5601-1987\?\\|\=\?euc-kr\?\\|\=\?big5\?\\).*") ("Spam" "^X-Mailer:\\(.*BulkMailer.*\\|.*MIME::Lite.*\\|\\)") ("Spam" "^X-Mailer:\\(.*CyberCreek Avalanche\\|.*http\:\/\/GetResponse\.com\\)") ("Spam" "^From:.*\\(verizon\.net\\|prontomail\.com\\|money\\|ConsumerDirect\\).*") - ("Spam" "^Delivered-To: GMX delivery to spamtrap@@gmx.bla$") + ("Spam" "^Delivered-To: GMX delivery to spamtrap@@gmx.invalid$") ("Spam" "^Received: from link2buy.com") - ("Spam" "^CC: .*azzrael@@t-online.bla") + ("Spam" "^CC: .*azzrael@@t-online.invalid") ("Spam" "^X-Mailer-Version: 1.50 BETA") - ("Uni" "^\\(CC:\\|To:\\).*localpart@@uni-koblenz.bla.*") - ("Inbox" "^\\(CC:\\|To:\\).*\\(my\ name\\|address@@one.bla\\|adress@@two.bla\\)") + ("Uni" "^\\(CC:\\|To:\\).*localpart@@uni-koblenz.invalid.*") + ("Inbox" "^\\(CC:\\|To:\\).*\\(my\ name\\|address@@one.invalid\\|adress@@two.invalid\\)") ("Spam" ""))) @end example @noindent @@ -1314,7 +1314,7 @@ This example should make the syntax clear: (setq gnus-posting-styles '((".*" (name "Frank Schmitt") - (address "me@@there.bla") + (address "me@@there.invalid") (organization "Hamme net, kren mer och nimmi") (signature-file "~/.signature") ("X-SampleHeader" "foobar") @@ -1366,21 +1366,21 @@ at the bottom. @example (setq gnus-posting-styles - '((".*" ;;default - (name "Frank Schmitt") - (organization "Hamme net, kren mer och nimmi") - (signature-file "~/.signature") ) - ((message-news-p) ;;Usenet news? - (address "mySpamTrap@@Frank-Schmitt.bla") - ("Reply-To" "hereRealRepliesOnlyPlease@@Frank-Schmitt.bla") ) - ((message-mail-p) ;;mail? - (address "usedForMails@@Frank-Schmitt.bla") ) - ("^gmane" ;;this is mail, too in fact - (address "usedForMails@@Frank-Schmitt.net") - ("Reply-To" nil) ) - ("^gmane.mail.spam.spamassassin.general$" - (eval (setq mail-envelope-from "Azzrael@@rz-online.de")) - (address "Azzrael@@rz-online.de")) )) + '((".*" ;;default + (name "Frank Schmitt") + (organization "Hamme net, kren mer och nimmi") + (signature-file "~/.signature")) + ((message-news-p) ;;Usenet news? + (address "mySpamTrap@@Frank-Schmitt.invalid") + (reply-to "hereRealRepliesOnlyPlease@@Frank-Schmitt.invalid")) + ((message-mail-p) ;;mail? + (address "usedForMails@@Frank-Schmitt.invalid")) + ("^gmane" ;;this is mail, too in fact + (address "usedForMails@@Frank-Schmitt.invalid") + (reply-to nil)) + ("^gmane\\.mail\\.spam\\.spamassassin\\.general$" + (eval (set (make-local-variable 'message-sendmail-envelope-from) + "Azzrael@@rz-online.de"))))) @end example @noindent @@ -1464,7 +1464,7 @@ You can store your mail addresses in a ~/.mailrc file using a simple alias syntax: @example -alias al "Al " +alias al "Al " @end example @noindent @@ -1495,8 +1495,8 @@ place them in ~/.emacs: (setq bbdb-north-american-phone-numbers-p nil) ;;Tell bbdb about your email address: (setq bbdb-user-mail-names - (regexp-opt '("Your.Email@@here.bla" - "Your.other@@mail.there.bla"))) + (regexp-opt '("Your.Email@@here.invalid" + "Your.other@@mail.there.invalid"))) ;;cycling while completing email addresses (setq bbdb-complete-name-allow-cycling t) ;;No popup-buffers @@ -1551,12 +1551,19 @@ Now you only have to tell Gnus to include the X-face in your postings by saying (setq message-default-headers (with-temp-buffer (insert "X-Face: ") - (insert-file-contents "~/.xemacs/xface") + (insert-file-contents "~/.xface") (buffer-string))) @end example @noindent -in ~/.gnus.el. +in ~/.gnus.el. If you use Gnus 5.10, you can simply add an entry + +@example +(x-face-file "~/.xface") +@end example +@noindent + +to gnus-posting-styles. @node [5.9] @subsubheading Question 5.9 @@ -2121,11 +2128,15 @@ Which mailing lists and newsgroups are there? @subsubheading Answer -There's the newsgroup gnu.emacs.gnus (pull it from -e.g. news.gnus.org) which deals with general questions and the -ding mailing list (ding@@gnus.org) dealing with development of +There's the newsgroup gnu.emacs.gnus +(also available as +@uref{http://dir.gmane.org/gmane.emacs.gnus.user, +gmane.emacs.gnus.user}) +which deals with general Gnus questions. +The ding mailing list (ding@@gnus.org) deals with development of Gnus. You can read the ding list via NNTP, too under the name -gmane.emacs.gnus.general from news.gmane.org. +@uref{http://dir.gmane.org/gmane.emacs.gnus.general, +gmane.emacs.gnus.general} from news.gmane.org. If you want to stay in the big8, news.software.newssreaders is also read by some Gnus diff --git a/texi/gnus-news.el b/texi/gnus-news.el index 2c223ce..3c25d99 100644 --- a/texi/gnus-news.el +++ b/texi/gnus-news.el @@ -1,5 +1,5 @@ ;;; gnus-news.el --- a hack to create GNUS-NEWS from texinfo source -;; Copyright (C) 2004 Free Software Foundation, Inc. +;; Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. ;; Author: Reiner Steib ;; Keywords: tools @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: @@ -27,16 +27,13 @@ (defvar gnus-news-header-disclaimer "GNUS NEWS -- history of user-visible changes. -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. +Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, + 2006 Free Software Foundation, Inc. See the end for copying conditions. Please send Gnus bug reports to bugs\@gnus.org. For older news, see Gnus info node \"New Features\". - - -* Changes in No Gnus - ") (defvar gnus-news-trailer @@ -46,7 +43,8 @@ For older news, see Gnus info node \"New Features\". ---------------------------------------------------------------------- Copyright information: -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. +Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, + 2006 Free Software Foundation, Inc. Permission is granted to anyone to make or distribute verbatim copies of this document as received, in any medium, provided that the @@ -62,7 +60,7 @@ paragraph-separate: \"[ ]*$\"\nend:\n") (defvar gnus-news-makeinfo-command "makeinfo") -(defvar gnus-news-fill-column 72) +(defvar gnus-news-fill-column 80) (defvar gnus-news-makeinfo-switches (concat " --no-headers --paragraph-indent=0" @@ -99,10 +97,17 @@ paragraph-separate: \"[ ]*$\"\nend:\n") (goto-char (point-min)) (save-excursion (while (re-search-forward "^ \\* " nil t) + (replace-match "\f\n* "))) + (save-excursion + (while (re-search-forward "^ \\* " nil t) (replace-match "** "))) (save-excursion (while (re-search-forward "^ " nil t) (replace-match ""))) + ;; Avoid `*' from @ref at beginning of line: + (save-excursion + (while (re-search-forward "^\\*Note" nil t) + (replace-match " \\&"))) (goto-char (point-min)) (insert gnus-news-header-disclaimer) (goto-char (point-max)) diff --git a/texi/gnus-news.texi b/texi/gnus-news.texi index 270cab5..eac9414 100644 --- a/texi/gnus-news.texi +++ b/texi/gnus-news.texi @@ -1,6 +1,6 @@ @c -*-texinfo-*- -@c Copyright (C) 2004, 2005 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. @c Permission is granted to anyone to make or distribute verbatim copies @c of this document as received, in any medium, provided that the @@ -18,6 +18,9 @@ @itemize @bullet +@item Installation changes + +@itemize @bullet @item Upgrading from previous (stable) version if you have used No Gnus. If you have tried No Gnus (the unstable Gnus branch leading to this @@ -29,106 +32,191 @@ file, where this release will store flags for nntp. See a later entry for more information about nntp marks. Note that downgrading isn't safe in general. -@item The nntp back end store article marks in @file{~/News/marks}. +@item Lisp files are now installed in @file{.../site-lisp/gnus/} by default. +It defaulted to @file{.../site-lisp/} formerly. In addition to this, +the new installer issues a warning if other Gnus installations which +will shadow the latest one are detected. You can then remove those +shadows manually or remove them using @code{make +remove-installed-shadows}. +@end itemize -The directory can be changed using the (customizable) variable -@code{nntp-marks-directory}, and marks can be disabled using the -(back end) variable @code{nntp-marks-is-evil}. The advantage of this -is that you can copy @file{~/News/marks} (using rsync, scp or -whatever) to another Gnus installation, and it will realize what -articles you have read and marked. The data in @file{~/News/marks} -has priority over the same data in @file{~/.newsrc.eld}. +@item New packages and libraries within Gnus + +@itemize @bullet + +@item Gnus includes the Emacs Lisp @acronym{SASL} library. + +This provides a clean @acronym{API} to @acronym{SASL} mechanisms from +within Emacs. The user visible aspects of this, compared to the earlier +situation, include support for @acronym{DIGEST}-@acronym{MD5} and +@acronym{NTLM}. @xref{Top, ,Emacs SASL, sasl, Emacs SASL}. + +@item ManageSieve connections uses the @acronym{SASL} library by default. + +The primary change this brings is support for @acronym{DIGEST-MD5} and +@acronym{NTLM}, when the server supports it. + +@item Gnus includes a password cache mechanism in password.el. + +It is enabled by default (see @code{password-cache}), with a short +timeout of 16 seconds (see @code{password-cache-expiry}). If +@acronym{PGG} is used as the @acronym{PGP} back end, the @acronym{PGP} +passphrase is managed by this mechanism. Passwords for ManageSieve +connections are managed by this mechanism, after querying the user +about whether to do so. +@end itemize + +@item Changes in summary and article mode + +@itemize @bullet +@item International host names (@acronym{IDNA}) can now be decoded +inside article bodies using @kbd{W i} +(@code{gnus-summary-idna-message}). This requires that GNU Libidn +(@url{http://www.gnu.org/software/libidn/}) has been installed. +@c FIXME: Also mention @code{message-use-idna}? + +@item Gnus now displays @acronym{DNS} master files sent as text/dns +using dns-mode. + +@item Gnus supports new limiting commands in the Summary buffer: +@kbd{/ r} (@code{gnus-summary-limit-to-replied}) and @kbd{/ R} +(@code{gnus-summary-limit-to-recipient}). @xref{Limiting}. + +@item Gnus supports a new sort command in the Summary buffer: +@kbd{C-c C-s C-t} (@code{gnus-summary-sort-by-recipient}). @xref{Summary +Sorting}. + +@item @acronym{S/MIME} now features @acronym{LDAP} user certificate searches. +You need to configure the server in @code{smime-ldap-host-list}. + +@item URLs inside Open@acronym{PGP} headers are retrieved and imported +to your PGP key ring when you click on them. @item Picons can be displayed right from the textual address, see -@code{gnus-picon-style}. @ref{Picons}. +@code{gnus-picon-style}. @xref{Picons}. -@item -You can import and export your @acronym{RSS} subscriptions from -@acronym{OPML} files. @xref{RSS}. +@item @acronym{ANSI} @acronym{SGR} control sequences can be transformed +using @kbd{W A}. + +@acronym{ANSI} sequences are used in some Chinese hierarchies for +highlighting articles (@code{gnus-article-treat-ansi-sequences}). + +@item Gnus now MIME decodes articles even when they lack "MIME-Version" header. +This changes the default of @code{gnus-article-loose-mime}. + +@item @code{gnus-decay-scores} can be a regexp matching score files. +For example, set it to @samp{\\.ADAPT\\'} and only adaptive score files +will be decayed. @xref{Score Decays}. + +@item Strings prefixing to the @code{To} and @code{Newsgroup} headers in +summary lines when using @code{gnus-ignored-from-addresses} can be +customized with @code{gnus-summary-to-prefix} and +@code{gnus-summary-newsgroup-prefix}. @xref{To From Newsgroups}. + +@item You can replace @acronym{MIME} parts with external bodies. +See @code{gnus-mime-replace-part} and @code{gnus-article-replace-part}. +@xref{MIME Commands}, @ref{Using MIME}. @item The option @code{mm-fill-flowed} can be used to disable treatment of format=flowed messages. Also, flowed text is disabled when sending inline @acronym{PGP} signed messages. +@xref{Flowed text, ,Flowed text, emacs-mime, The Emacs MIME Manual}. -@item You can now drag and drop attachments to the Message buffer. +@end itemize -@item @acronym{ANSI} @acronym{SGR} control sequences can be transformed -using @kbd{W A}. +@item Changes in Message mode -@acronym{ANSI} sequences are used in some Chinese hierarchies for -highlighting articles (@code{gnus-article-treat-ansi-sequences}). +@itemize @bullet +@item Gnus now supports the ``hashcash'' client puzzle anti-spam mechanism. +Use @code{(setq message-generate-hashcash t)} to enable. +@xref{Hashcash}. -@item International host names (@acronym{IDNA}) can now be decoded -inside article bodies using @kbd{W i} -(@code{gnus-summary-idna-message}). This require that GNU Libidn -(@url{http://www.gnu.org/software/libidn/}) has been installed. +@item You can now drag and drop attachments to the Message buffer. +See @code{mml-dnd-protocol-alist} and @code{mml-dnd-attach-options}. +@xref{MIME, ,MIME, message, Message Manual}. -@item Gnus includes an Emacs Lisp @acronym{SASL} library. +@item The option @code{message-yank-empty-prefix} now controls how +empty lines are prefixed in cited text. @xref{Insertion Variables, +,Insertion Variables, message, Message Manual}. -This provide a clean @acronym{API} to @acronym{SASL} mechanisms from -within Emacs. The user visible aspects of this, compared to the earlier -situation, include support for @acronym{DIGEST}-@acronym{MD5} and -@acronym{NTLM}. +@item Gnus uses narrowing to hide headers in Message buffers. +The @code{References} header is hidden by default. To make all +headers visible, use @code{(setq message-hidden-headers nil)}. +@xref{Message Headers, ,Message Headers, message, Message Manual}. +@end itemize -@item ManageSieve connections uses the @acronym{SASL} library by default. +@item Changes in back ends -The primary change this brings is support for @acronym{DIGEST-MD5} and -@acronym{NTLM}, when the server support it. +@itemize @bullet +@item The nntp back end stores article marks in @file{~/News/marks}. -@item Gnus include a password cache mechanism in password.el. +The directory can be changed using the (customizable) variable +@code{nntp-marks-directory}, and marks can be disabled using the +(back end) variable @code{nntp-marks-is-evil}. The advantage of this +is that you can copy @file{~/News/marks} (using rsync, scp or +whatever) to another Gnus installation, and it will realize what +articles you have read and marked. The data in @file{~/News/marks} +has priority over the same data in @file{~/.newsrc.eld}. -It is enabled by default (see @code{password-cache}), with a short -timeout of 16 seconds (see @code{password-cache-expiry}). If -@acronym{PGG} is used as the @acronym{PGP} back end, the @acronym{PGP} -passphrase is managed by this mechanism. Passwords for ManageSieve -connections are managed by this mechanism, after quering the user about -whether to do so. +@item +You can import and export your @acronym{RSS} subscriptions from +@acronym{OPML} files. @xref{RSS}. @item @acronym{IMAP} identity (@acronym{RFC} 2971) is supported. -By default, Gnus do not send any information about itself, but you can +By default, Gnus does not send any information about itself, but you can customize it using the variable @code{nnimap-id}. -@item The @file{all.SCORE} file can be edited from the group buffer -using @kbd{W e}. +@item The @code{nnrss} back end now supports multilingual text. +Non-@acronym{ASCII} group names for the @code{nnrss} groups are also +supported. @xref{RSS}. -@item Gnus now MIME decode articles even when they lack "MIME-Version" header. -This changes the default of @code{gnus-article-loose-mime}. +@item Retrieving mail with @acronym{POP3} is supported over @acronym{SSL}/@acronym{TLS} and with StartTLS. -@item Gnus now view DNS master files sent as text/dns using dns-mode. +@item The nnml back end allows other compression programs beside @file{gzip} +for compressed message files. @xref{Mail Spool}. +@end itemize -@item Gnus now support the ``hashcash'' client puzzle anti-spam idea. -See the Gnus manual, section Hashcash, for more information. Use -@code{(setq message-generate-hashcash t)} to enable. +@item Appearance +@c Maybe it's not worth to separate this from "Miscellaneous"? -@item Gnus supports new limiting commands in the Summary buffer: -@kbd{/ r} (@code{gnus-summary-limit-to-replied}) and @kbd{/ R} -(@code{gnus-summary-limit-to-recipient}). @ref{Limiting}. +@itemize @bullet -@item Gnus supports a new sort command in the Summary buffer: -@kbd{C-c C-s C-t} (@code{gnus-summary-sort-by-recipient}). @ref{Summary -Sorting} +@item The tool bar has been updated to use GNOME icons. +You can also customize the tool bar. There's no documentation in the +manual yet, but @kbd{M-x customize-apropos RET -tool-bar$} should get +you started. (Only for Emacs, not in XEmacs.) +@c FIXME: Document this in the manual -@item The @code{nnrss} back end now supports multilingual text. -Non-@acronym{ASCII} group names for the @code{nnrss} groups are also -supported. @xref{RSS}. +@item The tool bar icons are now (de)activated correctly +in the group buffer, see the variable @code{gnus-group-update-tool-bar}. +Its default value depends on your Emacs version. +@c FIXME: Document this in the manual -@item URLs inside OpenPGP: headers are retrieved and imported to your -PGP key ring when you click on them. +@item You can change the location of XEmacs' toolbars in Gnus buffers. +See @code{gnus-use-toolbar} and @code{message-use-toolbar}. -@item Gnus uses narrowing to hide headers in Message buffers. -The @code{References} header is hidden by default. To make all -headers visible, use @code{(setq message-hidden-headers nil)}. +@end itemize -@item @code{gnus-decay-scores} can be a regexp matching score files. -This allows to decay only adaptive score files. @ref{Score Decays}. +@item Miscellaneous changes -@item @acronym{S/MIME} now feature @acronym{LDAP} user certificate searches. -You need to configure the server in @code{smime-ldap-host-list}. +@itemize @bullet +@item Having edited the select-method for the foreign server in the +server buffer is immediately reflected to the subscription of the groups +which use the server in question. For instance, if you change +@code{nntp-via-address} into @samp{bar.example.com} from +@samp{foo.example.com}, Gnus will connect to the news host by way of the +intermediate host @samp{bar.example.com} from next time. + +@item The @file{all.SCORE} file can be edited from the group buffer +using @kbd{W e}. @end itemize + +@end itemize + @c gnus-news.texi ends here. @ignore diff --git a/texi/gnus-refcard.tex b/texi/gnus-refcard.tex index 06e28e8..32d7b35 100644 --- a/texi/gnus-refcard.tex +++ b/texi/gnus-refcard.tex @@ -112,7 +112,8 @@ \newcommand{\Copyright}{% \begin{center} - Copyright \copyright\ 1995 Free Software Foundation, Inc.\\* + Copyright \copyright\ 1995, 2002, 2003, 2004, + 2005, 2006 Free Software Foundation, Inc.\\* Copyright \copyright\ 1995 Vladimir Alexiev $<$vladimir@cs.ualberta.ca$>$.\\* Copyright \copyright\ 2000 Felix Natter $<$fnatter@gmx.net$>$.\\* diff --git a/texi/gnus.texi b/texi/gnus.texi index 150bd2e..840a5b1 100644 --- a/texi/gnus.texi +++ b/texi/gnus.texi @@ -9,13 +9,12 @@ @documentencoding ISO-8859-1 @copying -Copyright (c) 1995, 1996, 1997, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, +2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with the Front-Cover texts being ``A GNU Manual'', and with the Back-Cover Texts as in (a) below. A copy of the @@ -52,7 +51,8 @@ license to the document, as described in section 6 of the license. \makeindex \begin{document} -\newcommand{\gnusversionname}{No Gnus v0.3} +% Adjust ../Makefile.in if you change the following line: +\newcommand{\gnusversionname}{No Gnus v0.4} \newcommand{\gnuschaptername}{} \newcommand{\gnussectionname}{} @@ -361,7 +361,8 @@ can be gotten by any nefarious means you can think of---@acronym{NNTP}, local spool or your mbox file. All at the same time, if you want to push your luck. -This manual corresponds to No Gnus v0.3. +@c Adjust ../Makefile.in if you change the following line: +This manual corresponds to No Gnus v0.4. @end ifinfo @@ -624,6 +625,7 @@ Select Methods * IMAP:: Using Gnus as a @acronym{IMAP} client. * Other Sources:: Reading directories, files, SOUP packets. * Combined Groups:: Combining groups into one group. +* Email Based Diary:: Using mails to manage diary events in Gnus. * Gnus Unplugged:: Reading news and mail offline. Server Buffer @@ -688,7 +690,7 @@ Browsing the Web * Ultimate:: The Ultimate Bulletin Board systems. * Web Archive:: Reading mailing list archived on web. * RSS:: Reading RDF site summary. -* Customizing w3:: Doing stuff to Emacs/w3 from Gnus. +* Customizing W3:: Doing stuff to Emacs/W3 from Gnus. @acronym{IMAP} @@ -722,6 +724,25 @@ Combined Groups * Virtual Groups:: Combining articles from many groups. * Kibozed Groups:: Looking through parts of the newsfeed for articles. +Email Based Diary + +* The NNDiary Back End:: Basic setup and usage. +* The Gnus Diary Library:: Utility toolkit on top of nndiary. +* Sending or Not Sending:: A final note on sending diary messages. + +The NNDiary Back End + +* Diary Messages:: What makes a message valid for nndiary. +* Running NNDiary:: NNDiary has two modes of operation. +* Customizing NNDiary:: Bells and whistles. + +The Gnus Diary Library + +* Diary Summary Line Format:: A nicer summary buffer line format. +* Diary Articles Sorting:: A nicer way to sort messages. +* Diary Headers Generation:: Not doing it manually. +* Diary Group Parameters:: Not handling them manually. + Gnus Unplugged * Agent Basics:: How it all is supposed to work. @@ -731,6 +752,7 @@ Gnus Unplugged * Agent as Cache:: The Agent is a big cache too. * Agent Expiry:: How to make old articles go away. * Agent Regeneration:: How to recover from lost connections and other accidents. +* Agent and flags:: How the Agent maintains flags. * Agent and IMAP:: How to use the Agent with @acronym{IMAP}. * Outgoing Messages:: What happens when you post/mail something? * Agent Variables:: Customizing is fun. @@ -828,22 +850,22 @@ Thwarting Email Spam Filtering Spam Using The Spam ELisp Package -* Spam ELisp Package Sequence of Events:: -* Spam ELisp Package Filtering of Incoming Mail:: -* Spam ELisp Package Global Variables:: -* Spam ELisp Package Configuration Examples:: -* Blacklists and Whitelists:: -* BBDB Whitelists:: -* Gmane Spam Reporting:: -* Anti-spam Hashcash Payments:: -* Blackholes:: -* Regular Expressions Header Matching:: -* Bogofilter:: -* SpamAssassin back end:: -* ifile spam filtering:: -* spam-stat spam filtering:: -* SpamOracle:: -* Extending the Spam ELisp package:: +* Spam ELisp Package Sequence of Events:: +* Spam ELisp Package Filtering of Incoming Mail:: +* Spam ELisp Package Global Variables:: +* Spam ELisp Package Configuration Examples:: +* Blacklists and Whitelists:: +* BBDB Whitelists:: +* Gmane Spam Reporting:: +* Anti-spam Hashcash Payments:: +* Blackholes:: +* Regular Expressions Header Matching:: +* Bogofilter:: +* SpamAssassin back end:: +* ifile spam filtering:: +* spam-stat spam filtering:: +* SpamOracle:: +* Extending the Spam ELisp package:: Filtering Spam Using Statistics with spam-stat @@ -883,7 +905,7 @@ New Features * Quassia Gnus:: Two times two is four, or Gnus 5.6/5.7. * Pterodactyl Gnus:: Pentad also starts with P, AKA Gnus 5.8/5.9. * Oort Gnus:: It's big. It's far out. Gnus 5.10/5.11. -* No Gnus:: Lars, FIXME! +* No Gnus:: Very punny. Customization @@ -1396,7 +1418,7 @@ cache for all groups). Most common Unix news readers use a shared startup file called @file{.newsrc}. This file contains all the information about what groups are subscribed, and which articles in these groups have been -read. +read. Things got a bit more complicated with @sc{gnus}. In addition to keeping the @file{.newsrc} file updated, it also used a file called @@ -1471,15 +1493,17 @@ startup files. If you want to turn backup creation off, say something like: @vindex gnus-init-file @vindex gnus-site-init-file When Gnus starts, it will read the @code{gnus-site-init-file} -(@file{.../site-lisp/gnus} by default) and @code{gnus-init-file} +(@file{.../site-lisp/gnus-init} by default) and @code{gnus-init-file} (@file{~/.gnus} by default) files. These are normal Emacs Lisp files and can be used to avoid cluttering your @file{~/.emacs} and @file{site-init} files with Gnus stuff. Gnus will also check for files with the same names as these, but with @file{.elc} and @file{.el} suffixes. In other words, if you have set @code{gnus-init-file} to @file{~/.gnus}, it will look for @file{~/.gnus.elc}, @file{~/.gnus.el}, -and finally @file{~/.gnus} (in this order). - +and finally @file{~/.gnus} (in this order). If Emacs was invoked with +the @option{-q} or @option{--no-init-file} options (@pxref{Initial +Options, ,Initial Options, emacs, The Emacs Manual}), Gnus doesn't read +@code{gnus-init-file}. @node Auto Save @@ -2764,6 +2788,9 @@ If the group parameter list has the element @code{(visible . t)}, that group will always be visible in the Group buffer, regardless of whether it has any unread articles. +This parameter cannot be set via @code{gnus-parameters}. See +@code{gnus-permanently-visible-groups} as an alternative. + @item broken-reply-to @cindex broken-reply-to Elements like @code{(broken-reply-to . t)} signals that @code{Reply-To} @@ -3031,7 +3058,7 @@ This can also be used as a group-specific hook function. If you want to hear a beep when you enter a group, you could put something like @code{(dummy-variable (ding))} in the parameters of that group. @code{dummy-variable} will be set to the (meaningless) result of the -@code{(ding)} form. +@code{(ding)} form. Alternatively, since the VARIABLE becomes local to the group, this pattern can be used to temporarily change a hook. For example, if the @@ -3055,8 +3082,9 @@ parameters (@pxref{Topic Parameters}). @vindex gnus-parameters Group parameters can be set via the @code{gnus-parameters} variable too. -But some variables, such as @code{visible}, have no effect. For -example: +But some variables, such as @code{visible}, have no effect (For this +case see @code{gnus-permanently-visible-groups} as an alternative.). +For example: @lisp (setq gnus-parameters @@ -3082,6 +3110,46 @@ example: String value of parameters will be subjected to regexp substitution, as the @code{to-group} example shows. +@vindex gnus-parameters-case-fold-search +By default, whether comparing the group name and one of those regexps +specified in @code{gnus-parameters} is done in a case-sensitive manner +or a case-insensitive manner depends on the value of +@code{case-fold-search} at the time when the comparison is done. The +value of @code{case-fold-search} is typically @code{t}; it means, for +example, the element @code{("INBOX\\.FOO" (total-expire . t))} might be +applied to both the @samp{INBOX.FOO} group and the @samp{INBOX.foo} +group. If you want to make those regexps always case-sensitive, set the +value of the @code{gnus-parameters-case-fold-search} variable to +@code{nil}. Otherwise, set it to @code{t} if you want to compare them +always in a case-insensitive manner. + +You can define different sorting to different groups via +@code{gnus-parameters}. Here is an example to sort an @acronym{NNTP} +group by reverse date to see the latest news at the top and an +@acronym{RSS} group by subject. In this example, the first group is the +Debian daily news group @code{gmane.linux.debian.user.news} from +news.gmane.org. The @acronym{RSS} group corresponds to the Debian +weekly news RSS feed +@url{http://packages.debian.org/unstable/newpkg_main.en.rdf}, +@xref{RSS}. + +@lisp +(setq + gnus-parameters + '(("nntp.*gmane\\.debian\\.user\\.news" + (gnus-show-threads nil) + (gnus-article-sort-functions '((not gnus-article-sort-by-date))) + (gnus-use-adaptive-scoring nil) + (gnus-use-scoring nil)) + ("nnrss.*debian" + (gnus-show-threads nil) + (gnus-article-sort-functions 'gnus-article-sort-by-subject) + (gnus-use-adaptive-scoring nil) + (gnus-use-scoring t) + (gnus-score-find-score-files-function 'gnus-score-find-single) + (gnus-summary-line-format "%U%R%z%d %I%(%[ %s %]%)\n")))) +@end lisp + @node Listing Groups @section Listing Groups @@ -4007,7 +4075,7 @@ Gnus 8: comp.binaries.fractals 13: comp.sources.unix 452: alt.sex.emacs -@end group +@end group @end example The @samp{Emacs} topic has the topic parameter @code{(score-file @@ -4046,6 +4114,22 @@ happens. You just have to be careful if you do stuff like that. @table @kbd +@item v +@kindex v (Group) +@cindex keys, reserved for users (Group) +The key @kbd{v} is reserved for users. You can bind it key to some +function or better use it as a prefix key. For example: + +@lisp +(define-key gnus-group-mode-map (kbd "v j d") + (lambda () + (interactive) + (gnus-group-jump-to-group "nndraft:drafts"))) +@end lisp + +On keys reserved for users in Emacs and on keybindings in general +@xref{Keymaps, Keymaps, , emacs, The Emacs Editor}. + @item ^ @kindex ^ (Group) @findex gnus-group-enter-server-mode @@ -4441,6 +4525,14 @@ group buffer (@pxref{Selecting a Group}). You can have as many summary buffers open as you wish. +@kindex v (Summary) +@cindex keys, reserved for users (Summary) +The key @kbd{v} is reserved for users. You can bind it key to some +function or better use it as a prefix key. For example: +@lisp +(define-key gnus-summary-mode-map (kbd "v -") "LrS") ;; lower subthread +@end lisp + @menu * Summary Buffer Format:: Deciding how the summary buffer is to look. * Summary Maneuvering:: Moving around the summary buffer. @@ -4682,6 +4774,8 @@ article has any children. The line number. @item O Download mark. +@item * +Desired cursor position (instead of after first colon). @item &user-date; Age sensitive date format. Various date format is defined in @code{gnus-user-date-format-alist}. @@ -4755,6 +4849,13 @@ summary line spec returns the @code{To}, @code{Newsreader} or @code{From} header, the value of the @code{To} or @code{Newsreader} headers are used instead. +To distinguish regular articles from those where the @code{From} field +has been swapped, a string is prefixed to the @code{To} or +@code{Newsgroups} header in the summary line. By default the string is +@samp{-> } for @code{To} and @samp{=> } for @code{Newsgroups}, you can +customize these strings with @code{gnus-summary-to-prefix} and +@code{gnus-summary-newsgroup-prefix}. + @end enumerate @vindex nnmail-extra-headers @@ -5112,10 +5213,10 @@ the server and display it in the article buffer. @item gnus-select-article-hook @vindex gnus-select-article-hook -This hook is called whenever an article is selected. By default it -exposes any threads hidden under the selected article. If you would -like each article to be saved in the Agent as you read it, putting -@code{gnus-agent-fetch-selected-article} on this hook will do so. +This hook is called whenever an article is selected. The default is +@code{nil}. If you would like each article to be saved in the Agent as +you read it, putting @code{gnus-agent-fetch-selected-article} on this +hook will do so. @item gnus-mark-article-hook @vindex gnus-mark-article-hook @@ -5125,8 +5226,8 @@ like each article to be saved in the Agent as you read it, putting This hook is called whenever an article is selected. It is intended to be used for marking articles as read. The default value is @code{gnus-summary-mark-read-and-unread-as-read}, and will change the -mark of almost any article you read to @code{gnus-unread-mark}. The -only articles not affected by this function are ticked, dormant, and +mark of almost any article you read to @code{gnus-read-mark}. The only +articles not affected by this function are ticked, dormant, and expirable articles. If you'd instead like to just have unread articles marked as read, you can use @code{gnus-summary-mark-unread-as-read} instead. It will leave marks like @code{gnus-low-score-mark}, @@ -5500,7 +5601,7 @@ default, the message is decoded and forwarded as an rfc822 @acronym{MIME} sectio @cindex digests @cindex making digests Digest the current series and forward the result to a newsgroup -(@code{gnus-uu-digest-mail-forward}). This command uses the +(@code{gnus-uu-digest-post-forward}). This command uses the process/prefix convention. @item S u @@ -6980,10 +7081,11 @@ Matching}). @findex gnus-thread-sort-by-total-score @findex gnus-thread-sort-by-date +@findex gnus-thread-sort-by-date-reverse @findex gnus-thread-sort-by-score @findex gnus-thread-sort-by-subject @findex gnus-thread-sort-by-author -@c @findex gnus-thread-sort-by-recipient +@findex gnus-thread-sort-by-recipient @findex gnus-thread-sort-by-number @findex gnus-thread-sort-by-random @vindex gnus-thread-sort-functions @@ -6996,8 +7098,10 @@ function, a list of functions, or a list containing functions and By default, sorting is done on article numbers. Ready-made sorting predicate functions include @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}, +@code{gnus-thread-sort-by-author}, @code{gnus-thread-sort-by-recipient}, +@code{gnus-thread-sort-by-subject}, +@code{gnus-thread-sort-by-date}, @code{gnus-thread-sort-by-date-reverse}, +@code{gnus-thread-sort-by-score}, @code{gnus-thread-sort-by-most-recent-number}, @code{gnus-thread-sort-by-most-recent-date}, @code{gnus-thread-sort-by-random} and @@ -7035,8 +7139,7 @@ say something like: @lisp (setq gnus-thread-sort-functions - '((lambda (t1 t2) - (not (gnus-thread-sort-by-number t1 t2))) + '((not gnus-thread-sort-by-number) gnus-thread-sort-by-score)) @end lisp @@ -7073,6 +7176,8 @@ say something like: gnus-article-sort-by-subject)) @end lisp +You can define group specific sorting via @code{gnus-parameters}, +@xref{Group Parameters}. @node Asynchronous Fetching @@ -8613,7 +8718,9 @@ Treat @acronym{HTML} (@code{gnus-article-wash-html}). Note that this is usually done automatically by Gnus if the message in question has a @code{Content-Type} header that says that the message is @acronym{HTML}. -If a prefix is given, a charset will be asked for. +If a prefix is given, a charset will be asked for. If it is a number, +the charset defined in @code{gnus-summary-show-article-charset-alist} +(@pxref{Paging the Article}) will be used. @vindex gnus-article-wash-function The default is to use the function specified by @@ -8625,11 +8732,14 @@ can use include: @table @code @item w3 -Use Emacs/w3. +Use Emacs/W3. @item w3m Use @uref{http://emacs-w3m.namazu.org/, emacs-w3m}. +@item w3m-standalone +Use @uref{http://w3m.sourceforge.net/, w3m}. + @item links Use @uref{http://links.sf.net/, Links}. @@ -9220,7 +9330,7 @@ Translate the article from one language to another @cindex viewing attachments The following commands all understand the numerical prefix. For -instance, @kbd{3 b} means ``view the third @acronym{MIME} part''. +instance, @kbd{3 K v} means ``view the third @acronym{MIME} part''. @table @kbd @item b @@ -9233,6 +9343,21 @@ View the @acronym{MIME} part. @kindex K o (Summary) Save the @acronym{MIME} part. +@item K O +@kindex K O (Summary) +Prompt for a file name, then save the @acronym{MIME} part and strip it +from the article. The stripped @acronym{MIME} object will be referred +via the message/external-body @acronym{MIME} type. + +@item K r +@kindex K r (Summary) +Replace the @acronym{MIME} part with an external body. + +@item K d +@kindex K d (Summary) +Delete the @acronym{MIME} part and add some information about the +removed part. + @item K c @kindex K c (Summary) Copy the @acronym{MIME} part. @@ -9361,6 +9486,12 @@ To see e.g. security buttons but no other buttons, you could set this variable to @code{("multipart/signed")} and leave @code{gnus-unbuttonized-mime-types} at the default value. +You could also add @code{"multipart/alternative"} to this list to +display radio buttons that allow you to choose one of two media types +those mails include. See also @code{mm-discouraged-alternatives} +(@pxref{Display Customization, ,Display Customization, emacs-mime, The +Emacs MIME Manual}). + @item gnus-inhibit-mime-unbuttonizing @vindex gnus-inhibit-mime-unbuttonizing If this is non-@code{nil}, then all @acronym{MIME} parts get buttons. The @@ -9400,10 +9531,10 @@ Display "multipart/alternative" parts as "multipart/mixed". Display "multipart/related" parts as "multipart/mixed". If displaying "text/html" is discouraged, see -@code{mm-discouraged-alternatives} in @ref{Display Customization, -Display Customization, , emacs-mime, Emacs-Mime Manual}. Images or -other material inside a "multipart/related" part might be overlooked -when this variable is @code{nil}. +@code{mm-discouraged-alternatives}, images or other material inside a +"multipart/related" part might be overlooked when this variable is +@code{nil}. @ref{Display Customization, Display Customization, , +emacs-mime, Emacs-Mime Manual}. @vindex gnus-mime-display-multipart-as-mixed @item gnus-mime-display-multipart-as-mixed @@ -9461,7 +9592,7 @@ newsreaders and mailers that do not understand or use @acronym{MIME}, and just send out messages without saying what character sets they use. To help a bit with this, some local news hierarchies have policies that say what character set is the default. For instance, the @samp{fj} -hierarchy uses @code{iso-2022-jp-2}. +hierarchy uses @code{iso-2022-jp}. @vindex gnus-group-charset-alist This knowledge is encoded in the @code{gnus-group-charset-alist} @@ -9684,17 +9815,16 @@ by giving the @kbd{A T} command a numerical prefix. @kindex M-^ (Summary) @cindex Message-ID @cindex fetching by Message-ID -You can also ask the @acronym{NNTP} server for an arbitrary article, no -matter what group it belongs to. @kbd{M-^} -(@code{gnus-summary-refer-article}) will ask you for a -@code{Message-ID}, which is one of those long, hard-to-read thingies -that look something like @samp{<38o6up$6f2@@hymir.ifi.uio.no>}. You -have to get it all exactly right. No fuzzy searches, I'm afraid. -@end table +You can also ask Gnus for an arbitrary article, no matter what group it +belongs to. @kbd{M-^} (@code{gnus-summary-refer-article}) will ask you +for a @code{Message-ID}, which is one of those long, hard-to-read +thingies that look something like @samp{<38o6up$6f2@@hymir.ifi.uio.no>}. +You have to get it all exactly right. No fuzzy searches, I'm afraid. -The current select method will be used when fetching by -@code{Message-ID} from non-news select method, but you can override this -by giving this command a prefix. +Gnus looks for the @code{Message-ID} in the headers that have already +been fetched, but also tries all the select methods specified by +@code{gnus-refer-article-method} if it is not found. +@end table @vindex gnus-refer-article-method If the group you are reading is located on a back end that does not @@ -10469,6 +10599,12 @@ Mark all articles, even the ticked ones, as read and then exit Mark all articles as read and go to the next group (@code{gnus-summary-catchup-and-goto-next-group}). +@item Z p +@kindex Z p (Summary) +@findex gnus-summary-catchup-and-goto-prev-group +Mark all articles as read and go to the previous group +(@code{gnus-summary-catchup-and-goto-prev-group}). + @item Z R @itemx C-x C-s @kindex Z R (Summary) @@ -10690,8 +10826,8 @@ or newer is recommended. @end enumerate -More information on how to set things up can be found in the message -manual (@pxref{Security, ,Security, message, Message Manual}). +The variables that control security functionality on reading messages +include: @table @code @item mm-verify-option @@ -10722,6 +10858,15 @@ deprecated. @end table +By default the buttons that display security information are not +shown, because they clutter reading the actual e-mail. You can type +@kbd{K b} manually to display the information. Use the +@code{gnus-buttonized-mime-types} and +@code{gnus-unbuttonized-mime-types} variables to control this +permanently. @ref{MIME Commands} for further details, and hints on +how to customize these variables to always display security +information. + @cindex snarfing keys @cindex importing PGP keys @cindex PGP key ring import @@ -10742,6 +10887,10 @@ application/pgp-keys; gpg --import --interactive --verbose; needsterminal This happens to also be the default action defined in @code{mailcap-mime-data}. +More information on how to set things for sending outgoing signed and +encrypted messages up can be found in the message manual +(@pxref{Security, ,Security, message, Message Manual}). + @node Mailing List @section Mailing List @cindex mailing list @@ -11006,6 +11155,13 @@ like. The stripped @acronym{MIME} object will be referred via the message/external-body @acronym{MIME} type. (@code{gnus-mime-save-part-and-strip}). +@findex gnus-mime-replace-part +@item r (Article) +@kindex r (Article) +Prompt for a file name, replace the @acronym{MIME} object with an +external body refering to the file via the message/external-body +@acronym{MIME} type. (@code{gnus-mime-replace-part}). + @findex gnus-mime-delete-part @item d (Article) @kindex d (Article) @@ -11013,6 +11169,8 @@ Delete the @acronym{MIME} object from the article and replace it with some information about the removed @acronym{MIME} object (@code{gnus-mime-delete-part}). +@c FIXME: gnus-auto-select-part should be documented here + @findex gnus-mime-copy-part @item c (Article) @kindex c (Article) @@ -11118,7 +11276,10 @@ for sensible values. @code{head}: Do the treatment on the headers. @item -@code{last}: Do this treatment on the last part. +@code{first}: Do this treatment on the first body part. + +@item +@code{last}: Do this treatment on the last body part. @item An integer: Do this treatment on all body parts that have a length less @@ -11171,7 +11332,7 @@ possible but those listed are probably sufficient for most people. @item gnus-treat-overstrike (t, integer) @item gnus-treat-strip-cr (t, integer) @item gnus-treat-strip-headers-in-body (t, integer) -@item gnus-treat-strip-leading-blank-lines (t, integer) +@item gnus-treat-strip-leading-blank-lines (t, first, integer) @item gnus-treat-strip-multiple-blank-lines (t, integer) @item gnus-treat-strip-pem (t, last, integer) @item gnus-treat-strip-trailing-blank-lines (t, last, integer) @@ -11265,6 +11426,11 @@ buffer, which means that you don't actually have to have a summary buffer displayed while reading. You can do it all from the article buffer. +@kindex v (Article) +@cindex keys, reserved for users (Article) +The key @kbd{v} is reserved for users. You can bind it key to some +function or better use it as a prefix key. + A few additional keystrokes are available: @table @kbd @@ -11500,13 +11666,15 @@ that have none when you do a @kbd{a}. @item gnus-confirm-mail-reply-to-news @vindex gnus-confirm-mail-reply-to-news -This can also be a function receiving the group name as the only -parameter which should return non-@code{nil} if a confirmation is -needed, or a regular expression matching group names, where -confirmation is should be asked for. +If non-@code{nil}, Gnus will ask you for a confirmation when you are +about to reply to news articles by mail. If it is @code{nil}, nothing +interferes in what you want to do. This can also be a function +receiving the group name as the only parameter which should return +non-@code{nil} if a confirmation is needed, or a regular expression +matching group names, where confirmation should be asked for. If you find yourself never wanting to reply to mail, but occasionally -press R anyway, this variable might be for you. +press @kbd{R} anyway, this variable might be for you. @item gnus-confirm-treat-mail-like-news @vindex gnus-confirm-treat-mail-like-news @@ -11956,7 +12124,8 @@ So here's a new example: '((".*" (signature-file "~/.signature") (name "User Name") - ("X-Home-Page" (getenv "WWW_HOME")) + (x-face-file "~/.xface") + (x-url (getenv "WWW_HOME")) (organization "People's Front Against MWM")) ("^rec.humor" (signature my-funny-signature-randomizer)) @@ -12200,6 +12369,7 @@ The different methods all have their peculiarities, of course. * IMAP:: Using Gnus as a @acronym{IMAP} client. * Other Sources:: Reading directories, files, SOUP packets. * Combined Groups:: Combining groups into one group. +* Email Based Diary:: Using mails to manage diary events in Gnus. * Gnus Unplugged:: Reading news and mail offline. @end menu @@ -12266,6 +12436,9 @@ Where the news is to be fetched from---the address. @item s The opened/closed/denied status of the server. + +@item a +Whether this server is agentized. @end table @vindex gnus-server-mode-line-format @@ -12290,6 +12463,12 @@ Also @pxref{Formatting Variables}. @table @kbd +@item v +@kindex v (Server) +@cindex keys, reserved for users (Server) +The key @kbd{v} is reserved for users. You can bind it key to some +function or better use it as a prefix key. + @item a @kindex a (Server) @findex gnus-server-add-server @@ -12425,7 +12604,19 @@ configuration to the example above: (nntp-via-rlogin-command "ssh") @end lisp -See also @code{nntp-via-rlogin-command-switches}. +See also @code{nntp-via-rlogin-command-switches}. Here's an example for +an indirect connection: +@lisp +(setq gnus-select-method + '(nntp "indirect" + (nntp-address "news.server.example") + (nntp-via-user-name "intermediate_user_name") + (nntp-via-address "intermediate.host.example") + (nntp-via-rlogin-command "ssh") + (nntp-end-of-line "\n") + (nntp-via-rlogin-command-switches ("-C" "-t" "-e" "none")) + (nntp-open-connection-function nntp-open-via-rlogin-and-telnet))) +@end lisp If you're behind a firewall, but have direct access to the outside world through a wrapper command like "runsocks", you could open a socksified @@ -12744,35 +12935,6 @@ that says how many seconds the @code{nntp} back end should wait for a connection before giving up. If it is @code{nil}, which is the default, no timeouts are done. -@c @item nntp-command-timeout -@c @vindex nntp-command-timeout -@c @cindex PPP connections -@c @cindex dynamic IP addresses -@c If you're running Gnus on a machine that has a dynamically assigned -@c address, Gnus may become confused. If the address of your machine -@c changes after connecting to the @acronym{NNTP} server, Gnus will simply sit -@c waiting forever for replies from the server. To help with this -@c unfortunate problem, you can set this command to a number. Gnus will -@c then, if it sits waiting for a reply from the server longer than that -@c number of seconds, shut down the connection, start a new one, and resend -@c the command. This should hopefully be transparent to the user. A -@c likely number is 30 seconds. -@c -@c @item nntp-retry-on-break -@c @vindex nntp-retry-on-break -@c If this variable is non-@code{nil}, you can also @kbd{C-g} if Gnus -@c hangs. This will have much the same effect as the command timeout -@c described above. - -@item nntp-server-hook -@vindex nntp-server-hook -This hook is run as the last step when connecting to an @acronym{NNTP} -server. - -@item nntp-buggy-select -@vindex nntp-buggy-select -Set this to non-@code{nil} if your select routine is buggy. - @item nntp-nov-is-evil @vindex nntp-nov-is-evil If the @acronym{NNTP} server does not support @acronym{NOV}, you could set this @@ -12804,11 +12966,6 @@ that fetching will probably be slower. If this variable is @code{nil}, @vindex nntp-prepare-server-hook A hook run before attempting to connect to an @acronym{NNTP} server. -@item nntp-warn-about-losing-connection -@vindex nntp-warn-about-losing-connection -If this variable is non-@code{nil}, some noise will be made when a -server closes connection. - @item nntp-record-commands @vindex nntp-record-commands If non-@code{nil}, @code{nntp} will log all commands it sends to the @@ -12821,9 +12978,9 @@ that doesn't seem to work. It is possible to customize how the connection to the nntp server will be opened. If you specify an @code{nntp-open-connection-function} parameter, Gnus will use that function to establish the connection. -Five pre-made functions are supplied. These functions can be grouped in -two categories: direct connection functions (three pre-made), and -indirect ones (two pre-made). +Seven pre-made functions are supplied. These functions can be grouped +in two categories: direct connection functions (four pre-made), and +indirect ones (three pre-made). @item nntp-prepare-post-hook @vindex nntp-prepare-post-hook @@ -12840,14 +12997,6 @@ inhibit Gnus to add a @code{Message-ID} header, you could say: Note that not all servers support the recommended ID. This works for INN versions 2.3.0 and later, for instance. -@item nntp-read-timeout -@vindex nntp-read-timeout -How long nntp should wait between checking for the end of output. -Shorter values mean quicker response, but is more CPU intensive. The -default is 0.1 seconds. If you have a slow line to the server (and -don't like to see Emacs eat your available CPU power), you might set -this to, say, 1. - @end table @menu @@ -13001,7 +13150,7 @@ List of strings to be used as the switches to @item nntp-open-via-telnet-and-telnet @findex nntp-open-via-telnet-and-telnet -Does essentially also the same, but uses @samp{telnet} instead of +Does essentially the same, but uses @samp{telnet} instead of @samp{rlogin} to connect to the intermediate host. @code{nntp-open-via-telnet-and-telnet}-specific variables: @@ -13060,7 +13209,9 @@ Address of the intermediate host to connect to. The following variables affect the behavior of all, or several of the pre-made connection functions. When not specified, all functions are -affected. +affected (the values of the following variables will be used as the +default if each virtual @code{nntp} server doesn't specify those server +variables individually). @table @code @@ -13068,7 +13219,7 @@ affected. @vindex nntp-pre-command A command wrapper to use when connecting through a non native connection function (all except @code{nntp-open-network-stream}, -@code{nntp-open-tls-stream}, and @code{nntp-open-ssl-stream}. This is +@code{nntp-open-tls-stream}, and @code{nntp-open-ssl-stream}). This is where you would put a @samp{SOCKS} wrapper for instance. @item nntp-address @@ -13079,7 +13230,7 @@ The address of the @acronym{NNTP} server. @vindex nntp-port-number Port number to connect to the @acronym{NNTP} server. The default is @samp{nntp}. If you use @acronym{NNTP} over -@acronym{tls}/@acronym{ssl}, you may want to use integer ports rather +@acronym{TLS}/@acronym{SSL}, you may want to use integer ports rather than named ports (i.e, use @samp{563} instead of @samp{snews} or @samp{nntps}), because external @acronym{TLS}/@acronym{SSL} tools may not work with named ports. @@ -13447,7 +13598,7 @@ function. By default the splitting codes @acronym{MIME} decodes headers so you can match on non-@acronym{ASCII} strings. The @code{nnmail-mail-splitting-charset} variable specifies the default -charset for decoding. The behaviour can be turned off completely by +charset for decoding. The behavior can be turned off completely by binding @code{nnmail-mail-splitting-decodes} to @code{nil}, which is useful if you want to match articles based on the raw header data. @@ -13985,7 +14136,8 @@ is to say where the incoming files will be stored if the variable Prefix for file name for storing incoming mail. The default is @file{Incoming}, in which case files will end up with names like @file{Incoming30630D_} or @file{Incoming298602ZD}. This is really only -relevant if @code{mail-source-delete-incoming} is @code{nil}. +relevant if @code{mail-source-delete-incoming} is @code{nil} or a +number. @item mail-source-default-file-modes @vindex mail-source-default-file-modes @@ -14165,17 +14317,26 @@ splits. Here are the possible split syntaxes: @table @code -@item group +@item group If the split is a string, that will be taken as a group name. Normal regexp match expansion will be done. See below for examples. -@item (@var{field} @var{value} [- @var{restrict} [@dots{}] ] @var{split}) -If the split is a list, the first element of which is a string, then -store the message as specified by @var{split}, if header @var{field} -(a regexp) contains @var{value} (also a regexp). If @var{restrict} -(yet another regexp) matches some string after @var{field} and before -the end of the matched @var{value}, the @var{split} is ignored. If -none of the @var{restrict} clauses match, @var{split} is processed. +@c Don't fold this line. +@item (@var{field} @var{value} [- @var{restrict} [@dots{}] ] @var{split} [@var{invert-partial}]) +The split can be a list containing at least three elements. If the +first element @var{field} (a regexp matching a header) contains +@var{value} (also a regexp) then store the message as specified by +@var{split}. + +If @var{restrict} (yet another regexp) matches some string after +@var{field} and before the end of the matched @var{value}, the +@var{split} is ignored. If none of the @var{restrict} clauses match, +@var{split} is processed. + +The last element @var{invert-partial} is optional. If it is +non-@code{nil}, the match-partial-words behavior controlled by the +variable @code{nnmail-split-fancy-match-partial-words} (see below) is +be inverted. (New in Gnus 5.10.7) @item (| @var{split} @dots{}) If the split is a list, and the first element is @code{|} (vertical @@ -14230,10 +14391,49 @@ If the split is @code{nil}, it is ignored. @end table In these splits, @var{field} must match a complete field name. -@var{value} must match a complete word according to the fundamental mode -syntax table. You can use @code{.*} in the regexps to match partial -field names or words. In other words, all @var{value}'s are wrapped in -@samp{\<} and @samp{\>} pairs. + +Normally, @var{value} in these splits must match a complete @emph{word} +according to the fundamental mode syntax table. In other words, all +@var{value}'s will be implicitly surrounded by @code{\<...\>} markers, +which are word delimiters. Therefore, if you use the following split, +for example, + +@example +(any "joe" "joemail") +@end example + +@noindent +messages sent from @samp{joedavis@@foo.org} will normally not be filed +in @samp{joemail}. If you want to alter this behavior, you can use any +of the following three ways: + +@enumerate +@item +@vindex nnmail-split-fancy-match-partial-words +You can set the @code{nnmail-split-fancy-match-partial-words} variable +to non-@code{nil} in order to ignore word boundaries and instead the +match becomes more like a grep. This variable controls whether partial +words are matched during fancy splitting. The default value is +@code{nil}. + +Note that it influences all @var{value}'s in your split rules. + +@item +@var{value} beginning with @code{.*} ignores word boundaries in front of +a word. Similarly, if @var{value} ends with @code{.*}, word boundaries +in the rear of a word will be ignored. For example, the @var{value} +@code{"@@example\\.com"} does not match @samp{foo@@example.com} but +@code{".*@@example\\.com"} does. + +@item +You can set the @var{invert-partial} flag in your split rules of the +@samp{(@var{field} @var{value} @dots{})} types, aforementioned in this +section. If the flag is set, word boundaries on both sides of a word +are ignored even if @code{nnmail-split-fancy-match-partial-words} is +@code{nil}. Contrarily, if the flag is set, word boundaries are not +ignored even if @code{nnmail-split-fancy-match-partial-words} is +non-@code{nil}. (New in Gnus 5.10.7) +@end enumerate @vindex nnmail-split-abbrev-alist @var{field} and @var{value} can also be Lisp symbols, in that case @@ -14281,25 +14481,6 @@ groups when users send to an address using different case (i.e. mailing-list@@domain vs Mailing-List@@Domain). The default value is @code{t}. -@vindex nnmail-split-fancy-match-partial-words -@code{nnmail-split-fancy-match-partial-words} controls whether partial -words are matched during fancy splitting. - -Normally, regular expressions given in @code{nnmail-split-fancy} are -implicitly surrounded by @code{\<...\>} markers, which are word -delimiters. If this variable is true, they are not implicitly -surrounded by anything. - -@example -(any "joe" "joemail") -@end example - -In this example, messages sent from @samp{joedavis@@foo.org} will -normally not be filed in @samp{joemail}. With -@code{nnmail-split-fancy-match-partial-words} set to t, however, the -match will happen. In effect, the requirement of a word boundary is -removed and instead the match becomes more like a grep. - @findex nnmail-split-fancy-with-parent @code{nnmail-split-fancy-with-parent} is a function which allows you to split followups into the same groups their parents are in. Sometimes @@ -15036,7 +15217,7 @@ When the marks file is used (which it is by default), @code{nnml} servers have the property that you may backup them using @code{tar} or similar, and later be able to restore them into Gnus (by adding the proper @code{nnml} server) and have all your marks be preserved. Marks -for a group is usually stored in the @code{.marks} file (but see +for a group are usually stored in the @code{.marks} file (but see @code{nnml-marks-file-name}) within each @code{nnml} group's directory. Individual @code{nnml} groups are also possible to backup, use @kbd{G m} to restore the group (after restoring the backup into the nnml @@ -15095,7 +15276,18 @@ The name of the @dfn{marks} files. The default is @file{.marks}. @item nnml-use-compressed-files @vindex nnml-use-compressed-files If non-@code{nil}, @code{nnml} will allow using compressed message -files. +files. This requires @code{auto-compression-mode} to be enabled +(@pxref{Compressed Files, ,Compressed Files, emacs, The Emacs Manual}). +If the value of @code{nnml-use-compressed-files} is a string, it is used +as the file extension specifying the comression program. You can set it +to @samp{.bz2} if your Emacs supports it. A value of @code{t} is +equivalent to @samp{.gz}. + +@item nnml-compressed-files-size-threshold +@vindex nnml-compressed-files-size-threshold +Default size threshold for compressed message files. Message files with +bodies larger than that many characters will be automatically compressed +if @code{nnml-use-compressed-files} is non-@code{nil}. @end table @@ -15280,8 +15472,9 @@ An integer specifying the minimum age, in seconds, of an article before it will be expired, or the symbol @code{never} to specify that articles should never be expired. If this parameter is not set, @code{nnmaildir} falls back to the usual -@code{nnmail-expiry-wait}(@code{-function}) variables (overrideable by -the @code{expiry-wait}(@code{-function}) group parameters. If you +@code{nnmail-expiry-wait}(@code{-function}) variables (the +@code{expiry-wait} group parameter overrides @code{nnmail-expiry-wait} +and makes @code{nnmail-expiry-wait-function} ineffective). If you wanted a value of 3 days, you could use something like @code{[(* 3 24 60 60)]}; @code{nnmaildir} will evaluate the form and use the result. An article's age is measured starting from the article file's @@ -15304,8 +15497,8 @@ the parameter belongs to, then the article is not expired at all. If you use the vector form, the first element is evaluated once for each article. So that form can refer to @code{nnmaildir-article-file-name}, etc., to decide where to put the -article. @emph{If this parameter is not set, @code{nnmaildir} does -not fall back to the @code{expiry-target} group parameter or the +article. @emph{Even if this parameter is not set, @code{nnmaildir} +does not fall back to the @code{expiry-target} group parameter or the @code{nnmail-expiry-target} variable.} @item read-only @@ -15426,7 +15619,7 @@ When the marks file is used (which it is by default), @code{nnfolder} servers have the property that you may backup them using @code{tar} or similar, and later be able to restore them into Gnus (by adding the proper @code{nnfolder} server) and have all your marks be preserved. -Marks for a group is usually stored in a file named as the mbox file +Marks for a group are usually stored in a file named as the mbox file with @code{.mrk} concatenated to it (but see @code{nnfolder-marks-file-suffix}) within the @code{nnfolder} directory. Individual @code{nnfolder} groups are also possible to @@ -15721,10 +15914,11 @@ interfaces to these sources. * Ultimate:: The Ultimate Bulletin Board systems. * Web Archive:: Reading mailing list archived on web. * RSS:: Reading RDF site summary. -* Customizing w3:: Doing stuff to Emacs/w3 from Gnus. +* Customizing W3:: Doing stuff to Emacs/W3 from Gnus. @end menu -All the web sources require Emacs/w3 and the url library to work. +All the web sources require Emacs/W3 and the url library or those +alternatives to work. The main caveat with all these web sources is that they probably won't work for a very long time. Gleaning information from the @acronym{HTML} data @@ -15811,8 +16005,9 @@ make money off of advertisements, not to provide services to the community. Since @code{nnweb} washes the ads off all the articles, one might think that the providers might be somewhat miffed. We'll see. -You must have the @code{url} and @code{w3} package installed to be able -to use @code{nnweb}. +You must have the @code{url} and @code{W3} package or those alternatives +(try @code{customize-group} on the @samp{mm-url} variable group) +installed to be able to use @code{nnweb}. Virtual server variables: @@ -16032,9 +16227,9 @@ system because @acronym{RSS} uses UTF-8 for encoding non-@acronym{ASCII} text by default. It is also used by default for non-@acronym{ASCII} group names. -@kindex G R (Summary) -Use @kbd{G R} from the summary buffer to subscribe to a feed---you will -be prompted for the location, the title and the description of the feed. +@kindex G R (Group) +Use @kbd{G R} from the group buffer to subscribe to a feed---you will be +prompted for the location, the title and the description of the feed. The title, which allows any characters, will be used for the group name and the name of the group data file. The description can be omitted. @@ -16051,6 +16246,10 @@ the value of @code{default-file-name-coding-system}. If you are using XEmacs and want to use non-@acronym{ASCII} group names, you should set the value for the @code{nnmail-pathname-coding-system} variable properly. +The @code{nnrss} back end generates @samp{multipart/alternative} +@acronym{MIME} articles in which each contains a @samp{text/plain} part +and a @samp{text/html} part. + @cindex OPML You can also use the following commands to import and export your subscriptions from a file in @acronym{OPML} format (Outline Processor @@ -16088,6 +16287,15 @@ If you set @code{nnrss-use-local} to @code{t}, @code{nnrss} will read the feeds from local files in @code{nnrss-directory}. You can use the command @code{nnrss-generate-download-script} to generate a download script using @command{wget}. + +@item nnrss-wash-html-in-text-plain-parts +Non-@code{nil} means that @code{nnrss} renders text in @samp{text/plain} +parts as @acronym{HTML}. The function specified by the +@code{mm-text-html-renderer} variable (@pxref{Display Customization, +,Display Customization, emacs-mime, The Emacs MIME Manual}) will be used +to render text. If it is @code{nil}, which is the default, text will +simply be folded. Leave it @code{nil} if you prefer to see +@samp{text/html} parts. @end table The following code may be helpful, if you want to show the description in @@ -16105,6 +16313,7 @@ the summary buffer. The following code may be useful to open an nnrss url directly from the summary buffer. + @lisp (require 'browse-url) @@ -16127,18 +16336,44 @@ summary buffer. (add-to-list 'nnmail-extra-headers nnrss-url-field) @end lisp -@node Customizing w3 -@subsection Customizing w3 -@cindex w3 +Even if you have added @code{"text/html"} to the +@code{mm-discouraged-alternatives} variable (@pxref{Display +Customization, ,Display Customization, emacs-mime, The Emacs MIME +Manual}) since you don't want to see @acronym{HTML} parts, it might be +more useful especially in @code{nnrss} groups to display +@samp{text/html} parts. Here's an example of setting +@code{mm-discouraged-alternatives} as a group parameter (@pxref{Group +Parameters}) in order to display @samp{text/html} parts only in +@code{nnrss} groups: + +@lisp +;; @r{Set the default value of @code{mm-discouraged-alternatives}.} +(eval-after-load "gnus-sum" + '(add-to-list + 'gnus-newsgroup-variables + '(mm-discouraged-alternatives + . '("text/html" "image/.*")))) + +;; @r{Display @samp{text/html} parts in @code{nnrss} groups.} +(add-to-list + 'gnus-parameters + '("\\`nnrss:" (mm-discouraged-alternatives nil))) +@end lisp + + +@node Customizing W3 +@subsection Customizing W3 +@cindex W3 @cindex html @cindex url @cindex Netscape -Gnus uses the url library to fetch web pages and Emacs/w3 to display web -pages. Emacs/w3 is documented in its own manual, but there are some -things that may be more relevant for Gnus users. +Gnus uses the url library to fetch web pages and Emacs/W3 (or those +alternatives) to display web pages. Emacs/W3 is documented in its own +manual, but there are some things that may be more relevant for Gnus +users. -For instance, a common question is how to make Emacs/w3 follow links +For instance, a common question is how to make Emacs/W3 follow links using the @code{browse-url} functions (which will call some external web browser like Netscape). Here's one way: @@ -16153,7 +16388,7 @@ browser like Netscape). Here's one way: (w3-fetch-orig url target))))) @end lisp -Put that in your @file{.emacs} file, and hitting links in w3-rendered +Put that in your @file{.emacs} file, and hitting links in W3-rendered @acronym{HTML} in the Gnus article buffers will use @code{browse-url} to follow the link. @@ -16451,7 +16686,7 @@ RFC 2060 for more information on valid strings. A file containing credentials used to log in on servers. The format is (almost) the same as the @code{ftp} @file{~/.netrc} file. See the variable @code{nntp-authinfo-file} for exact syntax; also see -@ref{NNTP}. An example of an .authinfo line for an IMAP server, is: +@ref{NNTP}. An example of an .authinfo line for an IMAP server, is: @example machine students.uio.no login larsi password geheimnis port imap @@ -16651,7 +16886,7 @@ Nnmail equivalent: @code{nnmail-split-fancy}. Set to non-@code{nil} to download entire articles during splitting. This is generally not required, and will slow things down considerably. You may need it if you want to use an advanced -splitting function that analyses the body to split the article. +splitting function that analyzes the body to split the article. @end table @@ -16746,7 +16981,7 @@ delete them. @cindex namespaces The @acronym{IMAP} protocol has a concept called namespaces, described -by the following text in the RFC: +by the following text in the RFC2060: @display 5.1.2. Mailbox Namespace Naming Convention @@ -16789,7 +17024,7 @@ tool and should be used only if you are sure what the effects are. @acronym{IMAP} is a complex protocol, more so than @acronym{NNTP} or @acronym{POP3}. Implementation bugs are not unlikely, and we do our -best to fix them right away. If you encounter odd behaviour, chances +best to fix them right away. If you encounter odd behavior, chances are that either the server or Gnus is buggy. If you are familiar with network protocols in general, you will @@ -16804,7 +17039,7 @@ to include the protocol dump when reporting IMAP bugs in Gnus. @vindex imap-log Because the protocol dump, when enabled, generates lots of data, it is disabled by default. You can enable it by setting @code{imap-log} as -follows: +follows: @lisp (setq imap-log t) @@ -16936,12 +17171,11 @@ as a newsgroup. Several files types are supported: @table @code @cindex Babyl @cindex Rmail mbox - @item babyl The Babyl (Rmail) mail box. + @cindex mbox @cindex Unix mbox - @item mbox The standard Unix mbox file. @@ -16952,13 +17186,9 @@ The MMDF mail box format. @item news Several news articles appended into a file. -@item rnews @cindex rnews batch files +@item rnews The rnews batch transport format. -@cindex forwarded messages - -@item forward -Forwarded articles. @item nsmail Netscape mail boxes. @@ -16975,6 +17205,7 @@ A @acronym{MIME} digest of messages. @item lanl-gov-announce Announcement messages from LANL Gov Announce. +@cindex forwarded messages @item rfc822-forward A message forwarded according to RFC822. @@ -17078,34 +17309,48 @@ totally ignored. @item article-begin This setting has to be present in all document type definitions. It -says what the beginning of each article looks like. +says what the beginning of each article looks like. To do more +complicated things that cannot be dealt with a simple regexp, you can +use @code{article-begin-function} instead of this. -@item head-begin-function -If present, this should be a function that moves point to the head of -the article. +@item article-begin-function +If present, this should be a function that moves point to the beginning +of each article. This setting overrides @code{article-begin}. -@item nndoc-head-begin +@item head-begin If present, this should be a regexp that matches the head of the -article. +article. To do more complicated things that cannot be dealt with a +simple regexp, you can use @code{head-begin-function} instead of this. -@item nndoc-head-end +@item head-begin-function +If present, this should be a function that moves point to the head of +the article. This setting overrides @code{head-begin}. + +@item head-end This should match the end of the head of the article. It defaults to @samp{^$}---the empty line. +@item body-begin +This should match the beginning of the body of the article. It defaults +to @samp{^\n}. To do more complicated things that cannot be dealt with +a simple regexp, you can use @code{body-begin-function} instead of this. + @item body-begin-function If present, this function should move point to the beginning of the body -of the article. +of the article. This setting overrides @code{body-begin}. -@item body-begin -This should match the beginning of the body of the article. It defaults -to @samp{^\n}. +@item body-end +If present, this should match the end of the body of the article. To do +more complicated things that cannot be dealt with a simple regexp, you +can use @code{body-end-function} instead of this. @item body-end-function If present, this function should move point to the end of the body of -the article. +the article. This setting overrides @code{body-end}. -@item body-end -If present, this should match the end of the body of the article. +@item file-begin +If present, this should match the beginning of the file. All text +before this regexp will be totally ignored. @item file-end If present, this should match the end of the file. All text after this @@ -17136,6 +17381,19 @@ understand. It is called with the article number as a parameter, and is expected to generate a nice head for the article in question. It is called when requesting the headers of all articles. +@item generate-article-function +If present, this function is called to generate an entire article that +Gnus can understand. It is called with the article number as a +parameter when requesting all articles. + +@item dissection-function +If present, this function is called to dissect a document by itself, +overriding @code{first-article}, @code{article-begin}, +@code{article-begin-function}, @code{head-begin}, +@code{head-begin-function}, @code{head-end}, @code{body-begin}, +@code{body-begin-function}, @code{body-end}, @code{body-end-function}, +@code{file-begin}, and @code{file-end}. + @end table Let's look at the most complicated example I can come up with---standard @@ -17605,16 +17863,16 @@ group have to be alive (i.e., subscribed or unsubscribed). Killed or zombie groups can't be component groups for @code{nnvirtual} groups. @vindex nnvirtual-always-rescan -If the @code{nnvirtual-always-rescan} is non-@code{nil}, -@code{nnvirtual} will always scan groups for unread articles when -entering a virtual group. If this variable is @code{nil} (which is the -default) and you read articles in a component group after the virtual -group has been activated, the read articles from the component group -will show up when you enter the virtual group. You'll also see this -effect if you have two virtual groups that have a component group in -common. If that's the case, you should set this variable to @code{t}. -Or you can just tap @code{M-g} on the virtual group every time before -you enter it---it'll have much the same effect. +If the @code{nnvirtual-always-rescan} variable is non-@code{nil} (which +is the default), @code{nnvirtual} will always scan groups for unread +articles when entering a virtual group. If this variable is @code{nil} +and you read articles in a component group after the virtual group has +been activated, the read articles from the component group will show up +when you enter the virtual group. You'll also see this effect if you +have two virtual groups that have a component group in common. If +that's the case, you should set this variable to @code{t}. Or you can +just tap @code{M-g} on the virtual group every time before you enter +it---it'll have much the same effect. @code{nnvirtual} can have both mail and news groups as component groups. When responding to articles in @code{nnvirtual} groups, @code{nnvirtual} @@ -17684,6 +17942,381 @@ Articles marked as read in the @code{nnkiboze} group will have their @acronym{NOV} lines removed from the @acronym{NOV} file. +@node Email Based Diary +@section Email Based Diary +@cindex diary +@cindex email based diary +@cindex calendar + +This section describes a special mail back end called @code{nndiary}, +and its companion library @code{gnus-diary}. It is ``special'' in the +sense that it is not meant to be one of the standard alternatives for +reading mail with Gnus. See @ref{Choosing a Mail Back End} for that. +Instead, it is used to treat @emph{some} of your mails in a special way, +namely, as event reminders. + +Here is a typical scenario: + +@itemize @bullet +@item +You've got a date with Andy Mc Dowell or Bruce Willis (select according +to your sexual preference) in one month. You don't want to forget it. +@item +So you send a ``reminder'' message (actually, a diary one) to yourself. +@item +You forget all about it and keep on getting and reading new mail, as usual. +@item +From time to time, as you type `g' in the group buffer and as the date +is getting closer, the message will pop up again to remind you of your +appointment, just as if it were new and unread. +@item +Read your ``new'' messages, this one included, and start dreaming again +of the night you're gonna have. +@item +Once the date is over (you actually fell asleep just after dinner), the +message will be automatically deleted if it is marked as expirable. +@end itemize + +The Gnus Diary back end has the ability to handle regular appointments +(that wouldn't ever be deleted) as well as punctual ones, operates as a +real mail back end and is configurable in many ways. All of this is +explained in the sections below. + +@menu +* The NNDiary Back End:: Basic setup and usage. +* The Gnus Diary Library:: Utility toolkit on top of nndiary. +* Sending or Not Sending:: A final note on sending diary messages. +@end menu + + +@node The NNDiary Back End +@subsection The NNDiary Back End +@cindex nndiary +@cindex the nndiary back end + +@code{nndiary} is a back end very similar to @code{nnml} (@pxref{Mail +Spool}). Actually, it could appear as a mix of @code{nnml} and +@code{nndraft}. If you know @code{nnml}, you're already familiar with +the message storing scheme of @code{nndiary}: one file per message, one +directory per group. + + Before anything, there is one requirement to be able to run +@code{nndiary} properly: you @emph{must} use the group timestamp feature +of Gnus. This adds a timestamp to each group's parameters. @ref{Group +Timestamp} to see how it's done. + +@menu +* Diary Messages:: What makes a message valid for nndiary. +* Running NNDiary:: NNDiary has two modes of operation. +* Customizing NNDiary:: Bells and whistles. +@end menu + +@node Diary Messages +@subsubsection Diary Messages +@cindex nndiary messages +@cindex nndiary mails + +@code{nndiary} messages are just normal ones, except for the mandatory +presence of 7 special headers. These headers are of the form +@code{X-Diary-}, @code{} being one of +@code{Minute}, @code{Hour}, @code{Dom}, @code{Month}, @code{Year}, +@code{Time-Zone} and @code{Dow}. @code{Dom} means ``Day of Month'', and +@code{dow} means ``Day of Week''. These headers actually behave like +crontab specifications and define the event date(s): + +@itemize @bullet +@item +For all headers except the @code{Time-Zone} one, a header value is +either a star (meaning all possible values), or a list of fields +(separated by a comma). +@item +A field is either an integer, or a range. +@item +A range is two integers separated by a dash. +@item +Possible integer values are 0--59 for @code{Minute}, 0--23 for +@code{Hour}, 1--31 for @code{Dom}, 1--12 for @code{Month}, above 1971 +for @code{Year} and 0--6 for @code{Dow} (0 meaning Sunday). +@item +As a special case, a star in either @code{Dom} or @code{Dow} doesn't +mean ``all possible values'', but ``use only the other field''. Note +that if both are star'ed, the use of either one gives the same result. +@item +The @code{Time-Zone} header is special in that it can only have one +value (@code{GMT}, for instance). A star doesn't mean ``all possible +values'' (because it makes no sense), but ``the current local time +zone''. Most of the time, you'll be using a star here. However, for a +list of available time zone values, see the variable +@code{nndiary-headers}. +@end itemize + +As a concrete example, here are the diary headers to add to your message +for specifying ``Each Monday and each 1st of month, at 12:00, 20:00, +21:00, 22:00, 23:00 and 24:00, from 1999 to 2010'' (I'll let you find +what to do then): + +@example +X-Diary-Minute: 0 +X-Diary-Hour: 12, 20-24 +X-Diary-Dom: 1 +X-Diary-Month: * +X-Diary-Year: 1999-2010 +X-Diary-Dow: 1 +X-Diary-Time-Zone: * +@end example + +@node Running NNDiary +@subsubsection Running NNDiary +@cindex running nndiary +@cindex nndiary operation modes + +@code{nndiary} has two modes of operation: ``traditional'' (the default) +and ``autonomous''. In traditional mode, @code{nndiary} does not get new +mail by itself. You have to move (@kbd{B m}) or copy (@kbd{B c}) mails +from your primary mail back end to nndiary groups in order to handle them +as diary messages. In autonomous mode, @code{nndiary} retrieves its own +mail and handles it independently from your primary mail back end. + +One should note that Gnus is not inherently designed to allow several +``master'' mail back ends at the same time. However, this does make +sense with @code{nndiary}: you really want to send and receive diary +messages to your diary groups directly. So, @code{nndiary} supports +being sort of a ``second primary mail back end'' (to my knowledge, it is +the only back end offering this feature). However, there is a limitation +(which I hope to fix some day): respooling doesn't work in autonomous +mode. + +In order to use @code{nndiary} in autonomous mode, you have several +things to do: + +@itemize @bullet +@item +Allow @code{nndiary} to retrieve new mail by itself. Put the following +line in your @file{gnusrc} file: + +@lisp +(setq nndiary-get-new-mail t) +@end lisp +@item +You must arrange for diary messages (those containing @code{X-Diary-*} +headers) to be split in a private folder @emph{before} Gnus treat them. +Again, this is needed because Gnus cannot (yet ?) properly handle +multiple primary mail back ends. Getting those messages from a separate +source will compensate this misfeature to some extent. + +As an example, here's my procmailrc entry to store diary files in +@file{~/.nndiary} (the default @code{nndiary} mail source file): + +@example +:0 HD : +* ^X-Diary +.nndiary +@end example +@end itemize + +Once this is done, you might want to customize the following two options +that affect the diary mail retrieval and splitting processes: + +@defvar nndiary-mail-sources +This is the diary-specific replacement for the standard +@code{mail-sources} variable. It obeys the same syntax, and defaults to +@code{(file :path "~/.nndiary")}. +@end defvar + +@defvar nndiary-split-methods +This is the diary-specific replacement for the standard +@code{nnmail-split-methods} variable. It obeys the same syntax. +@end defvar + + Finally, you may add a permanent @code{nndiary} virtual server +(something like @code{(nndiary "diary")} should do) to your +@code{gnus-secondary-select-methods}. + + Hopefully, almost everything (see the TODO section in +@file{nndiary.el}) will work as expected when you restart Gnus: in +autonomous mode, typing @kbd{g} and @kbd{M-g} in the group buffer, will +also get your new diary mails and split them according to your +diary-specific rules, @kbd{F} will find your new diary groups etc. + +@node Customizing NNDiary +@subsubsection Customizing NNDiary +@cindex customizing nndiary +@cindex nndiary customization + +Now that @code{nndiary} is up and running, it's time to customize it. +The custom group is called @code{nndiary} (no, really ?!). You should +browse it to figure out which options you'd like to tweak. The following +two variables are probably the only ones you will want to change: + +@defvar nndiary-reminders +This is the list of times when you want to be reminded of your +appointements (e.g. 3 weeks before, then 2 days before, then 1 hour +before and that's it). Remember that ``being reminded'' means that the +diary message will pop up as brand new and unread again when you get new +mail. +@end defvar + +@defvar nndiary-week-starts-on-monday +Rather self-explanatory. Otherwise, Sunday is assumed (this is the +default). +@end defvar + + +@node The Gnus Diary Library +@subsection The Gnus Diary Library +@cindex gnus-diary +@cindex the gnus diary library + +Using @code{nndiary} manually (I mean, writing the headers by hand and +so on) would be rather boring. Fortunately, there is a library called +@code{gnus-diary} written on top of @code{nndiary}, that does many +useful things for you. + + In order to use it, add the following line to your @file{gnusrc} file: + +@lisp +(require 'gnus-diary) +@end lisp + + Also, you shouldn't use any @code{gnus-user-format-function-[d|D]} +(@pxref{Summary Buffer Lines}). @code{gnus-diary} provides both of these +(sorry if you used them before). + + +@menu +* Diary Summary Line Format:: A nicer summary buffer line format. +* Diary Articles Sorting:: A nicer way to sort messages. +* Diary Headers Generation:: Not doing it manually. +* Diary Group Parameters:: Not handling them manually. +@end menu + +@node Diary Summary Line Format +@subsubsection Diary Summary Line Format +@cindex diary summary buffer line +@cindex diary summary line format + +Displaying diary messages in standard summary line format (usually +something like @samp{From Joe: Subject}) is pretty useless. Most of +the time, you're the one who wrote the message, and you mostly want to +see the event's date. + + @code{gnus-diary} provides two supplemental user formats to be used in +summary line formats. @code{D} corresponds to a formatted time string +for the next occurrence of the event (e.g. ``Sat, Sep 22 01, 12:00''), +while @code{d} corresponds to an approximative remaining time until the +next occurrence of the event (e.g. ``in 6 months, 1 week''). + + For example, here's how Joe's birthday is displayed in my +@code{nndiary+diary:birthdays} summary buffer (note that the message is +expirable, but will never be deleted, as it specifies a periodic event): + +@example + E Sat, Sep 22 01, 12:00: Joe's birthday (in 6 months, 1 week) +@end example + +In order to get something like the above, you would normally add the +following line to your diary groups'parameters: + +@lisp +(gnus-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n") +@end lisp + +However, @code{gnus-diary} does it automatically (@pxref{Diary Group +Parameters}). You can however customize the provided summary line format +with the following user options: + +@defvar gnus-diary-summary-line-format +Defines the summary line format used for diary groups (@pxref{Summary +Buffer Lines}). @code{gnus-diary} uses it to automatically update the +diary groups'parameters. +@end defvar + +@defvar gnus-diary-time-format +Defines the format to display dates in diary summary buffers. This is +used by the @code{D} user format. See the docstring for details. +@end defvar + +@defvar gnus-diary-delay-format-function +Defines the format function to use for displaying delays (remaining +times) in diary summary buffers. This is used by the @code{d} user +format. There are currently built-in functions for English and French; +you can also define your own. See the docstring for details. +@end defvar + +@node Diary Articles Sorting +@subsubsection Diary Articles Sorting +@cindex diary articles sorting +@cindex diary summary lines sorting +@findex gnus-summary-sort-by-schedule +@findex gnus-thread-sort-by-schedule +@findex gnus-article-sort-by-schedule + +@code{gnus-diary} provides new sorting functions (@pxref{Sorting the +Summary Buffer} ) called @code{gnus-summary-sort-by-schedule}, +@code{gnus-thread-sort-by-schedule} and +@code{gnus-article-sort-by-schedule}. These functions let you organize +your diary summary buffers from the closest event to the farthest one. + +@code{gnus-diary} automatically installs +@code{gnus-summary-sort-by-schedule} as a menu item in the summary +buffer's ``sort'' menu, and the two others as the primary (hence +default) sorting functions in the group parameters (@pxref{Diary Group +Parameters}). + +@node Diary Headers Generation +@subsubsection Diary Headers Generation +@cindex diary headers generation +@findex gnus-diary-check-message + +@code{gnus-diary} provides a function called +@code{gnus-diary-check-message} to help you handle the @code{X-Diary-*} +headers. This function ensures that the current message contains all the +required diary headers, and prompts you for values or corrections if +needed. + + This function is hooked into the @code{nndiary} back end, so that +moving or copying an article to a diary group will trigger it +automatically. It is also bound to @kbd{C-c D c} in @code{message-mode} +and @code{article-edit-mode} in order to ease the process of converting +a usual mail to a diary one. + + This function takes a prefix argument which will force prompting of +all diary headers, regardless of their presence or validity. That way, +you can very easily reschedule an already valid diary message, for +instance. + +@node Diary Group Parameters +@subsubsection Diary Group Parameters +@cindex diary group parameters + +When you create a new diary group, or visit one, @code{gnus-diary} +automatically checks your group parameters and if needed, sets the +summary line format to the diary-specific value, installs the +diary-specific sorting functions, and also adds the different +@code{X-Diary-*} headers to the group's posting-style. It is then easier +to send a diary message, because if you use @kbd{C-u a} or @kbd{C-u m} +on a diary group to prepare a message, these headers will be inserted +automatically (although not filled with proper values yet). + +@node Sending or Not Sending +@subsection Sending or Not Sending + +Well, assuming you've read of of the above, here are two final notes on +mail sending with @code{nndiary}: + +@itemize @bullet +@item +@code{nndiary} is a @emph{real} mail back end. You really send real diary +messsages for real. This means for instance that you can give +appointements to anybody (provided they use Gnus and @code{nndiary}) by +sending the diary message to them as well. +@item +However, since @code{nndiary} also has a @code{request-post} method, you +can also use @kbd{C-u a} instead of @kbd{C-u m} on a diary group and the +message won't actually be sent; just stored locally in the group. This +comes in very handy for private appointments. +@end itemize + @node Gnus Unplugged @section Gnus Unplugged @cindex offline @@ -17723,6 +18356,7 @@ Of course, to use it as such, you have to learn a few new commands. * Agent as Cache:: The Agent is a big cache too. * Agent Expiry:: How to make old articles go away. * Agent Regeneration:: How to recover from lost connections and other accidents. +* Agent and flags:: How the Agent maintains flags. * Agent and IMAP:: How to use the Agent with @acronym{IMAP}. * Outgoing Messages:: What happens when you post/mail something? * Agent Variables:: Customizing is fun. @@ -17887,9 +18521,6 @@ listed below. @cindex Agent Parameters @table @code -@item agent-cat-name -The name of the category. - @item agent-groups The list of groups that are in this category. @@ -17897,7 +18528,7 @@ The list of groups that are in this category. A predicate which (generally) gives a rough outline of which articles are eligible for downloading; and -@item agent-score-file +@item agent-score a score rule which (generally) gives you a finer granularity when deciding what articles to download. (Note that this @dfn{download score} is not necessarily related to normal scores.) @@ -17918,11 +18549,11 @@ an integer that overrides the value of @code{gnus-agent-low-score}. @item agent-high-score an integer that overrides the value of @code{gnus-agent-high-score}. -@item agent-length-when-short +@item agent-short-article an integer that overrides the value of @code{gnus-agent-short-article}. -@item agent-length-when-long +@item agent-long-article an integer that overrides the value of @code{gnus-agent-long-article}. @item agent-enable-undownloaded-faces @@ -18434,9 +19065,9 @@ Download all eligible (@pxref{Agent Categories}) articles in this group. @item J s @kindex J s (Agent Summary) -@findex gnus-agent-fetch-series +@findex gnus-agent-summary-fetch-series Download all processable articles in this group. -(@code{gnus-agent-fetch-series}). +(@code{gnus-agent-summary-fetch-series}). @item J u @kindex J u (Agent Summary) @@ -18521,10 +19152,10 @@ normal faces will be obscured by the undownloaded faces. If you would like to use the undownloaded faces, you must enable the undownloaded faces by setting the @code{agent-enable-undownloaded-faces} -group parameter to t. This parameter, like all other agent -parameters, may be set on an Agent Category (@pxref{Agent -Categories}), a Group Topic (@pxref{Topic Parameters}), or an -individual group (@pxref{Group Parameters}). +group parameter to @code{t}. This parameter, like all other agent +parameters, may be set on an Agent Category (@pxref{Agent Categories}), +a Group Topic (@pxref{Topic Parameters}), or an individual group +(@pxref{Group Parameters}). The one problem common to all users using the agent is how quickly it can consume disk space. If you using the agent on many groups, it is @@ -18629,23 +19260,19 @@ then updates the internal data structures that document which articles are stored locally. An optional argument will mark articles in the agent as unread. -@node Agent and IMAP -@subsection Agent and IMAP +@node Agent and flags +@subsection Agent and flags -The Agent works with any Gnus back end, including nnimap. However, -since there are some conceptual differences between @acronym{NNTP} and -@acronym{IMAP}, this section (should) provide you with some information to -make Gnus Agent work smoother as a @acronym{IMAP} Disconnected Mode client. +The Agent works with any Gnus back end including those, such as +nnimap, that store flags (read, ticked, etc) on the server. Sadly, +the Agent does not actually know which backends keep their flags in +the backend server rather than in @file{.newsrc}. This means that the +Agent, while unplugged or disconnected, will always record all changes +to the flags in its own files. -The first thing to keep in mind is that all flags (read, ticked, etc) -are kept on the @acronym{IMAP} server, rather than in @file{.newsrc} as is the -case for nntp. Thus Gnus need to remember flag changes when -disconnected, and synchronize these flags when you plug back in. - -Gnus keeps track of flag changes when reading nnimap groups under the -Agent. When you plug back in, Gnus will check if you have any changed -any flags and ask if you wish to synchronize these with the server. -The behavior is customizable by @code{gnus-agent-synchronize-flags}. +When you plug back in, Gnus will then check to see if you have any +changed any flags and ask if you wish to synchronize these with the +server. This behavior is customizable by @code{gnus-agent-synchronize-flags}. @vindex gnus-agent-synchronize-flags If @code{gnus-agent-synchronize-flags} is @code{nil}, the Agent will @@ -18659,6 +19286,23 @@ re-connect, you can do it manually with the @code{gnus-agent-synchronize-flags} command that is bound to @kbd{J Y} in the group buffer. +Technical note: the synchronization algorithm does not work by ``pushing'' +all local flags to the server, but rather by incrementally updated the +server view of flags by changing only those flags that were changed by +the user. Thus, if you set one flag on an article, quit the group then +re-select the group and remove the flag; the flag will be set and +removed from the server when you ``synchronize''. The queued flag +operations can be found in the per-server @code{flags} file in the Agent +directory. It's emptied when you synchronize flags. + +@node Agent and IMAP +@subsection Agent and IMAP + +The Agent works with any Gnus back end, including nnimap. However, +since there are some conceptual differences between @acronym{NNTP} and +@acronym{IMAP}, this section (should) provide you with some information to +make Gnus Agent work smoother as a @acronym{IMAP} Disconnected Mode client. + Some things are currently not implemented in the Agent that you'd might expect from a disconnected @acronym{IMAP} client, including: @@ -18672,16 +19316,6 @@ Creating/deleting nnimap groups when unplugged. @end itemize -Technical note: the synchronization algorithm does not work by ``pushing'' -all local flags to the server, but rather incrementally update the -server view of flags by changing only those flags that were changed by -the user. Thus, if you set one flag on an article, quit the group and -re-select the group and remove the flag; the flag will be set and -removed from the server when you ``synchronize''. The queued flag -operations can be found in the per-server @code{flags} file in the Agent -directory. It's emptied when you synchronize flags. - - @node Outgoing Messages @subsection Outgoing Messages @@ -18763,7 +19397,15 @@ online status. If @code{gnus-agent-mark-unread-after-downloaded} is non-@code{nil}, mark articles as unread after downloading. This is usually a safe thing to do as the newly downloaded article has obviously not been -read. The default is t. +read. The default is @code{t}. + +@item gnus-agent-synchronize-flags +@vindex gnus-agent-synchronize-flags +If @code{gnus-agent-synchronize-flags} is @code{nil}, the Agent will +never automatically synchronize flags. If it is @code{ask}, which is +the default, the Agent will check if you made any changes and if so +ask if you wish to synchronize these when you re-connect. If it has +any other value, all flags will be synchronized automatically. @item gnus-agent-consider-all-articles @vindex gnus-agent-consider-all-articles @@ -18914,7 +19556,7 @@ may ask: @table @dfn @item If I read an article while plugged, do they get entered into the Agent? -@strong{No}. If you want this behaviour, add +@strong{No}. If you want this behavior, add @code{gnus-agent-fetch-selected-article} to @code{gnus-select-article-hook}. @@ -19959,7 +20601,8 @@ group name, the @var{file-name} will be used as the home score file. @item A function. If the function returns non-@code{nil}, the result will -be used as the home score file. +be used as the home score file. The function will be called with the +name of the group as the parameter. @item A string. Use the string as the home score file. @@ -20497,8 +21140,19 @@ very interesting: 1000) @end example -The possibilities are endless. +Suppose you're reading a high volume group and you're only interested +in replies. The plan is to score down all articles that don't have +subject that begin with "Re:", "Fw:" or "Fwd:" and then score up all +parents of articles that have subjects that begin with reply marks. +@example +((! ("subject" "re:\\|fwd?:" r)) + -200) +((1- ("subject" "re:\\|fwd?:" r)) + 200) +@end example + +The possibilities are endless. @node Advanced Scoring Tips @subsection Advanced Scoring Tips @@ -21016,7 +21670,7 @@ mode-line variables. Gnus usually moves point to a pre-defined place on each line in most buffers. By default, point move to the first colon character on the -line. You can customize this behaviour in three different ways. +line. You can customize this behavior in three different ways. You can move the colon character to somewhere else on the line. @@ -21701,6 +22355,15 @@ There are some variables to customize, of course: Set this variable to @code{t} to set the ball rolling. It is @code{nil} by default. +You can also set this variable to a positive number as a group level. +In that case, Gnus scans NoCeM messages when checking new news if this +value is not exceeding a group level that you specify as the prefix +argument to some commands, e.g. @code{gnus}, +@code{gnus-group-get-new-news}, etc. Otherwise, Gnus does not scan +NoCeM messages if you specify a group level to those commands. For +example, if you use 1 or 2 on the mail groups and the levels on the news +groups remain the default, 3 is the best choice. + @item gnus-nocem-groups @vindex gnus-nocem-groups Gnus will look for NoCeM messages in the groups in this list. The @@ -21753,27 +22416,18 @@ The specs are applied left-to-right. @item gnus-nocem-verifyer @vindex gnus-nocem-verifyer -@findex mc-verify +@findex pgg-verify This should be a function for verifying that the NoCeM issuer is who she -says she is. The default is @code{mc-verify}, which is a Mailcrypt -function. If this is too slow and you don't care for verification -(which may be dangerous), you can set this variable to @code{nil}. +says she is. The default is @code{pgg-verify}, which returns +non-@code{nil} if the verification is successful, otherwise (including +the case the NoCeM message was not signed) returns @code{nil}. If this +is too slow and you don't care for verification (which may be dangerous), +you can set this variable to @code{nil}. -If you want signed NoCeM messages to be verified and unsigned messages -not to be verified (but used anyway), you could do something like: - -@lisp -(setq gnus-nocem-verifyer 'my-gnus-mc-verify) - -(defun my-gnus-mc-verify () - (not (eq 'forged - (ignore-errors - (if (mc-verify) - t - 'forged))))) -@end lisp - -This might be dangerous, though. +Formerly the default was @code{mc-verify}, which is a Mailcrypt +function. While you can still use it, you can change it into +@code{pgg-verify} running with GnuPG if you are willing to add the +@acronym{PGP} public keys to GnuPG's keyring. @item gnus-nocem-directory @vindex gnus-nocem-directory @@ -21963,10 +22617,20 @@ readers. @end iftex @c @anchor{X-Face} -Decoding an @code{X-Face} header either requires an Emacs that has +Viewing an @code{X-Face} header either requires an Emacs that has @samp{compface} support (which most XEmacs versions has), or that you -have @samp{compface} installed on your system. If either is true, -Gnus will default to displaying @code{X-Face} headers. +have suitable conversion or display programs installed. If your Emacs +has image support the default action is to display the face before the +@code{From} header. If there's no native @code{X-Face} support, Gnus +will try to convert the @code{X-Face} header using external programs +from the @code{pbmplus} package and friends. For XEmacs it's faster if +XEmacs has been compiled with @code{X-Face} support. The default action +under Emacs without image support is to fork off the @code{display} +program. + +On a GNU/Linux system, the @code{display} program is from the +ImageMagick package. For external conversion programs look for packages +with names like @code{netpbm}, @code{libgr-progs} and @code{compface}. The variable that controls this is the @code{gnus-article-x-face-command} variable. If this variable is a @@ -21975,21 +22639,6 @@ function, this function will be called with the face as the argument. If the @code{gnus-article-x-face-too-ugly} (which is a regexp) matches the @code{From} header, the face will not be shown. -The default action under Emacs 20 is to fork off the @code{display} -program@footnote{@code{display} is from the ImageMagick package. For -the @code{uncompface} and @code{icontopbm} programs look for a package -like @code{compface} or @code{faces-xface} on a GNU/Linux system.} to -view the face. - -Under XEmacs or Emacs 21+ with suitable image support, the default -action is to display the face before the @code{From} header. (It's -nicer if XEmacs has been compiled with @code{X-Face} support---that -will make display somewhat faster. If there's no native @code{X-Face} -support, Gnus will try to convert the @code{X-Face} header using -external programs from the @code{pbmplus} package and -friends.@footnote{On a GNU/Linux system look for packages with names -like @code{netpbm}, @code{libgr-progs} and @code{compface}.}) - (Note: @code{x-face} is used in the variable/function names, not @code{xface}). @@ -22030,8 +22679,12 @@ on the @code{xface} image type in XEmacs if it is built with the @samp{libcompface} library. @end table -Gnus provides a few convenience functions and variables to allow -easier insertion of X-Face headers in outgoing messages. +If you use posting styles, you can use an @code{x-face-file} entry in +@code{gnus-posting-styles}, @xref{Posting Styles}. If you don't, Gnus +provides a few convenience functions and variables to allow easier +insertion of X-Face headers in outgoing messages. You also need the +above mentioned ImageMagick, netpbm or other image conversion packages +(depending the values of the variables below) for these functions. @findex gnus-random-x-face @vindex gnus-convert-pbm-to-x-face-command @@ -22078,7 +22731,7 @@ Using the last function would be something like this: @subsection Face @cindex face -@c #### FIXME: faces and x-faces'implementations should really be harmonized. +@c #### FIXME: faces and x-faces' implementations should really be harmonized. @code{Face} headers are essentially a funkier version of @code{X-Face} ones. They describe a 48x48 pixel colored image that's supposed to @@ -22093,6 +22746,13 @@ specifications. The @code{gnus-face-properties-alist} variable affects the appearance of displayed Face images. @xref{X-Face}. +Viewing an @code{Face} header requires an Emacs that is able to display +PNG images. +@c Maybe add this: +@c (if (featurep 'xemacs) +@c (featurep 'png) +@c (image-type-available-p 'png)) + Gnus provides a few convenience functions and variables to allow easier insertion of Face headers in outgoing messages. @@ -22259,18 +22919,6 @@ This is where Gnus will look for pictures. Gnus will normally auto-detect this directory, but you may set it manually if you have an unusual directory structure. -@item gnus-xmas-logo-color-alist -@vindex gnus-xmas-logo-color-alist -This is an alist where the key is a type symbol and the values are the -foreground and background color of the splash page glyph. - -@item gnus-xmas-logo-color-style -@vindex gnus-xmas-logo-color-style -This is the key used to look up the color in the alist described above. -Valid values include @code{flame}, @code{pine}, @code{moss}, -@code{irish}, @code{sky}, @code{tin}, @code{velvet}, @code{grape}, -@code{labia}, @code{berry}, @code{neutral}, and @code{september}. - @item gnus-xmas-modeline-glyph @vindex gnus-xmas-modeline-glyph A glyph displayed in all Gnus mode lines. It is a tiny gnu head by @@ -22284,9 +22932,19 @@ default. @item gnus-use-toolbar @vindex gnus-use-toolbar -If @code{nil}, don't display toolbars. If non-@code{nil}, it should be -one of @code{default-toolbar}, @code{top-toolbar}, @code{bottom-toolbar}, -@code{right-toolbar}, or @code{left-toolbar}. +This variable specifies the position to display the toolbar. If +@code{nil}, don't display toolbars. If it is non-@code{nil}, it should +be one of the symbols @code{default}, @code{top}, @code{bottom}, +@code{right}, and @code{left}. @code{default} means to use the default +toolbar, the rest mean to display the toolbar on the place which those +names show. The default is @code{default}. + +@item gnus-toolbar-thickness +@vindex gnus-toolbar-thickness +Cons of the height and the width specifying the thickness of a toolbar. +The height is used for the toolbar displayed on the top or the bottom, +the width is used for the toolbar displayed on the right or the left. +The default is that of the default toolbar. @item gnus-group-toolbar @vindex gnus-group-toolbar @@ -22399,7 +23057,7 @@ messages per day from @samp{random-address@@vmadmin.com}, you block @samp{vmadmin.com}. If you get 200 messages about @samp{VIAGRA}, you discard all messages with @samp{VIAGRA} in the message. If you get lots of spam from Bulgaria, for example, you try to filter all mail -from Bulgarian IPs. +from Bulgarian IPs. This, unfortunately, is a great way to discard legitimate e-mail. The risks of blocking a whole country (Bulgaria, Norway, Nigeria, China, @@ -22748,24 +23406,24 @@ variables. Try @code{customize-group} on the @samp{spam} variable group. @menu -* Spam ELisp Package Sequence of Events:: -* Spam ELisp Package Filtering of Incoming Mail:: -* Spam ELisp Package Global Variables:: -* Spam ELisp Package Sorting and Score Display in Summary Buffer:: -* Spam ELisp Package Configuration Examples:: -* Blacklists and Whitelists:: -* BBDB Whitelists:: -* Gmane Spam Reporting:: -* Anti-spam Hashcash Payments:: -* Blackholes:: -* Regular Expressions Header Matching:: -* Bogofilter:: -* SpamAssassin back end:: -* ifile spam filtering:: -* spam-stat spam filtering:: -* SpamOracle:: -* Extending the Spam ELisp package:: -@end menu +* Spam ELisp Package Sequence of Events:: +* Spam ELisp Package Filtering of Incoming Mail:: +* Spam ELisp Package Global Variables:: +* Spam ELisp Package Sorting and Score Display in Summary Buffer:: +* Spam ELisp Package Configuration Examples:: +* Blacklists and Whitelists:: +* BBDB Whitelists:: +* Gmane Spam Reporting:: +* Anti-spam Hashcash Payments:: +* Blackholes:: +* Regular Expressions Header Matching:: +* Bogofilter:: +* SpamAssassin back end:: +* ifile spam filtering:: +* spam-stat spam filtering:: +* SpamOracle:: +* Extending the Spam ELisp package:: +@end menu @node Spam ELisp Package Sequence of Events @subsubsection Spam ELisp Package Sequence of Events @@ -23179,7 +23837,7 @@ Now just set your summary line format to use @code{%uS}. Here's an example that formats the spam score in a 5-character field: @lisp -(setq gnus-summary-line-format +(setq gnus-summary-line-format "%U%R %10&user-date; $%5uS %6k %B %(%4L: %*%-25,25a%) %s \n") @end lisp @@ -23269,7 +23927,7 @@ From Ted Zlatanov . ;; @r{any ham goes to my @samp{nnimap+mail.lifelogs.com:mail} folder, but} ;; @r{also to my @samp{nnimap+mail.lifelogs.com:trainham} folder for training} - (ham-process-destination "nnimap+mail.lifelogs.com:mail" + (ham-process-destination "nnimap+mail.lifelogs.com:mail" "nnimap+mail.lifelogs.com:trainham") ;; @r{in this group, only @samp{!} marks are ham} (ham-marks @@ -23310,7 +23968,7 @@ does most of the job for me: (spam-contents gnus-group-spam-classification-ham)) @end lisp -@itemize +@itemize @item @b{The Spam folder:} @@ -23403,11 +24061,11 @@ customizing the group parameters or the added to a group's @code{spam-process} parameter, the senders of spam-marked articles will be added to the blacklist. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-spam-exit-processor-blacklist}, it is recommended -that you use @code{'(spam spam-use-blacklist)}. Everything will work +that you use @code{(spam spam-use-blacklist)}. Everything will work the same way, we promise. @end defvar @@ -23421,11 +24079,11 @@ added to a group's @code{spam-process} parameter, the senders of ham-marked articles in @emph{ham} groups will be added to the whitelist. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-ham-exit-processor-whitelist}, it is recommended -that you use @code{'(ham spam-use-whitelist)}. Everything will work +that you use @code{(ham spam-use-whitelist)}. Everything will work the same way, we promise. @end defvar @@ -23492,11 +24150,11 @@ added to a group's @code{spam-process} parameter, the senders of ham-marked articles in @emph{ham} groups will be added to the BBDB. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-ham-exit-processor-BBDB}, it is recommended -that you use @code{'(ham spam-use-BBDB)}. Everything will work +that you use @code{(ham spam-use-BBDB)}. Everything will work the same way, we promise. @end defvar @@ -23519,11 +24177,11 @@ HTTP request. Gmane can be found at @uref{http://gmane.org}. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-spam-exit-processor-report-gmane}, it is recommended -that you use @code{'(spam spam-use-gmane)}. Everything will work the +that you use @code{(spam spam-use-gmane)}. Everything will work the same way, we promise. @end defvar @@ -23534,8 +24192,15 @@ This variable is @code{t} by default. Set it to @code{nil} if you are running your own news server, for instance, and the local article numbers don't correspond to the Gmane article numbers. When @code{spam-report-gmane-use-article-number} is @code{nil}, -@code{spam-report.el} will use the @code{X-Report-Spam} header that -Gmane provides. +@code{spam-report.el} will fetch the number from the article headers. + +@end defvar + +@defvar spam-report-user-mail-address + +Mail address exposed in the User-Agent spam reports to Gmane. It allows +the Gmane administrators to contact you in case of misreports. The +default is @code{user-mail-address}. @end defvar @@ -23686,11 +24351,11 @@ customizing the group parameters or the added to a group's @code{spam-process} parameter, spam-marked articles will be added to the Bogofilter spam database. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-spam-exit-processor-bogofilter}, it is recommended -that you use @code{'(spam spam-use-bogofilter)}. Everything will work +that you use @code{(spam spam-use-bogofilter)}. Everything will work the same way, we promise. @end defvar @@ -23702,11 +24367,11 @@ added to a group's @code{spam-process} parameter, the ham-marked articles in @emph{ham} groups will be added to the Bogofilter database of non-spam messages. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-ham-exit-processor-bogofilter}, it is recommended -that you use @code{'(ham spam-use-bogofilter)}. Everything will work +that you use @code{(ham spam-use-bogofilter)}. Everything will work the same way, we promise. @end defvar @@ -23842,11 +24507,11 @@ customizing the group parameters or the added to a group's @code{spam-process} parameter, the spam-marked articles will be added to the spam-stat database of spam messages. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-spam-exit-processor-stat}, it is recommended -that you use @code{'(spam spam-use-stat)}. Everything will work +that you use @code{(spam spam-use-stat)}. Everything will work the same way, we promise. @end defvar @@ -23858,11 +24523,11 @@ added to a group's @code{spam-process} parameter, the ham-marked articles in @emph{ham} groups will be added to the spam-stat database of non-spam messages. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-ham-exit-processor-stat}, it is recommended -that you use @code{'(ham spam-use-stat)}. Everything will work +that you use @code{(ham spam-use-stat)}. Everything will work the same way, we promise. @end defvar @@ -23950,11 +24615,11 @@ customizing the group parameter or the to a group's @code{spam-process} parameter, spam-marked articles will be sent to SpamOracle as spam samples. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-spam-exit-processor-spamoracle}, it is recommended -that you use @code{'(spam spam-use-spamoracle)}. Everything will work +that you use @code{(spam spam-use-spamoracle)}. Everything will work the same way, we promise. @end defvar @@ -23966,11 +24631,11 @@ to a group's @code{spam-process} parameter, the ham-marked articles in @emph{ham} groups will be sent to the SpamOracle as samples of ham messages. -@emph{WARNING} +@emph{WARNING} Instead of the obsolete @code{gnus-group-ham-exit-processor-spamoracle}, it is recommended -that you use @code{'(ham spam-use-spamoracle)}. Everything will work +that you use @code{(ham spam-use-spamoracle)}. Everything will work the same way, we promise. @end defvar @@ -24038,8 +24703,8 @@ Note you don't have to provide a spam or a ham processor. Only provide them if Blackbox supports spam or ham processing. Also, ham and spam processors are being phased out as single -variables. Instead the form @code{'(spam spam-use-blackbox)} or -@code{'(ham spam-use-blackbox)} is favored. For now, spam/ham +variables. Instead the form @code{(spam spam-use-blackbox)} or +@code{(ham spam-use-blackbox)} is favored. For now, spam/ham processor variables are still around but they won't be for long. @lisp @@ -24483,7 +25148,7 @@ to the Gnus back ends instead of Gnus proper. @item nnheader-max-head-length @vindex nnheader-max-head-length When the back ends read straight heads of articles, they all try to read -as little as possible. This variable (default 4096) specifies +as little as possible. This variable (default 8192) specifies the absolute max length the back ends will try to read before giving up on finding a separator line between the head and the body. If this variable is @code{nil}, there is no upper read bound. If it is @@ -24600,7 +25265,7 @@ XEmacs is distributed as a collection of packages. You should install whatever packages the Gnus XEmacs package requires. The current requirements are @samp{gnus}, @samp{mail-lib}, @samp{xemacs-base}, @samp{eterm}, @samp{sh-script}, @samp{net-utils}, @samp{os-utils}, -@samp{dired}, @samp{mh-e}, @samp{sieve}, @samp{ps-print}, @samp{w3}, +@samp{dired}, @samp{mh-e}, @samp{sieve}, @samp{ps-print}, @samp{W3}, @samp{pgg}, @samp{mailcrypt}, @samp{ecrypto}, and @samp{sasl}. @@ -24664,20 +25329,23 @@ On July 28th 1996 work on Red Gnus was begun, and it was released on January 25th 1997 (after 84 releases) as ``Gnus 5.4'' (67 releases). On September 13th 1997, Quassia Gnus was started and lasted 37 releases. -If was released as ``Gnus 5.6'' on March 8th 1998 (46 releases). +It was released as ``Gnus 5.6'' on March 8th 1998 (46 releases). Gnus 5.6 begat Pterodactyl Gnus on August 29th 1998 and was released as ``Gnus 5.8'' (after 99 releases and a CVS repository) on December 3rd 1999. -On the 26th of October 2000, Oort Gnus was begun. +On the 26th of October 2000, Oort Gnus was begun and was released as +Gnus 5.10 on May 1st 2003 (24 releases). + +On the January 4th 2004, No Gnus was begun. If you happen upon a version of Gnus that has a prefixed name -- ``(ding) Gnus'', ``September Gnus'', ``Red Gnus'', ``Quassia Gnus'', -``Pterodactyl Gnus'', ``Oort Gnus'' -- don't panic. Don't let it know -that you're frightened. Back away. Slowly. Whatever you do, don't -run. Walk away, calmly, until you're out of its reach. Find a proper -released version of Gnus and snuggle up to that instead. +``Pterodactyl Gnus'', ``Oort Gnus'', ``No Gnus'' -- don't panic. +Don't let it know that you're frightened. Back away. Slowly. Whatever +you do, don't run. Walk away, calmly, until you're out of its reach. +Find a proper released version of Gnus and snuggle up to that instead. @node Other Gnus Versions @@ -24855,7 +25523,7 @@ decryption). @item PGP/MIME - RFC 2015/3156 RFC 2015 (superseded by 3156 which references RFC 2440 instead of RFC -1991) describes the @acronym{MIME}-wrapping around the RF 1991/2440 format. +1991) describes the @acronym{MIME}-wrapping around the RFC 1991/2440 format. Gnus supports both encoding and decoding. @item S/MIME - RFC 2633 @@ -25285,7 +25953,7 @@ actually are people who are using Gnus. Who'd'a thunk it! * Quassia Gnus:: Two times two is four, or Gnus 5.6/5.7. * Pterodactyl Gnus:: Pentad also starts with P, AKA Gnus 5.8/5.9. * Oort Gnus:: It's big. It's far out. Gnus 5.10/5.11. -* No Gnus:: Lars, FIXME! +* No Gnus:: Very punny. @end menu These lists are, of course, just @emph{short} overviews of the @@ -26205,7 +26873,7 @@ The new variable @code{gnus-parameters} can be used to set group parameters. Earlier this was done only via @kbd{G p} (or @kbd{G c}), which stored the parameters in @file{~/.newsrc.eld}, but via this variable you can enjoy the powers of customize, and simplified backups since you set the -variable in @file{~/.emacs} instead of @file{~/.newsrc.eld}. The +variable in @file{~/.gnus.el} instead of @file{~/.newsrc.eld}. The variable maps regular expressions matching group names to group parameters, a'la: @lisp @@ -26220,7 +26888,7 @@ parameters, a'la: @item Smileys (@samp{:-)}, @samp{;-)} etc) are now iconized for Emacs too. -Put @code{(setq gnus-treat-display-smileys nil)} in @file{~/.emacs} to +Put @code{(setq gnus-treat-display-smileys nil)} in @file{~/.gnus.el} to disable it. @item @@ -26247,8 +26915,8 @@ appropriate headers and a note in the body for cross-postings and followups (see the variables @code{message-cross-post-@var{*}}). @item -References and X-Draft-Headers are no longer generated when you start -composing messages and @code{message-generate-headers-first} is +References and X-Draft-From headers are no longer generated when you +start composing messages and @code{message-generate-headers-first} is @code{nil}. @item @@ -26321,7 +26989,7 @@ unplugged state. You can enroll or remove servers with @kbd{J a} and @kbd{J r} in the server buffer. Gnus will not download articles into the Agent cache, unless you instruct it to do so, though, by using @kbd{J u} or @kbd{J s} from the Group buffer. You revert to the old -behaviour of having the Agent disabled with @code{(setq gnus-agent +behavior of having the Agent disabled with @code{(setq gnus-agent nil)}. Note that putting @code{(gnus-agentize)} in @file{~/.gnus.el} is not needed any more. @@ -26341,6 +27009,8 @@ groups. A new file from Raymond Scholz @email{rscholz@@zonix.de} for deuglifying broken Outlook (Express) articles. +@c FIXME: `gnus-load' is mentioned in README, which is not included in +@c CVS. We should find a better place for this item. @item @code{(require 'gnus-load)} @@ -26429,6 +27099,11 @@ Decoding format=flowed was present but not documented in earlier versions. @item +The option @code{mm-fill-flowed} can be used to disable treatment of +``format=flowed'' messages. Also, flowed text is disabled when sending +inline PGP signed messages. (New in Gnus 5.10.7) + +@item Gnus supports the generation of RFC 2298 Disposition Notification requests. This is invoked with the @kbd{C-c M-n} key binding from message mode. @@ -26461,7 +27136,7 @@ you post a message, and saves it in your @file{~/.emacs} using the Custom system. While the variable is called @code{canlock-password}, it is not security sensitive data. Publishing your canlock string on the web will not allow anyone to be able to anything she could not already do. -The behaviour can be changed by customizing @code{message-insert-canlock}. +The behavior can be changed by customizing @code{message-insert-canlock}. @item Gnus supports server-side mail filtering using Sieve. @@ -26489,7 +27164,8 @@ It was aliased to @kbd{Y c} (@code{gnus-summary-insert-cached-articles}). The new function filters out other articles. -@item Some limiting commands accept a @kbd{C-u} prefix to negate the match. +@item +Some limiting commands accept a @kbd{C-u} prefix to negate the match. If @kbd{C-u} is used on subject, author or extra headers, i.e., @kbd{/ s}, @kbd{/ a}, and @kbd{/ x} @@ -26561,7 +27237,7 @@ This change was made to avoid conflict with the standard binding of @item The default for @code{message-forward-show-mml} changed to symbol @code{best}. -The behaviour for the @code{best} value is to show @acronym{MML} (i.e., +The behavior for the @code{best} value is to show @acronym{MML} (i.e., convert to @acronym{MIME}) when appropriate. @acronym{MML} will not be used when forwarding signed or encrypted messages, as the conversion invalidate the digital signature. @@ -26949,7 +27625,7 @@ minimum. You can, in fact, make do without them altogether---most of the useful data is in the summary buffer, anyway. Set this variable to @samp{^NEVVVVER} or @samp{From:}, or whatever you feel you need. -Set this hook to all the available hiding commands: +Use the following to enable all the available hiding features: @lisp (setq gnus-treat-hide-headers 'head gnus-treat-hide-signature t @@ -27095,7 +27771,7 @@ in order to solve the problem yourself and send a patch, you can use edebug. Debugging Lisp code is documented in the Elisp manual (@pxref{Debugging, , Debugging Lisp Programs, elisp, The GNU Emacs Lisp Reference Manual}). To get you started with edebug, consider if -you discover some weird behaviour when pressing @kbd{c}, the first +you discover some weird behavior when pressing @kbd{c}, the first step is to do @kbd{C-h k c} and click on the hyperlink (Emacs only) in the documentation buffer that leads you to the function definition, then press @kbd{M-x edebug-defun RET} with point inside that function, @@ -28679,8 +29355,10 @@ interpreted.) If you decide that you don't like the way Gnus does certain things, it's trivial to have it do something a different way. (Well, at least if you know how to write Lisp code.) However, that's beyond the scope of this manual, so we are simply going to talk about -some common constructs that you normally use in your @file{.emacs} file -to customize Gnus. +some common constructs that you normally use in your @file{~/.gnus.el} +file to customize Gnus. (You can also use the @file{~/.emacs} file, but +in order to set things of Gnus up, it is much better to use the +@file{~/.gnus.el} file, @xref{Startup Files}.) If you want to set the variable @code{gnus-florgbnize} to four (4), you write the following: @@ -28691,12 +29369,12 @@ write the following: This function (really ``special form'') @code{setq} is the one that can set a variable to some value. This is really all you need to know. Now -you can go and fill your @file{.emacs} file with lots of these to change -how Gnus works. +you can go and fill your @file{~/.gnus.el} file with lots of these to +change how Gnus works. -If you have put that thing in your @file{.emacs} file, it will be read -and @code{eval}ed (which is lisp-ese for ``run'') the next time you -start Emacs. If you want to change the variable right away, simply say +If you have put that thing in your @file{~/.gnus.el} file, it will be +read and @code{eval}ed (which is Lisp-ese for ``run'') the next time you +start Gnus. If you want to change the variable right away, simply say @kbd{C-x C-e} after the closing parenthesis. That will @code{eval} the previous ``form'', which is a simple @code{setq} statement here. diff --git a/texi/infohack.el b/texi/infohack.el index e5c326f..ba6a31e 100644 --- a/texi/infohack.el +++ b/texi/infohack.el @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: diff --git a/texi/message.texi b/texi/message.texi index 117a7ea..38cbc1d 100644 --- a/texi/message.texi +++ b/texi/message.texi @@ -8,12 +8,12 @@ @copying This file documents Message, the Emacs message composition mode. -Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright @copyright{} 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, +2004, 2005, 2006 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with the Front-Cover texts being ``A GNU Manual'', and with the Back-Cover Texts as in (a) below. A copy of the @@ -67,9 +67,10 @@ Message mode buffers. * Key Index:: List of Message mode keys. @end menu -This manual corresponds to Message v5.10.6. Message is distributed -with the Gnus distribution bearing the same version number as this -manual. +@c Adjust ../Makefile.in if you change the following lines: +Message is distributed with Gnus. The Gnus distribution +@c +corresponding to this manual is No Gnus v0.4. @node Interface @@ -249,7 +250,10 @@ supersede the message in the current buffer. Headers matching the @code{message-ignored-supersedes-headers} are removed before popping up the new message buffer. The default is@* @samp{^Path:\\|^Date\\|^NNTP-Posting-Host:\\|^Xref:\\|^Lines:\\|@* -^Received:\\|^X-From-Line:\\|Return-Path:\\|^Supersedes:}. +^Received:\\|^X-From-Line:\\|^X-Trace:\\|^X-Complaints-To:\\|@* +Return-Path:\\|^Supersedes:\\|^NNTP-Posting-Date:\\|^X-Trace:\\|@* +^X-Complaints-To:\\|^Cancel-Lock:\\|^Cancel-Key:\\|^X-Hashcash:\\|@* +^X-Payment:\\|^Approved:}. @@ -330,7 +334,7 @@ undeliverable. @vindex message-ignored-bounced-headers Headers that match the @code{message-ignored-bounced-headers} regexp will be removed before popping up the buffer. The default is -@samp{^\\(Received\\|Return-Path\\):}. +@samp{^\\(Received\\|Return-Path\\|Delivered-To\\):}. @node Mailing Lists @@ -339,7 +343,7 @@ will be removed before popping up the buffer. The default is @cindex Mail-Followup-To Sometimes while posting to mailing lists, the poster needs to direct followups to the post to specific places. The Mail-Followup-To (MFT) -was created to enable just this. Two example scenarios where this is +was created to enable just this. Three example scenarios where this is useful: @itemize @bullet @@ -419,7 +423,7 @@ This is how you would do it. @vindex message-subscribed-address-file @item message-subscribed-address-file -You might be one organised human freak and have a list of addresses of +You might be one organized human freak and have a list of addresses of all subscribed mailing lists in a separate file! Then you can just set this variable to the name of the file and life would be good. @@ -681,26 +685,30 @@ stripped on replying, see @code{message-subject-trailing-was-query} @kindex C-c C-f x @findex message-cross-post-followup-to @vindex message-cross-post-default +@vindex message-cross-post-note-function @cindex X-Post @cindex cross-post -Ask for an additional @samp{Newsgroups} and @samp{FollowUp-To} for a -cross-post. @code{message-cross-post-followup-to} mangles -@samp{FollowUp-To} and @samp{Newsgroups} header to point to group. -If @code{message-cross-post-default} is @code{nil} or if called with a -prefix-argument @samp{Follow-Up} is set, but the message is not -cross-posted. +Set up the @samp{FollowUp-To} header with a target newsgroup for a +cross-post, add that target newsgroup to the @samp{Newsgroups} header if +it is not a member of @samp{Newsgroups}, and insert a note in the body. +If @code{message-cross-post-default} is @code{nil} or if this command is +called with a prefix-argument, only the @samp{FollowUp-To} header will +be set but the the target newsgroup will not be added to the +@samp{Newsgroups} header. The function to insert a note is controlled +by the @code{message-cross-post-note-function} variable. @item C-c C-f t @kindex C-c C-f t @findex message-reduce-to-to-cc Replace contents of @samp{To} header with contents of @samp{Cc} or -@samp{Bcc} header. +@samp{Bcc} header. (Iff @samp{Cc} header is not present, @samp{Bcc} +header will be used instead.) @item C-c C-f w @kindex C-c C-f w @findex message-insert-wide-reply Insert @samp{To} and @samp{Cc} headers as if you were doing a wide -reply. +reply even if the message was not made for a wide reply first. @item C-c C-f a @kindex C-c C-f a @@ -739,7 +747,7 @@ Move to the signature of the message (@code{message-goto-signature}). @vindex message-beginning-of-line If at beginning of header value, go to beginning of line, else go to beginning of header value. (The header value comes after the header -name and the colon.) This behaviour can be disabled by toggling +name and the colon.) This behavior can be disabled by toggling the variable @code{message-beginning-of-line}. @end table @@ -785,14 +793,18 @@ Insert the message headers (@code{message-insert-headers}). @item C-c M-m @kindex C-c M-m @findex message-mark-inserted-region -Mark some region in the current article with enclosing tags. -See @code{message-mark-insert-begin} and @code{message-mark-insert-end}. +Mark some region in the current article with enclosing tags. See +@code{message-mark-insert-begin} and @code{message-mark-insert-end}. +When called with a prefix argument, use slrn style verbatim marks +(@samp{#v+} and @samp{#v-}). @item C-c M-f @kindex C-c M-f @findex message-mark-insert-file Insert a file in the current article with enclosing tags. See @code{message-mark-insert-begin} and @code{message-mark-insert-end}. +When called with a prefix argument, use slrn style verbatim marks +(@samp{#v+} and @samp{#v-}). @end table @@ -812,8 +824,19 @@ automatically add the @code{Content-Type} and The most typical thing users want to use the multipart things in @acronym{MIME} for is to add ``attachments'' to mail they send out. This can be done with the @kbd{C-c C-a} command, which will prompt for -a file name and a @acronym{MIME} type. If your Emacs supports drag -and drop, you can also drop the file in the Message buffer. +a file name and a @acronym{MIME} type. + +@vindex mml-dnd-protocol-alist +@vindex mml-dnd-attach-options +If your Emacs supports drag and drop, you can also drop the file in the +Message buffer. The variable @code{mml-dnd-protocol-alist} specifies +what kind of action is done when you drop a file into the Message +buffer. The variable @code{mml-dnd-attach-options} controls which +@acronym{MIME} options you want to specify when dropping a file. If it +is a list, valid members are @code{type}, @code{description} and +@code{disposition}. @code{disposition} implies @code{type}. If it is +@code{nil}, don't ask for options. If it is @code{t}, ask the user +whether or not to specify options. You can also create arbitrarily complex multiparts using the @acronym{MML} language (@pxref{Composing, , Composing, emacs-mime, The Emacs MIME @@ -840,13 +863,14 @@ typed a non-@acronym{ASCII} domain name. The @code{message-use-idna} variable control whether @acronym{IDNA} is used. If the variable is @code{nil} no @acronym{IDNA} encoding will ever happen, if it is set to the symbol @code{ask} the user will be -queried (the default), and if set to @code{t} @acronym{IDNA} encoding -happens automatically. +queried, and if set to @code{t} (which is the default if @acronym{IDNA} +is fully available) @acronym{IDNA} encoding happens automatically. @findex message-idna-to-ascii-rhs If you want to experiment with the @acronym{IDNA} encoding, you can invoke @kbd{M-x message-idna-to-ascii-rhs RET} in the message buffer -to have the non-@acronym{ASCII} domain names encoded while you edit the message. +to have the non-@acronym{ASCII} domain names encoded while you edit +the message. Note that you must have @uref{http://www.gnu.org/software/libidn/, GNU Libidn} installed in order to use this functionality. @@ -1086,7 +1110,7 @@ The text is killed and replaced with the contents of the variable Kill the address under point. @item C-c C-z -@kindex C-c C-x +@kindex C-c C-z @findex message-kill-to-signature Kill all the text up to the signature, or if that's missing, up to the end of the message (@code{message-kill-to-signature}). @@ -1130,9 +1154,9 @@ prompt for a new buffer name. @kindex TAB @findex message-tab @vindex message-tab-body-function -If non-@code{nil} execute the function specified in -@code{message-tab-body-function}. Otherwise use the function bound to -@kbd{TAB} in @code{text-mode-map} or @code{global-map}. +If @code{message-tab-body-function} is non-@code{nil}, execute the +function it specifies. Otherwise use the function bound to @kbd{TAB} in +@code{text-mode-map} or @code{global-map}. @end table @@ -1378,14 +1402,29 @@ Controls what to do with trailing @samp{(was: )} in subject lines. If @code{nil}, leave the subject unchanged. If it is the symbol @code{ask}, query the user what do do. In this case, the subject is matched against @code{message-subject-trailing-was-ask-regexp}. If -@code{message-subject-trailing-was-query} is t, always strip the +@code{message-subject-trailing-was-query} is @code{t}, always strip the trailing old subject. In this case, @code{message-subject-trailing-was-regexp} is used. @item message-alternative-emails @vindex message-alternative-emails -A regexp to match the alternative email addresses. The first matched -address (not primary one) is used in the @code{From} field. +Regexp matching alternative email addresses. The first address in the +To, Cc or From headers of the original article matching this variable is +used as the From field of outgoing messages, replacing the default From +value. + +For example, if you have two secondary email addresses john@@home.net +and john.doe@@work.com and want to use them in the From field when +composing a reply to a message addressed to one of them, you could set +this variable like this: + +@lisp +(setq message-alternative-emails + (regexp-opt '("john@@home.net" "john.doe@@work.com"))) +@end lisp + +This variable has precedence over posting styles and anything that runs +off @code{message-setup-hook}. @item message-allow-no-recipients @vindex message-allow-no-recipients @@ -1425,13 +1464,14 @@ header when the message is already @code{Cc}ed to the recipient. @item message-required-mail-headers @vindex message-required-mail-headers @xref{News Headers}, for the syntax of this variable. It is -@code{(From Date Subject (optional . In-Reply-To) Message-ID Lines +@code{(From Subject Date (optional . In-Reply-To) Message-ID (optional . User-Agent))} by default. @item message-ignored-mail-headers @vindex message-ignored-mail-headers -Regexp of headers to be removed before mailing. The default is -@samp{^[GF]cc:\\|^Resent-Fcc:\\|^Xref:\\|^X-Draft-From:}. +Regexp of headers to be removed before mailing. The default is@* +@samp{^[GF]cc:\\|^Resent-Fcc:\\|^Xref:\\|^X-Draft-From:\\|@* +^X-Gnus-Agent-Meta-Information:}. @item message-default-mail-headers @vindex message-default-mail-headers @@ -1708,7 +1748,8 @@ All these conditions are checked by default. @item message-ignored-news-headers @vindex message-ignored-news-headers Regexp of headers to be removed before posting. The default is@* -@samp{^NNTP-Posting-Host:\\|^Xref:\\|^[BGF]cc:\\|^Resent-Fcc:\\|^X-Draft-From:}. +@samp{^NNTP-Posting-Host:\\|^Xref:\\|^[BGF]cc:\\|^Resent-Fcc:\\|@* +^X-Draft-From:\\|^X-Gnus-Agent-Meta-Information:}. @item message-default-news-headers @vindex message-default-news-headers @@ -1774,21 +1815,29 @@ Article Highlighting, gnus, The Gnus Manual}, for details. @cindex yanking @cindex quoting When you are replying to or following up an article, you normally want -to quote the person you are answering. Inserting quoted text is done -by @dfn{yanking}, and each line you yank will have -@code{message-yank-prefix} prepended to it (except for quoted and -empty lines which uses @code{message-yank-cited-prefix}). The default -is @samp{> }. +to quote the person you are answering. Inserting quoted text is done by +@dfn{yanking}, and each line you yank will have +@code{message-yank-prefix} prepended to it (except for quoted lines +which use @code{message-yank-cited-prefix} and empty lines which use +@code{message-yank-empty-prefix}). The default is @samp{> }. @item message-yank-cited-prefix @vindex message-yank-cited-prefix @cindex yanking @cindex cited @cindex quoting -When yanking text from an article which contains no text or already -cited text, each line will be prefixed with the contents of this -variable. The default is @samp{>}. See also -@code{message-yank-prefix}. +When yanking text from an article which contains already cited text, +each line will be prefixed with the contents of this variable. The +default is @samp{>}. See also @code{message-yank-prefix}. + +@item message-yank-empty-prefix +@vindex message-yank-empty-prefix +@cindex yanking +@cindex quoting +When yanking text from an article, each empty line will be prefixed with +the contents of this variable. The default is @samp{>}. You can set +this variable to an empty string to split the cited text into paragraphs +automatically. See also @code{message-yank-prefix}. @item message-indentation-spaces @vindex message-indentation-spaces @@ -1861,12 +1910,13 @@ say. @item message-default-charset @vindex message-default-charset @cindex charset -Symbol naming a @acronym{MIME} charset. Non-@acronym{ASCII} -characters in messages are assumed to be encoded using this charset. -The default is @code{nil}, which means ask the user. (This variable -is used only on non-@sc{mule} Emacsen. @xref{Charset Translation, , -Charset Translation, emacs-mime, Emacs MIME Manual}, for details on -the @sc{mule}-to-@acronym{MIME} translation process. +Symbol naming a @acronym{MIME} charset. Non-@acronym{ASCII} characters +in messages are assumed to be encoded using this charset. The default +is @code{iso-8859-1} on non-@sc{mule} Emacsen; otherwise @code{nil}, +which means ask the user. (This variable is used only on non-@sc{mule} +Emacsen.) @xref{Charset Translation, , Charset Translation, emacs-mime, +Emacs MIME Manual}, for details on the @sc{mule}-to-@acronym{MIME} +translation process. @item message-signature-separator @vindex message-signature-separator @@ -1974,8 +2024,11 @@ message composition doesn't break too bad. @item message-send-method-alist @vindex message-send-method-alist - -Alist of ways to send outgoing messages. Each element has the form +@findex message-mail-p +@findex message-news-p +@findex message-send-via-mail +@findex message-send-via-news +Alist of ways to send outgoing messages. Each element has the form: @lisp (@var{type} @var{predicate} @var{function}) @@ -1987,19 +2040,32 @@ A symbol that names the method. @item predicate A function called without any parameters to determine whether the -message is a message of type @var{type}. +message is a message of type @var{type}. The function will be called in +the buffer where the message is. @item function A function to be called if @var{predicate} returns non-@code{nil}. @var{function} is called with one parameter---the prefix. @end table +The default is: + @lisp ((news message-news-p message-send-via-news) (mail message-mail-p message-send-via-mail)) @end lisp - +The @code{message-news-p} function returns non-@code{nil} if the message +looks like news, and the @code{message-send-via-news} function sends the +message according to the @code{message-send-news-function} variable +(@pxref{News Variables}). The @code{message-mail-p} function returns +non-@code{nil} if the message looks like mail, and the +@code{message-send-via-mail} function sends the message according to the +@code{message-send-mail-function} variable (@pxref{Mail Variables}). + +All the elements in this alist will be tried in order, so a message +containing both a valid @samp{Newsgroups} header and a valid @samp{To} +header, for example, will be sent as news, and then as mail. @end table diff --git a/texi/pgg.texi b/texi/pgg.texi index 88c9ddd..f4fe0a0 100644 --- a/texi/pgg.texi +++ b/texi/pgg.texi @@ -6,14 +6,14 @@ @copying -This file describes the PGG. +This file describes PGG, an Emacs interface to various PGP implementations. -Copyright (C) 2003 Free Software Foundation, Inc. -Copyright (C) 2001 Daiki Ueno. +Copyright @copyright{} 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +Copyright @copyright{} 2001 Daiki Ueno. @quotation Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled ``GNU @@ -98,6 +98,8 @@ list autoload setting for desired functions as follows. @lisp (autoload 'pgg-encrypt-region "pgg" "Encrypt the current region." t) +(autoload 'pgg-encrypt-symmetric-region "pgg" + "Encrypt the current region with symmetric algorithm." t) (autoload 'pgg-decrypt-region "pgg" "Decrypt the current region." t) (autoload 'pgg-sign-region "pgg" @@ -127,7 +129,7 @@ signer's public key, for example, the function @code{pgg-verify-region} fails immediately, but if the function had been called interactively, it would ask you to retrieve the signer's public key from the server. -@deffn Command pgg-encrypt-region start end recipients &optional sign +@deffn Command pgg-encrypt-region start end recipients &optional sign passphrase Encrypt the current region between @var{start} and @var{end} for @var{recipients}. When the function were called interactively, you would be asked about the recipients. @@ -136,29 +138,47 @@ If encryption is successful, it replaces the current region contents (in the accessible portion) with the resulting data. If optional argument @var{sign} is non-@code{nil}, the function is -request to do a combined sign and encrypt. This currently only work -with GnuPG. +request to do a combined sign and encrypt. This currently is +confirmed to work with GnuPG, but might not work with PGP or PGP5. + +If optional @var{passphrase} is @code{nil}, the passphrase will be +obtained from the passphrase cache or user. +@end deffn + +@deffn Command pgg-encrypt-symmetric-region &optional start end passphrase +Encrypt the current region between @var{start} and @var{end} using a +symmetric cipher. After invocation you are asked for a passphrase. + +If optional @var{passphrase} is @code{nil}, the passphrase will be +obtained from the passphrase cache or user. + +symmetric-cipher encryption is currently only implemented for GnuPG. @end deffn -@deffn Command pgg-decrypt-region start end +@deffn Command pgg-decrypt-region start end &optional passphrase Decrypt the current region between @var{start} and @var{end}. If decryption is successful, it replaces the current region contents (in the accessible portion) with the resulting data. + +If optional @var{passphrase} is @code{nil}, the passphrase will be +obtained from the passphrase cache or user. @end deffn -@deffn Command pgg-sign-region start end &optional cleartext +@deffn Command pgg-sign-region start end &optional cleartext passphrase Make the signature from text between @var{start} and @var{end}. If the optional third argument @var{cleartext} is non-@code{nil}, or the function is called interactively, it does not create a detached signature. In such a case, it replaces the current region contents (in the accessible portion) with the resulting data. + +If optional @var{passphrase} is @code{nil}, the passphrase will be +obtained from the passphrase cache or user. @end deffn @deffn Command pgg-verify-region start end &optional signature fetch Verify the current region between @var{start} and @var{end}. If the -optional third argument @var{signature} is non-@code{nil}, or the function -is called interactively, it is treated as the detached signature of the -current region. +optional third argument @var{signature} is non-@code{nil}, it is treated +as the detached signature file of the current region. If the optional 4th argument @var{fetch} is non-@code{nil}, or the function is called interactively, we attempt to fetch the signer's @@ -183,22 +203,18 @@ considerably. For example, if you are using GnuPG, you know you can select cipher algorithm from 3DES, CAST5, BLOWFISH, and so on, but on the other hand the version 2 of PGP only supports IDEA. -By default, if the variable @code{pgg-scheme} is not set, PGG searches the -registered scheme for an implementation of the requested service -associated with the named algorithm. If there are no match, PGG uses -@code{pgg-default-scheme}. In other words, there are two options to -control which command is used to process the incoming PGP armors. One -is for encrypting and signing, the other is for decrypting and -verifying. +Which implementation is used is controlled by the @code{pgg-scheme} +variable. If it is @code{nil} (the default), the value of the +@code{pgg-default-scheme} variable will be used instead. @defvar pgg-scheme -Force specify the scheme of PGP implementation for decrypting and verifying. -The value can be @code{gpg}, @code{pgp}, and @code{pgp5}. +Force specify the scheme of PGP implementation. The value can be set to +@code{gpg}, @code{pgp}, and @code{pgp5}. The default is @code{nil}. @end defvar @defvar pgg-default-scheme -Force specify the scheme of PGP implementation for encrypting and signing. -The value can be @code{gpg}, @code{pgp}, and @code{pgp5}. +The default scheme of PGP implementation. The value should be one of +@code{gpg}, @code{pgp}, and @code{pgp5}. The default is @code{gpg}. @end defvar @node Caching passphrase @@ -209,8 +225,9 @@ default. @defvar pgg-cache-passphrase If non-@code{nil}, store passphrases. The default value of this -variable is @code{t}. If you were worry about security issue, however, -you could stop caching with setting it @code{nil}. +variable is @code{t}. If you are worried about security issues, +however, you could stop the caching of passphrases by setting this +variable to @code{nil}. @end defvar @defvar pgg-passphrase-cache-expiry @@ -300,19 +317,26 @@ argument @var{type} is non-@code{nil}, it searches from the secret keyrings. @end deffn -@deffn Method pgg-scheme-encrypt-region scheme start end recipients &optional sign +@deffn Method pgg-scheme-encrypt-region scheme start end recipients &optional sign passphrase Encrypt the current region between @var{start} and @var{end} for @var{recipients}. If @var{sign} is non-@code{nil}, do a combined sign and encrypt. If encryption is successful, it returns @code{t}, otherwise @code{nil}. @end deffn -@deffn Method pgg-scheme-decrypt-region scheme start end +@deffn Method pgg-scheme-encrypt-symmetric-region scheme start end &optional passphrase +Encrypt the current region between @var{start} and @var{end} using a +symmetric cipher and a passphrases. If encryption is successful, it +returns @code{t}, otherwise @code{nil}. This function is currently only +implemented for GnuPG. +@end deffn + +@deffn Method pgg-scheme-decrypt-region scheme start end &optional passphrase Decrypt the current region between @var{start} and @var{end}. If decryption is successful, it returns @code{t}, otherwise @code{nil}. @end deffn -@deffn Method pgg-scheme-sign-region scheme start end &optional cleartext +@deffn Method pgg-scheme-sign-region scheme start end &optional cleartext passphrase Make the signature from text between @var{start} and @var{end}. If the optional third argument @var{cleartext} is non-@code{nil}, it does not create a detached signature. If signing is successful, it returns diff --git a/texi/ps/Makefile.in b/texi/ps/Makefile.in index 644ad50..c11e474 100644 --- a/texi/ps/Makefile.in +++ b/texi/ps/Makefile.in @@ -136,7 +136,7 @@ pdf: $(PDFFILES) .ps.pdf: epstopdf $< -.SUFFIXES: .pdf .ps .eps .xbm .xpm .png .tif .gif +.SUFFIXES: .pdf .ps .eps .xbm .xpm .png .tif .gif clean: rm -f $(PSFILES) @@ -145,6 +145,7 @@ clean: veryclean: clean distclean: clean + rm -f Makefile install: diff --git a/texi/sasl.texi b/texi/sasl.texi index 0c650e1..9cd465a 100644 --- a/texi/sasl.texi +++ b/texi/sasl.texi @@ -14,10 +14,11 @@ @ifinfo This file describes the Emacs SASL library. -Copyright (C) 2000 Daiki Ueno. +Copyright @copyright{} 2004, 2005, 2006 Free Software Foundation, Inc. +Copyright @copyright{} 2000 Daiki Ueno. Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled "GNU @@ -36,7 +37,7 @@ Free Documentation License". Copyright @copyright{} 2000 Daiki Ueno. Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled "GNU diff --git a/texi/sieve.texi b/texi/sieve.texi index a33300e..34c554d 100644 --- a/texi/sieve.texi +++ b/texi/sieve.texi @@ -7,13 +7,14 @@ @synindex pg cp @copying -This file documents the Emacs Sieve package. +This file documents the Emacs Sieve package, for server-side mail filtering. -Copyright (C) 2001 Free Software Foundation, Inc. +Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006 Free +Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document -under the terms of the GNU Free Documentation License, Version 1.1 or +under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, with the Front-Cover texts being ``A GNU Manual'', and with the Back-Cover Texts as in (a) below. A copy of the diff --git a/texi/xml2texi.scm b/texi/xml2texi.scm index b2a6161..0eb2d24 100644 --- a/texi/xml2texi.scm +++ b/texi/xml2texi.scm @@ -18,8 +18,8 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;; diff --git a/texi/xml2texi.sh b/texi/xml2texi.sh index 779de36..ad6b1b1 100644 --- a/texi/xml2texi.sh +++ b/texi/xml2texi.sh @@ -21,8 +21,8 @@ exec mzscheme -mr $0 ${1+"$@"} ;; ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. ;;; Commentary: ;; diff --git a/todo b/todo index 92ff87e..9c6123a 100644 --- a/todo +++ b/todo @@ -1,6 +1,55 @@ ;; Also know as the "wish list". Some are done. For the others, no ;; promise when to be implemented. +* Go through the todo list and remove items already done. + +* Use a new custom type (`define-widget') for posting-style in `gnus-cus.el' + (G c) and for `gnus-posting-styles'. Maybe some allowed types are still + missing. + +* Add proper doc strings to functions and variables explained in the manual + (info "(gnus)Gnus Utility Functions") + +* Add Message-IDs or URLs refering to relevant discussions on lists and + newsgroups. + +* Use nicer tool bar icons from GNOME + + Done for Emacs (The GNOME icons won't fit into standard XEmacs icons, + IMHO. -- rsteib) in group, summary and message mode. + + Some modes might also deserve improved tool bars: + + - gnus-draft-mode + + - mml-preview buffer: + + . zap most buttons; except print, customize (?) and help + + . "exit" should just kill the buffer + + - gnus-server-mode: Add some commands from the Connections and Server + menu. + + - gnus-browse-mode (could borrow some icons from gnus-group-mode) + + (See http://article.gmane.org/gmane.emacs.gnus.general/62147). + +* Maybe Gnus should support the LIST SUBSCRIPTIONS, see RFC 2980. + +* Merge `message-extra-wide-headers' and ` message-header-synonyms'? + +* Maybe texi/emacs-mime.texi could be divided into user-visible stuff and + reference manual for the MIME library. + + Related: Bill Wohler's article on mh-e-user. + http://thread.gmane.org/29067.1138078896@olgas.newt.com + +* Fix `change servers' command, see David Kastrup's message. + http://thread.gmane.org/x54qewqxz4.fsf@lola.goethe.zz + +* texi/gnus-coding.texi should be fixed. + * gnus-topic-kill-region From Colin Marquardt @@ -34,10 +83,6 @@ Implement NOV caching with Gnus Agent. -* Multiple charsets for topic names. - - [Done] - * Allow specification of server in Newsgroups header [Kai wrote] @@ -51,23 +96,10 @@ Thanks for Micha Wiedenmann for this suggestion. -* Understand mail-user-agent. Maybe gnus-mail-user-agent. - - [Done] - -* Emphasis delimiters show when `W W c'. - - [Fixed] - * Parsing of the common list confirmation requests so that Gnus can prepare the response with a single command. Including LISTSERV periodic ping messages and the like. -* Parsing of the various List-* headers to enable automatic commands - like "send help message," "send unsubscribe message," and the like. - - [done, see gnus-ml.el] - * Parsing of the subscription notice to stash away details like what address you're subscribed to the list under (and automatically send mail to the list using that address, when you send mail inside the list @@ -89,11 +121,6 @@ Most likely using jka-compr. (It has been suggested that this do work but I think it should be verified for all backends.) -* Support for RFC2015, PGP-MIME. Probably has to involve the people in - the Mailcrypt project. - - [done] - * Agent (Can someone write some subtopics here? I don't use it myself so I don't know what is lacking.) @@ -106,9 +133,6 @@ posted on gnu.emacs.gnus does this. Also, gnus-article-encrypt `K E' encrypts the article body.] -* The stuff on "Newest Features" in the manual should be implemented - and the node updated (it maybe is?). - * Splitting .newsrc.eld so the history is in one file and the configuration is in another. To help those that reads at two locations (e.g. work and home) and want to have the same @@ -159,6 +183,9 @@ you want to instantiate, and what mail should land in each? [/viz./ problem of nnmail-split-methods interface.] + [Probably `assistant.el' will provide this. But it's development is + stalled.] + * Full integration of nnir into Gnus. Generic hooks for adding new external nnir sources. I use a couple experimental, in-house tools (JPRC is a research lab, occupied with document analysis and machine @@ -206,11 +233,6 @@ * A possibility to add notes to messages. If thouse could include links to other (stored) messages this would be very practical. -* A nnfolder like backend with .overview files. - This would not only speed up things, but also allow nnir to work on it. - - [done] - * Allow article editing in groups which do not support it, but emulating it via deleting the old article and entering the new one into the group. This would be very useful to support `T ^' (say) in @@ -223,8 +245,6 @@ cached-but-unticked ones.) This would become even more important when we allow labels. -* Go through the todo list and remove items already done. - * Create new data type `article identifier' and use that instead of article numbers. A first implementation could offer something like (num . 4711) but this could be extended. This would be useful for @@ -242,17 +262,6 @@ thread should always be hidden (as in `T h') by default, while most other threads are not hidden by default. Hm. -* New backend between nnfolder and nnml: have more than one article - per file, but more than one file per group. With .overview files. - - [done. nnfolder has .overview. Backward- and forward-compatible - between 1.0 and 2.0. (setq nnfolder-nov-is-evil t) disables the - feature] - -* .overview files for nnfolder? - - [done] - * New backend nnbabylfolder. There is also nnbabyl which is like nnmbox but uses babyl format, but there is no babyl format equivalent of nnfolder. @@ -383,13 +392,9 @@ the same in the group buffer and on the SPC prompt. * nndir doesn't read gzipped files. -* FAQ doesn't have an up node? - * when moving mail from a procmail spool to the crash-box, the crash-box is only appropriate to one specific group. -* `t' `t' makes X-Faces disappear. - * nnmh-be-safe means that crossposted articles will be marked as unread. @@ -435,8 +440,6 @@ exceeding lisp nesting on huge groups. * move nnmail-split-history out to the backends. -* nnweb doesn't work properly. - * using a virtual server name as `gnus-select-method' doesn't work? * when killing/yanking a group from one topic to another in a @@ -550,8 +553,6 @@ exceeding lisp nesting on huge groups. * stop using invisible text properties and start using overlays instead -* C-c C-f C-e to add an Expires header. - * go from one group to the next; everything is expunged; go to the next group instead of going to the group buffer. @@ -617,11 +618,6 @@ exceeding lisp nesting on huge groups. * support ProleText: -* when browsing a foreign server, the groups that are already - subscribed should be listed as such and not as "K". - - [done] - * generate font names dynamically. * score file mode auto-alist. @@ -668,8 +664,12 @@ exceeding lisp nesting on huge groups. * `gnus-summary-find-matching' should accept pseudo-"headers" like "body", "head" and "all" -* When buttifying things, all white space (including - newlines) should be ignored. +* When buttifying things, all white space (including newlines) should + be ignored. + + [Done] + + But not for cited URLs. * Process-marking all groups in a topic should process-mark groups in subtopics as well. @@ -690,10 +690,6 @@ exceeding lisp nesting on huge groups. * nnmbox should support a newsgroups file for descriptions. -* allow fetching mail from several pop servers. - - [done] - * Be able to specify whether the saving commands save the original or the formatted article. @@ -707,14 +703,14 @@ exceeding lisp nesting on huge groups. * more limiting functions - date, etc. + We have `gnus-summary-limit-to-age'. What's missing? Maybe enter a date? + * be able to limit on a random header; on body; using reverse matches. * a group parameter (`absofucking-total-expiry') that will make Gnus expire even unread articles. -* a command to print the article buffer as postscript. - * variable to disable password fetching when opening by nntp-open-telnet. @@ -1168,6 +1164,8 @@ exceeding lisp nesting on huge groups. then you could run the relevant function to complete the information in the header + [Done using `message-completion-alist'?] + * cache the newsgroups file locally to avoid reloading it all the time. @@ -1175,6 +1173,8 @@ exceeding lisp nesting on huge groups. * nnweb should allow fetching by Message-ID from servers. + [Done?] + * point in the article buffer doesn't always go to the beginning of the buffer when selecting new articles. @@ -1217,6 +1217,8 @@ exceeding lisp nesting on huge groups. default server if it fails on the current server? (controlled by a user variable, (nil, t, 'ask)). + [Done by `gnus-refer-article-method'?] + * make it possible to cancel articles using the select method for the current group. @@ -1250,29 +1252,6 @@ exceeding lisp nesting on huge groups. * a function for selecting a particular group which will contain the articles listed in a list of article numbers/id's. -* a battery of character translation functions to translate common - Mac, MS (etc) characters into ISO 8859-1. - - (defun article-fix-m$word () - "Fix M$Word smartquotes in an article." - (interactive) - (save-excursion - (let ((buffer-read-only nil)) - (goto-char (point-min)) - (while (search-forward "\221" nil t) - (replace-match "`" t t)) - (goto-char (point-min)) - (while (search-forward "\222" nil t) - (replace-match "'" t t)) - (goto-char (point-min)) - (while (search-forward "\223" nil t) - (replace-match "\"" t t)) - (goto-char (point-min)) - (while (search-forward "\224" nil t) - (replace-match "\"" t t))))) - - [done] - * (add-hook 'gnus-exit-query-functions '(lambda () (if (and (file-exists-p nnmail-spool-file) @@ -1419,10 +1398,6 @@ exceeding lisp nesting on huge groups. * The jingle is only played on the second invocation of Gnus. -* Bouncing articles should do MIME. - - [done] - * Crossposted articles should "inherit" the % or mark from the other groups it has been crossposted to, or something. (Agent.) @@ -1509,10 +1484,6 @@ exceeding lisp nesting on huge groups. (body "whatever.text") -* Be able to run `J u' from summary buffers. - - [Done] - * Solve the halting problem.