changeset 83513:966a40e7fb54

Merged from emacs@sv.gnu.org Patches applied: * emacs@sv.gnu.org/emacs--devo--0--patch-234 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-235 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-236 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-237 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-238 Merge from gnus--rel--5.10 * emacs@sv.gnu.org/emacs--devo--0--patch-239 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-240 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-241 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-242 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-243 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-244 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-245 (Ffield_beginning, find_field): Undo change of 2006-04-23. * emacs@sv.gnu.org/emacs--devo--0--patch-246 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-247 Rcirc patch from Ryan Yeske * emacs@sv.gnu.org/emacs--devo--0--patch-248 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-249 Merge from gnus--rel--5.10 * emacs@sv.gnu.org/emacs--devo--0--patch-250 Update from CVS * emacs@sv.gnu.org/emacs--devo--0--patch-251 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-87 Merge from emacs--devo--0 * emacs@sv.gnu.org/gnus--rel--5.10--patch-88 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-89 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-90 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-91 Merge from emacs--devo--0 * emacs@sv.gnu.org/gnus--rel--5.10--patch-92 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-93 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-94 Update from CVS * emacs@sv.gnu.org/gnus--rel--5.10--patch-95 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-553
author Karoly Lorentey <lorentey@elte.hu>
date Fri, 28 Apr 2006 14:48:18 +0000
parents 5d328dadd0f4 (current diff) 3732dd943c16 (diff)
children d9f8d2a65d18
files ChangeLog configure lisp/ChangeLog lisp/allout.el lisp/faces.el lisp/international/mule.el lisp/mh-e/ChangeLog lisp/mh-e/mh-e.el lisp/net/rcirc.el lisp/progmodes/gdb-ui.el lisp/startup.el lisp/subr.el lisp/url/url-gw.el lisp/url/url-handlers.el lispref/ChangeLog man/ChangeLog man/emacs.texi man/mh-e.texi src/.gdbinit src/dispextern.h src/frame.c src/image.c src/keymap.c src/macterm.c src/print.c src/w32term.c src/window.c src/xdisp.c
diffstat 136 files changed, 3675 insertions(+), 1944 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,7 @@
+2006-04-20 Ramprasad B <ramprasad_i82@yahoo.com>
+
+	* Copyright (sources/emacs): updated copyright year(s)
+	
 2006-04-01  Eli Zaretskii  <eliz@gnu.org>
 
 	* configure: Regenerated.
@@ -6225,7 +6229,7 @@
 ;; coding: iso-2022-7bit
 ;; End:
 
-    Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002
+    Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 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.
--- a/INSTALL	Thu Apr 20 16:09:11 2006 +0000
+++ b/INSTALL	Fri Apr 28 14:48:18 2006 +0000
@@ -1,5 +1,6 @@
 GNU Emacs Installation Guide
-Copyright (c) 1992, 94, 96, 97, 2000, 01, 02 Free software Foundation, Inc.
+Copyright (c) 1992, 1994, 1996, 1997, 2000, 2001, 2002, 2006 
+Free software Foundation, Inc.
 See the end of the file for copying permissions.
 
 
--- a/Makefile.in	Thu Apr 20 16:09:11 2006 +0000
+++ b/Makefile.in	Fri Apr 28 14:48:18 2006 +0000
@@ -2,7 +2,7 @@
 # DIST: make most of the changes to this file you might want, so try
 # DIST: that first.
 
-# Copyright (C) 1992,93,94,95,96,97,98,1999,2000,01,02,03,04,2005
+# Copyright (C) 1992,93,94,95,96,97,98,1999,2000,01,02,03,04,2005,2006
 #   Free Software Foundation, Inc.
 
 # This file is part of GNU Emacs.
--- a/admin/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,7 @@
+2006-04-17 Ramprasad B <ramprasad_i82@yahoo.com>
+
+	* ./* (Copyright): Updated Copyright year(s)
+	
 2006-02-24  Reiner Steib  <Reiner.Steib@gmx.de>
 
 	* FOR-RELEASE (BUGS): Add URLs/MIDs.
--- a/admin/alloc-colors.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/alloc-colors.c	Fri Apr 28 14:48:18 2006 +0000
@@ -1,5 +1,5 @@
 /* Allocate X colors.  Used for testing with dense colormaps.
-   Copyright (C) 2001 Free Software Foundation, Inc.
+   Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
--- a/admin/build-configs	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/build-configs	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 #! /usr/bin/perl
 
-# Copyright (C) 2001 Free Software Foundation, Inc.
+# Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
 #
--- a/admin/cus-test.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/cus-test.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; cus-test.el --- tests for custom types and load problems
 
-;; Copyright (C) 1998, 2000, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1998, 2000, 2002, 2006 Free Software Foundation, Inc.
 
 ;; Author: Markus Rost <markus.rost@mathematik.uni-regensburg.de>
 ;; Maintainer: Markus Rost <rost@math.ohio-state.edu>
--- a/admin/diff-tar-files	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/diff-tar-files	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 #! /bin/sh
 
-# Copyright (C) 2001 Free Software Foundation, Inc.
+# Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
 #
--- a/admin/make-emacs	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/make-emacs	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 #! /usr/bin/perl
 
-# Copyright (C) 2001 Free Software Foundation, Inc.
+# Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
 #
--- a/admin/revdiff	Thu Apr 20 16:09:11 2006 +0000
+++ b/admin/revdiff	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 #! /usr/bin/perl
 
-# Copyright (C) 2001 Free Software Foundation, Inc.
+# Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
 #
--- a/config.bat	Thu Apr 20 16:09:11 2006 +0000
+++ b/config.bat	Fri Apr 28 14:48:18 2006 +0000
@@ -1,7 +1,7 @@
 @echo off
 rem   ----------------------------------------------------------------------
 rem   Configuration script for MSDOS
-rem   Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2004
+rem   Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2004, 2006
 rem   Free Software Foundation, Inc.
 
 rem   This file is part of GNU Emacs.
--- a/config.guess	Thu Apr 20 16:09:11 2006 +0000
+++ b/config.guess	Fri Apr 28 14:48:18 2006 +0000
@@ -1,9 +1,9 @@
 #! /bin/sh
 # Attempt to guess a canonical system name.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
 
-timestamp='2005-12-23'
+timestamp='2006-04-20'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
--- a/config.sub	Thu Apr 20 16:09:11 2006 +0000
+++ b/config.sub	Fri Apr 28 14:48:18 2006 +0000
@@ -1,9 +1,9 @@
 #! /bin/sh
 # Configuration validation subroutine script.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
 
-timestamp='2005-12-23'
+timestamp='2006-04-20'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
--- a/configure	Thu Apr 20 16:09:11 2006 +0000
+++ b/configure	Fri Apr 28 14:48:18 2006 +0000
@@ -2,7 +2,7 @@
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.59.
 #
-# Copyright (C) 2003 Free Software Foundation, Inc.
+# Copyright (C) 2003, 2006 Free Software Foundation, Inc.
 # This configure script is free software; the Free Software Foundation
 # gives unlimited permission to copy, distribute and modify it.
 ## --------------------- ##
--- a/etc/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/etc/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,17 @@
+2006-04-21  Bill Wohler  <wohler@newt.com>
+
+	Release MH-E version 7.94.
+
+	* NEWS, MH-E-NEWS: Update for MH-E release 7.94.
+
+2006-04-21  Nick Roberts  <nickrob@snap.net.nz>
+
+	* NEWS: Mention t-mouse.el.  Touch up description of gdb-ui.el.
+
+2006-04-20  Carsten Dominik  <dominik@science.uva.nl>
+
+	* orgcard.tex: Version number change only.
+
 2006-04-18  Reiner Steib  <Reiner.Steib@gmx.de>
 
 	* gnus-refcard.tex: Bump version to 5.11.  Remove duplicate
--- a/etc/MH-E-NEWS	Thu Apr 20 16:09:11 2006 +0000
+++ b/etc/MH-E-NEWS	Fri Apr 28 14:48:18 2006 +0000
@@ -6,6 +6,90 @@
 are permitted in any medium without royalty provided the copyright
 notice and this notice are preserved.
 
+* Changes in MH-E 7.94
+
+Version 7.94, the first 8.0 release candidate, fixes a bunch of bugs,
+incorporates new features introduced in Emacs 22.1, improves folder
+completion, and spruces up the tool bar.
+
+** New Features in MH-E 7.94
+
+*** Add :package-version Keyword to Options
+
+This `defcustom', `defgroup', and `defface' keyword was introduced in
+Emacs 22.1. MH-E has been extended to take advantage of it. With this
+keyword, you can now use `M-x customize-changed-options' to see what
+options in MH-E have changed between versions of Emacs. In a future
+version of Emacs, you'll be able to see changes between MH-E versions
+as well (closes SF #1452724).
+
+** Bug Fixes in MH-E 7.94
+
+*** mhparam -components Fails on mailutils
+
+This error prevented MH-E from loading when using GNU mailutils. GNU
+mailutils drops the `s' in this argument, so we did too since
+-component still works in nmh and MH (closes SF #1446985).
+
+*** "/ s" Still Has Problems With []'d Mail
+
+On XEmacs, subjects that had special characters would prevent `/ s'
+from narrowing to the given subject. These characters are now quoted
+correctly in XEmacs (closes SF #1447598).
+
+*** Incorrect Example in mh-folder-list Docstring
+
+This has been fixed (closes SF #1448498).
+
+*** Variable mh-send-args Is a String, Not a List
+
+This was causing errors when sending under GNU mailutils. The internal
+variable `mh-send-args' is now a list which fixes the problem (closes
+SF #1448604).
+
+*** Update Icons
+
+Most of the tool bar icons have been replaced by GTK or GNOME 2 icons
+(closes SF #1452715).
+
+*** Can't customize tool bar for current session
+
+If you customized `mh-tool-bar-folder-buttons' or
+`mh-tool-bar-letter-buttons', and clicked Set for Current Session, the
+tool bar was not updated. This has been fixed (closes SF #1452718).
+
+*** Strip Build Number From emacs-version in X-Mailer
+
+This has been done (closes SF #1466481).
+
+*** mh-folder-completion-function Problems
+
+One could not longer browse folders outside of the standard MH Mail
+directory. This has been fixed. As a beneficial side-effect, you can
+once again use SPC to complete folders (closes SF #1470518).
+
+*** Rename Function and Variable Definers
+
+If you had ever shown help for an MH-E symbol that was both a function
+or variable, you might have found that the hyperlink to the file
+brought you to the wrong definition. This has been fixed by renaming
+the macros `mh-defgroup', `mh-defcustom', `mh-defface',
+`mh-defun-compat', and `mh-defmacro-compat' to `defgroup-mh',
+`defcustom-mh', `defface-mh', `defun-mh', `defmacro-mh' respectively
+(closes SF #1472029).
+
+*** mh-insert-letter Uses Wrong Default
+
+If you had used `C-c TAB' (`mh-insert-letter') to insert a letter into
+your draft, specified a different folder, and chose the default
+message number, you got the wrong message. This has been fixed (closes
+SF #1473729).
+
+*** "echo -e" in Makefile Causes Solaris 10 Problem
+
+This construct has been replaced with printf, which is reputed to be
+more portable (closes SF #1467222, #1473908).
+
 * Changes in MH-E 7.93
 
 Version 7.93, the fourth 8.0 beta release, fixes a handful of bugs in
--- a/etc/NEWS	Thu Apr 20 16:09:11 2006 +0000
+++ b/etc/NEWS	Fri Apr 28 14:48:18 2006 +0000
@@ -1849,6 +1849,10 @@
 paragraph will scroll the buffer by the respective amount of lines
 instead and point will be kept vertically fixed relative to window
 boundaries during scrolling.
+
+** The file t-mouse.el is now part of Emacs and provides access to mouse
+events from the console.  It still requires gpm to work but has been updated
+for Emacs 22. In particular, the mode-line is now position sensitive.
 
 * Changes in Specialized Modes and Packages in Emacs 22.1:
 
@@ -2627,14 +2631,15 @@
 
 +++
 *** The new package gdb-ui.el provides an enhanced graphical interface to
-GDB. You can interact with GDB through the GUD buffer in the usual way, but
+GDB.  You can interact with GDB through the GUD buffer in the usual way, but
 there are also further buffers which control the execution and describe the
 state of your program.  It can separate the input/output of your program from
 that of GDB and watches expressions in the speedbar.  It also uses features of
 Emacs 21/22 such as the toolbar, and bitmaps in the fringe to indicate
 breakpoints.
 
-Use M-x gdb to start GDB-UI.
+To use this package just type M-x gdb.  See the Emacs manual if you want the
+old behaviour.
 
 *** The variable tooltip-gud-tips-p has been removed.  GUD tooltips can now be
 toggled independently of normal tooltips with the minor mode
@@ -3020,7 +3025,7 @@
 ---
 ** MH-E changes.
 
-Upgraded to MH-E version 7.93. There have been major changes since
+Upgraded to MH-E version 7.94. There have been major changes since
 version 5.0.2; see MH-E-NEWS for details.
 
 ** Calendar changes:
--- a/etc/orgcard.tex	Thu Apr 20 16:09:11 2006 +0000
+++ b/etc/orgcard.tex	Fri Apr 28 14:48:18 2006 +0000
@@ -1,5 +1,5 @@
 % Reference Card for Org Mode
-\def\orgversionnumber{4.24}
+\def\orgversionnumber{4.26}
 \def\year{2006}
 %
 %**start of header
--- a/leim/leim-ext.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/leim-ext.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;; leim-ext.el -- extra leim configulation	-*- coding:iso-2022-7bit; -*-
 
-;; Copyright (C) 2004
+;; Copyright (C) 2004, 2006
 ;;   Free Software Foundation, Inc.
 ;; Copyright (C) 2004, 2005
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
--- a/leim/makefile.w32-in	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/makefile.w32-in	Fri Apr 28 14:48:18 2006 +0000
@@ -1,5 +1,5 @@
 # -*- Makefile -*- for leim subdirectory in GNU Emacs on the Microsoft W32 API.
-# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005
+# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006
 #   Free Software Foundation, Inc.
 # Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
 #   National Institute of Advanced Industrial Science and Technology (AIST)
--- a/leim/quail/croatian.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/croatian.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; quail/croatian.el -- Quail package for inputing Croatian  -*-coding: iso-8859-2;-*-
 
-;; Copyright (C) 2003 Free Software Foundation, Inc.
+;; Copyright (C) 2003, 2006 Free Software Foundation, Inc.
 
 ;; Author: Hrvoje Nik¹iæ <hniksic@xemacs.org>,
 ;;         modeled after czech.el by Milan Zamazal.
--- a/leim/quail/cyril-jis.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/cyril-jis.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; cyril-jis.el --- Quail package for inputting JISX0208 Cyrillic letters
 
-;; Copyright (C) 2001  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/cyrillic.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/cyrillic.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; cyrillic.el --- Quail package for inputting Cyrillic characters
 
-;; Copyright (C) 1997, 1998, 2001, 2002, 2003, 2004, 2005
+;; Copyright (C) 1997, 1998, 2001, 2002, 2003, 2004, 2005, 2006
 ;;   Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 2003
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
--- a/leim/quail/czech.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/czech.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; czech.el --- Quail package for inputting Czech -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1998, 2001  Free Software Foundation, Inc.
+;; Copyright (C) 1998, 2001, 2006  Free Software Foundation, Inc.
 
 ;; Author: Milan Zamazal <pdm@zamazal.org>
 ;; Maintainer: Pavel Jan,Bm(Bk <Pavel@Janik.cz>
--- a/leim/quail/ethiopic.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/ethiopic.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; ethiopic.el --- Quail package for inputting Ethiopic characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1998, 1999, 2001
+;; Copyright (C) 1997, 1998, 1999, 2001, 2006
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
 
--- a/leim/quail/georgian.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/georgian.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; georgian.el --- Quail package for inputting Georgian characters  -*-coding: utf-8;-*-
 
-;; Copyright (C) 2001  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006  Free Software Foundation, Inc.
 
 ;; Author: Dave Love <fx@gnu.org>
 ;; Keywords: i18n
--- a/leim/quail/greek.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/greek.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; greek.el --- Quail package for inputting Greek -*-coding: iso-2022-7bit-*-
 
-;; Copyright (C) 2001, 2002, 2003, 2004  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2002, 2003, 2004, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 2001
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/hangul.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/hangul.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; hangul.el --- Quail package for inputting Korean Hangul characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 2002  Free Software Foundation, Inc.
+;; Copyright (C) 2002, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/hangul3.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/hangul3.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; hangul3.el --- Quail package for inputting Korean Hangul characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1998, 2001, 2002  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1998, 2001, 2002, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 2002
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/hanja.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/hanja.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; hanja.el --- Quail-package for Korean Hanja (KSC5601)  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997 Free Software Foundation, Inc.
+;; Copyright (C) 1997, 2006 Free Software Foundation, Inc.
 ;; Copyright (C) 1997
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/hanja3.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/hanja3.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; hanja3.el --- Quail-package for Korean Hanja (KSC5601)  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1999, 2002  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1999, 2002, 2006  Free Software Foundation, Inc.
 
 ;; Author: Koaunghi Un <koanughi.un@zdv.uni-tuebingen.de>
 ;; Keywords: mule, quail, multilingual, input method, Korean, Hanja
--- a/leim/quail/indian.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/indian.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; indian.el --- Quail packages for inputting Indian
 
-;; Copyright (C) 2000, 2001, 2002, 2003  Free Software Foundation, Inc.
+;; Copyright (C) 2000, 2001, 2002, 2003, 2006  Free Software Foundation, Inc.
 
 ;; Author: KAWABATA, Taichi <kawabata@m17n.org>
 
--- a/leim/quail/japanese.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/japanese.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; japanese.el --- Quail package for inputting Japanese  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 2001  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2005
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/latin-alt.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/latin-alt.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; latin-alt.el --- Quail package for inputting various European characters -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1998, 2001, 2002  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1998, 2001, 2002, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1999
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/latin-ltx.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/latin-ltx.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; latin-ltx.el --- Quail package for TeX-style input -*-coding: utf-8;-*-
 
-;; Copyright (C) 2001, 2003, 2004, 2005  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2003, 2004, 2005, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 2001, 2005
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/latin-post.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/latin-post.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; latin-post.el --- Quail packages for inputting various European characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1998, 2001, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1998, 2001, 2002, 2006 Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1999
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/latin-pre.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/latin-pre.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; latin-pre.el --- Quail packages for inputting various European characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003
+;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2006
 ;;   Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1998, 1999, 2000, 2005
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
--- a/leim/quail/lrt.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/lrt.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; lrt.el --- Quail package for inputting Lao characters by LRT method  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1998  Free Software Foundation, Inc.
+;; Copyright (C) 1998, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1999
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/py-punct.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/py-punct.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; py-punct.el --- Quail packages for Chinese (pinyin + extra symbols)  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 2001 Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 2000
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
Binary file leim/quail/rfc1345.el has changed
--- a/leim/quail/sgml-input.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/sgml-input.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; sgml-input.el --- Quail method for Unicode entered as SGML entities -*- coding: utf-8 -*-
 
-;; Copyright (C) 2001  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006  Free Software Foundation, Inc.
 
 ;; Author: Dave Love <fx@gnu.org>
 ;; Keywords: i18n
--- a/leim/quail/sisheng.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/sisheng.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; sisheng.el --- sisheng input method for Chinese pinyin transliteration
 
-;; Copyright (C) 2004  Free Software Foundation, Inc.
+;; Copyright (C) 2004, 2006  Free Software Foundation, Inc.
 
 ;; Author: Werner LEMBERG <wl@gnu.org>
 
--- a/leim/quail/slovak.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/slovak.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; slovak.el --- Quail package for inputting Slovak  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 1998, 2001 Free Software Foundation, Inc.
+;; Copyright (C) 1998, 2001, 2006 Free Software Foundation, Inc.
 
 ;; Authors: Tibor ,B)(Bimko <tibor.simko@fmph.uniba.sk>
 ;;	Milan Zamazal <pdm@zamazal.org>
--- a/leim/quail/symbol-ksc.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/symbol-ksc.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; symbol-ksc.el --- Quail-package for Korean Symbol (KSC5601)
 
-;; Copyright (C) 1997, 2005  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 2005, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1998
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/tibetan.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/tibetan.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; tibetan.el --- Quail package for inputting Tibetan characters
 
-;; Copyright (C) 1997  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 1997, 1998, 1999, 2000
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/uni-input.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/uni-input.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; uni-input.el --- Hex Unicode input method
 
-;; Copyright (C) 2001, 2003  Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2003, 2006  Free Software Foundation, Inc.
 ;; Copyright (C) 2004
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
--- a/leim/quail/vntelex.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/vntelex.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; vntelex.el --- Quail package for Vietnamese by Telex method
 
-;; Copyright (C) 2001, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc.
 
 ;; Author:   Werner Lemberg <wl@gnu.org>
 ;; Keywords: multilingual, input method, Vietnamese
--- a/leim/quail/welsh.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/leim/quail/welsh.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1,6 +1,6 @@
 ;;; welsh.el --- Quail package for inputting Welsh characters  -*-coding: iso-2022-7bit;-*-
 
-;; Copyright (C) 2001 Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
 ;; Author: Dave Love <fx@gnu.org>
 ;; Keywords: i18n
--- a/lisp/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,207 @@
+2006-04-27  Jay Belanger  <belanger@truman.edu>
+
+	* calc-embed.el (calc-embedded-make-info): Use `math-read-expr' to
+	read expression when `math-read-big-expr' doesn't work.
+
+2006-04-27  Reiner Steib  <Reiner.Steib@gmx.de>
+
+	* startup.el (command-line-1): Display warning when
+	pure-space-overflow is non-nil.
+
+2006-04-26  Roland Winkler  <Roland.Winkler@physik.uni-erlangen.de>
+
+	* textmodes/bibtex.el (bibtex-user-optional-fields): Mark as
+	risky.
+
+2006-04-26  Roland Winkler  <Roland.Winkler@physik.uni-erlangen.de>
+
+	* textmodes/bibtex.el (bibtex-url): New optional arg no-browse.
+	Return the URL or nil if none can be generated.
+
+2006-04-27  Nick Roberts  <nickrob@snap.net.nz>
+
+	* progmodes/gud.el (gud-comint-buffer): Move forward to stop
+	byte compiler warnings.
+	(gud-basic-call, gud-find-expr): Let user select an expression
+	for printing.  Print expression as well as value in GUD buffer.
+
+2006-04-17  Ken Manheimer  <ken.manheimer@gmail.com>
+
+	* allout.el: Remove local autoload declaration for
+	pgg-gpg-symmetric-key-p, since that's now done in pgg-gpg.el.
+	(allout-show-bodies, allout-header-prefix, allout-primary-bullet)
+	(allout-plain-bullets-string, allout-distinctive-bullets-string)
+	(allout-use-mode-specific-leader, allout-old-style-prefixes)
+	(allout-stylish-prefixes, allout-numbered-bullet)
+	(allout-file-xref-bullet, allout-presentation-padding)
+	(allout-use-hanging-indents, allout-reindent-bodies): Mark as
+	safe-local-variable with suitable value spec, and add autoload
+	cookie for loaddefs inclusion.  We now use an explicit spec everywhere.
+	(move-beginning-of-line, move-end-of-line): Repair so these compat
+	functions now actually resituate the point, when appropriate.
+
+2006-04-26  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* progmodes/cc-subword.el (c-subword-mode-map): Use command remapping.
+
+	* add-log.el (add-log-iso8601-time-zone): Make parameter optional.
+	(add-log-iso8601-time-string): Fix call to format-time-string.
+
+2006-04-26  Kim F. Storm  <storm@cua.dk>
+
+	* subr.el (posn-string, posn-image, posn-object): Doc fix.
+
+2006-04-26  Masatake YAMATO  <jet@gyve.org>
+
+	* progmodes/asm-mode.el (asm-mode, asm-mode-syntax-table):
+	Add support for "//" style comments.  Remove `b' flag
+	from ?* in `asm-mode-syntax-table'.
+
+2006-04-26  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* follow.el: Use (featurep 'xemacs) everywhere.
+	(follow-mode): Use define-minor-mode.
+	(follow-mode-map): Move initialization into the declaration.
+	Use command remapping.
+	(follow-emacs-version-xemacs-p): Remove.
+	(follow-submit-feedback): Remove.
+
+	* allout.el (allout-layout, allout-passphrase-verifier-string)
+	(allout-passphrase-hint-string): Tighten up a bit the safety predicate.
+
+	* textmodes/reftex-vars.el (reftex-vref-is-default)
+	(reftex-fref-is-default, reftex-guess-label-type):
+	Tighten up a bit the safety predicate.
+
+	* textmodes/paragraphs.el (sentence-end-double-space)
+	(sentence-end-without-period, sentence-end-without-space)
+	(page-delimiter, paragraph-ignore-fill-prefix):
+	Tighten up a bit the safety predicate.
+
+	* textmodes/fill.el (colon-double-space): Tighten up the safety pred.
+
+	* progmodes/python.el (python-continuation-line-p)
+	(python-beginning-of-statement): syntax-ppss may return
+	a negative depth.
+	(python-mode): Don't forcefully enable font-lock.
+
+	* time-stamp.el (time-stamp-start, time-stamp-end)
+	(time-stamp-inserts-lines): Tighten up a bit the safety predicate.
+
+	* add-log.el: Remove spurious * in docstrings.
+	(add-log-time-zone-rule): Rename from change-log-time-zone-rule.
+	(add-change-log-entry): Use it here, since it's not specific
+	to iso8601.
+	(add-log-iso8601-time-string): Don't use it here any more.
+	(change-log-indent-text, change-log-indent): Rename from add-log-*.
+
+	* abbrev.el (abbrev-mode): Tighten up a bit the safety predicate.
+
+2006-04-25  Ryan Yeske  <rcyeske@gmail.com>
+
+	* net/rcirc.el (rcirc-print): Revert last change with ignored nicks.
+	(rcirc-toggle-low-priority): Doc fix.
+	(rcirc-handler-NOTICE): Remove beginning of line anchor in
+	ChanServ regexp.
+	(rcirc-startup-channels-alist): Connect to #rcirc by default, not
+	#emacs.
+	(rcirc-bright-nick-regexp, rcirc-dim-nick-regexp): Add variables.
+	(rcirc-decode-coding-system): Use utf-8 as the default.
+	(rcirc-multiline-minor-mode): Set the fill-column.
+	(rcirc-format-response-string): Display bright and dim nicks.
+	(rcirc-browse-url): Update interactive spec to fill ARG.
+	(rcirc-bright-nick, rcirc-dim-nick): Add faces.
+	(rcirc-print): Ignore dim-nick messages wrt modeline-activity.
+
+2006-04-24  J.D. Smith  <jdsmith@as.arizona.edu>
+
+	* textmodes/bibtex.el (bibtex-find-entry): Don't demand matching
+	case for @Article, etc.
+
+2006-04-23  Michael Albinus  <michael.albinus@gmx.de>
+
+	* net/tramp.el (tramp-register-file-name-handlers): New defun.
+	Added with autoload cookie.
+	(tramp-unload-file-name-handlers): Rename from
+	`tramp-unload-file-name-handler-alist'.
+
+2006-04-23  Romain Francoise  <romain@orebokech.com>
+
+	* comint.el (comint-match-partial-filename): Doc fix.
+
+2006-04-21  Glenn Morris  <rgm@gnu.org>
+
+	* calendar/cal-menu.el (calendar-mode-map): Refer to
+	`diary-view-entries' rather than alias `view-diary-entries'.
+	* calendar/diary-lib.el (view-other-diary-entries): Ditto.
+
+2006-04-21  Luc Teirlinck  <teirllm@auburn.edu>
+
+	* progmodes/antlr-mode.el (antlr-default):
+	* cus-edit.el (custom-documentation):
+	* faces.el (scroll-bar, border, cursor, mouse): Avoid nil spec
+	in defface.
+
+2006-04-21  Kim F. Storm  <storm@cua.dk>
+
+	* image.el (image-type): New defun split out of create-image.
+	(create-image): Use it.
+
+2006-04-21  Carsten Dominik  <dominik@science.uva.nl>
+
+	* textmodes/org.el (org-mode-map): Catch conflict with old allout.el.
+	(org-open-at-point): Remove the "...done" message to keep output
+	in the echo area visible.
+	(org-export-as-xoxo): Fix call to `indent-region'.
+
+2006-04-21  Kevin Ryde  <user42@zip.com.au>
+
+	* international/mule.el (keyboard-coding-system): defcustom
+	info-link fixes: "Specify Coding" has been split, keyboard now in
+	"Terminal Coding", and "Single-Byte Character Support" is now
+	"Unibyte Mode".
+
+2006-04-21  Nick Roberts  <nickrob@snap.net.nz>
+
+	* progmodes/gdb-ui.el (gdb-data-list-register-values-handler):
+	Use font-lock-warning-face for any errors e.g. no stack.
+	(gdb-stack-list-locals-handler): Display any errors e.g. no stack.
+
+2006-04-20  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* progmodes/sh-script.el (sh-shell): Mark as safe.
+
+	* newcomment.el (comment-start, comment-start-skip)
+	(comment-end-skip, comment-end): Mark as safe.
+
+2006-04-20  Carsten Dominik  <dominik@science.uva.nl>
+
+	* textmodes/org.el (org-deadline-announce): Face removed.
+	(org-level-faces, org-n-levels): Convert to constant.
+	(org-compatible-face): New function.
+	(org-hide, org-level-1, org-level-2, org-level-3, org-level-4)
+	(org-level-5, org-level-6, org-level-7, org-level-8)
+	(org-special-keyword, org-warning, org-headline-done, org-link)
+	(org-date, org-tag, org-todo, org-done, org-table, org-formula)
+	(org-scheduled-today, org-scheduled-previously, org-time-grid):
+	Face definition revised for better color tty support.
+	(org-bold-re, org-italic-re, org-underline-re): New constants.
+	(org-set-font-lock-defaults): Use the new constants.
+	(org-agenda-highlight-todo): New function.
+	(org-agenda-todo): Fix bug with point at end of line.
+	(org-agenda-change-all-lines, org-finalize-agenda-entries):
+	Fontify TODO keywords.
+	(org-insert-link): Preserve relative path in ../ links.
+	(org-export-as-html): Convert links pointing to .org files into
+	links that will work beteen the exported HTML files.
+	(org-todo-list): Fix bug when arg=0.
+	(org-insert-heading): More fine-tuning.
+
+2006-04-19  Romain Francoise  <romain@orebokech.com>
+
+	* mail/rmail.el (rmail-convert-to-babyl-format): Use second group
+	from `rmail-mime-charset-pattern'.
+
 2006-04-18  Dan Nicolaescu  <dann@ics.uci.edu>
 
 	* progmodes/python.el (python-mode): Fix typo.
@@ -8,12 +212,11 @@
 	when moving off either end of the input history ring.
 	(comint-delete-input): New function, used by
 	`comint-previous-input' and others.
-	(comint-previous-matching-input): Use
-	`coming-delete-input'. Save the partial input if leaving the
+	(comint-previous-matching-input):
+	Use `coming-delete-input'.  Save the partial input if leaving the
 	edit line.  Goto point-max before deleting input to avoid
 	partial input fragments hanging around.
-	(comint-restore-input): New function, used by
-	`comint-previous-input', and bound to "C-c C-j".
+	(comint-restore-input): New function, used by `comint-previous-input'.
 
 2006-04-18  Luc Teirlinck  <teirllm@auburn.edu>
 
@@ -21,8 +224,7 @@
 
 2006-04-18  Dan Nicolaescu  <dann@ics.uci.edu>
 
-	* progmodes/python.el (python-mode): Add support for
-	hs-minor-mode.
+	* progmodes/python.el (python-mode): Add support for hs-minor-mode.
 
 2006-04-19  Reiner Steib  <Reiner.Steib@gmx.de>
 
@@ -100,7 +302,7 @@
 	(gdb-frame-address): Re-use to identify frame for watch expression.
 	(gdb-var-list, gdb-var-create-handler): Add frame address for root
 	variables.
-	(gdb-init-1, gdb-source, gdb-post-prompt, )
+	(gdb-init-1, gdb-source, gdb-post-prompt)
 	(gdb-assembler-custom, gdb-invalidate-assembler): Use gdb-pc-address.
 	(gdb-frame-handler): Get gdb-frame-address.
 
@@ -181,7 +383,7 @@
 
 2006-04-13  Carsten Dominik  <dominik@science.uva.nl>
 
-	* textmodes/org.el: (org-set-regexps-and-options)
+	* textmodes/org.el (org-set-regexps-and-options)
 	(org-get-current-options): Better names for the startup folding
 	options.
 
@@ -190,7 +392,7 @@
 	* vc.el (vc-annotate): Arrange for point to end up at the same
 	line number as in the original, but only when using a new buffer.
 
-2006-04-12  Davis Herring  <herring@lanl.gov>  (tiny change)
+2006-04-12  Stuart Herring  <herring@lanl.gov>  (tiny change)
 
 	* files.el (hack-one-local-variable-eval-safep):
 	Recognize `edebug-form-spec' for `put', but only if it passes
@@ -204,7 +406,7 @@
 
 2006-04-13  Carsten Dominik  <dominik@science.uva.nl>
 
-	* textmodes/org.el: (org-ctrl-c-ctrl-c): Improve documentation string.
+	* textmodes/org.el (org-ctrl-c-ctrl-c): Improve documentation string.
 	(org-agenda-mouse-1-follows-link)
 	(org-mouse-1-follows-link): New options.
 	(org-format-agenda-item): Fix bug if TAGS is nil.
@@ -4554,7 +4756,7 @@
 	display-multi-frame-p, use selected-frame when menu-updating-frame
 	is nil.
 
-2005-12-20  Davis Herring  <herring@lanl.gov>  (tiny change)
+2005-12-20  Stuart Herring  <herring@lanl.gov>  (tiny change)
 
 	* align.el (align-rules-list): Use [ \t] instead of \s-
 	for column separators in text mode.
--- a/lisp/ChangeLog.11	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/ChangeLog.11	Fri Apr 28 14:48:18 2006 +0000
@@ -5065,7 +5065,7 @@
 
 	* imenu.el: Several doc fixes: don't say variables are buffer-local.
 
-2004-08-16  Davis Herring  <herring@lanl.gov>
+2004-08-16  Stuart Herring  <herring@lanl.gov>
 
 	* isearch.el (isearch-string, isearch-message-string, isearch-point)
 	(isearch-success, isearch-forward-flag, isearch-other-end)
@@ -5082,7 +5082,7 @@
 	* term/x-win.el (x-selection-value): If utf8 was successful but
 	ctext was not, use utf8 string.
 
-2004-08-14  Davis Herring  <herring@lanl.gov>
+2004-08-14  Stuart Herring  <herring@lanl.gov>
 
 	* isearch.el: Remove accidental changes of March 4.  Fix backing
 	up when a regexp isearch is made more general.  Use symbolic
@@ -11471,7 +11471,7 @@
 
 	* files.el (kill-some-buffers): Doc fix.
 
-2003-12-29  David Herring  <sdh6@ra.msstate.edu>  (tiny change)
+2003-12-29  Stuart Herring  <herring@lanl.gov>  (tiny change)
 
 	* comint.el (comint-watch-for-password-prompt): Pass `string' as
 	arg to send-invisible
--- a/lisp/abbrev.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/abbrev.el	Fri Apr 28 14:48:18 2006 +0000
@@ -58,7 +58,7 @@
 to enable or disable Abbrev mode in the current buffer."
   :type 'boolean
   :group 'abbrev-mode)
-;;;###autoload(put 'abbrev-mode 'safe-local-variable t)
+;;;###autoload(put 'abbrev-mode 'safe-local-variable 'symbolp)
 
 
 (defvar edit-abbrevs-map
@@ -363,5 +363,5 @@
 	    (if (or noquery (y-or-n-p (format "Expand `%s'? " string)))
 		(expand-abbrev)))))))
 
-;;; arch-tag: dbd6f3ae-dfe3-40ba-b00f-f9e3ff960df5
+;; arch-tag: dbd6f3ae-dfe3-40ba-b00f-f9e3ff960df5
 ;;; abbrev.el ends here
--- a/lisp/add-log.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/add-log.el	Fri Apr 28 14:48:18 2006 +0000
@@ -72,7 +72,7 @@
 
 ;;;###autoload
 (defcustom add-log-mailing-address nil
-  "*Email addresses of user, for inclusion in ChangeLog headers.
+  "Email addresses of user, for inclusion in ChangeLog headers.
 This defaults to the value of `user-mail-address'.  In addition to
 being a simple string, this value can also be a list.  All elements
 will be recognized as referring to the same user; when creating a new
@@ -83,7 +83,7 @@
   :group 'change-log)
 
 (defcustom add-log-time-format 'add-log-iso8601-time-string
-  "*Function that defines the time format.
+  "Function that defines the time format.
 For example, `add-log-iso8601-time-string', which gives the
 date in international ISO 8601 format,
 and `current-time-string' are two valid values."
@@ -95,7 +95,7 @@
   :group 'change-log)
 
 (defcustom add-log-keep-changes-together nil
-  "*If non-nil, normally keep day's log entries for one file together.
+  "If non-nil, normally keep day's log entries for one file together.
 
 Log entries for a given file made with \\[add-change-log-entry] or
 \\[add-change-log-entry-other-window] will only be added to others \
@@ -127,20 +127,20 @@
   :group 'change-log)
 
 (defcustom add-log-always-start-new-record nil
-  "*If non-nil, `add-change-log-entry' will always start a new record."
+  "If non-nil, `add-change-log-entry' will always start a new record."
   :version "22.1"
   :type 'boolean
   :group 'change-log)
 
 (defcustom add-log-buffer-file-name-function nil
-  "*If non-nil, function to call to identify the full filename of a buffer.
+  "If non-nil, function to call to identify the full filename of a buffer.
 This function is called with no argument.  If this is nil, the default is to
 use `buffer-file-name'."
   :type '(choice (const nil) function)
   :group 'change-log)
 
 (defcustom add-log-file-name-function nil
-  "*If non-nil, function to call to identify the filename for a ChangeLog entry.
+  "If non-nil, function to call to identify the filename for a ChangeLog entry.
 This function is called with one argument, the value of variable
 `buffer-file-name' in that buffer.  If this is nil, the default is to
 use the file's name relative to the directory of the change log file."
@@ -286,12 +286,16 @@
     map)
   "Keymap for Change Log major mode.")
 
-(defvar change-log-time-zone-rule nil
+;; It used to be called change-log-time-zone-rule but really should be
+;; called add-log-time-zone-rule since it's only used from add-log-* code.
+(defvaralias 'change-log-time-zone-rule 'add-log-time-zone-rule)
+(defvar add-log-time-zone-rule nil
   "Time zone used for calculating change log time stamps.
 It takes the same format as the TZ argument of `set-time-zone-rule'.
-If nil, use local time.")
+If nil, use local time.
+If t, use universal time.")
 
-(defun add-log-iso8601-time-zone (time)
+(defun add-log-iso8601-time-zone (&optional time)
   (let* ((utc-offset (or (car (current-time-zone time)) 0))
 	 (sign (if (< utc-offset 0) ?- ?+))
 	 (sec (abs utc-offset))
@@ -304,18 +308,14 @@
 		  (t "%c%02d"))
 	    sign hh mm ss)))
 
+(defvar add-log-iso8601-with-time-zone nil)
+
 (defun add-log-iso8601-time-string ()
-  (if change-log-time-zone-rule
-      (let ((tz (getenv "TZ"))
-	    (now (current-time)))
-	(unwind-protect
-	    (progn
-	      (set-time-zone-rule change-log-time-zone-rule)
-	      (concat
-	       (format-time-string "%Y-%m-%d " now)
-	       (add-log-iso8601-time-zone now)))
-	  (set-time-zone-rule tz)))
-    (format-time-string "%Y-%m-%d")))
+  (let ((time (format-time-string "%Y-%m-%d"
+                                  nil (eq t add-log-time-zone-rule))))
+    (if add-log-iso8601-with-time-zone
+        (concat time " " (add-log-iso8601-time-zone))
+      time)))
 
 (defun change-log-name ()
   "Return (system-dependent) default name for a change log file."
@@ -494,7 +494,7 @@
 permission notice.  The first blank line indicates the end of these
 notices.
 
-Today's date is calculated according to `change-log-time-zone-rule' if
+Today's date is calculated according to `add-log-time-zone-rule' if
 non-nil, otherwise in local time."
   (interactive (list current-prefix-arg
 		     (prompt-for-change-log-name)))
@@ -538,13 +538,22 @@
       (skip-chars-forward "\n"))
 
     ;; Advance into first entry if it is usable; else make new one.
-    (let ((new-entries (mapcar (lambda (addr)
-				 (concat (funcall add-log-time-format)
-					 "  " full-name
-					 "  <" addr ">"))
-			       (if (consp mailing-address)
-				   mailing-address
-				 (list mailing-address)))))
+    (let ((new-entries
+           (mapcar (lambda (addr)
+                     (concat
+                      (if (stringp add-log-time-zone-rule)
+                          (let ((tz (getenv "TZ")))
+                            (unwind-protect
+                                (progn
+                                  (set-time-zone-rule add-log-time-zone-rule)
+                                  (funcall add-log-time-format))
+                              (set-time-zone-rule tz)))
+                        (funcall add-log-time-format))
+                      "  " full-name
+                      "  <" addr ">"))
+                   (if (consp mailing-address)
+                       mailing-address
+                     (list mailing-address)))))
       (if (and (not add-log-always-start-new-record)
                (let ((hit nil))
 		 (dolist (entry new-entries hit)
@@ -652,21 +661,21 @@
   (add-change-log-entry whoami file-name t))
 ;;;###autoload (define-key ctl-x-4-map "a" 'add-change-log-entry-other-window)
 
-(defvar add-log-indent-text 0)
+(defvar change-log-indent-text 0)
 
-(defun add-log-indent ()
+(defun change-log-indent ()
   (let* ((indent
 	  (save-excursion
 	    (beginning-of-line)
 	    (skip-chars-forward " \t")
 	    (cond
-	     ((and (looking-at "\\(.*\\)  [^ \n].*[^ \n]  <.*>$")
+	     ((and (looking-at "\\(.*\\)  [^ \n].*[^ \n]  <.*>\\(?: +(.*)\\)? *$")
 		   ;; Matching the output of add-log-time-format is difficult,
 		   ;; but I'll get it has at least two adjacent digits.
 		   (string-match "[[:digit:]][[:digit:]]" (match-string 1)))
 	      0)
 	     ((looking-at "[^*(]")
-	      (+ (current-left-margin) add-log-indent-text))
+	      (+ (current-left-margin) change-log-indent-text))
 	     (t (current-left-margin)))))
 	 (pos (save-excursion (indent-line-to indent) (point))))
     (if (> pos (point)) (goto-char pos))))
@@ -688,7 +697,7 @@
 	tab-width 8)
   (set (make-local-variable 'fill-paragraph-function)
        'change-log-fill-paragraph)
-  (set (make-local-variable 'indent-line-function) 'add-log-indent)
+  (set (make-local-variable 'indent-line-function) 'change-log-indent)
   (set (make-local-variable 'tab-always-indent) nil)
   ;; We really do want "^" in paragraph-start below: it is only the
   ;; lines that begin at column 0 (despite the left-margin of 8) that
@@ -722,23 +731,23 @@
 
 (defcustom add-log-current-defun-header-regexp
   "^\\([[:upper:]][[:upper:]_ ]*[[:upper:]_]\\|[-_[:alpha:]]+\\)[ \t]*[:=]"
-  "*Heuristic regexp used by `add-log-current-defun' for unknown major modes."
+  "Heuristic regexp used by `add-log-current-defun' for unknown major modes."
   :type 'regexp
   :group 'change-log)
 
 ;;;###autoload
 (defvar add-log-lisp-like-modes
-    '(emacs-lisp-mode lisp-mode scheme-mode dsssl-mode lisp-interaction-mode)
+  '(emacs-lisp-mode lisp-mode scheme-mode dsssl-mode lisp-interaction-mode)
   "*Modes that look like Lisp to `add-log-current-defun'.")
 
 ;;;###autoload
 (defvar add-log-c-like-modes
-    '(c-mode c++-mode c++-c-mode objc-mode)
+  '(c-mode c++-mode c++-c-mode objc-mode)
   "*Modes that look like C to `add-log-current-defun'.")
 
 ;;;###autoload
 (defvar add-log-tex-like-modes
-    '(TeX-mode plain-TeX-mode LaTeX-mode plain-tex-mode latex-mode)
+  '(TeX-mode plain-TeX-mode LaTeX-mode plain-tex-mode latex-mode)
   "*Modes that look like TeX to `add-log-current-defun'.")
 
 ;;;###autoload
@@ -1103,5 +1112,5 @@
 
 (provide 'add-log)
 
-;;; arch-tag: 81eee6fc-088f-4372-a37f-80ad9620e762
+;; arch-tag: 81eee6fc-088f-4372-a37f-80ad9620e762
 ;;; add-log.el ends here
--- a/lisp/allout.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/allout.el	Fri Apr 28 14:48:18 2006 +0000
@@ -84,8 +84,6 @@
                           (require 'pgg-gpg)
                           (require 'overlay)
 			  ))
-(autoload 'pgg-gpg-symmetric-key-p "pgg-gpg"
-  "True if decoded armor MESSAGE-KEYS has symmetric encryption indicator.")
 
 ;;;_* USER CUSTOMIZATION VARIABLES:
 
@@ -199,6 +197,9 @@
   :type 'boolean
   :group 'allout)
 (make-variable-buffer-local 'allout-show-bodies)
+;;;###autoload
+(put 'allout-show-bodies 'safe-local-variable
+     (lambda (x) (member x '(t nil))))
 
 ;;;_  = allout-header-prefix
 (defcustom allout-header-prefix "."
@@ -212,6 +213,8 @@
   :type 'string
   :group 'allout)
 (make-variable-buffer-local 'allout-header-prefix)
+;;;###autoload
+(put 'allout-header-prefix 'safe-local-variable 'stringp)
 ;;;_  = allout-primary-bullet
 (defcustom allout-primary-bullet "*"
   "Bullet used for top-level outline topics.
@@ -227,6 +230,8 @@
   :type 'string
   :group 'allout)
 (make-variable-buffer-local 'allout-primary-bullet)
+;;;###autoload
+(put 'allout-primary-bullet 'safe-local-variable 'stringp)
 ;;;_  = allout-plain-bullets-string
 (defcustom allout-plain-bullets-string ".,"
   "*The bullets normally used in outline topic prefixes.
@@ -241,6 +246,8 @@
   :type 'string
   :group 'allout)
 (make-variable-buffer-local 'allout-plain-bullets-string)
+;;;###autoload
+(put 'allout-plain-bullets-string 'safe-local-variable 'stringp)
 ;;;_  = allout-distinctive-bullets-string
 (defcustom allout-distinctive-bullets-string "*+-=>()[{}&!?#%\"X@$~_\\:;^"
   "*Persistent outline header bullets used to distinguish special topics.
@@ -274,6 +281,8 @@
   :type 'string
   :group 'allout)
 (make-variable-buffer-local 'allout-distinctive-bullets-string)
+;;;###autoload
+(put 'allout-distinctive-bullets-string 'safe-local-variable 'stringp)
 
 ;;;_  = allout-use-mode-specific-leader
 (defcustom allout-use-mode-specific-leader t
@@ -292,7 +301,7 @@
 Set to the symbol for either of `allout-mode-leaders' or
 `comment-start' to use only one of them, respectively.
 
-Value nil means to always use the default \(`.').
+Value nil means to always use the default \(`.').t
 
 comment-start strings that do not end in spaces are tripled, and an
 `_' underscore is tacked on the end, to distinguish them from regular
@@ -305,6 +314,9 @@
 		 (const allout-mode-leaders)
 		 (const comment-start))
   :group 'allout)
+;;;###autoload
+(put 'allout-use-mode-specific-leader 'safe-local-variable
+     (lambda (x) (or (member x '(t nil)) (stringp x))))
 ;;;_  = allout-mode-leaders
 (defvar allout-mode-leaders '()
   "Specific allout-prefix leading strings per major modes.
@@ -330,6 +342,9 @@
   :type 'boolean
   :group 'allout)
 (make-variable-buffer-local 'allout-old-style-prefixes)
+;;;###autoload
+(put 'allout-old-style-prefixes 'safe-local-variable
+     (lambda (x) (member x '(t nil))))
 ;;;_  = allout-stylish-prefixes - alternating bullets
 (defcustom allout-stylish-prefixes t
   "*Do fancy stuff with topic prefix bullets according to level, etc.
@@ -376,6 +391,9 @@
   :type 'boolean
   :group 'allout)
 (make-variable-buffer-local 'allout-stylish-prefixes)
+;;;###autoload
+(put 'allout-stylish-prefixes 'safe-local-variable
+     (lambda (x) (member x '(t nil))))
 
 ;;;_  = allout-numbered-bullet
 (defcustom allout-numbered-bullet "#"
@@ -388,6 +406,9 @@
   :type '(choice (const nil) string)
   :group 'allout)
 (make-variable-buffer-local 'allout-numbered-bullet)
+;;;###autoload
+(put 'allout-numbered-bullet 'safe-local-variable
+     (lambda (x) (or (not x) (stringp x))))
 ;;;_  = allout-file-xref-bullet
 (defcustom allout-file-xref-bullet "@"
   "*Bullet signifying file cross-references, for `allout-resolve-xref'.
@@ -395,6 +416,9 @@
 Set this var to the bullet you want to use for file cross-references."
   :type '(choice (const nil) string)
   :group 'allout)
+;;;###autoload
+(put 'allout-file-xref-bullet 'safe-local-variable
+     (lambda (x) (or (not x) (stringp x))))
 ;;;_  = allout-presentation-padding
 (defcustom allout-presentation-padding 2
   "*Presentation-format white-space padding factor, for greater indent."
@@ -402,6 +426,8 @@
   :group 'allout)
 
 (make-variable-buffer-local 'allout-presentation-padding)
+;;;###autoload
+(put 'allout-presentation-padding 'safe-local-variable 'integerp)
 
 ;;;_  = allout-abbreviate-flattened-numbering
 (defcustom allout-abbreviate-flattened-numbering nil
@@ -455,11 +481,16 @@
   :group 'allout)
 
 ;;;_ + Topic encryption
+;;;_  = allout-encryption group
+(defgroup allout-encryption nil
+  "Settings for topic encryption features of allout outliner."
+  :group 'allout)
 ;;;_  = allout-topic-encryption-bullet
 (defcustom allout-topic-encryption-bullet "~"
   "*Bullet signifying encryption of the entry's body."
   :type '(choice (const nil) string)
-  :group 'allout)
+  :version "22.0"
+  :group 'allout-encryption)
 ;;;_  = allout-passphrase-verifier-handling
 (defcustom allout-passphrase-verifier-handling t
   "*Enable use of symmetric encryption passphrase verifier if non-nil.
@@ -467,7 +498,8 @@
 See the docstring for the `allout-enable-file-variable-adjustment'
 variable for details about allout ajustment of file variables."
   :type 'boolean
-  :group 'allout)
+  :version "22.0"
+  :group 'allout-encryption)
 (make-variable-buffer-local 'allout-passphrase-verifier-handling)
 ;;;_  = allout-passphrase-hint-handling
 (defcustom allout-passphrase-hint-handling 'always
@@ -482,7 +514,8 @@
   :type '(choice (const always)
                  (const needed)
                  (const disabled))
-  :group 'allout)
+  :version "22.0"
+  :group 'allout-encryption)
 (make-variable-buffer-local 'allout-passphrase-hint-handling)
 ;;;_  = allout-encrypt-unencrypted-on-saves
 (defcustom allout-encrypt-unencrypted-on-saves t
@@ -514,7 +547,8 @@
   :type '(choice (const :tag "Yes" t)
                  (const :tag "All except current topic" except-current)
                  (const :tag "No" nil))
-  :group 'allout)
+  :version "22.0"
+  :group 'allout-encryption)
 (make-variable-buffer-local 'allout-encrypt-unencrypted-on-saves)
 
 ;;;_ + Miscellaneous customization
@@ -585,6 +619,9 @@
   :type 'boolean
   :group 'allout)
 (make-variable-buffer-local 'allout-use-hanging-indents)
+;;;###autoload
+(put 'allout-use-hanging-indents 'safe-local-variable
+     (lambda (x) (member x '(t nil))))
 
 ;;;_  = allout-reindent-bodies
 (defcustom allout-reindent-bodies (if allout-use-hanging-indents
@@ -602,6 +639,9 @@
   :group 'allout)
 
 (make-variable-buffer-local 'allout-reindent-bodies)
+;;;###autoload
+(put 'allout-reindent-bodies 'safe-local-variable
+     (lambda (x) (member x '(nil t text force))))
 
 ;;;_  = allout-enable-file-variable-adjustment
 (defcustom allout-enable-file-variable-adjustment t
@@ -667,7 +707,9 @@
 case the value of `allout-default-layout' is used.")
 (make-variable-buffer-local 'allout-layout)
 ;;;###autoload
-(put 'allout-layout 'safe-local-variable t)
+(put 'allout-layout 'safe-local-variable
+     (lambda (x) (or (numberp x) (listp x) (integerp x)
+                     (member x '(: * + -)))))
 
 ;;;_  : Topic header format
 ;;;_   = allout-regexp
@@ -1053,7 +1095,8 @@
 the emacs buffer state, if file variable adjustments are enabled.  See
 `allout-enable-file-variable-adjustment' for details about that.")
 (make-variable-buffer-local 'allout-passphrase-verifier-string)
-(put 'allout-passphrase-verifier-string 'safe-local-variable t)
+;;;###autoload
+(put 'allout-passphrase-verifier-string 'safe-local-variable 'stringp)
 ;;;_   = allout-passphrase-hint-string
 (defvar allout-passphrase-hint-string ""
   "Variable used to retain reminder string for file's encryption passphrase.
@@ -1065,8 +1108,9 @@
 state, if file variable adjustments are enabled.  See
 `allout-enable-file-variable-adjustment' for details about that.")
 (make-variable-buffer-local 'allout-passphrase-hint-string)
-(put 'allout-passphrase-hint-string 'safe-local-variable t)
 (setq-default allout-passphrase-hint-string "")
+;;;###autoload
+(put 'allout-passphrase-hint-string 'safe-local-variable 'stringp)
 ;;;_   = allout-after-save-decrypt
 (defvar allout-after-save-decrypt nil
   "Internal variable, is nil or has the value of two points:
@@ -1573,6 +1617,12 @@
 				       ; epoch, minor-mode key bindings:
 	   (setq allout-mode-map
 		 (produce-allout-mode-map allout-keybindings-list))
+           (substitute-key-definition 'beginning-of-line
+                                      'move-beginning-of-line
+                                      allout-mode-map global-map)
+           (substitute-key-definition 'end-of-line
+                                      'move-end-of-line
+                                      allout-mode-map global-map)
 	   (produce-allout-mode-menubar-entries)
 	   (fset 'allout-mode-map allout-mode-map)
 				       ; Include on minor-mode-map-alist,
@@ -5778,17 +5828,14 @@
       (if (/= arg 1)
           (condition-case nil (line-move (1- arg)) (error nil)))
 
-      (let ((orig (point)))
-        ;; Move to beginning-of-line, ignoring fields and invisibles.
-        (skip-chars-backward "^\n")
-        (while (and (not (bobp)) (line-move-invisible-p (1- (point))))
-          (goto-char (if (featurep 'xemacs)
-                         (previous-property-change (point))
-                       (previous-char-property-change (point))))
-          (skip-chars-backward "^\n"))
-        (vertical-motion 0)
-        (if (/= orig (point))
-            (goto-char orig))))
+      ;; Move to beginning-of-line, ignoring fields and invisibles.
+      (skip-chars-backward "^\n")
+      (while (and (not (bobp)) (line-move-invisible-p (1- (point))))
+        (goto-char (if (featurep 'xemacs)
+                       (previous-property-change (point))
+                     (previous-char-property-change (point))))
+        (skip-chars-backward "^\n"))
+      (vertical-motion 0))
 )
 ;;;_  > move-end-of-line if necessary - older emacs, xemacs
 (if (not (fboundp 'move-end-of-line))
@@ -5802,8 +5849,7 @@
 To ignore intangibility, bind `inhibit-point-motion-hooks' to t."
       (interactive "p")
       (or arg (setq arg 1))
-      (let ((orig (point))
-            done)
+      (let (done)
         (while (not done)
           (let ((newpos
                  (save-excursion
@@ -5813,8 +5859,10 @@
                             (error nil))
                           (not (bobp))
                           (progn
-                            (while (and (not (bobp)) (line-move-invisible-p (1- (point))))
-                              (goto-char (previous-char-property-change (point))))
+                            (while (and (not (bobp))
+                                        (line-move-invisible-p (1- (point))))
+                              (goto-char
+                               (previous-char-property-change (point))))
                             (backward-char 1)))
                      (point)))))
             (goto-char newpos)
@@ -5827,9 +5875,7 @@
                   ;; and now we're not really at eol,
                   ;; keep going.
                   (setq arg 1)
-                (setq done t)))))
-        (if (/= orig (point))
-            (goto-char orig))))
+                (setq done t)))))))
   )
 ;;;_  > line-move-invisible-p if necessary
 (if (not (fboundp 'line-move-invisible-p))
--- a/lisp/calc/calc-embed.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/calc/calc-embed.el	Fri Apr 28 14:48:18 2006 +0000
@@ -932,7 +932,9 @@
 			     (substring str pref-len suff-pos)))
 		(if (string-match "[^ \t\n]" str)
 		    (setq pref-len 0
-			  val (math-read-big-expr str))
+			  val (condition-case nil
+                                  (math-read-big-expr str)
+                                (error (math-read-expr str))))
 		  (setq val nil))))
 	    (if (eq (car-safe val) 'error)
 		(setq val (list 'error
--- a/lisp/calendar/cal-menu.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/calendar/cal-menu.el	Fri Apr 28 14:48:18 2006 +0000
@@ -89,7 +89,7 @@
 (define-key calendar-mode-map [menu-bar diary mark]
  '("Mark All" . mark-diary-entries))
 (define-key calendar-mode-map [menu-bar diary view]
-  '("Cursor Date" . view-diary-entries))
+  '("Cursor Date" . diary-view-entries))
 (define-key calendar-mode-map [menu-bar diary view]
   '("Other File" . view-other-diary-entries))
 
--- a/lisp/calendar/diary-lib.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/calendar/diary-lib.el	Fri Apr 28 14:48:18 2006 +0000
@@ -79,7 +79,7 @@
    (list (prefix-numeric-value current-prefix-arg)
          (read-file-name "Enter diary file name: " default-directory nil t)))
   (let ((diary-file d-file))
-    (view-diary-entries arg)))
+    (diary-view-entries arg)))
 
 (autoload 'check-calendar-holidays "holidays"
   "Check the list of holidays for any that occur on DATE.
--- a/lisp/comint.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/comint.el	Fri Apr 28 14:48:18 2006 +0000
@@ -465,7 +465,6 @@
     (define-key map "\C-c\C-l" 	  'comint-dynamic-list-input-ring)
     (define-key map "\C-c\C-n" 	  'comint-next-prompt)
     (define-key map "\C-c\C-p" 	  'comint-previous-prompt)
-    (define-key map "\C-c\C-j" 	  'comint-restore-input)
     (define-key map "\C-c\C-d" 	  'comint-send-eof)
     (define-key map "\C-c\C-s" 	  'comint-write-output)
     (define-key map "\C-c." 	  'comint-insert-previous-argument)
@@ -2704,7 +2703,7 @@
     name))
 
 (defun comint-match-partial-filename ()
-  "Return the filename at point, or nil if non is found.
+  "Return the filename at point, or nil if none is found.
 Environment variables are substituted.  See `comint-word'."
   (let ((filename (comint-word comint-file-name-chars)))
     (and filename (comint-substitute-in-file-name
--- a/lisp/cus-edit.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/cus-edit.el	Fri Apr 28 14:48:18 2006 +0000
@@ -2089,7 +2089,7 @@
       'custom-button-pressed
     'custom-button-pressed-unraised))
 
-(defface custom-documentation nil
+(defface custom-documentation '((t nil))
   "Face used for documentation strings in customization buffers."
   :group 'custom-faces)
 ;; backward-compatibility alias
--- a/lisp/faces.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/faces.el	Fri Apr 28 14:48:18 2006 +0000
@@ -2190,19 +2190,19 @@
   :group 'frames
   :group 'basic-faces)
 
-(defface scroll-bar '()
+(defface scroll-bar '((t nil))
   "Basic face for the scroll bar colors under X."
   :version "21.1"
   :group 'frames
   :group 'basic-faces)
 
-(defface border '()
+(defface border '((t nil))
   "Basic face for the frame border under X."
   :version "21.1"
   :group 'frames
   :group 'basic-faces)
 
-(defface cursor '()
+(defface cursor '((t nil))
   "Basic face for the cursor color under X.
 Note: Other faces cannot inherit from the cursor face."
   :version "21.1"
@@ -2211,7 +2211,7 @@
 
 (put 'cursor 'face-no-inherit t)
 
-(defface mouse '()
+(defface mouse '((t nil))
   "Basic face for the mouse color under X."
   :version "21.1"
   :group 'mouse
--- a/lisp/follow.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/follow.el	Fri Apr 28 14:48:18 2006 +0000
@@ -7,7 +7,6 @@
 ;; Maintainer: FSF (Anders' email bounces, Sep 2005)
 ;; Created: 1995-05-25
 ;; Keywords: display, window, minor-mode, convenience
-;; Last Changed: 1999-11-17
 
 ;; This file is part of GNU Emacs.
 
@@ -46,14 +45,14 @@
 ;;   movement commands.
 ;;
 ;; Follow mode comes to its prime when a large screen and two
-;; side-by-side window are used. The user can, with the help of Follow
+;; side-by-side window are used.  The user can, with the help of Follow
 ;; mode, use two full-height windows as though they would have been
-;; one. Imagine yourself editing a large function, or section of text,
+;; one.  Imagine yourself editing a large function, or section of text,
 ;; and being able to use 144 lines instead of the normal 72... (your
 ;; mileage may vary).
 
 ;; To test this package, make sure `follow' is loaded, or will be
-;; autoloaded when activated (see below). Then do the following:
+;; autoloaded when activated (see below).  Then do the following:
 ;;
 ;; * Find your favorite file (preferably a long one).
 ;;
@@ -77,13 +76,13 @@
 ;;		    +----------+----------+
 ;;
 ;;   As you can see, the right-hand window starts at line 73, the line
-;;   immediately below the end of the left-hand window. As long as
+;;   immediately below the end of the left-hand window.  As long as
 ;;   `follow-mode' is active, the two windows will follow eachother!
 ;;
 ;; * Play around and enjoy! Scroll one window and watch the other.
-;;   Jump to the beginning or end. Press `Cursor down' at the last
-;;   line of the left-hand window. Enter new lines into the
-;;   text. Enter long lines spanning several lines, or several
+;;   Jump to the beginning or end.  Press `Cursor down' at the last
+;;   line of the left-hand window.  Enter new lines into the
+;;   text.  Enter long lines spanning several lines, or several
 ;;   windows.
 ;;
 ;; * Should you find `Follow' mode annoying, just type
@@ -146,7 +145,7 @@
 ;; Usage:
 ;;
 ;; To activate issue the command "M-x follow-mode"
-;; and press return. To deactivate, do it again.
+;; and press return.  To deactivate, do it again.
 ;;
 ;; The following is a list of commands useful when follow-mode is active.
 ;;
@@ -197,7 +196,7 @@
 ;;    in the same frame. (My apoligies to you who can't use frames.)
 ;;
 ;; 2) Bind `follow-mode' to key so you can turn it off whenever
-;;    you want to view two locations. Of course, `follow' mode can
+;;    you want to view two locations.  Of course, `follow' mode can
 ;;    be reactivated by hitting the same key again.
 ;;
 ;;    Example from my ~/.emacs:
@@ -208,7 +207,7 @@
 ;;
 ;; In an ideal world, follow mode would have been implemented in the
 ;; kernel of the display routines, making sure that the windows (using
-;; follow mode) ALWAYS are aligned. On planet earth, however, we must
+;; follow mode) ALWAYS are aligned.  On planet earth, however, we must
 ;; accept a solution where we ALMOST ALWAYS can make sure that the
 ;; windows are aligned.
 ;;
@@ -222,7 +221,7 @@
 ;;
 ;; Note that only the selected window is checked, for the reason of
 ;; efficiency and code complexity. (I.e. it is possible to make a
-;; non-selected windows unaligned. It will, however, pop right back
+;; non-selected windows unaligned.  It will, however, pop right back
 ;; when it is selected.)
 
 ;;}}}
@@ -259,7 +258,7 @@
 (eval-when-compile
   (if (or (featurep 'bytecomp)
 	  (featurep 'byte-compile))
-      (cond ((string-match "XEmacs" emacs-version)
+      (cond ((featurep 'xemacs)
 	     ;; Make XEmacs shut up!  I'm using standard Emacs
 	     ;; functions, they are NOT obsolete!
 	     (if (eq (get 'force-mode-line-update 'byte-compile)
@@ -278,53 +277,202 @@
   :group 'windows
   :group 'convenience)
 
-(defvar follow-mode nil
-  "Variable indicating if Follow mode is active.")
-
 (defcustom follow-mode-hook nil
-  "*Hooks to run when follow-mode is turned on."
+  "Hooks to run when follow-mode is turned on."
   :type 'hook
   :group 'follow)
 
 (defcustom follow-mode-off-hook nil
-  "*Hooks to run when follow-mode is turned off."
+  "Hooks to run when follow-mode is turned off."
   :type 'hook
   :group 'follow)
 
-(defvar follow-mode-map nil
-  "*Minor mode keymap for Follow mode.")
+
+;;{{{ Keymap/Menu
+
+;; Define keys for the follow-mode minor mode map and replace some
+;; functions in the global map.  All `follow' mode special functions
+;; can be found on (the somewhat cumbersome) "C-c . <key>"
+;; (Control-C dot <key>). (As of Emacs 19.29 the keys
+;; C-c <punctuation character> are reserved for minor modes.)
+;;
+;; To change the prefix, redefine `follow-mode-prefix' before
+;; `follow' is loaded, or see the section on `follow-mode-hook'
+;; above for an example of how to bind the keys the way you like.
+;;
+;; Please note that the keymap is defined the first time this file is
+;; loaded.  Also note that the only legal way to manipulate the
+;; keymap is to use `define-key'.  Don't change it using `setq' or
+;; similar!
+
+(defcustom follow-mode-prefix "\C-c."
+  "Prefix key to use for follow commands in Follow mode.
+The value of this variable is checked as part of loading Follow mode.
+After that, changing the prefix key requires manipulating keymaps."
+  :type 'string
+  :group 'follow)
+
+(defvar follow-mode-map
+  (let ((mainmap (make-sparse-keymap))
+        (map (make-sparse-keymap)))
+    (define-key map "\C-v"	'follow-scroll-up)
+    (define-key map "\M-v"	'follow-scroll-down)
+    (define-key map "v"		'follow-scroll-down)
+    (define-key map "1"		'follow-delete-other-windows-and-split)
+    (define-key map "b"		'follow-switch-to-buffer)
+    (define-key map "\C-b"	'follow-switch-to-buffer-all)
+    (define-key map "\C-l"	'follow-recenter)
+    (define-key map "<"		'follow-first-window)
+    (define-key map ">"		'follow-last-window)
+    (define-key map "n"		'follow-next-window)
+    (define-key map "p"		'follow-previous-window)
+
+    (define-key mainmap follow-mode-prefix map)
+
+    ;; Replace the standard `end-of-buffer', when in Follow Mode.  (I
+    ;; don't see the point in trying to replace every function that
+    ;; could be enhanced in Follow mode.  End-of-buffer is a special
+    ;; case since it is very simple to define and it greatly enhances
+    ;; the look and feel of Follow mode.)
+    (define-key mainmap [remap end-of-buffer] 'follow-end-of-buffer)
+
+    ;;
+    ;; The menu.
+    ;;
+
+    (if (not (featurep 'xemacs))
+
+	;;
+	;; Emacs
+	;;
+	(let ((menumap (funcall (symbol-function 'make-sparse-keymap)
+                                "Follow"))
+	      (count 0)
+	      id)
+	  (mapcar
+	   (function
+	    (lambda (item)
+	      (setq id
+		    (or (cdr item)
+			(progn
+			  (setq count (+ count 1))
+			  (intern (format "separator-%d" count)))))
+	      (define-key menumap (vector id) item)
+	      (or (eq id 'follow-mode)
+		  (put id 'menu-enable 'follow-mode))))
+	   ;; In reverse order:
+	   '(("Toggle Follow mode" . follow-mode)
+	     ("--")
+	     ("Recenter"           . follow-recenter)
+	     ("--")
+	     ("Previous Window"    . follow-previous-window)
+	     ("Next Windows"       . follow-next-window)
+	     ("Last Window"        . follow-last-window)
+	     ("First Window"       . follow-first-window)
+	     ("--")
+	     ("Switch To Buffer (all windows)"
+              . follow-switch-to-buffer-all)
+	     ("Switch To Buffer"   . follow-switch-to-buffer)
+	     ("--")
+	     ("Delete Other Windows and Split"
+              . follow-delete-other-windows-and-split)
+	     ("--")
+	     ("Scroll Down"        . follow-scroll-down)
+	     ("Scroll Up"          . follow-scroll-up)))
+
+	  ;; If there is a `tools' menu, we use it.  However, we can't add a
+	  ;; minor-mode specific item to it (it's broken), so we make the
+	  ;; contents ghosted when not in use, and add ourselves to the
+	  ;; global map.  If no `tools' menu is present, just make a
+	  ;; top-level menu visible when the mode is activated.
+
+	  (let ((tools-map (lookup-key (current-global-map) [menu-bar tools]))
+		(last nil))
+	    (if (sequencep tools-map)
+		(progn
+		  ;; Find the last entry in the menu and store it in `last'.
+		  (mapcar (function
+			   (lambda (x)
+			     (setq last (or (cdr-safe
+					     (cdr-safe
+					      (cdr-safe x)))
+					    last))))
+			  tools-map)
+		  (if last
+		      (progn
+			(funcall (symbol-function 'define-key-after)
+                                 tools-map [separator-follow] '("--") last)
+			(funcall (symbol-function 'define-key-after)
+				 tools-map [follow] (cons "Follow" menumap)
+				 'separator-follow))
+		    ;; Didn't find the last item, Adding to the top of
+		    ;; tools.  (This will probably never happend...)
+		    (define-key (current-global-map) [menu-bar tools follow]
+		      (cons "Follow" menumap))))
+	      ;; No tools menu, add "Follow" to the menubar.
+	      (define-key mainmap [menu-bar follow]
+		(cons "Follow" menumap)))))
+
+      ;;
+      ;; XEmacs.
+      ;;
+
+      ;; place the menu in the `Tools' menu.
+      (let ((menu '("Follow"
+		    :filter follow-menu-filter
+		    ["Scroll Up" follow-scroll-up t]
+		    ["Scroll Down" follow-scroll-down t]
+		    ["Delete Other Windows and Split"
+		     follow-delete-other-windows-and-split t]
+		    ["Switch To Buffer" follow-switch-to-buffer t]
+		    ["Switch To Buffer (all windows)"
+		     follow-switch-to-buffer-all t]
+		    ["First Window" follow-first-window t]
+		    ["Last Window" follow-last-window t]
+		    ["Next Windows" follow-next-window t]
+		    ["Previous Window" follow-previous-window t]
+		    ["Recenter" follow-recenter t]
+		    ["Deactivate" follow-mode t])))
+
+	;; Why not just `(set-buffer-menubar current-menubar)'?  The
+	;; question is a very good question.  The reason is that under
+	;; Emacs, neither `set-buffer-menubar' nor
+	;; `current-menubar' is defined, hence the byte-compiler will
+	;; warn.
+	(funcall (symbol-function 'set-buffer-menubar)
+		 (symbol-value 'current-menubar))
+	(funcall (symbol-function 'add-submenu) '("Tools") menu))
+
+      ;; When the mode is not activated, only one item is visible:
+      ;; "Activate".
+      (defun follow-menu-filter (menu)
+	(if follow-mode
+	    menu
+	  '(["Activate          " follow-mode t]))))
+    
+    mainmap)
+  "Minor mode keymap for Follow mode.")
+
+;;}}}
 
 (defcustom follow-mode-line-text " Follow"
-  "*Text shown in the mode line when Follow mode is active.
+  "Text shown in the mode line when Follow mode is active.
 Defaults to \" Follow\".  Examples of other values
 are \" Fw\", or simply \"\"."
   :type 'string
   :group 'follow)
 
 (defcustom follow-auto nil
-  "*Non-nil activates Follow mode whenever a file is loaded."
+  "Non-nil activates Follow mode whenever a file is loaded."
   :type 'boolean
   :group 'follow)
 
-(defcustom follow-mode-prefix "\C-c."
-  "*Prefix key to use for follow commands in Follow mode.
-The value of this variable is checked as part of loading Follow mode.
-After that, changing the prefix key requires manipulating keymaps."
-  :type 'string
-  :group 'follow)
-
-(defcustom follow-intercept-processes
-  (fboundp 'start-process)
-  "*When non-nil, Follow Mode will monitor process output."
+(defcustom follow-intercept-processes (fboundp 'start-process)
+  "When non-nil, Follow Mode will monitor process output."
   :type 'boolean
   :group 'follow)
 
-(defvar follow-emacs-version-xemacs-p
-  (string-match "XEmacs" emacs-version)
-  "Non-nil when running under XEmacs.")
-
-(defvar follow-avoid-tail-recenter-p
-  (not follow-emacs-version-xemacs-p)
+(defvar follow-avoid-tail-recenter-p (not (featurep 'xemacs))
   "*When non-nil, patch emacs so that tail windows won't be recentered.
 
 A \"tail window\" is a window that displays only the end of
@@ -381,38 +529,6 @@
   "Cache used by `follow-window-start-end'.")
 
 ;;}}}
-;;{{{ Bug report
-
-(eval-when-compile (require 'reporter))
-
-(defun follow-submit-feedback ()
-  "Submit feedback on Follow mode to the author: andersl@andersl.com"
-  (interactive)
-  (require 'reporter)
-  (and (y-or-n-p "Do you really want to submit a report on Follow mode? ")
-       (reporter-submit-bug-report
-	"Anders Lindgren <andersl@andersl.com>"
-	"follow.el"
-	'(post-command-hook
-	  pre-command-hook
-	  window-size-change-functions
-	  window-scroll-functions
-	  follow-mode-hook
-	  follow-mode-off-hook
-	  follow-auto
-	  follow-intercept-processes
-	  follow-avoid-tail-recenter-p
-	  follow-process-filter-alist)
-	nil
-	nil
-	(concat
-	 "Hi Anders!\n\n"
-	 "(I have read the section on how to report bugs in the "
-	 "Emacs manual.)\n\n"
-	 "Even though I know you are busy, I thought you might "
-	 "want to know...\n\n"))))
-
-;;}}}
 ;;{{{ Debug messages
 
 ;; This inline function must be as small as possible!
@@ -425,189 +541,10 @@
       (apply 'message args)))
 
 ;;}}}
-
-;;{{{ Keymap/Menu
-
-;;; Define keys for the follow-mode minor mode map and replace some
-;;; functions in the global map.  All `follow' mode special functions
-;;; can be found on (the somewhat cumbersome) "C-c . <key>"
-;;; (Control-C dot <key>). (As of Emacs 19.29 the keys
-;;; C-c <punctuation character> are reserved for minor modes.)
-;;;
-;;; To change the prefix, redefine `follow-mode-prefix' before
-;;; `follow' is loaded, or see the section on `follow-mode-hook'
-;;; above for an example of how to bind the keys the way you like.
-;;;
-;;; Please note that the keymap is defined the first time this file is
-;;; loaded.  Also note that the only legal way to manipulate the
-;;; keymap is to use `define-key'.  Don't change it using `setq' or
-;;; similar!
-
-
-(if follow-mode-map
-    nil
-  (setq follow-mode-map (make-sparse-keymap))
-  (let ((map (make-sparse-keymap)))
-    (define-key map "\C-v"	'follow-scroll-up)
-    (define-key map "\M-v"	'follow-scroll-down)
-    (define-key map "v"		'follow-scroll-down)
-    (define-key map "1"		'follow-delete-other-windows-and-split)
-    (define-key map "b"		'follow-switch-to-buffer)
-    (define-key map "\C-b"	'follow-switch-to-buffer-all)
-    (define-key map "\C-l"	'follow-recenter)
-    (define-key map "<"		'follow-first-window)
-    (define-key map ">"		'follow-last-window)
-    (define-key map "n"		'follow-next-window)
-    (define-key map "p"		'follow-previous-window)
-
-    (define-key follow-mode-map follow-mode-prefix map)
-
-    ;; Replace the standard `end-of-buffer', when in Follow Mode.  (I
-    ;; don't see the point in trying to replace every function that
-    ;; could be enhanced in Follow mode.  End-of-buffer is a special
-    ;; case since it is very simple to define and it greatly enhances
-    ;; the look and feel of Follow mode.)
-    ;;
-    ;; (The function `substitute-key-definition' does not work
-    ;; in all versions of Emacs.)
-    (mapcar
-     (function
-      (lambda (pair)
-	(let ((old (car pair))
-	      (new (cdr pair)))
-	  (mapcar (function (lambda (key)
-			      (define-key follow-mode-map key new)))
-		  (where-is-internal old global-map)))))
-     '((end-of-buffer      . follow-end-of-buffer)
-       (fkey-end-of-buffer . follow-end-of-buffer)))
-
-    ;;;
-    ;;; The menu.
-    ;;;
-
-    (if (not follow-emacs-version-xemacs-p)
-
-	;;
-	;; Emacs
-	;;
-	(let ((menumap (funcall (symbol-function 'make-sparse-keymap)
-			"Follow"))
-	      (count 0)
-	      id)
-	  (mapcar
-	   (function
-	    (lambda (item)
-	      (setq id
-		    (or (cdr item)
-			(progn
-			  (setq count (+ count 1))
-			  (intern (format "separator-%d" count)))))
-	      (define-key menumap (vector id) item)
-	      (or (eq id 'follow-mode)
-		  (put id 'menu-enable 'follow-mode))))
-	   ;; In reverse order:
-	   '(("Toggle Follow mode" . follow-mode)
-	     ("--")
-	     ("Recenter"           . follow-recenter)
-	     ("--")
-	     ("Previous Window"    . follow-previous-window)
-	     ("Next Windows"       . follow-next-window)
-	     ("Last Window"        . follow-last-window)
-	     ("First Window"       . follow-first-window)
-	     ("--")
-	     ("Switch To Buffer (all windows)"
-	                           . follow-switch-to-buffer-all)
-	     ("Switch To Buffer"   . follow-switch-to-buffer)
-	     ("--")
-	     ("Delete Other Windows and Split"
-	                           . follow-delete-other-windows-and-split)
-	     ("--")
-	     ("Scroll Down"        . follow-scroll-down)
-	     ("Scroll Up"          . follow-scroll-up)))
-
-	  ;; If there is a `tools' meny, we use it. However, we can't add a
-	  ;; minor-mode specific item to it (it's broken), so we make the
-	  ;; contents ghosted when not in use, and add ourselves to the
-	  ;; global map.  If no `tools' menu is present, just make a
-	  ;; top-level menu visible when the mode is activated.
-
-	  (let ((tools-map (lookup-key (current-global-map) [menu-bar tools]))
-		(last nil))
-	    (if (sequencep tools-map)
-		(progn
-		  ;; Find the last entry in the menu and store it in `last'.
-		  (mapcar (function
-			   (lambda (x)
-			     (setq last (or (cdr-safe
-					     (cdr-safe
-					      (cdr-safe x)))
-					    last))))
-			  tools-map)
-		  (if last
-		      (progn
-			(funcall (symbol-function 'define-key-after)
-				  tools-map [separator-follow] '("--") last)
-			(funcall (symbol-function 'define-key-after)
-				 tools-map [follow] (cons "Follow" menumap)
-				 'separator-follow))
-		    ;; Didn't find the last item, Adding to the top of
-		    ;; tools.  (This will probably never happend...)
-		    (define-key (current-global-map) [menu-bar tools follow]
-		      (cons "Follow" menumap))))
-	      ;; No tools menu, add "Follow" to the menubar.
-	      (define-key follow-mode-map [menu-bar follow]
-		(cons "Follow" menumap)))))
-
-      ;;
-      ;; XEmacs.
-      ;;
-
-      ;; place the menu in the `Tools' menu.
-      (let ((menu '("Follow"
-		    :filter follow-menu-filter
-		    ["Scroll Up" follow-scroll-up t]
-		    ["Scroll Down" follow-scroll-down t]
-		    ["Delete Other Windows and Split"
-		     follow-delete-other-windows-and-split t]
-		    ["Switch To Buffer" follow-switch-to-buffer t]
-		    ["Switch To Buffer (all windows)"
-		     follow-switch-to-buffer-all t]
-		    ["First Window" follow-first-window t]
-		    ["Last Window" follow-last-window t]
-		    ["Next Windows" follow-next-window t]
-		    ["Previous Window" follow-previous-window t]
-		    ["Recenter" follow-recenter t]
-		    ["Deactivate" follow-mode t])))
-
-	;; Why not just `(set-buffer-menubar current-menubar)'?  The
-	;; question is a very good question.  The reason is that under
-	;; Emacs, neither `set-buffer-menubar' nor
-	;; `current-menubar' is defined, hence the byte-compiler will
-	;; warn.
-	(funcall (symbol-function 'set-buffer-menubar)
-		 (symbol-value 'current-menubar))
-	(funcall (symbol-function 'add-submenu) '("Tools") menu))
-
-      ;; When the mode is not activated, only one item is visible:
-      ;; "Activate".
-      (defun follow-menu-filter (menu)
-	(if follow-mode
-	    menu
-	  '(["Activate          " follow-mode t]))))))
-
-
-;;; Register the follow mode keymap.
-(or (assq 'follow-mode minor-mode-map-alist)
-    (setq minor-mode-map-alist
-	  (cons (cons 'follow-mode follow-mode-map) minor-mode-map-alist)))
-
-;;}}}
 ;;{{{ Cache
 
-(let ((cmds follow-cache-command-list))
-  (while cmds
-    (put (car cmds) 'follow-mode-use-cache t)
-    (setq cmds (cdr cmds))))
+(dolist (cmd follow-cache-command-list)
+  (put cmd 'follow-mode-use-cache t))
 
 ;;}}}
 
@@ -615,20 +552,20 @@
 
 ;;;###autoload
 (defun turn-on-follow-mode ()
-  "Turn on Follow mode. Please see the function `follow-mode'."
+  "Turn on Follow mode.  Please see the function `follow-mode'."
   (interactive)
   (follow-mode 1))
 
 
 ;;;###autoload
 (defun turn-off-follow-mode ()
-  "Turn off Follow mode. Please see the function `follow-mode'."
+  "Turn off Follow mode.  Please see the function `follow-mode'."
   (interactive)
   (follow-mode -1))
 
-
+(put 'follow-mode 'permanent-local t)
 ;;;###autoload
-(defun follow-mode (arg)
+(define-minor-mode follow-mode
   "Minor mode that combines windows into one tall virtual window.
 
 The feeling of a \"virtual window\" has been accomplished by the use
@@ -665,39 +602,21 @@
 
 Keys specific to Follow mode:
 \\{follow-mode-map}"
-  (interactive "P")
-  (make-local-variable 'follow-mode)
-  (put 'follow-mode 'permanent-local t)
-  (let ((follow-mode-orig follow-mode))
-    (setq follow-mode
-	  (if (null arg)
-	      (not follow-mode)
-	    (> (prefix-numeric-value arg) 0)))
-    (if (and follow-mode follow-intercept-processes)
-	(follow-intercept-process-output))
-    (cond ((and follow-mode (not follow-mode-orig)) ; On
-	   ;; XEmacs: If this is non-nil, the window will scroll before
-	   ;; the point will have a chance to get into the next window.
-	   (if (boundp 'scroll-on-clipped-lines)
-	       (set 'scroll-on-clipped-lines nil))
-	   (force-mode-line-update)
-	   (add-hook 'post-command-hook 'follow-post-command-hook t)
-	   (run-hooks 'follow-mode-hook))
+  :keymap follow-mode-map
+  (if (and follow-mode follow-intercept-processes)
+      (follow-intercept-process-output))
+  (cond (follow-mode ; On
+         ;; XEmacs: If this is non-nil, the window will scroll before
+         ;; the point will have a chance to get into the next window.
+         (if (boundp 'scroll-on-clipped-lines)
+             (setq scroll-on-clipped-lines nil))
+         (force-mode-line-update)
+         (add-hook 'post-command-hook 'follow-post-command-hook t)
+         (run-hooks 'follow-mode-hook))
 
-	  ((and (not follow-mode) follow-mode-orig) ; Off
-	   (force-mode-line-update)
-	   (run-hooks 'follow-mode-off-hook)))))
-
-
-;; Register follow-mode as a minor mode.
-
-(if (fboundp 'add-minor-mode)
-    ;; XEmacs
-    (funcall (symbol-function 'add-minor-mode)
-	     'follow-mode 'follow-mode-line-text)
-  (or (assq 'follow-mode minor-mode-alist)
-      (setq minor-mode-alist
-	    (cons '(follow-mode follow-mode-line-text) minor-mode-alist))))
+        ((not follow-mode) ; Off
+         (force-mode-line-update)
+         (run-hooks 'follow-mode-off-hook))))
 
 ;;}}}
 ;;{{{ Find file hook
@@ -1033,7 +952,7 @@
 If WIN is nil, the selected window is used.
 
 Returns (end-pos end-of-buffer-p)"
-  (if follow-emacs-version-xemacs-p
+  (if (featurep 'xemacs)
       ;; XEmacs can calculate the end of the window by using
       ;; the 'guarantee options. GOOD!
       (let ((end (window-end win t)))
@@ -1511,7 +1430,7 @@
 ;;}}}
 ;;{{{ Post Command Hook
 
-;;; The magic little box. This function is called after every command.
+;; The magic little box. This function is called after every command.
 
 ;; This is not as complicated as it seems. It is simply a list of common
 ;; display situations and the actions to take, plus commands for redrawing
@@ -1735,17 +1654,17 @@
 
 ;;;; Scroll-bar support code.
 
-;;; Why is it needed? Well, if the selected window is in follow mode,
-;;; all its follower stick to it blindly. If one of them is scrolled,
-;;; it immediately returns to the original position when the mouse is
-;;; released. If the selected window is not a follower of the dragged
-;;; window the windows will be unaligned.
+;; Why is it needed? Well, if the selected window is in follow mode,
+;; all its follower stick to it blindly. If one of them is scrolled,
+;; it immediately returns to the original position when the mouse is
+;; released. If the selected window is not a follower of the dragged
+;; window the windows will be unaligned.
 
-;;; The advices doesn't get compiled. Aestetically, this might be a
-;;; problem but in practical life it isn't.
+;; The advices doesn't get compiled. Aestetically, this might be a
+;; problem but in practical life it isn't.
 
-;;; Discussion: Now when the other windows in the chain follow the
-;;; dragged, should we really select it?
+;; Discussion: Now when the other windows in the chain follow the
+;; dragged, should we really select it?
 
 (cond ((fboundp 'scroll-bar-drag)
        ;;;
@@ -1851,29 +1770,29 @@
 ;;}}}
 ;;{{{ Process output
 
-;;; The following sections installs a spy that listens to process
-;;; output and tries to reposition the windows whose buffers are in
-;;; Follow mode.  We play safe as much as possible...
-;;;
-;;; When follow-mode is activated all active processes are
-;;; intercepted.  All new processes that change their filter function
-;;; using `set-process-filter' are also intercepted.  The reason is
-;;; that a process can cause a redisplay recentering "tail" windows.
-;;; Note that it doesn't hurt to spy on more processes than needed.
-;;;
-;;; Technically, we set the process filter to `follow-generic-filter'.
-;;; The original filter is stored in `follow-process-filter-alist'.
-;;; Our generic filter calls the original filter, or inserts the
-;;; output into the buffer, if the buffer originally didn't have an
-;;; output filter.  It also makes sure that the windows connected to
-;;; the buffer are aligned.
-;;;
-;;; Discussion: How do we find processes that don't call
-;;; `set-process-filter'?  (How often are processes created in a
-;;; buffer after Follow mode are activated?)
-;;;
-;;; Discussion: Should we also advice `process-filter' to make our
-;;; filter invisible to others?
+;; The following sections installs a spy that listens to process
+;; output and tries to reposition the windows whose buffers are in
+;; Follow mode.  We play safe as much as possible...
+;;
+;; When follow-mode is activated all active processes are
+;; intercepted.  All new processes that change their filter function
+;; using `set-process-filter' are also intercepted.  The reason is
+;; that a process can cause a redisplay recentering "tail" windows.
+;; Note that it doesn't hurt to spy on more processes than needed.
+;;
+;; Technically, we set the process filter to `follow-generic-filter'.
+;; The original filter is stored in `follow-process-filter-alist'.
+;; Our generic filter calls the original filter, or inserts the
+;; output into the buffer, if the buffer originally didn't have an
+;; output filter.  It also makes sure that the windows connected to
+;; the buffer are aligned.
+;;
+;; Discussion: How do we find processes that don't call
+;; `set-process-filter'?  (How often are processes created in a
+;; buffer after Follow mode are activated?)
+;;
+;; Discussion: Should we also advice `process-filter' to make our
+;; filter invisible to others?
 
 ;;{{{ Advice for `set-process-filter'
 
@@ -1980,7 +1899,7 @@
 
 The only reason to call this function is if the Follow mode spy filter
 would interfere with some other package.  If this happens, please
-report this using the `follow-submit-feedback' function."
+report this using the `report-emacs-bug' function."
   (interactive)
   (follow-tidy-process-filter-alist)
   (let ((list (process-list)))
@@ -1999,12 +1918,12 @@
 ;;}}}
 ;;{{{ The filter
 
-;;; The following section is a naive method to make buffers with
-;;; process output to work with Follow mode. Whenever the start of the
-;;; window displaying the buffer is moved, we moves it back to its
-;;; original position and try to select a new window.  (If we fail,
-;;; the normal redisplay functions of Emacs will scroll it right
-;;; back!)
+;; The following section is a naive method to make buffers with
+;; process output to work with Follow mode. Whenever the start of the
+;; window displaying the buffer is moved, we moves it back to its
+;; original position and try to select a new window.  (If we fail,
+;; the normal redisplay functions of Emacs will scroll it right
+;; back!)
 
 (defun follow-generic-filter (proc output)
   "Process output filter for process connected to buffers in Follow mode."
@@ -2219,7 +2138,7 @@
 ;; unless we are in `slow-search-mode', i.e. only a few lines
 ;; of text is visible.
 
-(if follow-emacs-version-xemacs-p
+(if (featurep 'xemacs)
     (defadvice isearch-done (before follow-isearch-done activate)
       (if (and (boundp 'follow-mode)
 	       follow-mode
@@ -2235,28 +2154,28 @@
 ;;}}}
 ;;{{{ Tail window handling
 
-;;; In Emacs (not XEmacs) windows showing nothing are sometimes
-;;; recentered.  When in Follow Mode, this is not desireable for
-;;; non-first windows in the window chain.  This section tries to
-;;; make the windows stay where they should be.
-;;;
-;;; If the display is updated, all windows starting at (point-max) are
-;;; going to be recentered at the next redisplay, unless we do a
-;;; read-and-write cycle to update the `force' flag inside the windows.
-;;;
-;;; In 19.30, a new varible `window-scroll-functions' is called every
-;;; time a window is recentered.  It is not perfect for our situation,
-;;; since when it is called for a tail window, it is to late.  However,
-;;; if it is called for another window, we can try to update our
-;;; windows.
-;;;
-;;; By patching `sit-for' we can make sure that to catch all explicit
-;;; updates initiated by lisp programs.  Internal calls, on the other
-;;; hand, are not handled.
-;;;
-;;; Please note that the function `follow-avoid-tail-recenter' is also
-;;; called from other places, e.g. `post-command-hook' and
-;;; `post-command-idle-hook'.
+;; In Emacs (not XEmacs) windows showing nothing are sometimes
+;; recentered.  When in Follow Mode, this is not desireable for
+;; non-first windows in the window chain.  This section tries to
+;; make the windows stay where they should be.
+;;
+;; If the display is updated, all windows starting at (point-max) are
+;; going to be recentered at the next redisplay, unless we do a
+;; read-and-write cycle to update the `force' flag inside the windows.
+;;
+;; In 19.30, a new varible `window-scroll-functions' is called every
+;; time a window is recentered.  It is not perfect for our situation,
+;; since when it is called for a tail window, it is to late.  However,
+;; if it is called for another window, we can try to update our
+;; windows.
+;;
+;; By patching `sit-for' we can make sure that to catch all explicit
+;; updates initiated by lisp programs.  Internal calls, on the other
+;; hand, are not handled.
+;;
+;; Please note that the function `follow-avoid-tail-recenter' is also
+;; called from other places, e.g. `post-command-hook' and
+;; `post-command-idle-hook'.
 
 ;; If this function is called it is too late for this window, but
 ;; we might save other windows from being recentered.
@@ -2328,9 +2247,9 @@
 
 ;;{{{ The end
 
-;;;
-;;; We're done!
-;;;
+;;
+;; We're done!
+;;
 
 (provide 'follow)
 
--- a/lisp/gnus/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,57 @@
+2006-04-26  Reiner Steib  <Reiner.Steib@gmx.de>
+
+	* deuglify.el (gnus-outlook-deuglify-unwrap-min)
+	(gnus-outlook-deuglify-unwrap-max): Remove autoload.
+
+	* 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.  Sync from the trunk.
+
+	* mml.el (mml-mode-map): Add key bindings for those functions.
+	(mml-menu): Simplify security menu entries.  Suggested by Jesper
+	Harder <harder@myrealbox.com>.  Sync from the trunk.
+
+	* message.el (message-valid-fqdn-regexp): Add TLDs .cat, jobs,
+	.mobi and .travel.  Remove .nato, .bitnet and .uucp.
+	(message-in-body-p): New function.  Sync from the trunk.
+
+	* mml.el (mml-mode, mml-dnd-protocol-alist)
+	(mml-dnd-attach-options, mml-dnd-attach-file)
+	(mml-attach-file, mml-attach-buffer, mml-attach-external): Sync
+	DND support and use of message-in-body-p from the trunk.
+
+2006-04-25  Andreas Seltenreich  <uwi7@rz.uni-karlsruhe.de>
+
+	* nnweb.el (nnweb-google-wash-article): Sync up to new Google
+	HTML.
+
+2006-04-25  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+	* mm-uu.el (mm-uu-pgp-signed-test): Erase prompt.
+	(mm-uu-pgp-encrypted-test): Ditto.
+	(mm-uu-pgp-encrypted-extract-1): Make sure there's a blank line
+	between header and body; return application/pgp-encrypted handle
+	if decryption failed; decode decrypted body by charset.
+
+	* mm-decode.el (mm-automatic-display): Don't make application/pgp
+	element match to application/pgp-*.
+
+2006-04-20  Reiner Steib  <Reiner.Steib@gmx.de>
+
+	* gnus-util.el (gnus-replace-in-string): Prefer
+	replace-regexp-in-string over of replace-in-string.
+
+2006-04-20  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+	* gnus-group.el: Bind tool-bar-mode instead of tool-bar-map.
+
+	* gnus-sum.el: Ditto.
+
+	* gnus-util.el (gnus-select-frame-set-input-focus): Use
+	select-frame-set-input-focus if it is available in XEmacs; use
+	definition defined in Emacs 22 for old Emacsen.
+
 2006-04-17  Reiner Steib  <Reiner.Steib@gmx.de>
 
 	[ Merge from Gnus trunk. ]
--- a/lisp/gnus/deuglify.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/deuglify.el	Fri Apr 28 14:48:18 2006 +0000
@@ -234,14 +234,12 @@
   :version "22.1"
   :group 'gnus)
 
-;;;###autoload
 (defcustom gnus-outlook-deuglify-unwrap-min 45
   "Minimum length of the cited line above the (possibly) wrapped line."
   :version "22.1"
   :type 'integer
   :group 'gnus-outlook-deuglify)
 
-;;;###autoload
 (defcustom gnus-outlook-deuglify-unwrap-max 95
   "Maximum length of the cited line after unwrapping."
   :version "22.1"
@@ -288,7 +286,6 @@
   :type 'string
   :group 'gnus-outlook-deuglify)
 
-;;;###autoload
 (defcustom gnus-outlook-display-hook nil
   "A hook called after an deuglified article has been prepared.
 It is run after `gnus-article-prepare-hook'."
--- a/lisp/gnus/gnus-group.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/gnus-group.el	Fri Apr 28 14:48:18 2006 +0000
@@ -29,7 +29,7 @@
 
 (eval-when-compile
   (require 'cl)
-  (defvar tool-bar-map))
+  (defvar tool-bar-mode))
 
 (require 'gnus)
 (require 'gnus-start)
--- a/lisp/gnus/gnus-sum.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/gnus-sum.el	Fri Apr 28 14:48:18 2006 +0000
@@ -29,7 +29,7 @@
 
 (eval-when-compile
   (require 'cl)
-  (defvar tool-bar-map))
+  (defvar tool-bar-mode))
 
 (require 'gnus)
 (require 'gnus-group)
--- a/lisp/gnus/gnus-util.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/gnus-util.el	Fri Apr 28 14:48:18 2006 +0000
@@ -61,8 +61,11 @@
 
 (eval-and-compile
   (cond
-   ((fboundp 'replace-in-string)
-    (defalias 'gnus-replace-in-string 'replace-in-string))
+   ;; Prefer `replace-regexp-in-string' (present in Emacs, XEmacs 21.5,
+   ;; SXEmacs 22.1.4) over `replace-in-string'.  The later leads to inf-loops
+   ;; on empty matches:
+   ;;   (replace-in-string "foo" "/*$" "/")
+   ;;   (replace-in-string "xe" "\\(x\\)?" "")
    ((fboundp 'replace-regexp-in-string)
     (defun gnus-replace-in-string (string regexp newtext &optional literal)
       "Replace all matches for REGEXP with NEWTEXT in STRING.
@@ -71,6 +74,8 @@
 
 This is a compatibility function for different Emacsen."
       (replace-regexp-in-string regexp newtext string nil literal)))
+   ((fboundp 'replace-in-string)
+    (defalias 'gnus-replace-in-string 'replace-in-string))
    (t
     (defun gnus-replace-in-string (string regexp newtext &optional literal)
       "Replace all matches for REGEXP with NEWTEXT in STRING.
@@ -1424,20 +1429,19 @@
 (defun gnus-select-frame-set-input-focus (frame)
   "Select FRAME, raise it, and set input focus, if possible."
   (cond ((featurep 'xemacs)
-	 (raise-frame frame)
-	 (select-frame frame)
-	 (focus-frame frame))
-	;; The function `select-frame-set-input-focus' won't set
-	;; the input focus under Emacs 21.2 and X window system.
-	;;((fboundp 'select-frame-set-input-focus)
-	;; (defalias 'gnus-select-frame-set-input-focus
-	;;   'select-frame-set-input-focus)
-	;; (select-frame-set-input-focus frame))
+	 (if (fboundp 'select-frame-set-input-focus)
+	     (select-frame-set-input-focus frame)
+	   (raise-frame frame)
+	   (select-frame frame)
+	   (focus-frame frame)))
+	;; `select-frame-set-input-focus' defined in Emacs 21 will not
+	;; set the input focus.
+	((>= emacs-major-version 22)
+	 (select-frame-set-input-focus frame))
 	(t
 	 (raise-frame frame)
 	 (select-frame frame)
-	 (cond ((and (eq window-system 'x)
-		     (fboundp 'x-focus-frame))
+	 (cond ((memq window-system '(x mac))
 		(x-focus-frame frame))
 	       ((eq window-system 'w32)
 		(w32-focus-frame frame)))
--- a/lisp/gnus/message.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/message.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1586,11 +1586,16 @@
 (defcustom message-valid-fqdn-regexp
   (concat "[a-z0-9][-.a-z0-9]+\\." ;; [hostname.subdomain.]domain.
 	  ;; valid TLDs:
-	  "\\([a-z][a-z]" ;; two letter country TDLs
-	  "\\|biz\\|com\\|edu\\|gov\\|int\\|mil\\|net\\|org"
-	  "\\|aero\\|coop\\|info\\|name\\|museum"
-	  "\\|arpa\\|pro\\|uucp\\|bitnet\\|bofh" ;; old style?
-	  "\\)")
+	  "\\([a-z][a-z]\\|" ;; two letter country TDLs
+	  "aero\\|arpa\\|bitnet\\|biz\\|bofh\\|"
+	  "cat\\|com\\|coop\\|edu\\|gov\\|"
+	  "info\\|int\\|jobs\\|"
+	  "mil\\|mobi\\|museum\\|name\\|net\\|"
+	  "org\\|pro\\|travel\\|uucp\\)")
+  ;; http://en.wikipedia.org/wiki/List_of_Internet_top-level_domains
+  ;; http://en.wikipedia.org/wiki/GTLD
+  ;; `in the process of being approved': .asia .post .tel .sex
+  ;; "dead" nato bitnet uucp
   "Regular expression that matches a valid FQDN."
   ;; see also: gnus-button-valid-fqdn-regexp
   :version "22.1"
@@ -2679,6 +2684,11 @@
   (or (search-forward (concat "\n" mail-header-separator "\n") nil t)
       (search-forward-regexp "[^:]+:\\([^\n]\\|\n[ \t]\\)+\n\n" nil t)))
 
+(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-eoh ()
   "Move point to the end of the headers."
   (interactive)
--- a/lisp/gnus/mm-decode.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/mm-decode.el	Fri Apr 28 14:48:18 2006 +0000
@@ -307,7 +307,7 @@
     "application/pkcs7-signature" "application/x-pkcs7-mime"
     "application/pkcs7-mime"
     ;; Mutt still uses this even though it has already been withdrawn.
-    "application/pgp")
+    "application/pgp\\'")
   "A list of MIME types to be displayed automatically."
   :type '(repeat regexp)
   :group 'mime-display)
--- a/lisp/gnus/mm-uu.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/mm-uu.el	Fri Apr 28 14:48:18 2006 +0000
@@ -352,7 +352,9 @@
     ((eq mm-verify-option 'never) nil)
     ((eq mm-verify-option 'always) t)
     ((eq mm-verify-option 'known) t)
-    (t (y-or-n-p "Verify pgp signed part? ")))))
+    (t (prog1
+	   (y-or-n-p "Verify pgp signed part? ")
+	 (message ""))))))
 
 (eval-when-compile
   (defvar gnus-newsgroup-charset))
@@ -403,15 +405,44 @@
     ((eq mm-decrypt-option 'never) nil)
     ((eq mm-decrypt-option 'always) t)
     ((eq mm-decrypt-option 'known) t)
-    (t (y-or-n-p "Decrypt pgp encrypted part? ")))))
+    (t (prog1
+	   (y-or-n-p "Decrypt pgp encrypted part? ")
+	 (message ""))))))
 
 (defun mm-uu-pgp-encrypted-extract-1 (handles ctl)
-  (let ((buf (mm-uu-copy-to-buffer (point-min) (point-max))))
-    (if (mm-uu-pgp-encrypted-test)
-	(with-current-buffer buf
-	  (mml2015-clean-buffer)
-	  (funcall (mml2015-clear-decrypt-function))))
-    (list (mm-make-handle buf mm-uu-text-plain-type))))
+  (let ((buf (mm-uu-copy-to-buffer (point-min) (point-max)))
+	(first t)
+	charset)
+    ;; Make sure there's a blank line between header and body.
+    (with-current-buffer buf
+      (goto-char (point-min))
+      (while (prog2
+		 (forward-line 1)
+		 (if first
+		     (looking-at "[^\t\n ]+:")
+		   (looking-at "[^\t\n ]+:\\|[\t ]"))
+	       (setq first nil)))
+      (unless (memq (char-after) '(?\n nil))
+	(insert "\n"))
+      (save-restriction
+	(narrow-to-region (point-min) (point))
+	(setq charset (mail-fetch-field "charset")))
+      (if (and (mm-uu-pgp-encrypted-test)
+	       (progn
+		 (mml2015-clean-buffer)
+		 (funcall (mml2015-clear-decrypt-function))
+		 (equal (mm-handle-multipart-ctl-parameter mm-security-handle
+							   'gnus-info)
+			"OK")))
+	  (progn
+	    ;; Decode charset.
+	    (when (and (or charset
+			   (setq charset gnus-newsgroup-charset))
+		       (setq charset (mm-charset-to-coding-system charset))
+		       (not (eq charset 'ascii)))
+	      (mm-decode-coding-region (point-min) (point-max) charset))
+	    (list (mm-make-handle buf mm-uu-text-plain-type)))
+	(list (mm-make-handle buf '("application/pgp-encrypted")))))))
 
 (defun mm-uu-pgp-encrypted-extract ()
   (let ((mm-security-handle (list (format "multipart/encrypted"))))
--- a/lisp/gnus/mml-sec.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/mml-sec.el	Fri Apr 28 14:48:18 2006 +0000
@@ -188,6 +188,29 @@
 						(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)
@@ -249,6 +272,34 @@
     (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)
--- a/lisp/gnus/mml.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/mml.el	Fri Apr 28 14:48:18 2006 +0000
@@ -40,7 +40,8 @@
   (autoload 'message-fetch-field "message")
   (autoload 'message-info "message")
   (autoload 'fill-flowed-encode "flow-fill")
-  (autoload 'message-posting-charset "message"))
+  (autoload 'message-posting-charset "message")
+  (autoload 'dnd-get-local-file-name "dnd"))
 
 (defvar gnus-article-mime-handles)
 (defvar gnus-mouse-2)
@@ -51,6 +52,7 @@
 (defvar message-posting-charset)
 (defvar message-required-mail-headers)
 (defvar message-required-news-headers)
+(defvar dnd-protocol-alist)
 
 (defcustom mml-content-type-parameters
   '(name access-type expiration size permission format)
@@ -878,6 +880,11 @@
 	(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)
@@ -915,26 +922,54 @@
     ["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 t]
+    ["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]
     "----"
@@ -958,8 +993,11 @@
   (when (set (make-local-variable 'mml-mode)
 	     (if (null arg) (not mml-mode)
 	       (> (prefix-numeric-value arg) 0)))
-    (gnus-add-minor-mode 'mml-mode " MML" mml-mode-map)
+    (add-minor-mode 'mml-mode " MML" mml-mode-map)
     (easy-menu-add mml-menu mml-mode-map)
+    (when (boundp 'dnd-protocol-alist)
+      (set (make-local-variable 'dnd-protocol-alist)
+	   (append mml-dnd-protocol-alist dnd-protocol-alist)))
     (run-hooks 'mml-mode-hook)))
 
 ;;;
@@ -1057,6 +1095,36 @@
 
 ;;; 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 "22.1" ;; Gnus 5.10.9
+  :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 "22.1" ;; Gnus 5.10.9
+  :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
@@ -1074,11 +1142,37 @@
 	  (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.
+
+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 ((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)
   "Attach a buffer to the outgoing MIME message.
@@ -1088,8 +1182,11 @@
 	  (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.
@@ -1100,8 +1197,10 @@
 	  (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): "
--- a/lisp/gnus/mml1991.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/mml1991.el	Fri Apr 28 14:48:18 2006 +0000
@@ -229,23 +229,25 @@
   (defvar pgg-output-buffer))
 
 (defun mml1991-pgg-sign (cont)
+  ;; Make sure to load pgg.el before binding pgg-* variables.
+  (require 'pgg)
   (let ((pgg-text-mode t)
+	(pgg-default-user-id (or (message-options-get 'mml-sender)
+				 pgg-default-user-id))
 	headers cte)
     ;; Don't sign headers.
     (goto-char (point-min))
-    (while (not (looking-at "^$"))
-      (forward-line))
-    (unless (eobp) ;; no headers?
+    (when (re-search-forward "^$" nil t)
       (setq headers (buffer-substring (point-min) (point)))
-      (forward-line) ;; skip header/body separator
-      (delete-region (point-min) (point)))
-    (when (string-match "^Content-Transfer-Encoding: \\(.+\\)" headers)
-      (setq cte (intern (match-string 1 headers))))
-    (mm-decode-content-transfer-encoding cte)
-    (unless (let ((pgg-default-user-id
-		   (or (message-options-get 'mml-sender)
-		       pgg-default-user-id)))
-	      (pgg-sign-region (point-min) (point-max) t))
+      (save-restriction
+	(narrow-to-region (point-min) (point))
+	(setq cte (mail-fetch-field "content-transfer-encoding")))
+      (forward-line 1)
+      (delete-region (point-min) (point))
+      (when cte
+	(setq cte (intern (downcase cte)))
+	(mm-decode-content-transfer-encoding cte)))
+    (unless (pgg-sign-region (point-min) (point-max) t)
       (pop-to-buffer pgg-errors-buffer)
       (error "Encrypt error"))
     (delete-region (point-min) (point-max))
@@ -254,7 +256,8 @@
       (goto-char (point-min))
       (while (re-search-forward "\r+$" nil t)
 	(replace-match "" t t))
-      (mm-encode-content-transfer-encoding cte)
+      (when cte
+	(mm-encode-content-transfer-encoding cte))
       (goto-char (point-min))
       (when headers
 	(insert headers))
@@ -262,34 +265,35 @@
     t))
 
 (defun mml1991-pgg-encrypt (cont &optional sign)
-  (let ((pgg-text-mode t)
-	cte)
-    ;; Strip MIME Content[^ ]: headers since it will be ASCII ARMOURED
-    (goto-char (point-min))
-    (while (looking-at "^Content[^ ]+:")
-      (when (looking-at "^Content-Transfer-Encoding: \\(.+\\)")
-	(setq cte (intern (match-string 1))))
-      (forward-line))
-    (unless (bobp)
-      (delete-region (point-min) (point)))
-    (mm-decode-content-transfer-encoding cte)
-    (unless (pgg-encrypt-region
-	     (point-min) (point-max)
-	     (split-string
-	      (or
-	       (message-options-get 'message-recipients)
-	       (message-options-set 'message-recipients
-				    (read-string "Recipients: ")))
-	      "[ \f\t\n\r\v,]+")
-	     sign)
-      (pop-to-buffer pgg-errors-buffer)
-      (error "Encrypt error"))
-    (delete-region (point-min) (point-max))
-    ;;(insert "Content-Type: application/pgp-encrypted\n\n")
-    ;;(insert "Version: 1\n\n")
-    (insert "\n")
-    (insert-buffer-substring pgg-output-buffer)
-    t))
+  (goto-char (point-min))
+  (when (re-search-forward "^$" nil t)
+    (let ((cte (save-restriction
+		 (narrow-to-region (point-min) (point))
+		 (mail-fetch-field "content-transfer-encoding"))))
+      ;; Strip MIME headers since it will be ASCII armoured.
+      (forward-line 1)
+      (delete-region (point-min) (point))
+      (when cte
+	(mm-decode-content-transfer-encoding (intern (downcase cte))))))
+  (unless (progn
+	    ;; Make sure to load pgg.el before binding `pgg-text-mode'.
+	    (require 'pgg)
+	    (let ((pgg-text-mode t))
+	      (pgg-encrypt-region
+	       (point-min) (point-max)
+	       (split-string
+		(or
+		 (message-options-get 'message-recipients)
+		 (message-options-set 'message-recipients
+				      (read-string "Recipients: ")))
+		"[ \f\t\n\r\v,]+")
+	       sign)))
+    (pop-to-buffer pgg-errors-buffer)
+    (error "Encrypt error"))
+  (delete-region (point-min) (point-max))
+  (insert "\n")
+  (insert-buffer-substring pgg-output-buffer)
+  t)
 
 ;;;###autoload
 (defun mml1991-encrypt (cont &optional sign)
--- a/lisp/gnus/nnweb.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/gnus/nnweb.el	Fri Apr 28 14:48:18 2006 +0000
@@ -307,8 +307,8 @@
 (defun nnweb-google-wash-article ()
   ;; We have Google's masked e-mail addresses here.  :-/
   (let ((case-fold-search t)
-	(start-re "<pre>\n *")
-	(end-re "\n *</pre>"))
+	(start-re "<pre>[\r\n ]*")
+	(end-re "[\r\n ]*</pre>"))
     (goto-char (point-min))
     (if (save-excursion
 	  (or (re-search-forward "The requested message.*could not be found."
--- a/lisp/image.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/image.el	Fri Apr 28 14:48:18 2006 +0000
@@ -280,6 +280,35 @@
 
 
 ;;;###autoload
+(defun image-type (file-or-data &optional type data-p)
+  "Determine and return image type.
+FILE-OR-DATA is an image file name or image data.
+Optional TYPE is a symbol describing the image type.  If TYPE is omitted
+or nil, try to determine the image type from its first few bytes
+of image data.  If that doesn't work, and FILE-OR-DATA is a file name,
+use its file extension as image type.
+Optional DATA-P non-nil means FILE-OR-DATA is a string containing image data."
+  (when (and (not data-p) (not (stringp file-or-data)))
+    (error "Invalid image file name `%s'" file-or-data))
+  (cond ((null data-p)
+	 ;; FILE-OR-DATA is a file name.
+	 (unless (or type
+		     (setq type (image-type-from-file-header file-or-data)))
+	   (let ((extension (file-name-extension file-or-data)))
+	     (unless extension
+	       (error "Cannot determine image type"))
+	     (setq type (intern extension)))))
+	(t
+	 ;; FILE-OR-DATA contains image data.
+	 (unless type
+	   (setq type (image-type-from-data file-or-data)))))
+  (unless type
+    (error "Cannot determine image type"))
+  (unless (symbolp type)
+    (error "Invalid image type `%s'" type))
+  type)
+
+;;;###autoload
 (defun image-type-available-p (type)
   "Return non-nil if image type TYPE is available.
 Image types are symbols like `xbm' or `jpeg'."
@@ -301,24 +330,7 @@
 Value is the image created, or nil if images of type TYPE are not supported.
 
 Images should not be larger than specified by `max-image-size'."
-  (when (and (not data-p) (not (stringp file-or-data)))
-    (error "Invalid image file name `%s'" file-or-data))
-  (cond ((null data-p)
-	 ;; FILE-OR-DATA is a file name.
-	 (unless (or type
-		     (setq type (image-type-from-file-header file-or-data)))
-	   (let ((extension (file-name-extension file-or-data)))
-	     (unless extension
-	       (error "Cannot determine image type"))
-	     (setq type (intern extension)))))
-	(t
-	 ;; FILE-OR-DATA contains image data.
-	 (unless type
-	   (setq type (image-type-from-data file-or-data)))))
-  (unless type
-    (error "Cannot determine image type"))
-  (unless (symbolp type)
-    (error "Invalid image type `%s'" type))
+  (setq type (image-type file-or-data type data-p))
   (when (image-type-available-p type)
     (append (list 'image :type type (if data-p :data :file) file-or-data)
 	    props)))
--- a/lisp/international/mule.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/international/mule.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1288,15 +1288,15 @@
   "Specify coding system for keyboard input.
 If you set this on a terminal which can't distinguish Meta keys from
 8-bit characters, you will have to use ESC to type Meta characters.
-See Info node `Specify Coding' and Info node `Single-Byte Character Support'.
+See Info node `Terminal Coding' and Info node `Unibyte Mode'.
 
 On non-windowing terminals, this is set from the locale by default.
 
 Setting this variable directly does not take effect;
 use either \\[customize] or \\[set-keyboard-coding-system]."
   :type '(coding-system :tag "Coding system")
-  :link '(info-link "(emacs)Specify Coding")
-  :link '(info-link "(emacs)Single-Byte Character Support")
+  :link '(info-link "(emacs)Terminal Coding")
+  :link '(info-link "(emacs)Unibyte Mode")
   :set (lambda (symbol value)
 	 ;; Don't load encoded-kb unnecessarily.
 	 (if (or value (boundp 'encoded-kbd-setup-display))
--- a/lisp/mail/rmail.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mail/rmail.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1994,7 +1994,7 @@
 					   (re-search-backward
 					    rmail-mime-charset-pattern
 					    start t))))
-				  (intern (downcase (match-string 1))))))
+				  (intern (downcase (match-string 2))))))
 			 (rmail-decode-region start (point) mime-charset)))))
 	       ;; Add an X-Coding-System: header if we don't have one.
 	       (save-excursion
@@ -2155,7 +2155,7 @@
 				       (re-search-backward
 					rmail-mime-charset-pattern
 					start t))))
-			      (intern (downcase (match-string 1))))))
+			      (intern (downcase (match-string 2))))))
 		     (rmail-decode-region start (point) mime-charset)))
 	       (save-excursion
 		 (goto-char start)
--- a/lisp/mh-e/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,71 @@
+2006-04-26  Eric Ding  <ericding@alum.mit.edu>
+
+	* mh-e.el (mh-invisible-header-fields-internal): Add entry
+	"X-Provags-ID:"
+
+2006-04-25  Bill Wohler  <wohler@newt.com>
+
+	* mh-letter.el (mh-folder-expand-at-point): Fix folder completion.
+	Folders returned by mh-folder-completion-function no longer need
+	adornment (closes SF #1476270).
+
+2006-04-21  Bill Wohler  <wohler@newt.com>
+
+	* mh-e.el (Version, mh-version): Add +cvs to version.
+
+2006-04-21  Bill Wohler  <wohler@newt.com>
+
+	Release MH-E version 7.94.
+
+	* mh-e.el (Version, mh-version): Update for release 7.94.
+
+2006-04-21  Bill Wohler  <wohler@newt.com>
+
+	* mh-letter.el (mh-insert-letter): If a message number isn't
+	given, throw an error rather than using a potentially incorrect
+	message number (closes SF #1473729). In addition, use the cur
+	message if mh-sent-from-msg is nil (when sending a message, in
+	contrast to replying). Move conversion of int to string into
+	interactive stanza so body can assume variables are of proper
+	type.
+
+2006-04-20  Bill Wohler  <wohler@newt.com>
+
+	* mh-tool-bar.el (image-load-path): Define to shush compiler.
+	(mh-buffer-exists-p): Move inside mh-do-in-gnu-emacs since it
+	isn't used outside of it.
+	(mh-tool-bar-folder-buttons-init,
+	mh-tool-bar-letter-buttons-init): Update load-path/image-load-path
+	before setting buttons. This code used to be in
+	mh-folder-mode/mh-letter-mode but this was the wrong place since
+	mh-tool-bar-*-buttons-init can also be called when customizing the
+	buttons.
+	(mh-tool-bar-update): New function which updates tool-bar-map in
+	all of the MH-E buffers after customizing the buttons (closes SF
+	#1452718).
+	(mh-tool-bar-folder-buttons-set, mh-tool-bar-letter-buttons-set):
+	Call it (closes SF #1452718).
+
+	* mh-folder.el (mh-folder-buttons-init-flag): Delete. Use
+	mh-folder-tool-bar-map instead.
+	(image-load-path): Delete. No longer used.
+	(mh-folder-mode): Moved setting of image-load-path into
+	mh-tool-bar-folder-buttons-init.
+
+	* mh-letter.el (mh-letter-buttons-init-flag): Delete. Use
+	mh-letter-tool-bar-map instead.
+	(image-load-path): Delete. No longer used.
+	(mh-letter-mode): Moved setting of image-load-path into
+	mh-tool-bar-letter-buttons-init.
+
+	* mh-seq.el (mh-narrow-to-seq, mh-widen): Use with-current-buffer
+	instead of set-buffer.
+
+2006-04-19  Bill Wohler  <wohler@newt.com>
+
+	* mh-tool-bar.el (mh-tool-bar-define): Fix enable-expr so that one
+	can permanently disable a button (such as a separator) with nil.
+
 2006-04-18  Bill Wohler  <wohler@newt.com>
 
 	* mh-e.el (defcustom-mh, defface-mh, defgroup-mh, mh-face-data)
--- a/lisp/mh-e/mh-e.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/mh-e.el	Fri Apr 28 14:48:18 2006 +0000
@@ -6,7 +6,7 @@
 
 ;; Author: Bill Wohler <wohler@newt.com>
 ;; Maintainer: Bill Wohler <wohler@newt.com>
-;; Version: 7.93+cvs
+;; Version: 7.94+cvs
 ;; Keywords: mail
 
 ;; This file is part of GNU Emacs.
@@ -136,7 +136,7 @@
 ;; Try to keep variables local to a single file. Provide accessors if
 ;; variables are shared. Use this section as a last resort.
 
-(defconst mh-version "7.93+cvs" "Version number of MH-E.")
+(defconst mh-version "7.94+cvs" "Version number of MH-E.")
 
 ;; Variants
 
@@ -2526,6 +2526,7 @@
     "X-Originating-IP:"                 ; Hotmail
     "X-Postfilter:"
     "X-Priority:"                       ; MS Outlook
+    "X-Provags-ID:"
     "X-Qotd-"                           ; User added
     "X-RM"
     "X-Received-Date:"
--- a/lisp/mh-e/mh-folder.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/mh-folder.el	Fri Apr 28 14:48:18 2006 +0000
@@ -524,11 +524,8 @@
 ;; Shush compiler.
 (defvar desktop-save-buffer)
 (defvar font-lock-auto-fontify)
-(defvar image-load-path)
 (defvar font-lock-defaults)             ; XEmacs
 
-(defvar mh-folder-buttons-init-flag nil)
-
 ;; Ensure new buffers won't get this mode if default-major-mode is nil.
 (put 'mh-folder-mode 'mode-class 'special)
 
@@ -590,13 +587,8 @@
 
 \\{mh-folder-mode-map}"
   (mh-do-in-gnu-emacs
-    (unless mh-folder-buttons-init-flag
-      (let* ((load-path (mh-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)
-        (setq mh-folder-buttons-init-flag t)))
+    (unless mh-folder-tool-bar-map
+        (mh-tool-bar-folder-buttons-init))
     (set (make-local-variable 'tool-bar-map) mh-folder-tool-bar-map))
   (mh-do-in-xemacs
     (mh-tool-bar-init :folder))
--- a/lisp/mh-e/mh-letter.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/mh-letter.el	Fri Apr 28 14:48:18 2006 +0000
@@ -275,10 +275,7 @@
 
 ;;; MH-Letter Mode
 
-(defvar mh-letter-buttons-init-flag nil)
-
 ;; Shush compiler.
-(defvar image-load-path)
 (defvar font-lock-defaults)             ; XEmacs
 
 ;; Ensure new buffers won't get this mode if default-major-mode is nil.
@@ -313,13 +310,8 @@
   (make-local-variable 'mh-sent-from-folder)
   (make-local-variable 'mh-sent-from-msg)
   (mh-do-in-gnu-emacs
-    (unless mh-letter-buttons-init-flag
-      (let* ((load-path (mh-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-letter-buttons-init)
-        (setq mh-letter-buttons-init-flag t)))
+    (unless mh-letter-tool-bar-map
+      (mh-tool-bar-letter-buttons-init))
     (set (make-local-variable 'tool-bar-map) mh-letter-tool-bar-map))
   (mh-do-in-xemacs
     (mh-tool-bar-init :letter))
@@ -401,24 +393,26 @@
 This command leaves the mark before the letter and point after it."
   (interactive
    (let* ((folder
-           (mh-prompt-for-folder "Message from"
-                                 mh-sent-from-folder nil))
+           (mh-prompt-for-folder "Message from" mh-sent-from-folder nil))
           (default
-            (if (and (equal folder mh-sent-from-folder)
-                     (numberp mh-sent-from-msg))
-                mh-sent-from-msg
+            (if (equal folder mh-sent-from-folder)
+                (or mh-sent-from-msg (nth 0 (mh-translate-range folder "cur")))
               (nth 0 (mh-translate-range folder "cur"))))
           (message
            (read-string (concat "Message number"
                                 (or (and default
                                          (format " (default %d): " default))
-                                    ": ")))))
+                                    ": "))
+                        nil nil
+                        (if (numberp default)
+                            (int-to-string default)
+                          default))))
      (list folder message current-prefix-arg)))
+  (if (equal message "")
+      (error "No message number given"))
   (save-restriction
     (narrow-to-region (point) (point))
     (let ((start (point-min)))
-      (if (and (equal message "") (numberp mh-sent-from-msg))
-          (setq message (int-to-string mh-sent-from-msg)))
       (insert-file-contents
        (expand-file-name message (mh-expand-file-name folder)))
       (when (not verbatim)
@@ -872,15 +866,12 @@
   "Do folder name completion in Fcc header field."
   (let* ((end (point))
          (beg (mh-beginning-of-word))
-         (folder (buffer-substring beg end))
+         (folder (buffer-substring-no-properties beg end))
          (leading-plus (and (> (length folder) 0) (equal (aref folder 0) ?+)))
-         (last-slash (mh-search-from-end ?/ folder))
-         (prefix (and last-slash (substring folder 0 last-slash)))
-         (choices (mapcar #'(lambda (x)
-                              (list (cond (prefix (format "%s/%s" prefix x))
-                                          (leading-plus (format "+%s" x))
-                                          (t x))))
+         (choices (mapcar (lambda (x) (list x))
                           (mh-folder-completion-function folder nil t))))
+    (unless leading-plus
+      (setq folder (concat "+" folder)))
     (mh-complete-word folder choices beg end)))
 
 ;;;###mh-autoload
--- a/lisp/mh-e/mh-seq.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/mh-seq.el	Fri Apr 28 14:48:18 2006 +0000
@@ -238,8 +238,7 @@
                (set (make-local-variable 'tool-bar-map)
                     mh-folder-seq-tool-bar-map)
                (when (buffer-live-p (get-buffer mh-show-buffer))
-                 (save-excursion
-                   (set-buffer (get-buffer mh-show-buffer))
+                 (with-current-buffer mh-show-buffer
                    (set (make-local-variable 'tool-bar-map)
                         mh-show-seq-tool-bar-map))))
              (push 'widen mh-view-ops)))
@@ -371,8 +370,7 @@
   (when (and (null mh-folder-view-stack) (boundp 'tool-bar-mode) tool-bar-mode)
     (set (make-local-variable 'tool-bar-map) mh-folder-tool-bar-map)
     (when (buffer-live-p (get-buffer mh-show-buffer))
-      (save-excursion
-        (set-buffer (get-buffer mh-show-buffer))
+      (with-current-buffer mh-show-buffer
         (set (make-local-variable 'tool-bar-map) mh-show-tool-bar-map)))))
 
 
--- a/lisp/mh-e/mh-tool-bar.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/mh-e/mh-tool-bar.el	Fri Apr 28 14:48:18 2006 +0000
@@ -83,6 +83,9 @@
 
 ;;; Tool Bar Creation
 
+;; Shush compiler.
+(defvar image-load-path)
+
 (defmacro mh-tool-bar-define (defaults &rest buttons)
   "Define a tool bar for MH-E.
 DEFAULTS is the list of buttons that are present by default. It
@@ -151,7 +154,7 @@
              (doc (if (string-match "\\(.*\\)\n" full-doc)
                       (match-string 1 full-doc)
                     full-doc))
-             (enable-expr (or (nth 4 button) t))
+             (enable-expr (if (eql (length button) 4) t (nth 4 button)))
              (modes (nth 1 button))
              functions show-sym)
         (when (memq 'letter modes) (setq functions `(:letter ,name)))
@@ -178,7 +181,7 @@
                                     (t 'folder-vectors)))
                  (list (cond ((eq type :letter) 'mh-tool-bar-letter-buttons)
                              (t 'mh-tool-bar-folder-buttons)))
-                 (key (intern (concat "mh-" type1 "tool-bar-" name-str)))
+                 (key (intern (concat "mh-" type1 "-tool-bar-" name-str)))
                  (setter (intern (concat type1 "-button-setter")))
                  (mbuttons (cond ((eq type :letter) 'letter-buttons)
                                  ((eq type :show) 'show-buttons)
@@ -209,50 +212,79 @@
       (unless (memq x letter-buttons)
         (error "Letter defaults contains unknown button %s" x)))
     `(eval-when (compile load eval)
-       (defun mh-buffer-exists-p (mode)
-         "Test whether a buffer with major mode MODE is present."
-         (loop for buf in (buffer-list)
-               when (save-excursion
-                      (set-buffer buf)
-                      (eq major-mode mode))
-               return t))
-
        ;; GNU Emacs tool bar specific code
        (mh-do-in-gnu-emacs
+         (defun mh-buffer-exists-p (mode)
+           "Test whether a buffer with major mode MODE is present."
+           (loop for buf in (buffer-list)
+                 when (with-current-buffer buf
+                        (eq major-mode mode))
+                 return t))
          ;; Tool bar initialization functions
          (defun mh-tool-bar-folder-buttons-init ()
            (when (mh-buffer-exists-p 'mh-folder-mode)
-             (setq mh-folder-tool-bar-map
-                   (let ((tool-bar-map (make-sparse-keymap)))
-                     ,@(nreverse folder-button-setter)
-                     tool-bar-map))
-             (setq mh-show-tool-bar-map
-                   (let ((tool-bar-map (make-sparse-keymap)))
-                     ,@(nreverse show-button-setter)
-                     tool-bar-map))
-             (setq mh-show-seq-tool-bar-map
-                   (let ((tool-bar-map (copy-keymap mh-show-tool-bar-map)))
-                     ,@(nreverse show-seq-button-setter)
-                     tool-bar-map))
-             (setq mh-folder-seq-tool-bar-map
-                   (let ((tool-bar-map (copy-keymap mh-folder-tool-bar-map)))
-                     ,@(nreverse sequence-button-setter)
-                     tool-bar-map))))
+             (let* ((load-path (mh-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))))
+               (setq mh-folder-tool-bar-map
+                     (let ((tool-bar-map (make-sparse-keymap)))
+                       ,@(nreverse folder-button-setter)
+                       tool-bar-map))
+               (setq mh-folder-seq-tool-bar-map
+                     (let ((tool-bar-map (copy-keymap mh-folder-tool-bar-map)))
+                       ,@(nreverse sequence-button-setter)
+                       tool-bar-map))
+               (setq mh-show-tool-bar-map
+                     (let ((tool-bar-map (make-sparse-keymap)))
+                       ,@(nreverse show-button-setter)
+                       tool-bar-map))
+               (setq mh-show-seq-tool-bar-map
+                     (let ((tool-bar-map (copy-keymap mh-show-tool-bar-map)))
+                       ,@(nreverse show-seq-button-setter)
+                       tool-bar-map)))))
          (defun mh-tool-bar-letter-buttons-init ()
            (when (mh-buffer-exists-p 'mh-letter-mode)
-             (setq mh-letter-tool-bar-map
-                   (let ((tool-bar-map (make-sparse-keymap)))
-                     ,@(nreverse letter-button-setter)
-                     tool-bar-map))))
+             (let* ((load-path (mh-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))))
+               (setq mh-letter-tool-bar-map
+                     (let ((tool-bar-map (make-sparse-keymap)))
+                       ,@(nreverse letter-button-setter)
+                       tool-bar-map)))))
          ;; Custom setter functions
+         (defun mh-tool-bar-update (mode default-map sequence-map)
+           "Update `tool-bar-map' in all buffers of MODE.
+Use SEQUENCE-MAP if display is limited; DEFAULT-MAP otherwise."
+           (loop for buf in (buffer-list)
+                 do (with-current-buffer buf
+                      (if (eq mode major-mode)
+                          (let ((map (if mh-folder-view-stack
+                                         sequence-map
+                                       default-map)))
+                            ;; Yes, make-local-variable is necessary since we
+                            ;; get here during initialization when loading
+                            ;; mh-e.el, after the +inbox buffer has been
+                            ;; created, but before mh-folder-mode has run and
+                            ;; created the local map.
+                            (set (make-local-variable 'tool-bar-map) map))))))
          (defun mh-tool-bar-folder-buttons-set (symbol value)
            "Construct tool bar for `mh-folder-mode' and `mh-show-mode'."
            (set-default symbol value)
-           (mh-tool-bar-folder-buttons-init))
+           (mh-tool-bar-folder-buttons-init)
+           (mh-tool-bar-update 'mh-folder-mode mh-folder-tool-bar-map
+                               mh-folder-seq-tool-bar-map)
+           (mh-tool-bar-update 'mh-show-mode mh-show-tool-bar-map
+                               mh-show-seq-tool-bar-map))
          (defun mh-tool-bar-letter-buttons-set (symbol value)
            "Construct tool bar for `mh-letter-mode'."
            (set-default symbol value)
-           (mh-tool-bar-letter-buttons-init)))
+           (mh-tool-bar-letter-buttons-init)
+           (mh-tool-bar-update 'mh-letter-mode mh-letter-tool-bar-map
+                               mh-letter-tool-bar-map)))
        ;; XEmacs specific code
        (mh-do-in-xemacs
          (defvar mh-tool-bar-folder-vector-map
@@ -318,7 +350,8 @@
         'mh-tool-bar-folder-buttons
         '(list ,@(mapcar (lambda (x) `(quote ,x)) folder-defaults))
         "List of buttons to include in MH-Folder tool bar."
-        :group 'mh-tool-bar :set 'mh-tool-bar-folder-buttons-set
+        :group 'mh-tool-bar
+        :set 'mh-tool-bar-folder-buttons-set
         :type '(set ,@(loop for x in folder-buttons
                             for y in folder-docs
                             collect `(const :tag ,y ,x)))
@@ -328,7 +361,8 @@
         'mh-tool-bar-letter-buttons
         '(list ,@(mapcar (lambda (x) `(quote ,x)) letter-defaults))
         "List of buttons to include in MH-Letter tool bar."
-        :group 'mh-tool-bar :set 'mh-tool-bar-letter-buttons-set
+        :group 'mh-tool-bar
+        :set 'mh-tool-bar-letter-buttons-set
         :type '(set ,@(loop for x in letter-buttons
                             for y in letter-docs
                             collect `(const :tag ,y ,x)))
--- a/lisp/net/rcirc.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/net/rcirc.el	Fri Apr 28 14:48:18 2006 +0000
@@ -74,13 +74,13 @@
   :group 'rcirc)
 
 (defcustom rcirc-default-user-full-name (if (string= (user-full-name) "")
-				 rcirc-user-name
-			       (user-full-name))
+					    rcirc-user-name
+					  (user-full-name))
   "The full name sent to the server when connecting."
   :type 'string
   :group 'rcirc)
 
-(defcustom rcirc-startup-channels-alist '(("^irc.freenode.net$" "#emacs"))
+(defcustom rcirc-startup-channels-alist '(("^irc.freenode.net$" "#rcirc"))
   "Alist of channels to join at startup.
 Each element looks like (SERVER-REGEXP . CHANNEL-LIST)."
   :type '(alist :key-type string :value-type (repeat string))
@@ -206,6 +206,18 @@
 Nicks will be removed from the automatic list on follow-up renamings or
 parts.")
 
+(defcustom rcirc-bright-nick-regexp nil
+  "Regexp matching nicks to be emphasized.
+See `rcirc-bright-nick' face."
+  :type 'regexp
+  :group 'rcirc)
+
+(defcustom rcirc-dim-nick-regexp nil
+  "Regexp matching nicks to be deemphasized.
+See `rcirc-dim-nick' face."
+  :type 'regexp
+  :group 'rcirc)
+
 (defcustom rcirc-print-hooks nil
   "Hook run after text is printed.
 Called with 5 arguments, PROCESS, SENDER, RESPONSE, TARGET and TEXT."
@@ -217,7 +229,7 @@
   :type 'boolean
   :group 'rcirc)
 
-(defcustom rcirc-decode-coding-system 'undecided
+(defcustom rcirc-decode-coding-system 'utf-8
   "Coding system used to decode incoming irc messages."
   :type 'coding-system
   :group 'rcirc)
@@ -546,7 +558,7 @@
     (with-current-buffer rcirc-server-buffer
       (or rcirc-nick rcirc-default-nick))))
 
-(defvar rcirc-max-message-length 450
+(defvar rcirc-max-message-length 420
   "Messages longer than this value will be split.")
 
 (defun rcirc-send-message (process target message &optional noticep)
@@ -955,7 +967,8 @@
   :global nil
   :group 'rcirc
   (make-local-variable 'rcirc-parent-buffer)
-  (put 'rcirc-parent-buffer 'permanent-local t))
+  (put 'rcirc-parent-buffer 'permanent-local t)
+  (setq fill-column rcirc-max-message-length))
 
 (defun rcirc-multiline-minor-submit ()
   "Send the text in buffer back to parent buffer."
@@ -1029,6 +1042,7 @@
 	 (split-string (or (cdr (assoc response rcirc-response-formats))
 			   (cdr (assq t rcirc-response-formats)))
 		       "%"))
+	(sender (or sender ""))
 	(result "")
 	(face nil)
 	key face-key repl)
@@ -1054,9 +1068,16 @@
 		     (rcirc-facify nick
 				   (if (eq key ?n)
 				       face
-				     (if (string= sender (rcirc-nick process))
-					 'rcirc-my-nick
-				       'rcirc-other-nick)))))
+				     (cond ((string= sender (rcirc-nick process))
+					    'rcirc-my-nick)
+					   ((and rcirc-bright-nick-regexp
+						 (string-match rcirc-bright-nick-regexp sender))
+					    'rcirc-bright-nick)
+					   ((and rcirc-dim-nick-regexp
+						 (string-match rcirc-dim-nick-regexp sender))
+					    'rcirc-dim-nick)
+					   (t
+					    'rcirc-other-nick))))))
 		  ((eq key ?T)
 		   ;; %T -- timestamp
 		   (rcirc-facify
@@ -1130,8 +1151,9 @@
   (or text (setq text ""))
   (unless (or (member sender rcirc-ignore-list)
 	      (member (with-syntax-table rcirc-nick-syntax-table
-			(when (string-match "^\\([^/]\\w*\\)\\b" text)
-			  (match-string 1 text))) rcirc-ignore-list))
+			(when (string-match "^\\([^/]\\w*\\)[:,]" text)
+			  (match-string 1 text)))
+		      rcirc-ignore-list))
     (let* ((buffer (rcirc-target-buffer process sender response target text))
 	   (inhibit-read-only t))
       (with-current-buffer buffer
@@ -1222,10 +1244,12 @@
 				       (regexp-quote (rcirc-nick process))
 				       "\\b")
 			       text)))
-	    (when (or (not rcirc-ignore-buffer-activity-flag)
-		      ;; always notice when our nick is mentioned, even
-		      ;; if ignoring channel activity
-		      nick-match)
+	    (when (if rcirc-ignore-buffer-activity-flag
+		      ;; - Always notice when our nick is mentioned
+		      nick-match
+		    ;; - Never bother us if a dim-nick spoke
+		    (not (and rcirc-dim-nick-regexp sender
+			      (string-match rcirc-dim-nick-regexp sender))))
 	      (rcirc-record-activity
 	       (current-buffer)
 	       (when (or nick-match (and (not (rcirc-channel-p rcirc-target))
@@ -1375,7 +1399,7 @@
   (force-mode-line-update))
 
 (defun rcirc-toggle-low-priority ()
-  "Toggle the value of `rcirc-ignore-buffer-activity-flag'."
+  "Toggle the value of `rcirc-low-priority-flag'."
   (interactive)
   (setq rcirc-low-priority-flag
 	(not rcirc-low-priority-flag))
@@ -1788,7 +1812,7 @@
 
 (defun rcirc-browse-url (&optional arg)
   "Prompt for URL to browse based on URLs in buffer."
-  (interactive)
+  (interactive "P")
   (let ((completions (mapcar (lambda (x) (cons x nil)) rcirc-urls))
         (initial-input (car rcirc-urls))
         (history (cdr rcirc-urls)))
@@ -1910,7 +1934,7 @@
 		   (cond ((rcirc-channel-p target)
 			  target)
 			 ;;; -ChanServ- [#gnu] Welcome...
-			 ((string-match "^\\[\\(#[^ ]+\\)\\]" message)
+			 ((string-match "\\[\\(#[^\] ]+\\)\\]" message)
 			  (match-string 1 message))
 			 (sender
 			  (if (string= sender (rcirc-server-name process))
@@ -2211,6 +2235,25 @@
   "The face used to highlight other messages."
   :group 'rcirc-faces)
 
+(defface rcirc-bright-nick
+  '((((class grayscale) (background light))
+     (:foreground "LightGray" :weight bold :underline t))
+    (((class grayscale) (background dark))
+     (:foreground "Gray50" :weight bold :underline t))
+    (((class color) (min-colors 88) (background light)) (:foreground "CadetBlue"))
+    (((class color) (min-colors 88) (background dark)) (:foreground "Aquamarine"))
+    (((class color) (min-colors 16) (background light)) (:foreground "CadetBlue"))
+    (((class color) (min-colors 16) (background dark)) (:foreground "Aquamarine"))
+    (((class color) (min-colors 8)) (:foreground "magenta"))
+    (t (:weight bold :underline t)))
+  "Face used for nicks matched by `rcirc-bright-nick-regexp'."
+  :group 'rcirc-faces)
+
+(defface rcirc-dim-nick
+  '((t :inherit default))
+  "Face used for nicks matched by `rcirc-dim-nick-regexp'."
+  :group 'rcirc-faces)
+
 (defface rcirc-server			; font-lock-comment-face
   '((((class grayscale) (background light))
      (:foreground "DimGray" :weight bold :slant italic))
--- a/lisp/net/tramp.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/net/tramp.el	Fri Apr 28 14:48:18 2006 +0000
@@ -4337,19 +4337,34 @@
 	(save-match-data (apply (cdr fn) args))
       (tramp-completion-run-real-handler operation args))))
 
-;;;###autoload
-(put 'tramp-completion-file-name-handler 'safe-magic t)
-
-;; Register in file name handler alist
+;; Register in `file-name-handler-alist'.
+;; `tramp-completion-file-name-handler' must not be active when temacs
+;; dumps.  And it makes no sense in batch mode anyway.
 ;;;###autoload
-(add-to-list 'file-name-handler-alist
-	     (cons tramp-file-name-regexp 'tramp-file-name-handler))
-(add-to-list 'file-name-handler-alist
-	     (cons tramp-completion-file-name-regexp
-		   'tramp-completion-file-name-handler))
+(defun tramp-register-file-name-handlers ()
+  "Add tramp file name handlers to `file-name-handler-alist'."
+  (unless noninteractive
+    (add-to-list 'file-name-handler-alist
+		 (cons tramp-file-name-regexp 'tramp-file-name-handler))
+    (add-to-list 'file-name-handler-alist
+		 (cons tramp-completion-file-name-regexp
+		       'tramp-completion-file-name-handler))
+    (put 'tramp-completion-file-name-handler 'safe-magic t)))
+
+;; LAMBDA function used temporarily, because older/other versions of
+;; Tramp don't know of `tramp-register-file-name-handlers'.  Can be
+;; replaced once that DEFUN is established.  Relevant for Emacs 22 only.
+;;;###;autoload(add-hook 'emacs-startup-hook 'tramp-register-file-name-handlers)
+;;;###autoload(add-hook
+;;;###autoload 'emacs-startup-hook
+;;;###autoload '(lambda ()
+;;;###autoload    (condition-case nil
+;;;###autoload        (funcall 'tramp-register-file-name-handlers)
+;;;###autoload      (error nil))))
+(tramp-register-file-name-handlers)
 
 ;;;###autoload
-(defun tramp-unload-file-name-handler-alist ()
+(defun tramp-unload-file-name-handlers ()
   (setq file-name-handler-alist
 	(delete (rassoc 'tramp-file-name-handler
 			file-name-handler-alist)
@@ -4357,7 +4372,7 @@
 				file-name-handler-alist)
 			file-name-handler-alist))))
 
-(add-hook 'tramp-unload-hook 'tramp-unload-file-name-handler-alist)
+(add-hook 'tramp-unload-hook 'tramp-unload-file-name-handlers)
 
 (defun tramp-repair-jka-compr ()
   "If jka-compr is already loaded, move it to the front of
@@ -7629,7 +7644,7 @@
 (defun tramp-unload-tramp ()
   (interactive)
   ;; When Tramp is not loaded yet, its autoloads are still active.
-  (tramp-unload-file-name-handler-alist)
+  (tramp-unload-file-name-handlers)
   ;; ange-ftp settings must be enabled.
   (when (functionp 'tramp-ftp-enable-ange-ftp)
     (funcall (symbol-function 'tramp-ftp-enable-ange-ftp)))
--- a/lisp/newcomment.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/newcomment.el	Fri Apr 28 14:48:18 2006 +0000
@@ -108,21 +108,25 @@
 ;;;###autoload
 (defvar comment-start nil
   "*String to insert to start a new comment, or nil if no comment syntax.")
+;;;###autoload(put 'comment-start 'safe-local-variable 'string-or-null-p)
 
 ;;;###autoload
 (defvar comment-start-skip nil
   "*Regexp to match the start of a comment plus everything up to its body.
 If there are any \\(...\\) pairs, the comment delimiter text is held to begin
 at the place matched by the close of the first pair.")
+;;;###autoload(put 'comment-start-skip 'safe-local-variable 'string-or-null-p)
 
 ;;;###autoload
 (defvar comment-end-skip nil
   "Regexp to match the end of a comment plus everything up to its body.")
+;;;###autoload(put 'comment-end-skip 'safe-local-variable 'string-or-null-p)
 
 ;;;###autoload
 (defvar comment-end ""
   "*String to insert to end a new comment.
 Should be an empty string if comments are terminated by end-of-line.")
+;;;###autoload(put 'comment-end 'safe-local-variable 'string-or-null-p)
 
 ;;;###autoload
 (defvar comment-indent-function 'comment-indent-default
--- a/lisp/progmodes/antlr-mode.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/antlr-mode.el	Fri Apr 28 14:48:18 2006 +0000
@@ -829,7 +829,7 @@
 `antlr-font-lock-maximum-decoration'.")
 
 (defvar antlr-default-face 'antlr-default)
-(defface antlr-default nil
+(defface antlr-default '((t nil))
   "Face to prevent strings from language dependent highlighting.
 Do not change."
   :group 'antlr)
--- a/lisp/progmodes/asm-mode.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/asm-mode.el	Fri Apr 28 14:48:18 2006 +0000
@@ -62,9 +62,9 @@
 
 (defvar asm-mode-syntax-table
   (let ((st (make-syntax-table)))
-    (modify-syntax-entry ?\n ">" st)
-    (modify-syntax-entry ?/  ". 14b" st)
-    (modify-syntax-entry ?*  ". 23b" st)
+    (modify-syntax-entry ?\n "> b" st)
+    (modify-syntax-entry ?/  ". 124b" st)
+    (modify-syntax-entry ?*  ". 23" st)
     st)
   "Syntax table used while in Asm mode.")
 
@@ -136,14 +136,14 @@
   (use-local-map (nconc (make-sparse-keymap) asm-mode-map))
   (local-set-key (vector asm-comment-char) 'asm-comment)
   (set-syntax-table (make-syntax-table asm-mode-syntax-table))
-  (modify-syntax-entry	asm-comment-char "<")
+  (modify-syntax-entry	asm-comment-char "< b")
 
   (make-local-variable 'comment-start)
   (setq comment-start (string asm-comment-char))
   (make-local-variable 'comment-add)
   (setq comment-add 1)
   (make-local-variable 'comment-start-skip)
-  (setq comment-start-skip "\\(?:\\s<+\\|/\\*+\\)[ \t]*")
+  (setq comment-start-skip "\\(?:\\s<+\\|/[/*]+\\)[ \t]*")
   (make-local-variable 'comment-end-skip)
   (setq comment-end-skip "[ \t]*\\(\\s>\\|\\*+/\\)")
   (make-local-variable 'comment-end)
--- a/lisp/progmodes/cc-subword.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/cc-subword.el	Fri Apr 28 14:48:18 2006 +0000
@@ -91,8 +91,8 @@
 ;; Don't complain about the `define-minor-mode' form if it isn't defined.
 (cc-bytecomp-defvar c-subword-mode)
 
-;;; Autoload directives must be on the top level, so we construct an
-;;; autoload form instead.
+;; Autoload directives must be on the top level, so we construct an
+;; autoload form instead.
 ;;;###autoload (autoload 'c-subword-mode "cc-subword" "Mode enabling subword movement and editing keys." t)
 
 (if (not (fboundp 'define-minor-mode))
@@ -107,36 +107,19 @@
 
   (defvar c-subword-mode-map
     (let ((map (make-sparse-keymap)))
-      (substitute-key-definition 'forward-word
-				 'c-forward-subword
-				 map global-map)
-      (substitute-key-definition 'backward-word
-				 'c-backward-subword
-				 map global-map)
-      (substitute-key-definition 'mark-word
-				 'c-mark-subword
-				 map global-map)
-    
-      (substitute-key-definition 'kill-word
-				 'c-kill-subword
-				 map global-map)
-      (substitute-key-definition 'backward-kill-word
-				 'c-backward-kill-subword
-				 map global-map)
-    
-      (substitute-key-definition 'transpose-words
-				 'c-transpose-subwords
-				 map global-map)
-    
-      (substitute-key-definition 'capitalize-word
-				 'c-capitalize-subword
-				 map global-map)
-      (substitute-key-definition 'upcase-word
-				 'c-upcase-subword
-				 map global-map)
-      (substitute-key-definition 'downcase-word
-				 'c-downcase-subword
-				 map global-map)
+      (dolist (cmd '(forward-word backward-word mark-word
+                     kill-word backward-kill-word
+                     transpose-words
+                     capitalize-word upcase-word downcase-word))
+        (let ((othercmd (let ((name (symbol-name cmd)))
+                          (string-match "\\(.*-\\)\\(word.*\\)" name)
+                          (intern (concat "c-"
+                                          (match-string 1 name)
+                                          "sub"
+                                          (match-string 2 name))))))
+          (if (fboundp 'command-remapping)
+              (define-key map (vector 'remap cmd) othercmd)
+            (substitute-key-definition cmd othercmd map global-map))))
       map)
     "Keymap used in command `c-subword-mode' minor mode.")
 
@@ -308,5 +291,5 @@
 
 (cc-provide 'cc-subword)
 
-;;; arch-tag: 2be9d294-7f30-4626-95e6-9964bb93c7a3
+;; arch-tag: 2be9d294-7f30-4626-95e6-9964bb93c7a3
 ;;; cc-subword.el ends here
--- a/lisp/progmodes/gdb-ui.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/gdb-ui.el	Fri Apr 28 14:48:18 2006 +0000
@@ -3294,6 +3294,7 @@
 	(with-current-buffer (gdb-get-buffer 'gdb-registers-buffer)
 	  (let ((buffer-read-only nil))
 	    (erase-buffer)
+	    (put-text-property 0 (length err) 'face font-lock-warning-face err)
 	    (insert err)
 	    (goto-char (point-min)))))
     (let ((register-list (reverse gdb-register-names))
@@ -3390,36 +3391,44 @@
 (defun gdb-stack-list-locals-handler ()
   (setq gdb-pending-triggers (delq 'gdb-invalidate-locals-1
 				  gdb-pending-triggers))
-  (let (local locals-list)
-    (goto-char (point-min))
-    (while (re-search-forward gdb-stack-list-locals-regexp nil t)
-      (let ((local (list (match-string 1)
-			 (match-string 2)
-			 nil)))
-	(if (looking-at ",value=\\(\".*\"\\).*?}")
-	    (setcar (nthcdr 2 local) (read (match-string 1))))
-	(push local locals-list)))
-    (let ((buf (gdb-get-buffer 'gdb-locals-buffer)))
-      (and buf (with-current-buffer buf
-		 (let* ((window (get-buffer-window buf 0))
-			(start (window-start window))
-			(p (window-point window))
-			(buffer-read-only nil))
-		   (erase-buffer)
-		   (dolist (local locals-list)
-		     (setq name (car local))
-		     (if (or (not (nth 2 local))
-			     (string-match "\\0x" (nth 2 local)))
-		       (add-text-properties 0 (length name)
-			    `(mouse-face highlight
-			      help-echo "mouse-2: create watch expression"
-			      local-map ,gdb-locals-watch-map-1)
-			    name))
+  (goto-char (point-min))
+  (if (re-search-forward gdb-error-regexp nil t)
+      (let ((err (match-string 1)))
+	(with-current-buffer (gdb-get-buffer 'gdb-locals-buffer)
+	  (let ((buffer-read-only nil))
+	    (erase-buffer)
+	    (insert err)
+	    (goto-char (point-min)))))
+    (let (local locals-list)
+      (goto-char (point-min))
+      (while (re-search-forward gdb-stack-list-locals-regexp nil t)
+	(let ((local (list (match-string 1)
+			   (match-string 2)
+			   nil)))
+	  (if (looking-at ",value=\\(\".*\"\\).*?}")
+	      (setcar (nthcdr 2 local) (read (match-string 1))))
+	  (push local locals-list)))
+      (let ((buf (gdb-get-buffer 'gdb-locals-buffer)))
+	(and buf (with-current-buffer buf
+		   (let* ((window (get-buffer-window buf 0))
+			  (start (window-start window))
+			  (p (window-point window))
+			  (buffer-read-only nil))
+		     (erase-buffer)
+		     (dolist (local locals-list)
+		       (setq name (car local))
+		       (if (or (not (nth 2 local))
+			       (string-match "^\\0x" (nth 2 local)))
+			   (add-text-properties 0 (length name)
+			        `(mouse-face highlight
+			          help-echo "mouse-2: create watch expression"
+			          local-map ,gdb-locals-watch-map-1)
+				name))
 		       (insert
 			(concat name "\t" (nth 1 local)
 				"\t" (nth 2 local) "\n")))
-		   (set-window-start window start)
-		   (set-window-point window p)))))))
+		     (set-window-start window start)
+		     (set-window-point window p))))))))
 
 (defun gdb-get-register-names ()
   "Create a list of register names."
--- a/lisp/progmodes/gud.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/gud.el	Fri Apr 28 14:48:18 2006 +0000
@@ -83,6 +83,8 @@
 (defvar gud-minor-mode nil)
 (put 'gud-minor-mode 'permanent-local t)
 
+(defvar gud-comint-buffer nil)
+
 (defvar gud-keep-buffer nil)
 
 (defun gud-symbol (sym &optional soft minor-mode)
@@ -740,8 +742,6 @@
 ;; The completion list is constructed by the process filter.
 (defvar gud-gdb-fetched-lines)
 
-(defvar gud-comint-buffer nil)
-
 (defun gud-gdb-complete-command (&optional command a b)
   "Perform completion on the GDB command preceding point.
 This is implemented using the GDB `complete' command which isn't
@@ -2889,8 +2889,11 @@
       (set-buffer gud-comint-buffer)
       (save-restriction
 	(widen)
-	(goto-char (process-mark proc))
-	(forward-line 0)
+	(if (marker-position gud-delete-prompt-marker)
+	    ;; We get here when printing an expression.
+	    (goto-char gud-delete-prompt-marker)
+	  (goto-char (process-mark proc))
+	  (forward-line 0))
 	(if (looking-at comint-prompt-regexp)
 	    (set-marker gud-delete-prompt-marker (point)))
 	(if (memq gud-minor-mode '(gdbmi gdba))
@@ -2911,7 +2914,21 @@
 (defvar gud-find-expr-function 'gud-find-c-expr)
 
 (defun gud-find-expr (&rest args)
-  (apply gud-find-expr-function args))
+  (let ((expr (if (and transient-mark-mode mark-active)
+		  (buffer-substring (region-beginning) (region-end))
+		(apply gud-find-expr-function args))))
+    (save-match-data
+      (if (string-match "\n" expr)
+	  (error "Expression must not include a newline"))
+      (with-current-buffer gud-comint-buffer
+	(save-excursion
+	  (goto-char (process-mark (get-buffer-process gud-comint-buffer)))
+	  (forward-line 0)
+	  (when (looking-at comint-prompt-regexp)
+	    (set-marker gud-delete-prompt-marker (point))
+	    (set-marker-insertion-type gud-delete-prompt-marker t))
+	  (insert (concat  expr " = ")))))
+    expr))
 
 ;; The next eight functions are hacked from gdbsrc.el by
 ;; Debby Ayers <ayers@asc.slb.com>,
--- a/lisp/progmodes/idlw-help.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/idlw-help.el	Fri Apr 28 14:48:18 2006 +0000
@@ -864,6 +864,7 @@
 		  (erase-buffer)
 		  (insert-file-contents file nil nil nil 'replace))
 	      (idlwave-help-error name type class keyword)))
+	  (goto-char (point-min))
 	  (if (and idlwave-help-fontify-source-code (not in-buf))
 	      (idlwave-help-fontify)))
       (idlwave-help-error name type class keyword))
--- a/lisp/progmodes/python.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/python.el	Fri Apr 28 14:48:18 2006 +0000
@@ -292,9 +292,9 @@
 comments and strings, or that the bracket/paren nesting depth is nonzero."
   (or (and (eq ?\\ (char-before (line-end-position 0)))
 	   (not (syntax-ppss-context (syntax-ppss))))
-      (/= 0 (syntax-ppss-depth
-	     (save-excursion	  ; syntax-ppss with arg changes point
-	       (syntax-ppss (line-beginning-position)))))))
+      (< 0 (syntax-ppss-depth
+            (save-excursion	  ; syntax-ppss with arg changes point
+              (syntax-ppss (line-beginning-position)))))))
 
 (defun python-comment-line-p ()
   "Return non-nil iff current line has only a comment."
@@ -719,7 +719,10 @@
 	(python-beginning-of-string)
 	;; Skip forward out of nested brackets.
 	(condition-case ()		; beware invalid syntax
-	    (progn (backward-up-list (syntax-ppss-depth (syntax-ppss))) t)
+	    (let ((depth (syntax-ppss-depth (syntax-ppss))))
+              ;; Beware negative depths.
+              (if (> depth 0) (backward-up-list depth))
+              t)
 	  (error (throw 'foo nil))))))
   (back-to-indentation))
 
@@ -1755,7 +1758,6 @@
   (if (featurep 'hippie-exp)
       (set (make-local-variable 'hippie-expand-try-functions-list)
 	   (cons 'python-try-complete hippie-expand-try-functions-list)))
-  (unless font-lock-mode (font-lock-mode 1))
   (when python-guess-indent (python-guess-indent))
   (set (make-local-variable 'python-command) python-python-command)
   (unless (boundp 'python-mode-running)	; kill the recursion from jython-mode
--- a/lisp/progmodes/sh-script.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/progmodes/sh-script.el	Fri Apr 28 14:48:18 2006 +0000
@@ -356,6 +356,7 @@
 
 (defvar sh-shell (sh-canonicalize-shell (file-name-nondirectory sh-shell-file))
   "The shell being programmed.  This is set by \\[sh-set-shell].")
+;;;###autoload(put 'sh-shell 'safe-local-variable 'symbolp)
 
 (defvar sh-mode-abbrev-table nil)
 
--- a/lisp/startup.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/startup.el	Fri Apr 28 14:48:18 2006 +0000
@@ -1619,6 +1619,15 @@
   (when init-file-had-error
     (sit-for 2))
 
+  (when (and pure-space-overflow
+	     (not noninteractive))
+    (display-warning
+     'initialization
+     "Building Emacs overflowed pure space."
+     ;; FIXME: Tell the user what kind of problems are possible and how to fix
+     ;; the overflow.
+     :warning))
+
   (when command-line-args-left
     ;; We have command args; process them.
     (let ((dir command-line-default-directory)
--- a/lisp/subr.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/subr.el	Fri Apr 28 14:48:18 2006 +0000
@@ -851,19 +851,23 @@
   (nth 3 position))
 
 (defsubst posn-string (position)
-  "Return the string object of POSITION, or nil if a buffer position.
+  "Return the string object of POSITION.
+Value is a cons (STRING . STRING-POS), or nil if not a string.
 POSITION should be a list of the form returned by the `event-start'
 and `event-end' functions."
   (nth 4 position))
 
 (defsubst posn-image (position)
-  "Return the image object of POSITION, or nil if a not an image.
+  "Return the image object of POSITION.
+Value is an list (image ...), or nil if not an image.
 POSITION should be a list of the form returned by the `event-start'
 and `event-end' functions."
   (nth 7 position))
 
 (defsubst posn-object (position)
   "Return the object (image or string) of POSITION.
+Value is a list (image ...) for an image object, a cons cell
+\(STRING . STRING-POS) for a string object, and nil for a buffer position.
 POSITION should be a list of the form returned by the `event-start'
 and `event-end' functions."
   (or (posn-image position) (posn-string position)))
--- a/lisp/textmodes/bibtex.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/textmodes/bibtex.el	Fri Apr 28 14:48:18 2006 +0000
@@ -103,6 +103,7 @@
                                        (choice :tag "Init" :value ""
                                                string
                                                function))))))
+(put 'bibtex-user-optional-fields 'risky-local-variable t)
 
 (defcustom bibtex-entry-format
   '(opts-or-alts required-fields numerical-fields)
@@ -3303,7 +3304,7 @@
               (display (message "Key `%s' not found" key)))
         found)
 
-    (let* (case-fold-search
+    (let* ((case-fold-search t)
            (pnt (save-excursion
                   (goto-char (or start (point-min)))
                   (if (re-search-forward (concat "^[ \t]*\\("
@@ -4330,11 +4331,12 @@
             "\n")
     (goto-char endpos)))
 
-(defun bibtex-url (&optional pos)
+(defun bibtex-url (&optional pos no-browse)
   "Browse a URL for the BibTeX entry at point.
 Optional POS is the location of the BibTeX entry.
 The URL is generated using the schemes defined in `bibtex-generate-url-list'
-\(see there\).  Then the URL is passed to `browse-url'."
+\(see there\).  Then the URL is passed to `browse-url' unless NO-BROWSE is nil.
+Return the URL or nil if none can be generated."
   (interactive)
   (save-excursion
     (if pos (goto-char pos))
@@ -4369,8 +4371,10 @@
                           (error "Match failed: %s" field)))
                       (if fmt (apply 'format fmt (nreverse obj))
                         (apply 'concat (nreverse obj)))))
-          (browse-url (message "%s" url))))
-      (unless url (message "No URL known.")))))
+          (if (interactive-p) (message "%s" url))
+          (unless no-browse (browse-url url))))
+      (if (and (not url) (interactive-p)) (message "No URL known."))
+      url)))
 
 
 ;; Make BibTeX a Feature
--- a/lisp/textmodes/fill.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/textmodes/fill.el	Fri Apr 28 14:48:18 2006 +0000
@@ -48,7 +48,7 @@
   "*Non-nil means put two spaces after a colon when filling."
   :type 'boolean
   :group 'fill)
-;;;###autoload(put 'colon-double-space 'safe-local-variable t)
+;;;###autoload(put 'colon-double-space 'safe-local-variable 'symbolp)
 
 (defvar fill-paragraph-function nil
   "Mode-specific function to fill a paragraph, or nil if there is none.
--- a/lisp/textmodes/org.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/textmodes/org.el	Fri Apr 28 14:48:18 2006 +0000
@@ -5,7 +5,7 @@
 ;; Author: Carsten Dominik <dominik at science dot uva dot nl>
 ;; Keywords: outlines, hypermedia, calendar, wp
 ;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/
-;; Version: 4.24
+;; Version: 4.26
 ;;
 ;; This file is part of GNU Emacs.
 ;;
@@ -79,8 +79,17 @@
 ;; excellent reference card made by Philip Rooke.  This card can be found
 ;; in the etc/ directory of Emacs 22.
 ;;
-;; Changes since version 4.00:
+;; Changes since version 4.10:
 ;; ---------------------------
+;; Version 4.26
+;;    - Bug fixes.
+;;
+;; Version 4.25
+;;    - Revision of the font-lock faces section, with better tty support.
+;;    - TODO keywords in Agenda buffer are fontified.
+;;    - Export converts links between .org files to links between .html files.
+;;    - Better support for bold/italic/underline emphasis.
+;;
 ;; Version 4.24
 ;;    - Bug fixes.
 ;;
@@ -113,60 +122,6 @@
 ;;      `org-time-stamp-rounding-minutes'.
 ;;    - Bug fixes (there are *always* more bugs).
 ;;
-;; Version 4.10
-;;    - Bug fixes.
-;;
-;; Version 4.09
-;;    - Bug fixes.
-;;    - Small improvements to font-lock support.
-;;    - MHE support finalized.
-;;
-;; Version 4.08
-;;    - Bug fixes.
-;;    - Improved MHE support
-;;
-;; Version 4.07
-;;    - Bug fixes.
-;;    - Leading stars in headlines can be hidden, so make the outline look
-;;      cleaner.
-;;    - Mouse-1 can be used to follow links.
-;;
-;; Version 4.06
-;;    - HTML exporter treats targeted internal links.
-;;    - Bug fixes.
-;;
-;; Version 4.05
-;;    - Changes to internal link system (thanks to David Wainberg for ideas).
-;;      - in-file links: [[Search String]] instead of <file:::Search String>
-;;      - automatic links to "radio targets".
-;;      - CamelCase not longer active by default, configure org-activate-camels
-;;        if you want to turn it back on.
-;;      - After following a link, `C-c &' jumps back to it.
-;;    - MH-E link support (thanks to Thomas Baumann).
-;;    - Special table lines are no longer exported.
-;;    - Bug fixes and minor improvements.
-;;
-;; Version 4.04
-;;    - Cleanup tags display in agenda.
-;;    - Bug fixes.
-;;
-;; Version 4.03
-;;    - Table alignment fixed for use with wide characters.
-;;    - `C-c -' leaves cursor in current table line.
-;;    - The current TAG can be incorporated into the agenda prefix.
-;;      See option `org-agenda-prefix-format' for details.
-;;
-;; Version 4.02
-;;    - Minor bug fixes and improvements around tag searches.
-;;    - XEmacs compatibility fixes.
-;;
-;; Version 4.01
-;;    - Tags can also be set remotely from agenda buffer.
-;;    - Boolean logic for tag searches.
-;;    - Additional agenda commands can be configured through the variable
-;;      `org-agenda-custom-commands'.
-;;    - Minor bug fixes.
-;;
 ;;; Code:
 
 (eval-when-compile 
@@ -182,7 +137,7 @@
 
 ;;; Customization variables
 
-(defvar org-version "4.24"
+(defvar org-version "4.26"
   "The version number of the file org.el.")
 (defun org-version ()
   (interactive)
@@ -192,7 +147,7 @@
 ;; of outline.el.
 (defconst org-noutline-p (featurep 'noutline)
   "Are we using the new outline mode?")
-(defconst org-xemacs-p (featurep 'xemacs))
+(defconst org-xemacs-p (featurep 'xemacs)) ; not used by org.el itself
 (defconst org-format-transports-properties-p
   (let ((x "a"))
     (add-text-properties 0 1 '(test t) x)
@@ -1829,6 +1784,18 @@
   :group 'org-export-html
   :type 'string)
 
+(defcustom org-export-html-link-org-files-as-html t
+  "Non-nil means, make file links to `file.org' point to `file.html'.
+When org-mode is exporting an org-mode file to HTML, links to
+non-html files are directly put into a href tag in HTML.
+However, links to other Org-mode files (recognized by the
+extension `.org.) should become links to the corresponding html
+file, assuming that the linked org-mode file will also be
+converted to HTML.
+When nil, the links still point to the plain `.org' file."
+  :group 'org-export-html
+  :type 'boolean)
+
 (defcustom org-export-html-inline-images t
   "Non-nil means, inline images into exported HTML pages.
 The link will still be to the original location of the image file.
@@ -1942,205 +1909,246 @@
   :tag "Org Faces"
   :group 'org-font-lock)
 
+(defun org-compatible-face (specs)
+  "Make a compatible face specification.
+XEmacs and Emacs 21 do not know about the `min-colors' attribute.
+For them we convert a (min-colors 8) entry to a `tty' entry and move it
+to the top of the list.  The `min-colors' attribute will be removed from
+any other entries, and any resulting duplicates will be removed entirely."
+  (if (or (featurep 'xemacs) (< emacs-major-version 22))
+      (let (r e a)
+	(while (setq e (pop specs))
+	  (cond
+	   ((memq (car e) '(t default)) (push e r))
+	   ((setq a (member '(min-colors 8) (car e)))
+	    (nconc r (list (cons (cons '(type tty) (delq (car a) (car e)))
+				 (cdr e)))))
+	   ((setq a (assq 'min-colors (car e)))
+	    (setq e (cons (delq a (car e)) (cdr e)))
+	    (or (assoc (car e) r) (push e r)))
+	   (t (or (assoc (car e) r) (push e r)))))
+	(nreverse r))
+    specs))
+
 (defface org-hide
-  '(
-    (((type tty) (class color)) (:foreground "white"))
-    (((class color) (background light)) (:foreground "white"))
-    (((class color) (background dark)) (:foreground "black"))
-    (t (:inverse-video nil)))
-  "Face used for level 1 headlines."
+  '((((background light)) (:foreground "white"))
+    (((background dark)) (:foreground "black")))
+  "Face used to hide leading stars in headlines.
+The forground color of this face should be equal to the background
+color of the frame."
   :group 'org-faces)
 
 (defface org-level-1 ;; font-lock-function-name-face
-  '((((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)))
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Blue1"))
+     (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue"))
+     (((class color) (min-colors 16) (background light)) (:foreground "Blue"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue"))
+     (((class color) (min-colors 8)) (:foreground "blue" :bold t))
+     (t (:bold t))))
   "Face used for level 1 headlines."
   :group 'org-faces)
 
 (defface org-level-2 ;; font-lock-variable-name-face
-  '((((type tty) (class color)) (:foreground "yellow" :weight light))
-    (((class color) (background light)) (:foreground "DarkGoldenrod"))
-    (((class color) (background dark)) (:foreground "LightGoldenrod"))
-    (t (:bold t :italic t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod"))
+     (((class color) (min-colors 16) (background dark))  (:foreground "LightGoldenrod"))
+     (((class color) (min-colors 8)  (background light)) (:foreground "yellow"))
+     (((class color) (min-colors 8)  (background dark))  (:foreground "yellow" :bold t))
+     (t (:bold t))))
   "Face used for level 2 headlines."
   :group 'org-faces)
 
 (defface org-level-3 ;; font-lock-keyword-face
-  '((((type tty) (class color)) (:foreground "cyan" :weight bold))
-    (((class color) (background light)) (:foreground "Purple"))
-    (((class color) (background dark)) (:foreground "Cyan"))
-    (t (:bold t)))
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Purple"))
+     (((class color) (min-colors 88) (background dark))  (:foreground "Cyan1"))
+     (((class color) (min-colors 16) (background light)) (:foreground "Purple"))
+     (((class color) (min-colors 16) (background dark))  (:foreground "Cyan"))
+     (((class color) (min-colors 8)  (background light)) (:foreground "purple" :bold t))
+     (((class color) (min-colors 8)  (background dark))  (:foreground "cyan" :bold t))
+     (t (:bold t))))
   "Face used for level 3 headlines."
   :group 'org-faces)
 
 (defface org-level-4   ;; font-lock-comment-face
-  '((((type tty pc) (class color) (background light)) (:foreground "red"))
-    (((type tty pc) (class color) (background dark)) (:foreground "red1"))
-    (((class color) (background light)) (:foreground "Firebrick"))
-    (((class color) (background dark)) (:foreground "chocolate1"))
-    (t (:bold t :italic t)))
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick"))
+     (((class color) (min-colors 88) (background dark))  (:foreground "chocolate1"))
+     (((class color) (min-colors 16) (background light)) (:foreground "red"))
+     (((class color) (min-colors 16) (background dark))  (:foreground "red1"))
+     (((class color) (min-colors 8) (background light))  (:foreground "red" :bold t))
+     (((class color) (min-colors 8) (background dark))   (:foreground "red" :bold t))
+     (t (:bold t))))
   "Face used for level 4 headlines."
   :group 'org-faces)
 
 (defface org-level-5 ;; font-lock-type-face
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "ForestGreen"))
-    (((class color) (background dark)) (:foreground "PaleGreen"))
-    (t (:bold t :underline t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen"))
+     (((class color) (min-colors 8)) (:foreground "green"))))
   "Face used for level 5 headlines."
   :group 'org-faces)
 
 (defface org-level-6 ;; font-lock-constant-face
-  '((((type tty) (class color)) (:foreground "magenta"))
-    (((class color) (background light)) (:foreground "CadetBlue"))
-    (((class color) (background dark)) (:foreground "Aquamarine"))
-    (t (:bold t :underline t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "CadetBlue"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "Aquamarine"))
+     (((class color) (min-colors 8)) (:foreground "magenta"))))
   "Face used for level 6 headlines."
   :group 'org-faces)
 
 (defface org-level-7 ;; font-lock-builtin-face
-  '((((type tty) (class color)) (:foreground "blue" :weight light))
-    (((class color) (background light)) (:foreground "Orchid"))
-    (((class color) (background dark)) (:foreground "LightSteelBlue"))
-    (t (:bold t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "Orchid"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSteelBlue"))
+     (((class color) (min-colors 8)) (:foreground "blue"))))  ;; FIXME: for dark bg?
   "Face used for level 7 headlines."
   :group 'org-faces)
 
 (defface org-level-8 ;; font-lock-string-face
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "RosyBrown"))
-    (((class color) (background dark)) (:foreground "LightSalmon"))
-    (t (:italic t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon"))
+     (((class color) (min-colors 8)) (:foreground "green"))))
   "Face used for level 8 headlines."
   :group 'org-faces)
 
 (defface org-special-keyword ;; font-lock-string-face
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "RosyBrown"))
-    (((class color) (background dark)) (:foreground "LightSalmon"))
-    (t (:italic t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon"))
+     (t (:italic t))))
   "Face used for special keywords."
   :group 'org-faces)
 
 (defface org-warning ;; font-lock-warning-face
-  '((((type tty) (class color)) (:foreground "red"))
-    (((class color) (background light)) (:foreground "Red" :bold t))
-    (((class color) (background dark)) (:foreground "Red1" :bold t))
-;    (((class color) (background dark)) (:foreground "Pink" :bold t))
-    (t (:inverse-video t :bold t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t))
+     (((class color) (min-colors 16) (background dark))  (:foreground "Pink" :bold t))
+     (((class color) (min-colors 8)  (background light)) (:foreground "red"  :bold t))
+     (((class color) (min-colors 8)  (background dark))  (:foreground "red"  :bold t))
+     (t (:bold t))))
   "Face for deadlines and TODO keywords."
   :group 'org-faces)
 
 (defface org-headline-done ;; font-lock-string-face
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "RosyBrown"))
-    (((class color) (background dark)) (:foreground "LightSalmon"))
-    (t (:italic t)))
-  "Face used to indicate that a headline is DONE.  See also the variable
-`org-fontify-done-headline'."
-  :group 'org-faces)
-
-;; Inheritance does not work for xemacs. So we just copy...
-
-(defface org-deadline-announce
-  '((((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 for upcoming deadlines."
-  :group 'org-faces)
-
-(defface org-scheduled-today
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "DarkGreen"))
-    (((class color) (background dark)) (:foreground "PaleGreen"))
-    (t (:bold t :underline t)))
-  "Face for items scheduled for a certain day."
-  :group 'org-faces)
-
-(defface org-scheduled-previously
-  '((((type tty pc) (class color) (background light)) (:foreground "red"))
-    (((type tty pc) (class color) (background dark)) (:foreground "red1"))
-    (((class color) (background light)) (:foreground "Firebrick"))
-    (((class color) (background dark)) (:foreground "chocolate1"))
-    (t (:bold t :italic t)))
-  "Face for items scheduled previously, and not yet done."
-  :group 'org-faces)
-
-(defface org-formula
-  '((((type tty pc) (class color) (background light)) (:foreground "red"))
-    (((type tty pc) (class color) (background dark)) (:foreground "red1"))
-    (((class color) (background light)) (:foreground "Firebrick"))
-    (((class color) (background dark)) (:foreground "chocolate1"))
-    (t (:bold t :italic t)))
-  "Face for formulas."
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon"))
+     (((class color) (min-colors 8)  (background light)) (:bold nil))))
+  "Face used to indicate that a headline is DONE.
+This face is only used if `org-fontify-done-headline' is set."
   :group 'org-faces)
 
 (defface org-link
-  '((((type tty) (class color)) (:foreground "cyan" :weight bold))
-    (((class color) (background light)) (:foreground "Purple" :underline t))
+  '((((class color) (background light)) (:foreground "Purple" :underline t))
     (((class color) (background dark)) (:foreground "Cyan" :underline t))
-    (t (:bold t)))
+    (t (:underline t)))
   "Face for links."
   :group 'org-faces)
 
 (defface org-date
-  '((((type tty) (class color)) (:foreground "cyan" :weight bold))
-    (((class color) (background light)) (:foreground "Purple" :underline t))
+  '((((class color) (background light)) (:foreground "Purple" :underline t))
     (((class color) (background dark)) (:foreground "Cyan" :underline t))
-    (t (:bold t)))
+    (t (:underline t)))
   "Face for links."
   :group 'org-faces)
 
 (defface org-tag
-  '((((type tty) (class color)) (:weight bold))
-    (((class color) (background light)) (:weight bold))
-    (((class color) (background dark)) (:weight bold))
-    (t (:bold t)))
+  '((t (:bold t)))
   "Face for tags."
   :group 'org-faces)
 
 (defface org-todo ;; font-lock-warning-face
-  '((((type tty) (class color)) (:foreground "red"))
-    (((class color) (background light)) (:foreground "Red" :bold t))
-    (((class color) (background dark)) (:foreground "Red1" :bold t))
-;    (((class color) (background dark)) (:foreground "Pink" :bold t))
-    (t (:inverse-video t :bold t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t))
+     (((class color) (min-colors 16) (background dark))  (:foreground "Pink" :bold t))
+     (((class color) (min-colors 8)  (background light)) (:foreground "red"  :bold t))
+     (((class color) (min-colors 8)  (background dark))  (:foreground "red"  :bold t))
+     (t (:inverse-video t :bold t))))
   "Face for TODO keywords."
   :group 'org-faces)
 
 (defface org-done ;; font-lock-type-face
-  '((((type tty) (class color)) (:foreground "green"))
-    (((class color) (background light)) (:foreground "ForestGreen" :bold t))
-    (((class color) (background dark)) (:foreground "PaleGreen" :bold t))
-    (t (:bold t :underline t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen"))
+     (((class color) (min-colors 8)) (:foreground "green"))
+     (t (:bold t))))
   "Face used for DONE."
   :group 'org-faces)
 
 (defface org-table ;; font-lock-function-name-face
-  '((((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)))
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Blue1"))
+     (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue"))
+     (((class color) (min-colors 16) (background light)) (:foreground "Blue"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue"))
+     (((class color) (min-colors 8)  (background light)) (:foreground "blue"))
+     (((class color) (min-colors 8)  (background dark)))))
   "Face used for tables."
   :group 'org-faces)
 
+(defface org-formula
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick"))
+     (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1"))
+     (((class color) (min-colors 8)  (background light)) (:foreground "red"))
+     (((class color) (min-colors 8)  (background dark)) (:foreground "red"))
+     (t (:bold t :italic t))))
+  "Face for formulas."
+  :group 'org-faces)
+
+(defface org-scheduled-today
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "DarkGreen"))
+     (((class color) (min-colors 88) (background dark)) (:foreground "PaleGreen"))
+     (((class color) (min-colors 8)) (:foreground "green"))
+     (t (:bold t :italic t))))
+  "Face for items scheduled for a certain day."
+  :group 'org-faces)
+
+(defface org-scheduled-previously
+  (org-compatible-face
+   '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick"))
+     (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1"))
+     (((class color) (min-colors 8)  (background light)) (:foreground "red"))
+     (((class color) (min-colors 8)  (background dark)) (:foreground "red" :bold t))
+     (t (:bold t))))
+  "Face for items scheduled previously, and not yet done."
+  :group 'org-faces)
+
 (defface org-time-grid ;; font-lock-variable-name-face
-  '((((type tty) (class color)) (:foreground "yellow" :weight light))
-    (((class color) (background light)) (:foreground "DarkGoldenrod"))
-    (((class color) (background dark)) (:foreground "LightGoldenrod"))
-    (t (:bold t :italic t)))
+  (org-compatible-face
+   '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod"))
+     (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod"))
+     (((class color) (min-colors 8)) (:foreground "yellow" :weight light)))) ; FIXME: turn off???
   "Face used for time grids."
   :group 'org-faces)
 
-(defvar org-level-faces
+(defconst org-level-faces
   '(org-level-1 org-level-2 org-level-3 org-level-4
     org-level-5 org-level-6 org-level-7 org-level-8
     ))
-(defvar org-n-levels (length org-level-faces))
-
+(defconst org-n-levels (length org-level-faces))
+
+(defconst org-bold-re
+  (if (featurep 'xemacs)
+      "\\([ ]\\|^\\)\\(\\*\\(\\w[a-zA-Z0-9-_ ]*?\\w\\)\\*\\)\\([ ,.]\\|$\\)"
+    "\\([ ]\\|^\\)\\(\\*\\(\\w[[:word:] -_]*?\\w\\)\\*\\)\\([ ,.]\\|$\\)")
+  "Regular expression for bold emphasis.")
+(defconst org-italic-re
+  (if (featurep 'xemacs)
+      "\\([ ]\\|^\\)\\(/\\(\\w[a-zA-Z0-9-_ ]*?\\w\\)/\\)\\([ ,.]\\|$\\)"
+    "\\([ ]\\|^\\)\\(/\\(\\w[[:word:] -_]*?\\w\\)/\\)\\([ ,.]\\|$\\)")
+  "Regular expression for italic emphasis.")
+(defconst org-underline-re
+  (if (featurep 'xemacs)
+      "\\([ ]\\|^\\)\\(_\\(\\w[a-zA-Z0-9-_ ]*?\\w\\)_\\)\\([ ,.]\\|$\\)"
+    "\\([ ]\\|^\\)\\(_\\(\\w[[:word:] -_]*?\\w\\)_\\)\\([ ,.]\\|$\\)")
+  "Regular expression for underline emphasis.")
 
 ;; Variables for pre-computed regular expressions, all buffer local
 (defvar org-done-string nil
@@ -2324,7 +2332,10 @@
 (defvar orgtbl-mode) ; defined later in this file
 ;;; Define the mode
 
-(defvar org-mode-map (copy-keymap outline-mode-map)
+(defvar org-mode-map 
+  (if (and (not (keymapp outline-mode-map)) (featurep 'allout))
+      (error "Conflict with outdated version of allout.el.  Load org.el before allout.el, or ugrade to newer allout, for example by switching to Emacs 22.")
+    (copy-keymap outline-mode-map))
   "Keymap for Org-mode.")
 
 (defvar org-struct-menu) ; defined later in this file
@@ -2728,9 +2739,12 @@
 	   (list (concat "\\<" org-deadline-string) '(0 'org-special-keyword t))
 	   (list (concat "\\<" org-scheduled-string) '(0 'org-special-keyword t))
 	   (list (concat "\\<" org-closed-string) '(0 'org-special-keyword t))
-	   (if em '("\\(\\W\\|^\\)\\(\\*\\w+\\*\\)\\(\\W\\|$\\)" 2 'bold prepend))
-	   (if em '("\\(\\W\\|^\\)\\(/\\w+/\\)\\(\\W\\|$\\)"     2 'italic prepend))
-	   (if em '("\\(\\W\\|^\\)\\(_\\w+_\\)\\(\\W\\|$\\)"     2 'underline prepend))
+;	   (if em '("\\(\\W\\|^\\)\\(\\*\\w+\\*\\)\\(\\W\\|$\\)" 2 'bold prepend))
+;	   (if em '("\\(\\W\\|^\\)\\(/\\w+/\\)\\(\\W\\|$\\)"     2 'italic prepend))
+;	   (if em '("\\(\\W\\|^\\)\\(_\\w+_\\)\\(\\W\\|$\\)"     2 'underline prepend))
+	   (if em (list org-bold-re 2 ''bold 'prepend))
+	   (if em (list org-italic-re 2 ''italic 'prepend))
+	   (if em (list org-underline-re 2 ''underline 'prepend))
 	   (list (concat "^\\*+[ \t]*\\<\\(" org-comment-string
 			 "\\|" org-quote-string "\\)\\>")
 		 '(1 'org-special-keyword t))
@@ -3109,13 +3123,14 @@
 		     (error (outline-next-heading)))
 		   (prog1 (match-string 0)
 		     (funcall outline-level)))))
-      (if (and (bolp) 
-	       (save-excursion (backward-char 1) (not (org-invisible-p))))
-	  (open-line 1)
-	(newline))
+      (cond 
+       ((and (org-on-heading-p) (bolp) 
+	     (save-excursion (backward-char 1) (not (org-invisible-p))))
+	(open-line 1))
+       ((bolp) nil)
+       (t (newline)))
       (insert head)
-      (if (looking-at "[ \t]*")
-	  (replace-match " "))
+      (just-one-space)
       (run-hooks 'org-insert-heading-hook))))
 
 (defun org-insert-item ()
@@ -3128,8 +3143,20 @@
 		(org-at-item-p)
 		t)
 	    (error nil)))
-    (unless (bolp) (newline))
-    (insert (match-string 0))
+    (let* ((bul (match-string 0))
+	   (eow (save-excursion (beginning-of-line 1) (looking-at "[ \t]*")
+				(match-end 0)))
+	   (eowcol (save-excursion (goto-char eow) (current-column))))
+      (cond
+       ((and (org-at-item-p) (<= (point) eow))
+	;; before the bullet
+	(beginning-of-line 1)
+	(open-line 1))
+       ((<= (point) eow)
+	(beginning-of-line 1))
+       (t (newline)))
+      (insert bul)
+      (just-one-space))
     (org-maybe-renumber-ordered-list)
     t))
 
@@ -5335,7 +5362,8 @@
 	 (completion-ignore-case t)
 	 (org-select-this-todo-keyword
 	  (if (stringp arg) arg
-	    (and arg (integerp arg) (nth (1- arg) org-todo-keywords))))
+	    (and arg (integerp arg) (> arg 0)
+                 (nth (1- arg) org-todo-keywords))))
 	 rtn rtnall files file pos)
     (when (equal arg '(4))
       (setq org-select-this-todo-keyword
@@ -5935,6 +5963,7 @@
   "Return the TODO information for agenda display."
   (let* ((props (list 'face nil
 		      'done-face 'org-done
+		      'org-not-done-regexp org-not-done-regexp
 		      'mouse-face 'highlight
 		      'keymap org-agenda-keymap
 		      'help-echo
@@ -5975,6 +6004,7 @@
 (defun org-agenda-get-timestamps ()
   "Return the date stamp information for agenda display."
   (let* ((props (list 'face nil
+		      'org-not-done-regexp org-not-done-regexp
 		      'mouse-face 'highlight
 		      'keymap org-agenda-keymap
 		      'help-echo
@@ -6040,6 +6070,7 @@
 (defun org-agenda-get-closed ()
   "Return the logged TODO entries for agenda display."
   (let* ((props (list 'mouse-face 'highlight
+		      'org-not-done-regexp org-not-done-regexp
 		      'keymap org-agenda-keymap
 		      'help-echo
 		      (format "mouse-2 or RET jump to org file %s"
@@ -6091,6 +6122,7 @@
   "Return the deadline information for agenda display."
   (let* ((wdays org-deadline-warning-days)
 	 (props (list 'mouse-face 'highlight
+		      'org-not-done-regexp org-not-done-regexp
 		      'keymap org-agenda-keymap
 		      'help-echo
 		      (format "mouse-2 or RET jump to org file %s"
@@ -6146,6 +6178,7 @@
 (defun org-agenda-get-scheduled ()
   "Return the scheduled information for agenda display."
   (let* ((props (list 'face 'org-scheduled-previously
+		      'org-not-done-regexp org-not-done-regexp
 		      'undone-face 'org-scheduled-previously
 		      'done-face 'org-done
 		      'mouse-face 'highlight
@@ -6195,6 +6228,7 @@
 (defun org-agenda-get-blocks ()
   "Return the date-range information for agenda display."
   (let* ((props (list 'face nil
+		      'org-not-done-regexp org-not-done-regexp
 		      'mouse-face 'highlight
 		      'keymap org-agenda-keymap
 		      'help-echo
@@ -6430,8 +6464,25 @@
 
 (defun org-finalize-agenda-entries (list)
   "Sort and concatenate the agenda items."
+  (setq list (mapcar 'org-agenda-highlight-todo list))
   (mapconcat 'identity (sort list 'org-entries-lessp) "\n"))
 
+(defun org-agenda-highlight-todo (x)
+  (let (re)
+    (if (eq x 'line)
+	(save-excursion
+	  (beginning-of-line 1)
+	  (setq re (get-text-property (point) 'org-not-done-regexp))
+	  (goto-char (+ (point) (get-text-property (point) 'prefix-length)))
+	  (and (looking-at (concat "[ \t]*" re))
+	       (add-text-properties (match-beginning 0) (match-end 0)
+				    '(face org-todo))))
+      (setq re (get-text-property 0 'org-not-done-regexp x))
+      (and re (string-match re x)
+	   (add-text-properties (match-beginning 0) (match-end 0)
+				'(face org-todo) x))
+      x)))
+
 (defsubst org-cmp-priority (a b)
   "Compare the priorities of string A and B."
   (let ((pa (or (get-text-property 1 'priority a) 0))
@@ -6582,7 +6633,7 @@
 	(and (outline-next-heading)
 	     (org-flag-heading nil)))   ; show the next heading
       (org-todo arg)
-      (forward-char 1)
+      (and (bolp) (forward-char 1))
       (setq newhead (org-get-heading))
       (save-excursion
 	(org-back-to-heading)
@@ -6622,12 +6673,13 @@
 		(replace-match new t t)
 		(beginning-of-line 1)
 		(add-text-properties (point-at-bol) (point-at-eol) props)
-		(if fixface
-		    (add-text-properties
-		     (point-at-bol) (point-at-eol)
-		     (list 'face
-			   (if org-last-todo-state-is-todo
-			       undone-face done-face))))
+		(when fixface
+		  (add-text-properties
+		   (point-at-bol) (point-at-eol)
+		   (list 'face
+			 (if org-last-todo-state-is-todo
+			     undone-face done-face)))
+		  (org-agenda-highlight-todo 'line))
 		(beginning-of-line 1))
 	    (error "Line update did not work")))
 	(beginning-of-line 0)))))
@@ -7348,9 +7400,8 @@
 				   (org-add-props cmd nil
 				     'face 'org-warning))))
 	      (progn
-		(message "Executing %s..." cmd)
-		(shell-command cmd)
-		(message "Executing %s...done" cmd))
+		(message "Executing %s" cmd)
+		(shell-command cmd))
 	    (error "Abort"))))
 
        (t
@@ -7804,7 +7855,10 @@
 	  (setq cmd 'emacs))))
     (cond
      ((and (stringp cmd) (not (string-match "^\\s-*$" cmd)))
-      (setq cmd (format cmd (concat "\"" file "\"")))
+      ;; Normalize use of quote, this can vary.
+      (if (string-match "['\"]%s['\"]" cmd)
+	  (setq cmd (replace-match "'%s'" t t cmd)))
+      (setq cmd (format cmd file))
       (save-window-excursion
 	(shell-command (concat cmd " &"))))
      ((or (stringp cmd)
@@ -8198,12 +8252,16 @@
      (complete-file
       ;; Completing read for file names.
       (setq file (read-file-name "File: "))
-      (let ((pwd (file-name-as-directory (expand-file-name "."))))
+      (let ((pwd (file-name-as-directory (expand-file-name ".")))
+	    (pwd1 (file-name-as-directory (abbreviate-file-name
+					   (expand-file-name ".")))))
 	(cond
 	 ((equal complete-file '(16))
 	  (setq link (org-make-link
 		      "file:"
 		      (abbreviate-file-name (expand-file-name file)))))
+	 ((string-match (concat "^" (regexp-quote pwd1) "\\(.+\\)") file)
+	  (setq link  (org-make-link "file:" (match-string 1 file))))
 	 ((string-match (concat "^" (regexp-quote pwd) "\\(.+\\)")
 			(expand-file-name file))
 	  (setq link  (org-make-link
@@ -8850,10 +8908,10 @@
 		    e (not (= (match-beginning 2) (match-end 2))))
 	      (setq f (format (if num " %%%ds %s" " %%-%ds %s")
 			      l (if e "|" (setq org-table-may-need-update t) ""))
-		    n (format f s t t))
+		    n (format f s))
 	      (if new
-		  (if (<= (length new) l)
-		      (setq n (format f new t t))  ;; FIXME: why t t?????
+		  (if (<= (length new) l)      ;; FIXME: length -> str-width?
+		      (setq n (format f new t t))  ;; FIXME: t t?
 		    (setq n (concat new "|") org-table-may-need-update t)))
 	      (or (equal n o)
 		  (let (org-table-may-need-update)
@@ -11796,14 +11854,27 @@
 	      ;; FILE link
 	      (let* ((filename path)
 		     (abs-p (file-name-absolute-p filename))
-		     (thefile (if abs-p (expand-file-name filename) filename))
-		     (thefile (save-match-data
-				(if (string-match ":[0-9]+$" thefile)
-				    (replace-match "" t t thefile)
-				  thefile)))
-		     (file-is-image-p
-		      (save-match-data
-			(string-match (org-image-file-name-regexp) thefile))))
+		     thefile file-is-image-p search)
+		(save-match-data
+		  (if (string-match "::\\(.*\\)" filename)
+		      (setq search (match-string 1 filename)
+			    filename (replace-match "" nil nil filename)))
+		  (setq file-is-image-p 
+			(string-match (org-image-file-name-regexp) filename))
+		  (setq thefile (if abs-p (expand-file-name filename) filename))
+		  (when (and org-export-html-link-org-files-as-html
+			     (string-match "\\.org$" thefile))
+		    (setq thefile (concat (substring thefile 0
+						     (match-beginning 0))
+					  ".html"))
+		    (if (and search
+			     ;; make sure this is can be used as target search
+			     (not (string-match "^[0-9]*$" search))
+			     (not (string-match "^\\*" search))
+			     (not (string-match "^/.*/$" search)))
+			(setq thefile (concat thefile "#" 
+					      (org-solidify-link-text
+					       (org-link-unescape search)))))))
 		(setq rpl (if (and org-export-html-inline-images
 				   file-is-image-p)
 			      (concat "<img src=\"" thefile "\"/>")
@@ -12157,14 +12228,13 @@
   string)
 
 (defun org-export-html-convert-emphasize (string)
-  (let (c (s 0))
-    (while (string-match "\\(\\W\\|^\\)\\([*/_]\\)\\(\\w+\\)\\2\\(\\W\\|$\\)" string s)
-      (setq c (cdr (assoc (match-string 2 string)
-			  '(("*" . "b") ("/" . "i") ("_" . "u"))))
-	    s (+ (match-end 0) 3)
-	    string (replace-match
-		    (concat "\\1<" c ">\\3</" c ">\\4") t nil string)))
-    string))
+  (while (string-match org-italic-re string)
+    (setq string (replace-match "\\1<i>\\3</i>\\4" t nil string)))
+  (while (string-match org-bold-re string)
+    (setq string (replace-match "\\1<b>\\3</b>\\4" t nil string)))
+  (while (string-match org-underline-re string)
+    (setq string (replace-match "\\1<u>\\3</u>\\4" t nil string)))
+  string)
 
 (defun org-parse-key-lines ()
   "Find the special key lines with the information for exporters."
@@ -12366,7 +12436,7 @@
 
       ;; Finish the buffer off and clean it up.
       (switch-to-buffer-other-window out)
-      (indent-region (point-min) (point-max))
+      (indent-region (point-min) (point-max) nil)
       (save-buffer)
       (goto-char (point-min))
       )))
@@ -12589,6 +12659,8 @@
 (define-key org-mode-map [?\C-c ?\C-x (right)] 'org-shiftright)
 
 ;; All the other keys
+
+(define-key org-mode-map "\C-c\C-a" 'show-all)  ; in case allout messed up.
 (define-key org-mode-map "\C-c$"    'org-archive-subtree)
 (define-key org-mode-map "\C-c\C-j" 'org-goto)
 (define-key org-mode-map "\C-c\C-t" 'org-todo)
--- a/lisp/textmodes/paragraphs.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/textmodes/paragraphs.el	Fri Apr 28 14:48:18 2006 +0000
@@ -128,7 +128,7 @@
 `sentence-end' is nil.  See Info node `(elisp)Standard Regexps'."
   :type 'boolean
   :group 'fill)
-;;;###autoload(put 'sentence-end-double-space 'safe-local-variable t)
+;;;###autoload(put 'sentence-end-double-space 'safe-local-variable 'symbolp)
 
 (defcustom sentence-end-without-period nil
   "*Non-nil means a sentence will end without a period.
@@ -140,7 +140,7 @@
 `sentence-end' is nil.  See Info node `(elisp)Standard Regexps'."
   :type 'boolean
   :group 'fill)
-;;;###autoload(put 'sentence-end-without-period 'safe-local-variable t)
+;;;###autoload(put 'sentence-end-without-period 'safe-local-variable 'symbolp)
 
 (defcustom sentence-end-without-space
   "$B!#!%!)!*$A!##.#?#!$(0!$!%!)!*$(G!$!%!)!*(B"
@@ -151,7 +151,7 @@
 `sentence-end' is nil.  See Info node `(elisp)Standard Regexps'."
   :group 'paragraphs
   :type 'string)
-;;;###autoload(put 'sentence-end-without-space 'safe-local-variable t)
+;;;###autoload(put 'sentence-end-without-space 'safe-local-variable 'symbolp)
 
 (defcustom sentence-end nil
   "*Regexp describing the end of a sentence.
@@ -198,14 +198,14 @@
   "*Regexp describing line-beginnings that separate pages."
   :group 'paragraphs
   :type 'regexp)
-;;;###autoload(put 'page-delimiter 'safe-local-variable t)
+;;;###autoload(put 'page-delimiter 'safe-local-variable 'stringp)
 
 (defcustom paragraph-ignore-fill-prefix nil
   "*Non-nil means the paragraph commands are not affected by `fill-prefix'.
 This is desirable in modes where blank lines are the paragraph delimiters."
   :group 'paragraphs
   :type 'boolean)
-;;;###autoload(put 'paragraph-ignore-fill-prefix 'safe-local-variable t)
+;;;###autoload(put 'paragraph-ignore-fill-prefix 'safe-local-variable 'symbolp)
 
 (defun forward-paragraph (&optional arg)
   "Move forward to end of paragraph.
--- a/lisp/textmodes/reftex-vars.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/textmodes/reftex-vars.el	Fri Apr 28 14:48:18 2006 +0000
@@ -948,7 +948,7 @@
 the label types for which it should be true."
   :group  'reftex-referencing-labels
   :type `(choice :tag "\\vref is default macro" ,@reftex-tmp))
-;;;###autoload(put 'reftex-vref-is-default 'safe-local-variable t)
+;;;###autoload(put 'reftex-vref-is-default 'safe-local-variable (lambda (x) (or (stringp x) (symbolp x))))
 
 (defcustom reftex-fref-is-default nil
   "*Non-nil means, the fancyref macro \\fref is used as default.
@@ -959,7 +959,7 @@
 the label types for which it should be true."
   :group  'reftex-referencing-labels
   :type `(choice :tag "\\fref is default macro" ,@reftex-tmp))
-;;;###autoload(put 'reftex-fref-is-default 'safe-local-variable t)
+;;;###autoload(put 'reftex-fref-is-default 'safe-local-variable (lambda (x) (or (stringp x) (symbolp x))))
 
 (defcustom reftex-level-indent 2
   "*Number of spaces to be used for indentation per section level."
@@ -975,7 +975,7 @@
 a label type.  If you set this variable to nil, RefTeX will always prompt."
   :group 'reftex-referencing-labels
   :type 'boolean)
-;;;###autoload(put 'reftex-guess-label-type 'safe-local-variable t)
+;;;###autoload(put 'reftex-guess-label-type 'safe-local-variable 'symbolp)
 
 (defcustom reftex-format-ref-function nil
   "Function which produces the string to insert as a reference.
--- a/lisp/time-stamp.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/time-stamp.el	Fri Apr 28 14:48:18 2006 +0000
@@ -164,7 +164,7 @@
 incompatible with other people's files!  If you must change them for some
 application, do so in the local variables section of the time-stamped file
 itself.")
-;;;###autoload(put 'time-stamp-start 'safe-local-variable t)
+;;;###autoload(put 'time-stamp-start 'safe-local-variable 'stringp)
 
 (defvar time-stamp-end "\\\\?[\">]"    ;Do not change!
   "Regexp marking the text after the time stamp.
@@ -184,7 +184,7 @@
 or `time-stamp-inserts-lines' for yourself or you will be incompatible
 with other people's files!  If you must change them for some application,
 do so in the local variables section of the time-stamped file itself.")
-;;;###autoload(put 'time-stamp-end 'safe-local-variable t)
+;;;###autoload(put 'time-stamp-end 'safe-local-variable 'stringp)
 
 
 (defvar time-stamp-inserts-lines nil    ;Do not change!
@@ -201,7 +201,7 @@
 yourself or you will be incompatible with other people's files!
 If you must change them for some application, do so in the local
 variables section of the time-stamped file itself.")
-;;;###autoload(put 'time-stamp-inserts-lines 'safe-local-variable t)
+;;;###autoload(put 'time-stamp-inserts-lines 'safe-local-variable 'symbolp)
 
 
 (defvar time-stamp-count 1		;Do not change!
--- a/lisp/url/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/url/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,11 @@
+2006-04-26  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* url-gw.el (url-open-stream): Don't hide errors.
+	(url-gateway-nslookup-host, url-open-telnet): Use with-current-buffer.
+
+	* url-handlers.el (url-insert): New function.
+	(url-insert-file-contents): Use it.
+
 2006-03-29  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	* url-handlers.el (url-handler-directory-file-name): New handler.
--- a/lisp/url/url-gw.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/url/url-gw.el	Fri Apr 28 14:48:18 2006 +0000
@@ -118,8 +118,7 @@
 				 url-gateway-nslookup-program host))
 	    (res host))
 	(set-process-query-on-exit-flag proc nil)
-	(save-excursion
-	  (set-buffer (process-buffer proc))
+	(with-current-buffer (process-buffer proc)
 	  (while (memq (process-status proc) '(run open))
 	    (accept-process-output proc))
 	  (goto-char (point-min))
@@ -168,8 +167,7 @@
 (defun url-open-telnet (name buffer host service)
   (if (not (stringp service))
       (setq service (int-to-string service)))
-  (save-excursion
-    (set-buffer (get-buffer-create buffer))
+  (with-current-buffer (get-buffer-create buffer)
     (erase-buffer)
     (let ((proc (start-process name buffer "telnet" "-8"))
 	  (case-fold-search t))
@@ -261,11 +259,15 @@
 			 (otherwise
 			  (error "Bad setting of url-gateway-method: %s"
 				 url-gateway-method)))))
-	(error
-	 (setq conn nil)))
+        ;; Ignoring errors here seems wrong.  E.g. it'll throw away the
+        ;; error signalled two lines above.  It was also found inconvenient
+        ;; during debugging.
+	;; (error
+	;;  (setq conn nil))
+	)
       conn)))
 
 (provide 'url-gw)
 
-;;; arch-tag: 1c4c0317-6d03-45b8-b3f3-838bd8f9d838
+;; arch-tag: 1c4c0317-6d03-45b8-b3f3-838bd8f9d838
 ;;; url-gw.el ends here
--- a/lisp/url/url-handlers.el	Thu Apr 20 16:09:11 2006 +0000
+++ b/lisp/url/url-handlers.el	Fri Apr 28 14:48:18 2006 +0000
@@ -216,33 +216,47 @@
     (url-copy-file url filename)
     filename))
 
+(defun url-insert (buffer &optional beg end)
+  "Insert the body of a URL object.
+BUFFER should be a complete URL buffer as returned by `url-retrieve'.
+If the headers specify a coding-system, it is applied to the body before it is inserted.
+Returns a list of the form (SIZE CHARSET), where SIZE is the size in bytes
+of the inserted text and CHARSET is the charset that was specified in the header,
+or nil if none was found.
+BEG and END can be used to only insert a subpart of the body.
+They count bytes from the beginning of the body."
+  (let* ((handle (with-current-buffer buffer (mm-dissect-buffer t)))
+         (data (with-current-buffer (mm-handle-buffer handle)
+                 (if beg
+                     (buffer-substring (+ (point-min) beg)
+                                       (if end (+ (point-min) end) (point-max)))
+		   (buffer-string))))
+         (charset (mail-content-type-get (mm-handle-type handle)
+                                          'charset)))
+    (mm-destroy-parts handle)
+    (if charset
+        (insert (mm-decode-string data (mm-charset-to-coding-system charset)))
+      (insert data))
+    (list (length data) charset)))
+
 ;;;###autoload
 (defun url-insert-file-contents (url &optional visit beg end replace)
-  (let ((buffer (url-retrieve-synchronously url))
-	(handle nil)
-	(charset nil)
-	(data nil))
+  (let ((buffer (url-retrieve-synchronously url)))
     (if (not buffer)
 	(error "Opening input file: No such file or directory, %s" url))
     (if visit (setq buffer-file-name url))
-    (with-current-buffer buffer
-      (setq handle (mm-dissect-buffer t))
-      (set-buffer (mm-handle-buffer handle))
-      (setq data (if beg (buffer-substring beg end)
-		   (buffer-string))))
-    (kill-buffer buffer)
-    (mm-destroy-parts handle)
-    (if replace (delete-region (point-min) (point-max)))
     (save-excursion
-      (setq charset (mail-content-type-get (mm-handle-type handle)
-					     'charset))
-      (let ((start (point)))
-	(if charset
-	    (insert (mm-decode-string data (mm-charset-to-coding-system charset)))
-	  (progn
-	    (insert data)
-	    (decode-coding-inserted-region start (point) url visit beg end replace)))))
-    (list url (length data))))
+      (let* ((start (point))
+             (size-and-charset (url-insert buffer beg end)))
+        (kill-buffer buffer)
+        (when replace
+          (delete-region (point-min) start)
+          (delete-region (point) (point-max)))
+        (unless (cadr size-and-charset)
+          ;; If the headers don't specify any particular charset, use the
+          ;; usual heuristic/rules that we apply to files.
+          (decode-coding-inserted-region start (point) url visit beg end replace))
+        (list url (car size-and-charset))))))
 
 (defun url-file-name-completion (url directory)
   (error "Unimplemented"))
--- a/lispref/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/lispref/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,3 +1,7 @@
+2006-04-26  Richard Stallman  <rms@gnu.org>
+
+	* syntax.texi (Parsing Expressions): Minor cleanup.
+
 2006-04-18  Richard Stallman  <rms@gnu.org>
 
 	* tips.texi (Coding Conventions): Explain when the package's
--- a/lispref/modes.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/lispref/modes.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -2336,8 +2336,6 @@
 * Font Lock Basics::            Overview of customizing Font Lock.
 * Search-based Fontification::  Fontification based on regexps.
 * Customizing Keywords::        Customizing search-based fontification.
-* Region to Fontify::           Controlling which region gets refontified
-                                  after a buffer change.
 * Other Font Lock Variables::   Additional customization facilities.
 * Levels of Font Lock::         Each mode can define alternative levels
                                   so that the user can select more or less.
@@ -2347,6 +2345,8 @@
 * Syntactic Font Lock::         Fontification based on syntax tables.
 * Setting Syntax Properties::   Defining character syntax based on context
                                   using the Font Lock mechanism.
+* Multi line Font Lock Elements:: How to coerce Font Lock into properly
+                                  highlighting multiline elements.
 @end menu
 
 @node Font Lock Basics
@@ -2623,16 +2623,9 @@
 Its value should have one of the forms described in this table.
 @end table
 
-@vindex font-lock-multiline
 @strong{Warning:} Do not design an element of @code{font-lock-keywords}
-to match text which spans lines; this does not work reliably.  While
-@code{font-lock-fontify-buffer} handles multi-line patterns correctly,
-updating when you edit the buffer does not, since it considers text one
-line at a time.  If you have patterns that typically only span one
-line but can occasionally span two or three, such as
-@samp{<title>...</title>}, you can ask Font Lock to be more careful by
-setting @code{font-lock-multiline} to @code{t}.  But it still will not
-work in all cases.
+to match text which spans lines; this does not work reliably.
+For details, see @xref{Multi line Font Lock Elements}.
 
 You can use @var{case-fold} in @code{font-lock-defaults} to specify
 the value of @code{font-lock-keywords-case-fold-search} which says
@@ -2718,36 +2711,6 @@
       font-lock-keyword-face)))))
 @end smallexample
 
-@node Region to Fontify
-@subsection Region to Fontify after a Buffer Change
-
-  When a buffer is changed, the region that Font Lock refontifies is by
-default the smallest sequence of whole lines that spans the change.
-While this works well most of the time, sometimes it doesn't---for
-example, when a buffer change has changed the syntactic meaning of text
-on an earlier line.
-
-You can enlarge (or even reduce) the region to fontify by setting either
-of the following variables:
-
-@defvar font-lock-extend-region-function
-This buffer-local variable is either @code{nil} or is a function that
-determines the region to fontify, which Emacs then calls after each
-buffer change.
-
-The function is given three parameters, the standard @var{beg},
-@var{end}, and @var{old-len} from after-change-functions (@pxref{Change
-Hooks}).  It should return either a cons of the beginning and end buffer
-positions (in that order) of the region to fontify, or @code{nil} (which
-directs the caller to fontify the default region).  This function need
-not preserve point or the match-data, but must preserve the current
-restriction.  The region it returns may start or end in the middle of a
-line.
-
-Since this function is called after every buffer change, it should be
-reasonably fast.
-@end defvar
-
 @node Other Font Lock Variables
 @subsection Other Font Lock Variables
 
@@ -3052,6 +3015,90 @@
 @code{font-lock-defaults}.
 @end defvar
 
+@node Multi line Font Lock Elements
+@subsection Multi line Font Lock Elements
+@cindex multi line font lock
+
+Normally, Font Lock elements specified via @code{font-lock-keywords}
+should not match across multiple lines.  If they do, Font Lock may
+fail to highlight them properly.  This is fundamentally due to the
+fact that Font Lock does not always look at the whole buffer at
+a time, for obvious performance reasons, and instead only looks
+at a small chunk at a time.  In order for the highlight to be correct,
+a chunk should not straddle an element matched by
+@code{font-lock-keywords}.  The default heuristic used for this is to
+start and end chunks at the beginning resp. end of a line.
+
+To work around this limitations, a few tools are provided.
+
+@menu
+* Font Lock Multiline::         Marking multiline chunks with a text property
+* Region to Fontify::           Controlling which region gets refontified
+                                  after a buffer change.
+@end menu
+
+@node Font Lock Multiline
+@subsubsection Font Lock Multiline
+
+In order to make it possible to properly highlight elements that span
+multiple lines, Font Lock obeys a special text property
+@code{font-lock-multiline} which if non-@code{nil} indicates that this
+piece of text is part of a multiline construct.  So when Font Lock is
+asked to highlight a region, it first verifies the two boundaries and
+extends them as needed so they do not fall in the middle of a piece of
+text marked with the @code{font-lock-multiline} property.
+Immediately after that, it also erases all @code{font-lock-multiline}
+properties from the region it is about to highlight, so it is the
+responsability of the highlighting specification (mostly
+@code{font-lock-keywords}) to make sure that this property is re-added
+where needed so as to inform the next round of Font Locking of the
+presence of a multiline construct.
+
+It is important to understand that the @code{font-lock-multiline}
+property should preferably only be used on Font Lock elements of
+moderate size: every time that text is modified within the multiline
+elements (or nearby), the whole multiline element will be completely
+re-highlighted, so if its size is large, the time to font-lock may
+render editing painfully slow.
+
+@defvar font-lock-multiline
+If the @code{font-lock-multiline} variable is set to @code{t}, Font
+Lock will try to automatically add the @code{font-lock-multiline}
+property on the keywords that span several lines.  This is no silver
+bullet however since it slows down Font Lock somewhat, and still does
+not always find all multiline constructs, especially when used with
+Jit Lock, which is enabled by default.
+@end defvar
+
+@node Region to Fontify
+@subsubsection Region to Fontify after a Buffer Change
+
+  When a buffer is changed, the region that Font Lock refontifies is by
+default the smallest sequence of whole lines that spans the change.
+While this works well most of the time, sometimes it doesn't---for
+example, when a buffer change has changed the syntactic meaning of text
+on an earlier line.
+
+You can enlarge (or even reduce) the region to fontify by setting @c either of
+the following variables:
+
+@defvar font-lock-extend-region-function
+This buffer-local variable is either @code{nil} or is a function that
+determines the region to fontify, which Emacs then calls after each
+buffer change.
+
+The function is given three parameters, the standard @var{beg},
+@var{end}, and @var{old-len} from after-change-functions (@pxref{Change
+Hooks}).  It should return either a cons of the beginning and end buffer
+positions (in that order) of the region to fontify, or @code{nil} (which
+directs the caller to fontify the default region).  This function needs
+to preserve point, the match-data, and the current restriction.
+The region it returns may start or end in the middle of a line.
+
+Since this function is called after every buffer change, it should be
+reasonably fast.
+@end defvar
+
 @node Desktop Save Mode
 @section Desktop Save Mode
 @cindex desktop save mode
--- a/lispref/syntax.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/lispref/syntax.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -672,7 +672,9 @@
 
 @enumerate 0
 @item
-The depth in parentheses, counting from 0.
+The depth in parentheses, counting from 0.  @strong{Warning:} this can
+be negative if there are more close parens than open parens between
+the start of the defun and point.
 
 @item
 @cindex innermost containing parentheses
--- a/make-dist	Thu Apr 20 16:09:11 2006 +0000
+++ b/make-dist	Fri Apr 28 14:48:18 2006 +0000
@@ -6,7 +6,7 @@
 #### be distributed.  This means that if you add a file with an odd name,
 #### you should make sure that this script will include it.
 
-# Copyright (C) 1995, 1997, 1998, 2000, 2001, 2002, 2005
+# Copyright (C) 1995, 1997, 1998, 2000, 2001, 2002, 2005, 2006
 #   Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
--- a/man/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,7 +1,71 @@
+2006-04-26  Reiner Steib  <Reiner.Steib@gmx.de>
+
+	* pgg.texi (Caching passphrase): Fix markup and typos.  Simplify.
+
+2006-04-26  Sascha Wilde  <wilde@sha-bang.de>
+
+	* pgg.texi (Caching passphrase): Added documentation for
+	pgg-gpg-use-agent.
+
+2006-04-24  Bill Wohler  <wohler@newt.com>
+
+	* mh-e.texi (Getting Started): Made it more explicit that you need
+	to install MH, and also included pointers to current MH implementations.
+
+2006-04-23  Richard Stallman  <rms@gnu.org>
+
+	* emacs.texi [TeX]: Use xresmini.texi instead of xresources.texi.
+
+	* xresmini.texi: New file.
+
+	* xresources.texi (Face Resources): Split table into font resources
+	and the rest.  Combine similar attributes for brevity.
+
+2006-04-21  Bill Wohler  <wohler@newt.com>
+
+	Release MH-E manual version 7.94.
+	
+	* mh-e.texi (VERSION, EDITION, UPDATED, UPDATE-MONTH): Update for
+	release 7.94.
+
+2006-04-21  Carsten Dominik  <dominik@science.uva.nl>
+
+	* org.texi: Many small fixes.
+	(Handling links): Renamed from "Managing links".
+
+2006-04-21  Eli Zaretskii  <eliz@gnu.org>
+
+	* emacs-xtra.texi (MS-DOS File Names): Remove section about
+	backslashes and case-insensitivity in file names (moved to the
+	main manual).
+	(MS-DOS Printing): Move most of the text to the main manual.
+
+	* msdog.texi (Windows Files, Windows HOME, MS-Windows Printing):
+	New nodes.
+	(Windows Processes, Windows System Menu): Add index entries and
+	fix wording.
+
+2006-04-20  Reiner Steib  <Reiner.Steib@gmx.de>
+
+	* gnus.texi (Spam Statistics Package): Fix typo in @pxref.
+	(Splitting mail using spam-stat): Fix @xref.
+
+2006-04-20  Chong Yidong <cyd@stupidchicken.com>
+
+	* gnus.texi (Spam Package): Major revision of the text.  Previouly
+	this node was "Filtering Spam Using The Spam ELisp Package".
+
+2006-04-20  Carsten Dominik  <dominik@science.uva.nl>
+
+	* org.texi: (Time stamps): Better explanation of the purpose of
+	different time stamps.
+	(Structure editing, Plain lists): More details on how new items
+	and headings are inserted.
+
 2006-04-18  J.D. Smith  <jdsmith@as.arizona.edu>
 
 	* misc.texi (Shell Ring): Added notes on saved input when
-	navigating off the end of the history list.  
+	navigating off the end of the history list.
 
 2006-04-18  Chong Yidong  <cyd@mit.edu>
 
--- a/man/emacs-xtra.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/emacs-xtra.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -3316,7 +3316,7 @@
 * Mouse: MS-DOS Mouse.         Mouse conventions on MS-DOS.
 * Display: MS-DOS Display.     Fonts, frames and display size on MS-DOS.
 * Files: MS-DOS File Names.    File name conventions on MS-DOS.
-* Printing: MS-DOS Printing.   How to specify the printer on MS-DOS.
+* Printing: MS-DOS Printing.   Printing specifics on MS-DOS.
 * I18N: MS-DOS and MULE.       Support for internationalization on MS-DOS.
 * Processes: MS-DOS Processes. Running subprocesses on MS-DOS.
 @end menu
@@ -3534,11 +3534,6 @@
 @cindex file names under MS-DOS
 @cindex init file, default name under MS-DOS
 
-  MS-DOS normally uses a backslash, @samp{\}, to separate name units
-within a file name, instead of the slash used on other systems.  Emacs
-on MS-DOS permits use of either slash or backslash, and also knows
-about drive letters in file names.
-
   On MS-DOS, file names are case-insensitive and limited to eight
 characters, plus optionally a period and three more characters.  Emacs
 knows enough about these limitations to handle file names that were
@@ -3593,55 +3588,14 @@
 @section Printing and MS-DOS
 
   Printing commands, such as @code{lpr-buffer}
-(@pxref{Printing,,,emacs, the Emacs Manual }) and
+(@pxref{Printing,,,emacs, the Emacs Manual}) and
 @code{ps-print-buffer} (@pxref{PostScript,,,emacs, the Emacs Manual})
-can work in MS-DOS and MS-Windows by sending the output to one of the
-printer ports, if a Posix-style @code{lpr} program is unavailable.
-The same Emacs variables control printing on all systems, but in some
-cases they have different default values on MS-DOS and MS-Windows.
-
-@vindex printer-name @r{(MS-DOS)}
-  If you want to use your local printer, printing on it in the usual DOS
-manner, then set the Lisp variable @code{lpr-command} to @code{""} (its
-default value) and @code{printer-name} to the name of the printer
-port---for example, @code{"PRN"}, the usual local printer port (that's
-the default), or @code{"LPT2"}, or @code{"COM1"} for a serial printer.
-You can also set @code{printer-name} to a file name, in which case
-``printed'' output is actually appended to that file.  If you set
-@code{printer-name} to @code{"NUL"}, printed output is silently
-discarded (sent to the system null device).
-
-  On MS-Windows, when the Windows network software is installed, you can
-also use a printer shared by another machine by setting
-@code{printer-name} to the UNC share name for that printer---for example,
-@code{"//joes_pc/hp4si"}.  (It doesn't matter whether you use forward
-slashes or backslashes here.)  To find out the names of shared printers,
-run the command @samp{net view} at a DOS command prompt to obtain a list
-of servers, and @samp{net view @var{server-name}} to see the names of printers
-(and directories) shared by that server.  Alternatively, click the
-@samp{Network Neighborhood} icon on your desktop, and look for machines
-which share their printers via the network.
-
-@cindex @samp{net use}, and printing on MS-Windows
-@cindex networked printers (MS-Windows)
-  If the printer doesn't appear in the output of @samp{net view}, or
-if setting @code{printer-name} to the UNC share name doesn't produce a
-hardcopy on that printer, you can use the @samp{net use} command to
-connect a local print port such as @code{"LPT2"} to the networked
-printer.  For example, typing @kbd{net use LPT2:
-\\joes_pc\hp4si}@footnote{
-Note that the @samp{net use} command requires the UNC share name to be
-typed with the Windows-style backslashes, while the value of
-@code{printer-name} can be set with either forward- or backslashes.}
-causes Windows to @dfn{capture} the LPT2 port and redirect the printed
-material to the printer connected to the machine @code{joes_pc}.
-After this command, setting @code{printer-name} to @code{"LPT2"}
-should produce the hardcopy on the networked printer.
-
-  With some varieties of Windows network software, you can instruct
-Windows to capture a specific printer port such as @code{"LPT2"}, and
-redirect it to a networked printer via the @w{@code{Control
-Panel->Printers}} applet instead of @samp{net use}.
+can work on MS-DOS by sending the output to one of the printer ports,
+if a Posix-style @code{lpr} program is unavailable.  The same Emacs
+variables control printing on all systems, but in some cases they have
+different default values on MS-DOS.
+
+@xref{MS-Windows Printing,,,emacs, the Emacs Manual}, for details.
 
   Some printers expect DOS codepage encoding of non-@acronym{ASCII} text, even
 though they are connected to a Windows machine which uses a different
@@ -3655,95 +3609,11 @@
 codepage 850 encoding.  You may need to create the @code{cp@var{nnn}}
 coding system with @kbd{M-x codepage-setup}.
 
-  If you set @code{printer-name} to a file name, it's best to use an
-absolute file name.  Emacs changes the working directory according to
-the default directory of the current buffer, so if the file name in
-@code{printer-name} is relative, you will end up with several such
-files, each one in the directory of the buffer from which the printing
-was done.
-
-@findex print-buffer @r{(MS-DOS)}
-@findex print-region @r{(MS-DOS)}
-@vindex lpr-headers-switches @r{(MS-DOS)}
-  The commands @code{print-buffer} and @code{print-region} call the
-@code{pr} program, or use special switches to the @code{lpr} program, to
-produce headers on each printed page.  MS-DOS and MS-Windows don't
-normally have these programs, so by default, the variable
-@code{lpr-headers-switches} is set so that the requests to print page
-headers are silently ignored.  Thus, @code{print-buffer} and
-@code{print-region} produce the same output as @code{lpr-buffer} and
-@code{lpr-region}, respectively.  If you do have a suitable @code{pr}
-program (for example, from GNU Textutils), set
-@code{lpr-headers-switches} to @code{nil}; Emacs will then call
-@code{pr} to produce the page headers, and print the resulting output as
-specified by @code{printer-name}.
-
-@vindex print-region-function @r{(MS-DOS)}
-@cindex lpr usage under MS-DOS
-@vindex lpr-command @r{(MS-DOS)}
-@vindex lpr-switches @r{(MS-DOS)}
-  Finally, if you do have an @code{lpr} work-alike, you can set the
-variable @code{lpr-command} to @code{"lpr"}.  Then Emacs will use
-@code{lpr} for printing, as on other systems.  (If the name of the
-program isn't @code{lpr}, set @code{lpr-command} to specify where to
-find it.)  The variable @code{lpr-switches} has its standard meaning
-when @code{lpr-command} is not @code{""}.  If the variable
-@code{printer-name} has a string value, it is used as the value for the
-@code{-P} option to @code{lpr}, as on Unix.
-
-@findex ps-print-buffer @r{(MS-DOS)}
-@findex ps-spool-buffer @r{(MS-DOS)}
-@vindex ps-printer-name @r{(MS-DOS)}
-@vindex ps-lpr-command @r{(MS-DOS)}
-@vindex ps-lpr-switches @r{(MS-DOS)}
-  A parallel set of variables, @code{ps-lpr-command},
-@code{ps-lpr-switches}, and @code{ps-printer-name} (@pxref{PostScript
-Variables,,,emacs, the Emacs Manual}), defines how PostScript files
-should be printed.  These variables are used in the same way as the
-corresponding variables described above for non-PostScript printing.
-Thus, the value of @code{ps-printer-name} is used as the name of the
-device (or file) to which PostScript output is sent, just as
-@code{printer-name} is used for non-PostScript printing.  (There are
-two distinct sets of variables in case you have two printers attached
-to two different ports, and only one of them is a PostScript printer.)
-
-  The default value of the variable @code{ps-lpr-command} is @code{""},
-which causes PostScript output to be sent to the printer port specified
-by @code{ps-printer-name}, but @code{ps-lpr-command} can also be set to
-the name of a program which will accept PostScript files.  Thus, if you
-have a non-PostScript printer, you can set this variable to the name of
-a PostScript interpreter program (such as Ghostscript).  Any switches
-that need to be passed to the interpreter program are specified using
-@code{ps-lpr-switches}.  (If the value of @code{ps-printer-name} is a
-string, it will be added to the list of switches as the value for the
-@code{-P} option.  This is probably only useful if you are using
-@code{lpr}, so when using an interpreter typically you would set
-@code{ps-printer-name} to something other than a string so it is
-ignored.)
-
-  For example, to use Ghostscript for printing on an Epson printer
-connected to the @samp{LPT2} port, put this in your @file{_emacs} file:
-
-@example
-(setq ps-printer-name t)  ; Ghostscript doesn't understand -P
-(setq ps-lpr-command "c:/gs/gs386")
-(setq ps-lpr-switches '("-q" "-dNOPAUSE"
-			"-sDEVICE=epson"
-			"-r240x72"
-			"-sOutputFile=LPT2"
-			"-Ic:/gs"))
-@end example
-
-@noindent
-(This assumes that Ghostscript is installed in the @file{"c:/gs"}
-directory.)
-
 @vindex dos-printer
 @vindex dos-ps-printer
   For backwards compatibility, the value of @code{dos-printer}
 (@code{dos-ps-printer}), if it has a value, overrides the value of
-@code{printer-name} (@code{ps-printer-name}), on MS-DOS and MS-Windows
-only.
+@code{printer-name} (@code{ps-printer-name}), on MS-DOS.
 
 
 @node MS-DOS and MULE
--- a/man/emacs.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/emacs.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -1544,7 +1544,12 @@
 
 @include doclicense.texi
 @include cmdargs.texi
+@iftex
+@include xresmini.texi
+@end iftex
+@ifnottex
 @include xresources.texi
+@end ifnottex
 
 @include anti.texi
 @include macos.texi
--- a/man/gnus.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/gnus.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -799,7 +799,8 @@
 * Moderation::                  What to do if you're a moderator.
 * Image Enhancements::          Modern versions of Emacs/XEmacs can display images.
 * Fuzzy Matching::              What's the big fuzz?
-* Thwarting Email Spam::        A how-to on avoiding unsolicited commercial email.
+* Thwarting Email Spam::        Simple ways to avoid unsolicited commercial email.
+* Spam Package::                A package for filtering and processing spam.
 * Other modes::                 Interaction with other modes.
 * Various Various::             Things that are really various.
 
@@ -818,7 +819,8 @@
 
 * X-Face::                      Display a funky, teensy black-and-white image.
 * Face::                        Display a funkier, teensier colored image.
-* Smileys::                     Show all those happy faces the way they were meant to be shown.
+* Smileys::                     Show all those happy faces the way they were
+                                  meant to be shown.
 * Picons::                      How to display pictures of what you're reading.
 * XVarious::                    Other XEmacsy Gnusey variables.
 
@@ -828,28 +830,19 @@
 * Anti-Spam Basics::            Simple steps to reduce the amount of spam.
 * SpamAssassin::                How to use external anti-spam tools.
 * Hashcash::                    Reduce spam by burning CPU time.
-* Filtering Spam Using The Spam ELisp Package::
-* Filtering Spam Using Statistics with spam-stat::
-
-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::
-* ifile spam filtering::
-* spam-stat spam filtering::
-* SpamOracle::
-* Extending the Spam ELisp package::
-
-Filtering Spam Using Statistics with spam-stat
+
+Spam Package
+
+* Spam Package Introduction::
+* Filtering Incoming Mail::
+* Detecting Spam in Groups::
+* Spam and Ham Processors::
+* Spam Package Configuration Examples::
+* Spam Back Ends::
+* Extending the Spam package::
+* Spam Statistics Package::
+
+Spam Statistics Package
 
 * Creating a spam-stat dictionary::
 * Splitting mail using spam-stat::
@@ -20797,7 +20790,8 @@
 * Fetching a Group::            Starting Gnus just to read a group.
 * Image Enhancements::          Modern versions of Emacs/XEmacs can display images.
 * Fuzzy Matching::              What's the big fuzz?
-* Thwarting Email Spam::        A how-to on avoiding unsolicited commercial email.
+* Thwarting Email Spam::        Simple ways to avoid unsolicited commercial email.
+* Spam Package::                A package for filtering and processing spam.
 * Other modes::                 Interaction with other modes.
 * Various Various::             Things that are really various.
 @end menu
@@ -22479,8 +22473,6 @@
 * Anti-Spam Basics::            Simple steps to reduce the amount of spam.
 * SpamAssassin::                How to use external anti-spam tools.
 * Hashcash::                    Reduce spam by burning CPU time.
-* Filtering Spam Using The Spam ELisp Package::
-* Filtering Spam Using Statistics with spam-stat::
 @end menu
 
 @node The problem of spam
@@ -22796,41 +22788,107 @@
 customized mail filtering scripts.  Improvements in this area would be
 a useful contribution, however.
 
-@node Filtering Spam Using The Spam ELisp Package
-@subsection Filtering Spam Using The Spam ELisp Package
+@node Spam Package
+@section Spam Package
 @cindex spam filtering
 @cindex spam
 
-The idea behind @file{spam.el} is to have a control center for spam detection
-and filtering in Gnus.  To that end, @file{spam.el} does two things: it
-filters new mail, and it analyzes mail known to be spam or ham.
-@dfn{Ham} is the name used throughout @file{spam.el} to indicate
-non-spam messages.
+The Spam package provides Gnus with a centralized mechanism for
+detecting and filtering spam.  It filters new mail, and processes
+messages according to whether they are spam or ham.  (@dfn{Ham} is the
+name used throughout this manual to indicate non-spam messages.)
+
+@menu
+* Spam Package Introduction::
+* Filtering Incoming Mail::
+* Detecting Spam in Groups::
+* Spam and Ham Processors::
+* Spam Package Configuration Examples::
+* Spam Back Ends::
+* Extending the Spam package::
+* Spam Statistics Package::
+@end menu
+
+@node Spam Package Introduction
+@subsection Spam Package Introduction
+@cindex spam filtering
+@cindex spam filtering sequence of events
+@cindex spam
+
+You must read this section to understand how the Spam package works.
+Do not skip, speed-read, or glance through this section.
 
 @cindex spam-initialize
-First of all, you @strong{must} run the function
-@code{spam-initialize} to autoload @code{spam.el} and to install the
-@code{spam.el} hooks.  There is one exception: if you use the
-@code{spam-use-stat} (@pxref{spam-stat spam filtering}) setting, you
-should turn it on before @code{spam-initialize}:
-
-@example
-(setq spam-use-stat t) ;; if needed
+@vindex spam-use-stat
+To use the Spam package, you @strong{must} first run the function
+@code{spam-initialize}:
+
+@example
 (spam-initialize)
 @end example
 
-So, what happens when you load @file{spam.el}?
-
-First, some hooks will get installed by @code{spam-initialize}.  There
-are some hooks for @code{spam-stat} so it can save its databases, and
-there are hooks so interesting things will happen when you enter and
-leave a group.  More on the sequence of events later (@pxref{Spam
-ELisp Package Sequence of Events}).
-
-You get the following keyboard commands:
-
-@table @kbd
-
+This autoloads @code{spam.el} and installs the various hooks necessary
+to let the Spam package do its job.  In order to make use of the Spam
+package, you have to set up certain group parameters and variables,
+which we will describe below.  All of the variables controlling the
+Spam package can be found in the @samp{spam} customization group.
+
+There are two ``contact points'' between the Spam package and the rest
+of Gnus: checking new mail for spam, and leaving a group.
+
+Checking new mail for spam is done in one of two ways: while splitting
+incoming mail, or when you enter a group.
+
+The first way, checking for spam while splitting incoming mail, is
+suited to mail back ends such as @code{nnml} or @code{nnimap}, where
+new mail appears in a single spool file.  The Spam package processes
+incoming mail, and sends mail considered to be spam to a designated
+``spam'' group.  @xref{Filtering Incoming Mail}.
+
+The second way is suited to back ends such as @code{nntp}, which have
+no incoming mail spool, or back ends where the server is in charge of
+splitting incoming mail.  In this case, when you enter a Gnus group,
+the unseen or unread messages in that group are checked for spam.
+Detected spam messages are marked as spam.  @xref{Detecting Spam in
+Groups}.
+
+@cindex spam back ends
+In either case, you have to tell the Spam package what method to use
+to detect spam messages.  There are several methods, or @dfn{spam back
+ends} (not to be confused with Gnus back ends!) to choose from: spam
+``blacklists'' and ``whitelists'', dictionary-based filters, and so
+forth.  @xref{Spam Back Ends}.
+
+In the Gnus summary buffer, messages that have been identified as spam
+always appear with a @samp{$} symbol.
+
+The Spam package divides Gnus groups into three categories: ham
+groups, spam groups, and unclassified groups.  You should mark each of
+the groups you subscribe to as either a ham group or a spam group,
+using the @code{spam-contents} group parameter (@pxref{Group
+Parameters}).  Spam groups have a special property: when you enter a
+spam group, all unseen articles are marked as spam.  Thus, mail split
+into a spam group is automatically marked as spam.
+
+Identifying spam messages is only half of the Spam package's job.  The
+second half comes into play whenever you exit a group buffer.  At this
+point, the Spam package does several things:
+
+First, it calls @dfn{spam and ham processors} to process the articles
+according to whether they are spam or ham.  There is a pair of spam
+and ham processors associated with each spam back end, and what the
+processors do depends on the back end.  At present, the main role of
+spam and ham processors is for dictionary-based spam filters: they add
+the contents of the messages in the group to the filter's dictionary,
+to improve its ability to detect future spam.  The @code{spam-process}
+group parameter specifies what spam processors to use.  @xref{Spam and
+Ham Processors}.
+
+If the spam filter failed to mark a spam message, you can mark it
+yourself, so that the message is processed as spam when you exit the
+group:
+
+@table @kbd
 @item M-d
 @itemx M s x
 @itemx S x
@@ -22838,189 +22896,103 @@
 @kindex S x
 @kindex M s x
 @findex gnus-summary-mark-as-spam
-@code{gnus-summary-mark-as-spam}.
-
-Mark current article as spam, showing it with the @samp{$} mark.
-Whenever you see a spam article, make sure to mark its summary line
-with @kbd{M-d} before leaving the group.  This is done automatically
-for unread articles in @emph{spam} groups.
-
-@item M s t
-@itemx S t
-@kindex M s t
-@kindex S t
-@findex spam-bogofilter-score
-@code{spam-bogofilter-score}.
-
-You must have Bogofilter installed for that command to work properly.
-
-@xref{Bogofilter}.
-
-@end table
-
-Also, when you load @file{spam.el}, you will be able to customize its
-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 Configuration Examples::
-* Blacklists and Whitelists::
-* BBDB Whitelists::
-* Gmane Spam Reporting::
-* Anti-spam Hashcash Payments::
-* Blackholes::
-* Regular Expressions Header Matching::
-* Bogofilter::
-* 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
-@cindex spam filtering
-@cindex spam filtering sequence of events
-@cindex spam
-
-You must read this section to understand how @code{spam.el} works.
-Do not skip, speed-read, or glance through this section.
-
-There are two @emph{contact points}, if you will, between
-@code{spam.el} and the rest of Gnus: checking new mail for spam, and
-leaving a group.
-
-Getting new mail is done in one of two ways.  You can either split
-your incoming mail or you can classify new articles as ham or spam
-when you enter the group.
-
-Splitting incoming mail is better suited to mail backends such as
-@code{nnml} or @code{nnimap} where new mail appears in a single file
-called a @dfn{Spool File}.  See @xref{Spam ELisp Package Filtering of
-Incoming Mail}.
-
-For backends such as @code{nntp} there is no incoming mail spool, so
-an alternate mechanism must be used.  This may also happen for
-backends where the server is in charge of splitting incoming mail, and
-Gnus does not do further splitting.  The @code{spam-autodetect} and
-@code{spam-autodetect-methods} group parameters (accessible with
-@kbd{G c} and @kbd{G p} as usual), and the corresponding variables
-@code{gnus-spam-autodetect-methods} and
-@code{gnus-spam-autodetect-methods} (accessible with @kbd{M-x
-customize-variable} as usual).
-
-When @code{spam-autodetect} is used, it hooks into the process of
-entering a group.  Thus, entering a group with unseen or unread
-articles becomes the substitute for checking incoming mail.  Whether
-only unseen articles or all unread articles will be processed is
-determined by the @code{spam-autodetect-recheck-messages}.  When set
-to @code{t}, unread messages will be rechecked.
-
-@code{spam-autodetect} grants the user at once more and less control
-of spam filtering.  The user will have more control over each group's
-spam methods, so for instance the @samp{ding} group may have
-@code{spam-use-BBDB} as the autodetection method, while the
-@samp{suspect} group may have the @code{spam-use-blacklist} and
-@code{spam-use-bogofilter} methods enabled.  Every article detected to
-be spam will be marked with the spam mark @samp{$} and processed on
-exit from the group as normal spam.  The user has less control over
-the @emph{sequence} of checks, as he might with @code{spam-split}.
-
-When the newly split mail goes into groups, or messages are
-autodetected to be ham or spam, those groups must be exited (after
-entering, if needed) for further spam processing to happen.  It
-matters whether the group is considered a ham group, a spam group, or
-is unclassified, based on its @code{spam-content} parameter
-(@pxref{Spam ELisp Package Global Variables}).  Spam groups have the
-additional characteristic that, when entered, any unseen or unread
-articles (depending on the @code{spam-mark-only-unseen-as-spam}
-variable) will be marked as spam.  Thus, mail split into a spam group
-gets automatically marked as spam when you enter the group.
-
-So, when you exit a group, the @code{spam-processors} are applied, if
-any are set, and the processed mail is moved to the
-@code{ham-process-destination} or the @code{spam-process-destination}
-depending on the article's classification.  If the
-@code{ham-process-destination} or the @code{spam-process-destination},
-whichever is appropriate, are @code{nil}, the article is left in the
-current group.
-
-If a spam is found in any group (this can be changed to only non-spam
-groups with @code{spam-move-spam-nonspam-groups-only}), it is
-processed by the active @code{spam-processors} (@pxref{Spam ELisp
-Package Global Variables}) when the group is exited.  Furthermore, the
-spam is moved to the @code{spam-process-destination} (@pxref{Spam
-ELisp Package Global Variables}) for further training or deletion.
-You have to load the @code{gnus-registry.el} package and enable the
-@code{spam-log-to-registry} variable if you want spam to be processed
-no more than once.  Thus, spam is detected and processed everywhere,
-which is what most people want.  If the
-@code{spam-process-destination} is @code{nil}, the spam is marked as
+@findex gnus-summary-mark-as-spam
+Mark current article as spam, showing it with the @samp{$} mark
+(@code{gnus-summary-mark-as-spam}).
+@end table
+
+@noindent
+Similarly, you can unmark an article if it has been erroneously marked
+as spam.  @xref{Setting Marks}.
+
+Normally, a ham message found in a non-ham group is not processed as
+ham---the rationale is that it should be moved into a ham group for
+further processing (see below).  However, you can force these articles
+to be processed as ham by setting
+@code{spam-process-ham-in-spam-groups} and
+@code{spam-process-ham-in-nonham-groups}.
+
+@vindex gnus-ham-process-destinations
+@vindex gnus-spam-process-destinations
+The second thing that the Spam package does when you exit a group is
+to move ham articles out of spam groups, and spam articles out of ham
+groups.  Ham in a spam group is moved to the group specified by the
+variable @code{gnus-ham-process-destinations}, or the group parameter
+@code{ham-process-destination}.  Spam in a ham group is moved to the
+group specified by the variable @code{gnus-spam-process-destinations},
+or the group parameter @code{spam-process-destination}.  If these
+variables are not set, the articles are left in their current group.
+If an article cannot not be moved (e.g., with a read-only backend such
+as @acronym{NNTP}), it is copied.
+
+If an article is moved to another group, it is processed again when
+you visit the new group.  Normally, this is not a problem, but if you
+want each article to be processed only once, load the
+@code{gnus-registry.el} package and set the variable
+@code{spam-log-to-registry} to @code{t}.  @xref{Spam Package
+Configuration Examples}.
+
+Normally, spam groups ignore @code{gnus-spam-process-destinations}.
+However, if you set @code{spam-move-spam-nonspam-groups-only} to
+@code{nil}, spam will also be moved out of spam groups, depending on
+the @code{spam-process-destination} parameter.
+
+The final thing the Spam package does is to mark spam articles as
 expired, which is usually the right thing to do.
 
-If spam can not be moved---because of a read-only backend such as
-@acronym{NNTP}, for example, it will be copied.
-
-If a ham mail is found in a ham group, as determined by the
-@code{ham-marks} parameter, it is processed as ham by the active ham
-@code{spam-processor} when the group is exited.  With the variables
-@code{spam-process-ham-in-spam-groups} and
-@code{spam-process-ham-in-nonham-groups} the behavior can be further
-altered so ham found anywhere can be processed.  You have to load the
-@code{gnus-registry.el} package and enable the
-@code{spam-log-to-registry} variable if you want ham to be processed
-no more than once.  Thus, ham is detected and processed only when
-necessary, which is what most people want.  More on this in
-@xref{Spam ELisp Package Configuration Examples}.
-
-If ham can not be moved---because of a read-only backend such as
-@acronym{NNTP}, for example, it will be copied.
-
 If all this seems confusing, don't worry.  Soon it will be as natural
 as typing Lisp one-liners on a neural interface@dots{} err, sorry, that's
 50 years in the future yet.  Just trust us, it's not so bad.
 
-@node Spam ELisp Package Filtering of Incoming Mail
-@subsubsection Spam ELisp Package Filtering of Incoming Mail
+@node Filtering Incoming Mail
+@subsection Filtering Incoming Mail
 @cindex spam filtering
 @cindex spam filtering incoming mail
 @cindex spam
 
-To use the @file{spam.el} facilities for incoming mail filtering, you
-must add the following to your fancy split list
-@code{nnmail-split-fancy} or @code{nnimap-split-fancy}:
+To use the Spam package to filter incoming mail, you must first set up
+fancy mail splitting.  @xref{Fancy Mail Splitting}.  The Spam package
+defines a special splitting function that you can add to your fancy
+split variable (either @code{nnmail-split-fancy} or
+@code{nnimap-split-fancy}, depending on your mail back end):
 
 @example
 (: spam-split)
 @end example
 
-Note that the fancy split may be called @code{nnmail-split-fancy} or
-@code{nnimap-split-fancy}, depending on whether you use the nnmail or
-nnimap back ends to retrieve your mail.
-
-Also, @code{spam-split} will not modify incoming mail in any way.
-
-The @code{spam-split} function will process incoming mail and send the
-mail considered to be spam into the group name given by the variable
-@code{spam-split-group}.  By default that group name is @samp{spam},
-but you can customize @code{spam-split-group}.  Make sure the contents
-of @code{spam-split-group} are an @emph{unqualified} group name, for
-instance in an @code{nnimap} server @samp{your-server} the value
-@samp{spam} will turn out to be @samp{nnimap+your-server:spam}.  The
-value @samp{nnimap+server:spam}, therefore, is wrong and will
-actually give you the group
-@samp{nnimap+your-server:nnimap+server:spam} which may or may not
-work depending on your server's tolerance for strange group names.
-
-You can also give @code{spam-split} a parameter,
-e.g. @code{spam-use-regex-headers} or @code{"maybe-spam"}.  Why is
-this useful?
-
-Take these split rules (with @code{spam-use-regex-headers} and
-@code{spam-use-blackholes} set):
+@vindex spam-split-group
+@noindent
+The @code{spam-split} function scans incoming mail according to your
+chosen spam back end(s), and sends messages identified as spam to a
+spam group.  By default, the spam group is a group named @samp{spam},
+but you can change this by customizing @code{spam-split-group}.  Make
+sure the contents of @code{spam-split-group} are an unqualified group
+name.  For instance, in an @code{nnimap} server @samp{your-server},
+the value @samp{spam} means @samp{nnimap+your-server:spam}.  The value
+@samp{nnimap+server:spam} is therefore wrong---it gives the group
+@samp{nnimap+your-server:nnimap+server:spam}.
+
+@code{spam-split} does not modify the contents of messages in any way.
+
+@vindex nnimap-split-download-body
+Note for IMAP users: if you use the @code{spam-check-bogofilter},
+@code{spam-check-ifile}, and @code{spam-check-stat} spam back ends,
+you should also set set the variable @code{nnimap-split-download-body}
+to @code{t}.  These spam back ends are most useful when they can
+``scan'' the full message body.  By default, the nnimap back end only
+retrieves the message headers; @code{nnimap-split-download-body} tells
+it to retrieve the message bodies as well.  We don't set this by
+default because it will slow @acronym{IMAP} down, and that is not an
+appropriate decision to make on behalf of the user.  @xref{Splitting
+in IMAP}.
+
+You have to specify one or more spam back ends for @code{spam-split}
+to use, by setting the @code{spam-use-*} variables.  @xref{Spam Back
+Ends}.  Normally, @code{spam-split} simply uses all the spam back ends
+you enabled in this way.  However, you can tell @code{spam-split} to
+use only some of them.  Why this is useful?  Suppose you are using the
+@code{spam-use-regex-headers} and @code{spam-use-blackholes} spam back
+ends, and the following split rule:
 
 @example
  nnimap-split-fancy '(|
@@ -23030,21 +23002,23 @@
                       "mail")
 @end example
 
-Now, the problem is that you want all ding messages to make it to the
-ding folder.  But that will let obvious spam (for example, spam
-detected by SpamAssassin, and @code{spam-use-regex-headers}) through,
-when it's sent to the ding list.  On the other hand, some messages to
-the ding list are from a mail server in the blackhole list, so the
-invocation of @code{spam-split} can't be before the ding rule.
-
-You can let SpamAssassin headers supersede ding rules, but all other
-@code{spam-split} rules (including a second invocation of the
-regex-headers check) will be after the ding rule:
+@noindent
+The problem is that you want all ding messages to make it to the ding
+folder.  But that will let obvious spam (for example, spam detected by
+SpamAssassin, and @code{spam-use-regex-headers}) through, when it's
+sent to the ding list.  On the other hand, some messages to the ding
+list are from a mail server in the blackhole list, so the invocation
+of @code{spam-split} can't be before the ding rule.
+
+The solution is to let SpamAssassin headers supersede ding rules, and
+perform the other @code{spam-split} rules (including a second
+invocation of the regex-headers check) after the ding rule.  This is
+done by passing a parameter to @code{spam-split}:
 
 @example
 nnimap-split-fancy
       '(|
-        ;; @r{all spam detected by @code{spam-use-regex-headers} goes to @samp{regex-spam}}
+        ;; @r{spam detected by @code{spam-use-regex-headers} goes to @samp{regex-spam}}
         (: spam-split "regex-spam" 'spam-use-regex-headers)
         (any "ding" "ding")
         ;; @r{all other spam detected by spam-split goes to @code{spam-split-group}}
@@ -23053,58 +23027,68 @@
         "mail")
 @end example
 
+@noindent
 This lets you invoke specific @code{spam-split} checks depending on
-your particular needs, and to target the results of those checks to a
+your particular needs, and target the results of those checks to a
 particular spam group.  You don't have to throw all mail into all the
 spam tests.  Another reason why this is nice is that messages to
 mailing lists you have rules for don't have to have resource-intensive
 blackhole checks performed on them.  You could also specify different
 spam checks for your nnmail split vs. your nnimap split.  Go crazy.
 
-You should still have specific checks such as
-@code{spam-use-regex-headers} set to @code{t}, even if you
-specifically invoke @code{spam-split} with the check.  The reason is
-that when loading @file{spam.el}, some conditional loading is done
-depending on what @code{spam-use-xyz} variables you have set.  This
-is usually not critical, though.
-
-@emph{Note for IMAP users}
-
-The boolean variable @code{nnimap-split-download-body} needs to be
-set, if you want to split based on the whole message instead of just
-the headers.  By default, the nnimap back end will only retrieve the
-message headers.  If you use @code{spam-check-bogofilter},
-@code{spam-check-ifile}, or @code{spam-check-stat} (the splitters that
-can benefit from the full message body), you should set this variable.
-It is not set by default because it will slow @acronym{IMAP} down, and
-that is not an appropriate decision to make on behalf of the user.
-
-@xref{Splitting in IMAP}.
-
-@emph{TODO: spam.el needs to provide a uniform way of training all the
-statistical databases.  Some have that functionality built-in, others
-don't.}
-
-@node Spam ELisp Package Global Variables
-@subsubsection Spam ELisp Package Global Variables
+You should set the @code{spam-use-*} variables for whatever spam back
+ends you intend to use.  The reason is that when loading
+@file{spam.el}, some conditional loading is done depending on what
+@code{spam-use-xyz} variables you have set.  @xref{Spam Back Ends}.
+
+@c @emph{TODO: spam.el needs to provide a uniform way of training all the
+@c statistical databases.  Some have that functionality built-in, others
+@c don't.}
+
+@node Detecting Spam in Groups
+@subsection Detecting Spam in Groups
+
+To detect spam when visiting a group, set the group's
+@code{spam-autodetect} and @code{spam-autodetect-methods} group
+parameters.  These are accessible with @kbd{G c} or @kbd{G p}, as
+usual (@pxref{Group Parameters}).
+
+You should set the @code{spam-use-*} variables for whatever spam back
+ends you intend to use.  The reason is that when loading
+@file{spam.el}, some conditional loading is done depending on what
+@code{spam-use-xyz} variables you have set.
+
+By default, only unseen articles are processed for spam.  You can
+force Gnus to recheck all messages in the group by setting the
+variable @code{spam-autodetect-recheck-messages} to @code{t}.
+
+If you use the @code{spam-autodetect} method of checking for spam, you
+can specify different spam detection methods for different groups.
+For instance, the @samp{ding} group may have @code{spam-use-BBDB} as
+the autodetection method, while the @samp{suspect} group may have the
+@code{spam-use-blacklist} and @code{spam-use-bogofilter} methods
+enabled.  Unlike with @code{spam-split}, you don't have any control
+over the @emph{sequence} of checks, but this is probably unimportant.
+
+@node Spam and Ham Processors
+@subsection Spam and Ham Processors
 @cindex spam filtering
 @cindex spam filtering variables
 @cindex spam variables
 @cindex spam
 
 @vindex gnus-spam-process-newsgroups
-The concepts of ham processors and spam processors are very important.
-Ham processors and spam processors for a group can be set with the
-@code{spam-process} group parameter, or the
-@code{gnus-spam-process-newsgroups} variable.  Ham processors take
-mail known to be non-spam (@emph{ham}) and process it in some way so
-that later similar mail will also be considered non-spam.  Spam
-processors take mail known to be spam and process it so similar spam
-will be detected later.
-
-The format of the spam or ham processor entry used to be a symbol,
-but now it is a @sc{cons} cell.  See the individual spam processor entries
-for more information.
+Spam and ham processors specify special actions to take when you exit
+a group buffer.  Spam processors act on spam messages, and ham
+processors on ham messages.  At present, the main role of these
+processors is to update the dictionaries of dictionary-based spam back
+ends such as Bogofilter (@pxref{Bogofilter}) and the Spam Statistics
+package (@pxref{Spam Statistics Filtering}).
+
+The spam and ham processors that apply to each group are determined by
+the group's@code{spam-process} group parameter.  If this group
+parameter is not defined, they are determined by the variable
+@code{gnus-spam-process-newsgroups}.
 
 @vindex gnus-spam-newsgroup-contents
 Gnus learns from the spam you get.  You have to collect your spam in
@@ -23258,8 +23242,8 @@
 only unseen articles or all unread articles should be checked for
 spam.  It is recommended that you leave it off.
 
-@node Spam ELisp Package Configuration Examples
-@subsubsection Spam ELisp Package Configuration Examples
+@node Spam Package Configuration Examples
+@subsection Spam Package Configuration Examples
 @cindex spam filtering
 @cindex spam filtering configuration examples
 @cindex spam configuration examples
@@ -23384,11 +23368,11 @@
 
 Because of the @code{gnus-group-spam-classification-spam} entry, all
 messages are marked as spam (with @code{$}).  When I find a false
-positive, I mark the message with some other ham mark (@code{ham-marks},
-@ref{Spam ELisp Package Global Variables}).  On group exit, those
-messages are copied to both groups, @samp{INBOX} (where I want to have
-the article) and @samp{training.ham} (for training bogofilter) and
-deleted from the @samp{spam.detected} folder.
+positive, I mark the message with some other ham mark
+(@code{ham-marks}, @ref{Spam and Ham Processors}).  On group exit,
+those messages are copied to both groups, @samp{INBOX} (where I want
+to have the article) and @samp{training.ham} (for training bogofilter)
+and deleted from the @samp{spam.detected} folder.
 
 The @code{gnus-article-sort-by-chars} entry simplifies detection of
 false positives for me.  I receive lots of worms (sweN, @dots{}), that all
@@ -23424,6 +23408,29 @@
 not the same as on news.gmane.org, thus @code{spam-report.el} has to check
 the @code{X-Report-Spam} header to find the correct number.
 
+@node Spam Back Ends
+@subsection Spam Back Ends
+@cindex spam back ends
+
+The spam package offers a variety of back ends for detecting spam.
+Each back end defines a set of methods for detecting spam
+(@pxref{Filtering Incoming Mail}, @pxref{Detecting Spam in Groups}),
+and a pair of spam and ham processors (@pxref{Spam and Ham
+Processors}).
+
+@menu
+* Blacklists and Whitelists::
+* BBDB Whitelists::
+* Gmane Spam Reporting::
+* Anti-spam Hashcash Payments::
+* Blackholes::
+* Regular Expressions Header Matching::
+* Bogofilter::
+* ifile spam filtering::
+* Spam Statistics Filtering::
+* SpamOracle::
+@end menu
+
 @node Blacklists and Whitelists
 @subsubsection Blacklists and Whitelists
 @cindex spam filtering
@@ -23728,6 +23735,15 @@
 
 @end defvar
 
+@table @kbd
+@item M s t
+@itemx S t
+@kindex M s t
+@kindex S t
+@findex spam-bogofilter-score
+Get the Bogofilter spamicity score (@code{spam-bogofilter-score}).
+@end table
+
 @defvar spam-use-bogofilter-headers
 
 Set this variable if you want @code{spam-split} to use Eric Raymond's
@@ -23829,20 +23845,21 @@
 should be used.  The 1.2.1 version of ifile was used to test this
 functionality.
 
-@node spam-stat spam filtering
-@subsubsection spam-stat spam filtering
+@node Spam Statistics Filtering
+@subsubsection Spam Statistics Filtering
 @cindex spam filtering
 @cindex spam-stat, spam filtering
 @cindex spam-stat
 @cindex spam
 
-@xref{Filtering Spam Using Statistics with spam-stat}.
+This back end uses the Spam Statistics Emacs Lisp package to perform
+statistics-based filtering (@pxref{Spam Statistics Package}).  Before
+using this, you may want to perform some additional steps to
+initialize your Spam Statistics dictionary.  @xref{Creating a
+spam-stat dictionary}.
 
 @defvar spam-use-stat
 
-Enable this variable if you want @code{spam-split} to use
-spam-stat.el, an Emacs Lisp statistical analyzer.
-
 @end defvar
 
 @defvar gnus-group-spam-exit-processor-stat
@@ -23902,18 +23919,17 @@
 @xref{Mail Source Specifiers}, (@pxref{SpamAssassin}).  This method has
 the advantage that the user can see the @emph{X-Spam} headers.
 
-The easiest method is to make @file{spam.el} (@pxref{Filtering Spam
-Using The Spam ELisp Package}) call SpamOracle.
+The easiest method is to make @file{spam.el} (@pxref{Spam Package})
+call SpamOracle.
 
 @vindex spam-use-spamoracle
 To enable SpamOracle usage by @file{spam.el}, set the variable
 @code{spam-use-spamoracle} to @code{t} and configure the
-@code{nnmail-split-fancy} or @code{nnimap-split-fancy} as described in
-the section @xref{Filtering Spam Using The Spam ELisp Package}.  In
-this example the @samp{INBOX} of an nnimap server is filtered using
-SpamOracle.  Mails recognized as spam mails will be moved to
-@code{spam-split-group}, @samp{Junk} in this case.  Ham messages stay
-in @samp{INBOX}:
+@code{nnmail-split-fancy} or @code{nnimap-split-fancy}.  @xref{Spam
+Package}.  In this example the @samp{INBOX} of an nnimap server is
+filtered using SpamOracle.  Mails recognized as spam mails will be
+moved to @code{spam-split-group}, @samp{Junk} in this case.  Ham
+messages stay in @samp{INBOX}:
 
 @example
 (setq spam-use-spamoracle t
@@ -23945,14 +23961,14 @@
 
 SpamOracle employs a statistical algorithm to determine whether a
 message is spam or ham.  In order to get good results, meaning few
-false hits or misses, SpamOracle needs training.  SpamOracle learns the
-characteristics of your spam mails.  Using the @emph{add} mode
+false hits or misses, SpamOracle needs training.  SpamOracle learns
+the characteristics of your spam mails.  Using the @emph{add} mode
 (training mode) one has to feed good (ham) and spam mails to
-SpamOracle.  This can be done by pressing @kbd{|} in the Summary buffer
-and pipe the mail to a SpamOracle process or using @file{spam.el}'s
-spam- and ham-processors, which is much more convenient.  For a
-detailed description of spam- and ham-processors, @xref{Filtering Spam
-Using The Spam ELisp Package}.
+SpamOracle.  This can be done by pressing @kbd{|} in the Summary
+buffer and pipe the mail to a SpamOracle process or using
+@file{spam.el}'s spam- and ham-processors, which is much more
+convenient.  For a detailed description of spam- and ham-processors,
+@xref{Spam Package}.
 
 @defvar gnus-group-spam-exit-processor-spamoracle
 Add this symbol to a group's @code{spam-process} parameter by
@@ -24001,8 +24017,8 @@
 processed by SpamOracle.  The processor sends the messages to
 SpamOracle as new samples for spam.
 
-@node Extending the Spam ELisp package
-@subsubsection Extending the Spam ELisp package
+@node Extending the Spam package
+@subsection Extending the Spam package
 @cindex spam filtering
 @cindex spam elisp package, extending
 @cindex extending the spam elisp package
@@ -24109,9 +24125,8 @@
 
 @end enumerate
 
-
-@node Filtering Spam Using Statistics with spam-stat
-@subsection Filtering Spam Using Statistics with spam-stat
+@node Spam Statistics Package
+@subsection Spam Statistics Package
 @cindex Paul Graham
 @cindex Graham, Paul
 @cindex naive Bayesian spam filtering
@@ -24138,7 +24153,11 @@
 probability of the mail being spam.  If this probability is higher
 than a certain threshold, the mail is considered to be spam.
 
-Gnus supports this kind of filtering.  But it needs some setting up.
+The Spam Statistics package adds support to Gnus for this kind of
+filtering.  It can be used as one of the back ends of the Spam package
+(@pxref{Spam Package}), or by itself.
+
+Before using the Spam Statistics package, you need to set it up.
 First, you need two collections of your mail, one with spam, one with
 non-spam.  Then you need to create a dictionary using these two
 collections, and save it.  And last but not least, you need to use
@@ -24224,8 +24243,10 @@
 @node Splitting mail using spam-stat
 @subsubsection Splitting mail using spam-stat
 
-In order to use @code{spam-stat} to split your mail, you need to add the
-following to your @file{~/.gnus.el} file:
+This section describes how to use the Spam statistics
+@emph{independently} of the @xref{Spam Package}.
+
+First, add the following to your @file{~/.gnus.el} file:
 
 @lisp
 (require 'spam-stat)
--- a/man/mh-e.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/mh-e.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -8,11 +8,11 @@
 @c %**end of header
 
 @c Version of the software and manual.
-@set VERSION 7.93
+@set VERSION 7.94
 @c Edition of the manual. It is either empty for the first edition or
 @c has the form ", nth Edition" (without the quotes).
-@set EDITION , 7th Edition
-@set UPDATED 2006-04-17
+@set EDITION , 2nd Edition
+@set UPDATED 2006-04-24
 @set UPDATE-MONTH April, 2006
 
 @c Other variables.
@@ -245,6 +245,8 @@
 the individual MH commands. When the name is not obvious, I'll guide
 you to a relevant MH manual page that describes the action more fully.
 
+@cindex @cite{MH & nmh: Email for Users & Programmers}
+@cindex MH book
 @cindex info
 @kindex C-h i
 
@@ -536,12 +538,49 @@
 installing MH-E.
 
 If the @code{mh-version} command displays @samp{No MH variant
-detected}, then you need to install MH or tell MH-E where to find
-MH@footnote{In very old versions of MH-E, you may get the error
+detected}@footnote{In very old versions of MH-E, you may get the error
 message, @samp{Cannot find the commands `inc' and `mhl' and the file
 `components'} if MH-E can't find MH. In this case, you need to update
 MH-E, and you may need to install MH too. However, newer versions of
-MH-E are better at finding MH if it is on your system.}.
+MH-E are better at finding MH if it is on your system.}, then you need
+to install MH or tell MH-E where to find MH.
+
+@cindex Debian
+@cindex nmh
+@cindex GNU mailutils
+
+If you don't have MH on your system already, you must install a
+variant of MH. The Debian mh-e package does this for you automatically
+(@pxref{Getting MH-E}). Most people use
+@uref{http://www.nongnu.org/nmh/, nmh}, but you may be interested in
+trying out @uref{http://www.gnu.org/software/mailutils/, GNU
+mailutils}, which supports IMAP. Your GNU/Linux distribution probably
+has packages for both of these.
+
+@cindex @command{install-mh}
+@cindex MH commands, @command{install-mh}
+@cindex MH book
+
+If you've never run MH before, you need to run @command{install-mh}
+from the shell before you continue. This sets up your personal MH
+environment@footnote{See the section
+@uref{@value{MH-BOOK-HOME}/../overall/setup.htm, Setting Up MH} in the
+MH book.}. If you don't, you'll be greeted with the error message:
+@samp{Install MH and run install-mh before running MH-E}. This is all
+you need to know about MH to use MH-E, but the more you know about MH,
+the more you can leverage its power. See the
+@uref{@value{MH-BOOK-HOME}, MH book} to learn more about MH.
+
+@cindex @samp{Path:} MH profile component
+@cindex MH profile
+@cindex MH profile component
+@cindex MH profile component, @samp{Path:}
+
+Your MH environment includes your @dfn{MH profile} which is found in
+the file @file{~/.mh_profile}. This file contains a number of @dfn{MH
+profile components}. For example, the @samp{Path:} MH profile
+component contains the path to your mail directory, which is
+@file{~/Mail} by default.
 
 @cindex @command{mhparam}
 @cindex MH commands, @command{mhparam}
@@ -551,8 +590,9 @@
 @vindex mh-variant
 @vindex mh-variant-in-use
 
-The option @code{mh-variant} specifies the variant used by MH-E
-(@pxref{Options}). The default setting of this option is
+There are several options MH-E uses to interact with your MH
+installation. The option @code{mh-variant} specifies the variant used
+by MH-E (@pxref{Options}). The default setting of this option is
 @samp{Auto-detect} which means that MH-E will automatically choose the
 first of nmh, MH, or GNU mailutils that it finds in the directories
 listed in @code{mh-path} (which you can customize),
@@ -585,27 +625,6 @@
 @end quotation
 @sp 1
 
-@cindex @command{install-mh}
-@cindex MH commands, @command{install-mh}
-
-If you've never run MH before, you need to run @command{install-mh}
-from the shell before you continue. This sets up your personal MH
-environment@footnote{See the section
-@uref{@value{MH-BOOK-HOME}/../overall/setup.htm, Setting Up MH} in the
-MH book.}. If you don't, you'll be greeted with the error message:
-@samp{Install MH and run install-mh before running MH-E}.
-
-@cindex @samp{Path:} MH profile component
-@cindex MH profile
-@cindex MH profile component
-@cindex MH profile component, @samp{Path:}
-
-Your MH environment includes your @dfn{MH profile} which is found in
-the file @file{~/.mh_profile}. This file contains a number of @dfn{MH
-profile components}. For example, the @samp{Path:} MH profile
-component contains the path to your mail directory, which is
-@file{~/Mail} by default.
-
 @cindex MH profile component, @samp{Draft-Folder:}
 @cindex MH profile component, @samp{Path:}
 @cindex MH profile component, @samp{Previous-Sequence:}
@@ -8609,6 +8628,12 @@
 MH-E has to offer (although we have no doubt that you will be
 extremely interested in all new releases).
 
+@cindex Debian
+
+If you use Debian, you can install the Debian
+@uref{http://packages.debian.org/unstable/mail/mh-e, mh-e package}
+instead.
+
 @cindex files, @samp{MH-E-NEWS}
 @cindex files, @samp{README}
 @cindex news
--- a/man/misc.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/misc.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -825,7 +825,9 @@
 
   When you find the previous input you want, you can resubmit it by
 typing @key{RET}, or you can edit it first and then resubmit it if you
-wish.
+wish.  Any partial input you were composing before navigating the
+history list is restored when you go to the beginning or end of the
+history ring.
 
   Often it is useful to reexecute several successive shell commands that
 were previously executed in sequence.  To do this, first find and
--- a/man/msdog.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/msdog.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -5,22 +5,26 @@
 @node Emacs and Microsoft Windows, Manifesto, Mac OS, Top
 @appendix Emacs and Microsoft Windows
 @cindex Microsoft Windows
+@cindex MS-Windows, Emacs peculiarities
 
   This section describes peculiarities of using Emacs on Microsoft
-Windows.  Information about Emacs and Microsoft's older MS-DOS
-``operating system'' (also known as ``MS-DOG'') is now in a separate
-manual (@inforef{MS-DOG,, emacs-xtra}).
+Windows.  Some of these peculiarities are also relevant to Microsoft's
+older MS-DOS ``operating system'' (also known as ``MS-DOG'').
+However, Emacs features that are relevant @emph{only} to MS-DOS are
+described in a separate manual (@inforef{MS-DOG,, emacs-xtra}).
 
-  Iif you want to use Emacs on Windows, you would normally build Emacs
-specifically for Windows.  If you do that, the behavior is reasonably
-similar to what is documented in the rest of the manual, including
-support for long file names, multiple frames, scroll bars, mouse
-menus, and subprocesses.  However, a few special considerations apply,
-and they are described here.
+  The behavior of Emacs on MS-Windows is reasonably similar to what is
+documented in the rest of the manual, including support for long file
+names, multiple frames, scroll bars, mouse menus, and subprocesses.
+However, a few special considerations apply, and they are described
+here.
 
 @menu
 * Text and Binary::            Text files use CRLF to terminate lines.
+* Windows Files::              File-name conventions on Windows.
+* Windows HOME::               Where Emacs looks for your @file{.emacs}.
 * Windows Processes::          Running subprocesses on Windows.
+* Windows Printing::           How to specify the printer on MS-Windows.
 * Windows System Menu::        Controlling what the ALT key does.
 @end menu
 
@@ -29,11 +33,11 @@
 @cindex text and binary files on MS-DOS/MS-Windows
 
   GNU Emacs uses newline characters to separate text lines.  This is the
-convention used on GNU and Unix.
+convention used on GNU, Unix, and other Posix-compliant systems.
 
 @cindex end-of-line conversion on MS-DOS/MS-Windows
-  MS-DOS and MS-Windows normally use carriage-return linefeed, a
-two-character sequence, to separate text lines.  (Linefeed is the same
+  By contrast, MS-DOS and MS-Windows normally use carriage-return linefeed,
+a two-character sequence, to separate text lines.  (Linefeed is the same
 character as newline.)  Therefore, convenient editing of typical files
 with Emacs requires conversion of these end-of-line (EOL) sequences.
 And that is what Emacs normally does: it converts carriage-return
@@ -57,11 +61,11 @@
 
   The mode line indicates whether end-of-line translation was used for
 the current buffer.  If MS-DOS end-of-line translation is in use for the
-buffer, a backslash @samp{\} is displayed after the coding system
-mnemonic near the beginning of the mode line (@pxref{Mode Line}).  If no
-EOL translation was performed, the string @samp{(Unix)} is displayed
-instead of the backslash, to alert you that the file's EOL format is not
-the usual carriage-return linefeed.
+buffer, the MS-Windows build of Emacs displays a backslash @samp{\} after
+the coding system mnemonic near the beginning of the mode line
+(@pxref{Mode Line}).  If no EOL translation was performed, the string
+@samp{(Unix)} is displayed instead of the backslash, to alert you that the
+file's EOL format is not the usual carriage-return linefeed.
 
 @cindex DOS-to-Unix conversion of files
   To visit a file and specify whether it uses DOS-style or Unix-style
@@ -78,14 +82,14 @@
 
 @cindex untranslated file system
 @findex add-untranslated-filesystem
-  When you use NFS or Samba to access file systems that reside on
-computers using GNU or Unix systems, Emacs should not perform
-end-of-line translation on any files in these file systems---not even
-when you create a new file.  To request this, designate these file
-systems as @dfn{untranslated} file systems by calling the function
-@code{add-untranslated-filesystem}.  It takes one argument: the file
-system name, including a drive letter and optionally a directory.  For
-example,
+  When you use NFS, Samba, or some other similar method to access file
+systems that reside on computers using GNU or Unix systems, Emacs
+should not perform end-of-line translation on any files in these file
+systems---not even when you create a new file.  To request this,
+designate these file systems as @dfn{untranslated} file systems by
+calling the function @code{add-untranslated-filesystem}.  It takes one
+argument: the file system name, including a drive letter and
+optionally a directory.  For example,
 
 @example
 (add-untranslated-filesystem "Z:")
@@ -103,7 +107,7 @@
 system.
 
   Most often you would use @code{add-untranslated-filesystem} in your
-@file{_emacs} file, or in @file{site-start.el} so that all the users at
+@file{.emacs} file, or in @file{site-start.el} so that all the users at
 your site get the benefit of it.
 
 @findex remove-untranslated-filesystem
@@ -120,9 +124,9 @@
 @vindex file-name-buffer-file-type-alist
 @cindex binary files, on MS-DOS/MS-Windows
   Some kinds of files should not be converted at all, because their
-contents are not really text.  Therefore, Emacs on MS-DOS distinguishes
+contents are not really text.  Therefore, Emacs on MS-Windows distinguishes
 certain files as @dfn{binary files}.  (This distinction is not part of
-MS-DOS; it is made by Emacs only.)  Binary files include executable
+MS-Windows; it is made by Emacs only.)  Binary files include executable
 programs, compressed archives, etc.  Emacs uses the file name to decide
 whether to treat a file as binary: the variable
 @code{file-name-buffer-file-type-alist} defines the file-name patterns
@@ -132,29 +136,88 @@
 @code{no-conversion} coding system (@pxref{Coding Systems}) which turns
 off @emph{all} coding-system conversions, not only the EOL conversion.
 @code{file-name-buffer-file-type-alist} also includes file-name patterns
-for files which are known to be DOS-style text files with
+for files which are known to be Windows-style text files with
 carriage-return linefeed EOL format, such as @file{CONFIG.SYS}; Emacs
-always writes those files with DOS-style EOLs.
+always writes those files with Windows-style EOLs.
 
   If a file which belongs to an untranslated file system matches one of
 the file-name patterns in @code{file-name-buffer-file-type-alist}, the
 EOL conversion is determined by @code{file-name-buffer-file-type-alist}.
 
+@node Windows Files
+@section File Names on MS-Windows
+@cindex file names on MS-Windows
+
+  MS-Windows and MS-DOS normally use a backslash, @samp{\}, to
+separate name units within a file name, instead of the slash used on
+other systems.  Emacs on MS-DOS/MS-Windows permits use of either slash or
+backslash, and also knows about drive letters in file names.
+
+@cindex file-name completion, on MS-Windows
+  On MS-DOS/MS-Windows, file names are case-insensitive, so Emacs by
+default ignores letter-case in file names during completion.
+
+@node Windows HOME
+@section HOME Directory on MS-Windows
+@cindex @code{HOME} directory on MS-Windows
+
+  The MS-Windows equivalent of the @code{HOME} directory is the
+@dfn{user-specific application data directory}.  The actual location
+depends on your Windows version and system configuration; typical values
+are @file{C:\Documents and Settings\@var{username}\Application Data} on
+Windows 2K/XP and later, and either @file{C:\WINDOWS\Application Data}
+or @file{C:\WINDOWS\Profiles\@var{username}\Application Data} on the
+older Windows 9X/ME systems.
+
+@cindex init file @file{.emacs} on MS-Windows
+  The home directory is where your init file @file{.emacs} is stored.
+When Emacs starts, it first checks whether the environment variable
+@env{HOME} is set.  If it is, it looks for the init file in the
+directory pointed by @env{HOME}.  If @env{HOME} is not defined, Emacs
+checks for an existing @file{.emacs} file in @file{C:\}, the root
+directory of drive @file{C:}@footnote{
+The check in @file{C:\} is in preference to the application data
+directory for compatibility with older versions of Emacs, which didn't
+check the application data directory.
+}.  If there's no such file in @file{C:\}, Emacs next uses the Windows
+system calls to find out the exact location of your application data
+directory.  If that fails as well, Emacs falls back to @file{C:\}.
+
+  Whatever the final place is, Emacs sets the value of the @env{HOME}
+environment variable to point to it, and it will use that location for
+other files and directories it normally creates in the user's home
+directory.
+
+  You can always find out where Emacs thinks is your home directory's
+location by typing @kbd{C-x d ~/ @key{RET}}.  This should present the
+list of files in the home directory, and show its full name on the
+first line.  Likewise, to visit your init file, type @kbd{C-x C-f
+~/.emacs @key{RET}}.
+
+@cindex @file{_emacs} init file, MS-Windows
+  Because MS-DOS does not allow file names with leading dots, and
+because older Windows systems made it hard to create files with such
+names, the Windows port of Emacs supports an alternative name
+@file{_emacs} as a fallback, if such a file exists in the home
+directory, whereas @file{.emacs} does not.
+
 @node Windows Processes
-@section Subprocesses on Windows 9X/ME and Windows NT/2K
+@section Subprocesses on Windows 9X/ME and Windows NT/2K/XP
+@cindex subprocesses on MS-Windows
 
+@cindex DOS applications, running from Emacs
   Emacs compiled as a native Windows application (as opposed to the DOS
 version) includes full support for asynchronous subprocesses.
 In the Windows version, synchronous and asynchronous subprocesses work
 fine on both
-Windows 9X and Windows NT/2K as long as you run only 32-bit Windows
+Windows 9X/ME and Windows NT/2K/XP as long as you run only 32-bit Windows
 applications.  However, when you run a DOS application in a subprocess,
 you may encounter problems or be unable to run the application at all;
 and if you run two DOS applications at the same time in two
 subprocesses, you may have to reboot your system.
 
 Since the standard command interpreter (and most command line utilities)
-on Windows 95 are DOS applications, these problems are significant when
+on Windows 9X are DOS applications, these problems are significant when
 using that system.  But there's nothing we can do about them; only
 Microsoft can fix them.
 
@@ -174,13 +237,14 @@
 subprocesses, the second one that is started will be suspended until the
 first one finishes, even if either or both of them are asynchronous.
 
+@cindex kill DOS application
 If you can go to the first subprocess, and tell it to exit, the second
 subprocess should continue normally.  However, if the second subprocess
 is synchronous, Emacs itself will be hung until the first subprocess
 finishes.  If it will not finish without user input, then you have no
 choice but to reboot if you are running on Windows 9X.  If you are
-running on Windows NT/2K, you can use a process viewer application to kill
-the appropriate instance of ntvdm instead (this will terminate both DOS
+running on Windows NT/2K/XP, you can use a process viewer application to kill
+the appropriate instance of NTVDM instead (this will terminate both DOS
 subprocesses).
 
 If you have to reboot Windows 9X in this situation, do not use the
@@ -189,16 +253,156 @@
 @code{Shutdown}.  That usually works, although it may take a few minutes
 to do its job.
 
+@node Windows Printing
+@section Printing and MS-Windows
+
+  Printing commands, such as @code{lpr-buffer} (@pxref{Printing}) and
+@code{ps-print-buffer} (@pxref{PostScript}) work in MS-DOS and
+MS-Windows by sending the output to one of the printer ports, if a
+Posix-style @code{lpr} program is unavailable.  The same Emacs
+variables control printing on all systems, but in some cases they have
+different default values on MS-DOS and MS-Windows.
+
+  Emacs on Windows automatically determines your default printer and
+sets the variable @var{printer-name} to that printer's name.  But in
+some rare cases this can fail, or you may wish to use a different
+printer from within Emacs.  The rest of this section explains how to
+tell Emacs which printer to use.
+
+@vindex printer-name@r{, (MS-DOS/MW-Windows)}
+  If you want to use your local printer, then set the Lisp variable
+@code{lpr-command} to @code{""} (its default value on Windows) and
+@code{printer-name} to the name of the printer port---for example,
+@code{"PRN"}, the usual local printer port or @code{"LPT2"}, or
+@code{"COM1"} for a serial printer.  You can also set
+@code{printer-name} to a file name, in which case ``printed'' output
+is actually appended to that file.  If you set @code{printer-name} to
+@code{"NUL"}, printed output is silently discarded (sent to the system
+null device).
+
+  You can also use a printer shared by another machine by setting
+@code{printer-name} to the UNC share name for that printer---for
+example, @code{"//joes_pc/hp4si"}.  (It doesn't matter whether you use
+forward slashes or backslashes here.)  To find out the names of shared
+printers, run the command @samp{net view} from the command prompt to
+obtain a list of servers, and @samp{net view @var{server-name}} to see
+the names of printers (and directories) shared by that server.
+Alternatively, click the @samp{Network Neighborhood} icon on your
+desktop, and look for machines which share their printers via the
+network.
+
+@cindex @samp{net use}, and printing on MS-Windows
+@cindex networked printers (MS-Windows)
+  If the printer doesn't appear in the output of @samp{net view}, or
+if setting @code{printer-name} to the UNC share name doesn't produce a
+hardcopy on that printer, you can use the @samp{net use} command to
+connect a local print port such as @code{"LPT2"} to the networked
+printer.  For example, typing @kbd{net use LPT2: \\joes_pc\hp4si}@footnote{
+Note that the @samp{net use} command requires the UNC share name to be
+typed with the Windows-style backslashes, while the value of
+@code{printer-name} can be set with either forward- or backslashes.}
+causes Windows to @dfn{capture} the @code{LPT2} port and redirect the
+printed material to the printer connected to the machine @code{joes_pc}.
+After this command, setting @code{printer-name} to @code{"LPT2"}
+should produce the hardcopy on the networked printer.
+
+  With some varieties of Windows network software, you can instruct
+Windows to capture a specific printer port such as @code{"LPT2"}, and
+redirect it to a networked printer via the @w{@code{Control
+Panel->Printers}} applet instead of @samp{net use}.
+
+  If you set @code{printer-name} to a file name, it's best to use an
+absolute file name.  Emacs changes the working directory according to
+the default directory of the current buffer, so if the file name in
+@code{printer-name} is relative, you will end up with several such
+files, each one in the directory of the buffer from which the printing
+was done.
+
+@findex print-buffer @r{(MS-DOS)}
+@findex print-region @r{(MS-DOS)}
+@vindex lpr-headers-switches @r{(MS-DOS)}
+  The commands @code{print-buffer} and @code{print-region} call the
+@code{pr} program, or use special switches to the @code{lpr} program, to
+produce headers on each printed page.  MS-DOS and MS-Windows don't
+normally have these programs, so by default, the variable
+@code{lpr-headers-switches} is set so that the requests to print page
+headers are silently ignored.  Thus, @code{print-buffer} and
+@code{print-region} produce the same output as @code{lpr-buffer} and
+@code{lpr-region}, respectively.  If you do have a suitable @code{pr}
+program (for example, from GNU Coreutils), set
+@code{lpr-headers-switches} to @code{nil}; Emacs will then call
+@code{pr} to produce the page headers, and print the resulting output as
+specified by @code{printer-name}.
+
+@vindex print-region-function @r{(MS-DOS)}
+@cindex lpr usage under MS-DOS
+@vindex lpr-command @r{(MS-DOS)}
+@vindex lpr-switches @r{(MS-DOS)}
+  Finally, if you do have an @code{lpr} work-alike, you can set the
+variable @code{lpr-command} to @code{"lpr"}.  Then Emacs will use
+@code{lpr} for printing, as on other systems.  (If the name of the
+program isn't @code{lpr}, set @code{lpr-command} to specify where to
+find it.)  The variable @code{lpr-switches} has its standard meaning
+when @code{lpr-command} is not @code{""}.  If the variable
+@code{printer-name} has a string value, it is used as the value for the
+@code{-P} option to @code{lpr}, as on Unix.
+
+@findex ps-print-buffer @r{(MS-DOS)}
+@findex ps-spool-buffer @r{(MS-DOS)}
+@vindex ps-printer-name @r{(MS-DOS)}
+@vindex ps-lpr-command @r{(MS-DOS)}
+@vindex ps-lpr-switches @r{(MS-DOS)}
+  A parallel set of variables, @code{ps-lpr-command},
+@code{ps-lpr-switches}, and @code{ps-printer-name} (@pxref{PostScript
+Variables}), defines how PostScript files should be printed.  These
+variables are used in the same way as the corresponding variables
+described above for non-PostScript printing.  Thus, the value of
+@code{ps-printer-name} is used as the name of the device (or file) to
+which PostScript output is sent, just as @code{printer-name} is used
+for non-PostScript printing.  (There are two distinct sets of
+variables in case you have two printers attached to two different
+ports, and only one of them is a PostScript printer.)
+
+  The default value of the variable @code{ps-lpr-command} is @code{""},
+which causes PostScript output to be sent to the printer port specified
+by @code{ps-printer-name}, but @code{ps-lpr-command} can also be set to
+the name of a program which will accept PostScript files.  Thus, if you
+have a non-PostScript printer, you can set this variable to the name of
+a PostScript interpreter program (such as Ghostscript).  Any switches
+that need to be passed to the interpreter program are specified using
+@code{ps-lpr-switches}.  (If the value of @code{ps-printer-name} is a
+string, it will be added to the list of switches as the value for the
+@code{-P} option.  This is probably only useful if you are using
+@code{lpr}, so when using an interpreter typically you would set
+@code{ps-printer-name} to something other than a string so it is
+ignored.)
+
+  For example, to use Ghostscript for printing on the system's default
+printer, put this in your @file{.emacs} file:
+
+@example
+(setq ps-printer-name t)
+(setq ps-lpr-command "D:/gs6.01/bin/gswin32c.exe")
+(setq ps-lpr-switches '("-q" "-dNOPAUSE" "-dBATCH"
+			"-sDEVICE=mswinpr2"
+			"-sPAPERSIZE=a4"))
+@end example
+
+@noindent
+(This assumes that Ghostscript is installed in the
+@file{D:/gs6.01} directory.)
+
 @node Windows System Menu
 @section Using the System Menu on Windows
+@cindex @code{Alt} key invokes menu (Windows)
 
 Emacs compiled as a native Windows application normally turns off the
-Windows feature that tapping the @key{ALT}
-key invokes the Windows menu.  The reason is that the @key{ALT} also
-serves as @key{META} in Emacs.  When using Emacs, users often press the
-@key{META} key temporarily and then change their minds; if this has the
-effect of bringing up the Windows menu, it alters the meaning of
-subsequent commands.  Many users find this frustrating.
+Windows feature that tapping the @key{ALT} key invokes the Windows
+menu.  The reason is that the @key{ALT} serves as @key{META} in Emacs.
+When using Emacs, users often press the @key{META} key temporarily and
+then change their minds; if this has the effect of bringing up the
+Windows menu, it alters the meaning of subsequent commands.  Many
+users find this frustrating.
 
 @vindex w32-pass-alt-to-system
 You can re-enable Windows' default handling of tapping the @key{ALT} key
--- a/man/org.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/org.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -4,7 +4,7 @@
 @setfilename ../info/org
 @settitle Org Mode Manual
 
-@set VERSION 4.24
+@set VERSION 4.26
 @set DATE April 2006
 
 @dircategory Emacs
@@ -76,13 +76,13 @@
 
 @menu
 * Introduction::                Getting started
-* Document Structure::          A tree works like your brain
+* Document structure::          A tree works like your brain
 * Tables::                      Pure magic for quick formatting
 * Hyperlinks::                  Notes in context
 * TODO items::                  Every tree branch can be a TODO item
 * Timestamps::                  Assign date and time to items
 * Tags::                        Tagging headlines and matching sets of tags
-* Agenda Views::                Collecting information into views
+* Agenda views::                Collecting information into views
 * Exporting::                   Sharing and publishing of notes
 * Miscellaneous::               All the rest which did not fit elsewhere
 * Index::                       The fast road to specific information
@@ -97,7 +97,7 @@
 * Installation and activation::  How to install Org-mode
 * Feedback::                    Bug reports, ideas, patches etc.
 
-Document Structure
+Document structure
 
 * Outlines::                    Org-mode is based on outline-mode
 * Headlines::                   How to typeset org-tree headlines
@@ -106,7 +106,7 @@
 * Structure editing::           Changing sequence and level of headlines
 * Archiving::                   Move done task trees to a different place
 * Sparse trees::                Matches embedded in context
-* Plain Lists::                 Editing hand-formatted lists
+* Plain lists::                 Editing hand-formatted lists
 
 Tables
 
@@ -130,7 +130,7 @@
 * Link format::                 How links in Org-mode are formatted
 * Internal links::              Links to other places in the current file
 * External links::              URL-like links to the world
-* Managing links::              Creating, inserting and following
+* Handling links::              Creating, inserting and following
 * Search Options::              Linking to a specific location
 * Remember::                    Org-trees store quick notes
 
@@ -163,11 +163,11 @@
 * Setting tags::                How to assign tags to a headline
 * Tag searches::                Searching for combinations of tags
 
-Agenda Views
+Agenda views
 
 * Agenda files::                Files being searched for agenda information
 * Agenda dispatcher::           Keyboard access to agenda views
-* Weekly/Daily Agenda::         The calendar page with current tasks
+* Weekly/Daily agenda::         The calendar page with current tasks
 * Global TODO list::            All unfinished action items
 * Matching headline tags::      Structured information with fine-tuned search
 * Timeline::                    Time-sorted view for single file
@@ -210,7 +210,7 @@
 @end detailmenu
 @end menu
 
-@node Introduction, Document Structure, Top, Top
+@node Introduction, Document structure, Top, Top
 @chapter Introduction
 @cindex introduction
 
@@ -242,10 +242,10 @@
 iCalendar file.
 
 Org-mode keeps simple things simple.  When first fired up, it should
-feel like a simple but easy to use outliner.  Complexity is not
-imposed, but a large amount of functionality is available when you
-need it.  Org-mode can be used on different levels and in different
-ways, for example:
+feel like a simple, easy to use outliner.  Complexity is not imposed,
+but a large amount of functionality is available when you need it.
+Org-mode can be used on different levels and in different ways, for
+example:
 
 @example
 @r{@bullet{} as an outline extension with visibility cycling and structure editing}
@@ -339,7 +339,7 @@
 @end enumerate
 @noindent Thank you for helping to improve this mode.
 
-@node Document Structure, Tables, Introduction, Top
+@node Document structure, Tables, Introduction, Top
 @chapter Document Structure
 @cindex document structure
 @cindex structure of document
@@ -355,10 +355,10 @@
 * Structure editing::           Changing sequence and level of headlines
 * Archiving::                   Move done task trees to a different place
 * Sparse trees::                Matches embedded in context
-* Plain Lists::                 Editing hand-formatted lists
+* Plain lists::                 Editing hand-formatted lists
 @end menu
 
-@node Outlines, Headlines, Document Structure, Document Structure
+@node Outlines, Headlines, Document structure, Document structure
 @section Outlines
 @cindex outlines
 @cindex outline-mode
@@ -373,7 +373,7 @@
 single command @command{org-cycle}, which is bound to the @key{TAB}
 key.
 
-@node Headlines, Visibility cycling, Outlines, Document Structure
+@node Headlines, Visibility cycling, Outlines, Document structure
 @section Headlines
 @cindex headlines
 @cindex outline tree
@@ -396,7 +396,7 @@
 outline that has whitespace followed by a single star as headline
 starters.  @ref{Clean view} describes a setup to realize this.
 
-@node Visibility cycling, Motion, Headlines, Document Structure
+@node Visibility cycling, Motion, Headlines, Document structure
 @section Visibility cycling
 @cindex cycling, visibility
 @cindex visibility cycling
@@ -458,7 +458,7 @@
 #+STARTUP: showall
 @end example
 
-@node Motion, Structure editing, Visibility cycling, Document Structure
+@node Motion, Structure editing, Visibility cycling, Document structure
 @section Motion
 @cindex motion, between headlines
 @cindex jumping, to headlines
@@ -491,7 +491,7 @@
 visible.
 @end table
 
-@node Structure editing, Archiving, Motion, Document Structure
+@node Structure editing, Archiving, Motion, Document structure
 @section Structure editing
 @cindex structure editing
 @cindex headline, promotion and demotion
@@ -507,9 +507,14 @@
 @kindex M-@key{RET}
 @item M-@key{RET}
 Insert new heading with same level as current.  If the cursor is in a
-plain list item, a new item is created.  To force creation of a new
-headline, use a prefix arg, or first press @key{RET} to get to the
-beginning of the next line.
+plain list item, a new item is created (@pxref{Plain lists}).  To force
+creation of a new headline, use a prefix arg, or first press @key{RET}
+to get to the beginning of the next line.  When this command is used in
+the middle of a line, the line is split and the rest of the line becomes
+the new headline.  If the command is used at the beginning of a
+headline, the new headline is created before the current line.  It at
+the beginning of any other line, the content of that line is made the
+new heading.
 @kindex M-S-@key{RET}
 @item M-S-@key{RET}
 Insert new TODO entry with same level as current heading.
@@ -559,7 +564,7 @@
 inside a table (@pxref{Tables}), the Meta-Cursor keys have different
 functionality.
 
-@node Archiving, Sparse trees, Structure editing, Document Structure
+@node Archiving, Sparse trees, Structure editing, Document structure
 @section Archiving
 @cindex archiving
 @cindex filing subtrees
@@ -583,7 +588,7 @@
 agenda, archiving to a different file is a good way to keep archived
 trees from contributing agenda items.
 
-@node Sparse trees, Plain Lists, Archiving, Document Structure
+@node Sparse trees, Plain lists, Archiving, Document structure
 @section Sparse trees
 @cindex sparse trees
 @cindex trees, sparse
@@ -637,14 +642,14 @@
 To print a sparse tree, you can use the Emacs command
 @code{ps-print-buffer-with-faces} which does not print invisible parts
 of the document @footnote{This does not work under XEmacs, because
-XEmacs uses selective display for outlining, not text properties}.
+XEmacs uses selective display for outlining, not text properties.}.
 Or you can use the command @kbd{C-c C-x v} to copy the visible part of
 the document to another file (extension @file{.txt}) which can then be
 printed in any desired way.
 
 
-@node Plain Lists,  , Sparse trees, Document Structure
-@section Plain Lists
+@node Plain lists,  , Sparse trees, Document structure
+@section Plain lists
 @cindex plain lists
 @cindex lists, plain
 @cindex lists, ordered
@@ -673,6 +678,7 @@
 less.  For example:
 
 @example
+@group
 ** Lord of the Rings
 My favorite scenes are (in this order)
 1. Eowyns fight with the witch king
@@ -682,6 +688,8 @@
 3. Peter Jackson being shot by Legolas
     - on DVD only
    He makes a really funny face when it happens.
+But in the end, not individual scenes matter but the film as a whole.
+@end group
 @end example
 
 Org-mode supports these lists by tuning filling and wrapping commands
@@ -699,7 +707,14 @@
 completely separated.
 @kindex M-@key{RET}
 @item M-@key{RET}
-Insert new item at current level.  With prefix arg, for a new heading.
+Insert new item at current level.  With prefix arg, force a new heading
+(@pxref{Structure editing}).  If this command is used in the middle of a
+line, the line is @emph{split} and the rest of the line becomes the new
+item.  If this command is executed in the @emph{whitespace before a bullet or
+number}, the new item is created @emph{before} the current item.  If the
+command is executed in the white space before the text that is part of
+an item but does not contain the bullet, a bullet is added to the
+current line.
 @kindex M-S-@key{up}
 @kindex M-S-@key{down}
 @item M-S-@key{up}
@@ -722,7 +737,7 @@
 Renumber the ordered list at the cursor.
 @end table
 
-@node Tables, Hyperlinks, Document Structure, Top
+@node Tables, Hyperlinks, Document structure, Top
 @chapter Tables
 @cindex tables
 @cindex editing tables
@@ -986,9 +1001,10 @@
 Sometimes a single field or a few fields need to carry more text,
 leading to inconveniently wide columns.  To limit@footnote{This feature
 does not work on XEmacs.} the width of a column, one field anywhere in
-the column must carry the string @samp{<N>} where @samp{N} is an integer
-specifying the width of the column in characters.  The next re-align
-will then set the width of this column to no more than this value.
+the column may contain just the string @samp{<N>} where @samp{N} is an
+integer specifying the width of the column in characters.  The next
+re-align will then set the width of this column to no more than this
+value.
 
 @example
 |---+------------------------------|               |---+--------|
@@ -1360,7 +1376,7 @@
 * Link format::                 How links in Org-mode are formatted
 * Internal links::              Links to other places in the current file
 * External links::              URL-like links to the world
-* Managing links::              Creating, inserting and following
+* Handling links::              Creating, inserting and following
 * Search Options::              Linking to a specific location
 * Remember::                    Org-trees store quick notes
 @end menu
@@ -1401,26 +1417,28 @@
 @cindex links, internal
 @cindex CamelCase links
 
-If the link text does not look like a URL, links are considered to be
-internal in the current file.  Links such as @samp{[[My Target]]} or
-@samp{[[My Target][Find my target]]} lead to a text search in the
-current file.  The link can be followed with @kbd{C-c C-o} when the
-cursor is on the link, or with a mouse click (@pxref{Managing links}).
-The preferred match for such a link is a dedicated target: The same
-string in double angular brackets.  Targets may be located anywhere,
-often it is convenient to put them into a comment line, for example
+If the link does not look like a URL, it is considered to be internal in
+the current file.  Links such as @samp{[[My Target]]} or @samp{[[My
+Target][Find my target]]} lead to a text search in the current file.
+The link can be followed with @kbd{C-c C-o} when the cursor is on the
+link, or with a mouse click (@pxref{Handling links}).  The preferred
+match for such a link is a dedicated target: The same string in double
+angular brackets.  Targets may be located anywhere, often it is
+convenient to put them into a comment line, for example
 
 @example
 # <<My Target>>
 @end example
 
+@noindent In HTML export (@pxref{HTML export}), such targets will become
+named anchors for direct access through @samp{http} links.
+
 If no dedicated target exists, Org-mode will search for the words in the
-link, often removing the need for a dedicated target.  In the above
-example the search would be for @samp{my target}.  Links starting with a
-star like @samp{*My Target} restrict the search to headlines.  When
-searching, Org-mode will first try an exact match, but then move on to
-more and more lenient searches.  For example, the link @samp{[[*My
-Targets]]} will find any of the following:
+link.  In the above example the search would be for @samp{my target}.
+Links starting with a star like @samp{*My Target} restrict the search to
+headlines.  When searching, Org-mode will first try an exact match, but
+then move on to more and more lenient searches.  For example, the link
+@samp{[[*My Targets]]} will find any of the following:
 
 @example
 ** My targets
@@ -1431,7 +1449,7 @@
 To insert a link targeting a headline, in-buffer completion can be used.
 Just type a star followed by a few optional letters into the buffer and
 press @kbd{M-@key{TAB}}.  All headlines in the current buffer will be
-offered as completions.  @xref{Managing links}, for more commands
+offered as completions.  @xref{Handling links}, for more commands
 creating links.
 
 Following a link pushes a mark onto Org-mode's own mark ring.  You can
@@ -1469,7 +1487,7 @@
 text search such that @samp{CamelCaseLink} is equivalent to
 @samp{[[camel case link]]}.
 
-@node External links, Managing links, Internal links, Hyperlinks
+@node External links, Handling links, Internal links, Hyperlinks
 @section External links
 @cindex links, external
 @cindex external links
@@ -1525,8 +1543,8 @@
 @samp{bbdb:Richard Stallman}) or to remove ambiguities about the end of
 the link, enclose them in angular brackets.
 
-@node Managing links, Search Options, External links, Hyperlinks
-@section Managing links
+@node Handling links, Search Options, External links, Hyperlinks
+@section Handling links
 
 Org-mode provides methods to create a link in the correct syntax, to
 insert it into an org-mode file, and to follow the link.
@@ -1537,15 +1555,17 @@
 @item C-c l
 Store a link to the current location.  This is a @emph{global} command
 which can be used in any buffer to create a link.  The link will be
-stored for later insertion into an Org-mode buffer (see below).  For VM,
-RMAIL, WANDERLUST, MH-E, GNUS and BBDB buffers, the link will point to
-the current article/entry.  For W3 and W3M buffers, the link goes to the
-current URL.  For Org-mode files, the current headline is targeted.  For
-any other files, the link will point to the file, with a search string
-(@pxref{Search Options}) pointing to the contents of the current line.
-If there is an active region, the selected words will form the basis of
-the search string.  The key binding @kbd{C-c l} is only a suggestion -
-see @ref{Installation and activation}.
+stored for later insertion into an Org-mode buffer (see below).  For
+Org-mode files, if there is a @samp{<<target>>} at the cursor, the link
+points to the target.  Otherwise it points to the current headline.  For
+VM, RMAIL, WANDERLUST, MH-E, GNUS and BBDB buffers, the link will
+indicate to the current article/entry.  For W3 and W3M buffers, the link
+goes to the current URL.  For any other files, the link will point to
+the file, with a search string (@pxref{Search Options}) pointing to the
+contents of the current line.  If there is an active region, the
+selected words will form the basis of the search string.  The key
+binding @kbd{C-c l} is only a suggestion - see @ref{Installation and
+activation}.
 
 @kindex C-c C-l
 @cindex link completion
@@ -1556,12 +1576,12 @@
 You can just type a link, using text for an internal link, or one of the
 link type prefixes mentioned in the examples above.  Through completion,
 all links stored during the current session can be accessed.  The link
-will be formatted as given in the variable @code{org-link-format} and
-inserted into the buffer, along with a descriptive text.  Note that you
-don't have to use this command to insert a link.  Links in Org-mode are
-plain text, and you can type or paste them straight into the buffer.
-By using this command, the links are automatically enclosed in double
-brackets, and you will be asked for the optional descriptive text.
+will be inserted into the buffer, along with a descriptive text.  Note
+that you don't have to use this command to insert a link.  Links in
+Org-mode are plain text, and you can type or paste them straight into
+the buffer.  By using this command, the links are automatically enclosed
+in double brackets, and you will be asked for the optional descriptive
+text.
 
 @kindex C-u C-c C-l
 @cindex file name completion
@@ -1571,9 +1591,10 @@
 a file will be inserted and you may use file name completion to select
 the name of the file.  The path to the file is inserted relative to the
 directory of the current org file, if the linked file is in the current
-directory or in a subdirectory of it.  Otherwise an absolute path, if
-possible with @samp{~/} for your home directory is used.  You can force
-an absolute path with two @kbd{C-u} prefixes.
+directory or in a subdirectory of it, or if the path is written relative
+to the current directory using @samp{../}.  Otherwise an absolute path
+is used, if possible with @samp{~/} for your home directory.  You can
+force an absolute path with two @kbd{C-u} prefixes.
 
 @item C-c C-l @r{with cursor on existing link}
 When the cursor is on an existing link, @kbd{C-c C-l} allows to edit the
@@ -1622,7 +1643,7 @@
 @end table
 
 
-@node Search Options, Remember, Managing links, Hyperlinks
+@node Search Options, Remember, Handling links, Hyperlinks
 @section Search options in file links
 @cindex search option in file links
 @cindex file links, searching
@@ -1648,7 +1669,9 @@
 @item My Target
 Search for a link target @samp{<<My Target>>}, or do a text search for
 @samp{my target}, similar to the search in internal links, see
-@ref{Internal links}.
+@ref{Internal links}.  In HTML export (@pxref{HTML export}), such a file
+link will become an html reference to the corresponding named anchor in
+the linked file.
 @item *My Target
 In an Org-mode file, restrict search to headlines.
 @item /regexp/
@@ -1821,13 +1844,13 @@
 @kindex C-c a t
 @item C-c a t
 Show the global TODO list.  This collects the TODO items from all
-agenda files (@pxref{Agenda Views}) into a single buffer.  The buffer is in
+agenda files (@pxref{Agenda views}) into a single buffer.  The buffer is in
 @code{agenda-mode}, so there are commands to examine and manipulate
 the TODO entries directly from that buffer (@pxref{Agenda commands}).
 @xref{Global TODO list}, for more information.
-@item @code{org-agenda-include-all-todo}
-If you would like to have all your TODO items listed as part of your
-agenda, customize the variable @code{org-agenda-include-all-todo}.
+@c @item @code{org-agenda-include-all-todo}
+@c If you would like to have all your TODO items listed as part of your
+@c agenda, customize the variable @code{org-agenda-include-all-todo}.
 @end table
 
 @node Progress logging, TODO extensions, TODO basics, TODO items
@@ -1847,7 +1870,7 @@
 @samp{CLOSED: [timestamp]} will be inserted just after the headline.
 If you turn the entry back into a TODO item again through further
 state cycling, that line will be removed again.  In the timeline
-(@pxref{Timeline}) and in the agenda (@pxref{Weekly/Daily Agenda}),
+(@pxref{Timeline}) and in the agenda (@pxref{Weekly/Daily agenda}),
 you can then use the @kbd{L} key to display the TODO items closed on
 each day, giving you an overview of what has been done on a day.
 
@@ -1989,7 +2012,7 @@
 With its standard setup, Org-mode supports priorities @samp{A},
 @samp{B}, and @samp{C}.  @samp{A} is the highest priority.  An entry
 without a cookie is treated as priority @samp{B}.  Priorities make a
-difference only in the agenda (@pxref{Weekly/Daily Agenda}).
+difference only in the agenda (@pxref{Weekly/Daily agenda}).
 
 @table @kbd
 @kindex @kbd{C-c ,}
@@ -2034,14 +2057,16 @@
 special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16
 Tue 09:39>}.  A time stamp can appear anywhere in the headline or body
 of an org-tree entry.  Its presence allows entries to be shown on specific
-dates in the agenda (@pxref{Weekly/Daily Agenda}).  We distinguish:
+dates in the agenda (@pxref{Weekly/Daily agenda}).  We distinguish:
 
 @table @var
 @cindex timestamp
 @item TIMESTAMP
-A simple time stamp just assigns a date/time to an item.  In the
-timeline and agenda displays, the headline of the entry will be shown
-exactly on that date.
+A simple time stamp just assigns a date/time to an item.  This is just
+like writing down an appointment in a paper agenda, or like writing down
+an event in a diary, when you want to take not of when something
+happened.  In the timeline and agenda displays, the headline of an entry
+associated with a plain time stamp will be shown exactly on that date.
 
 @item TIMERANGE
 @cindex timerange
@@ -2055,6 +2080,21 @@
    <2004-08-23 Mon>--<2004-08-26 Thu>
 @end example
 
+@item SCHEDULED
+@cindex SCHEDULED keyword
+If a time stamp is preceded by the word @samp{SCHEDULED:}, it means you
+are planning to start working on that task on the given date. So this is
+not about recording an event, but about planning your work.  The
+headline will be listed under the given date.  In addition, a reminder
+that the scheduled date has passed will be present in the compilation
+for @emph{today}, until the entry is marked DONE.  I.e., the task will
+automatically be forwarded until completed.
+
+@example
+*** TODO Call Trillian for a date on New Years Eve.
+    SCHEDULED: <2004-12-25 Sat>
+@end example
+
 @item DEADLINE
 @cindex DEADLINE keyword
 If a time stamp is preceded by the word @samp{DEADLINE:}, the task
@@ -2069,15 +2109,6 @@
     The editor in charge is <bbdb:Ford Prefect>
     DEADLINE: <2004-02-29 Sun>
 @end example
-
-@item SCHEDULED
-@cindex SCHEDULED keyword
-If a time stamp is preceded by the word @samp{SCHEDULED:}, it means
-you are planning to start working on that task on the given date.  The
-headline will be listed under the given date.  In addition, a reminder
-that the scheduled date has passed will be present in the compilation
-for @emph{today}, until the entry is marked DONE.  I.e., the
-task will automatically be forwarded.
 @end table
 
 @node Creating timestamps,  , Time stamps, Timestamps
@@ -2120,7 +2151,7 @@
 @kindex C-c C-o
 @item C-c C-o
 Access the agenda for the date given by the time stamp at point
-(@pxref{Weekly/Daily Agenda}).
+(@pxref{Weekly/Daily agenda}).
 
 @kindex C-c C-d
 @item C-c C-d
@@ -2207,7 +2238,7 @@
 Choose date in calendar (only if nothing typed into minibuffer).
 @end table
 
-@node Tags, Agenda Views, Timestamps, Top
+@node Tags, Agenda views, Timestamps, Top
 @chapter Tags
 @cindex tags
 @cindex headline tagging
@@ -2311,7 +2342,7 @@
 @samp{WORK|LAPTOP&NIGHT} requires that the @samp{:LAPTOP:} lines are
 also tagged @samp{NIGHT}.
 
-@node Agenda Views, Exporting, Tags, Top
+@node Agenda views, Exporting, Tags, Top
 @chapter Agenda Views
 @cindex agenda views
 
@@ -2345,14 +2376,14 @@
 @menu
 * Agenda files::                Files being searched for agenda information
 * Agenda dispatcher::           Keyboard access to agenda views
-* Weekly/Daily Agenda::         The calendar page with current tasks
+* Weekly/Daily agenda::         The calendar page with current tasks
 * Global TODO list::            All unfinished action items
 * Matching headline tags::      Structured information with fine-tuned search
 * Timeline::                    Time-sorted view for single file
 * Agenda commands::             Remote editing of org trees
 @end menu
 
-@node Agenda files, Agenda dispatcher, Agenda Views, Agenda Views
+@node Agenda files, Agenda dispatcher, Agenda views, Agenda views
 @section Agenda files
 
 The information to be shown is collected from all @emph{agenda files},
@@ -2385,7 +2416,7 @@
 The Org menu contains the current list of files and can be used
 to visit any of them.
 
-@node Agenda dispatcher, Weekly/Daily Agenda, Agenda files, Agenda Views
+@node Agenda dispatcher, Weekly/Daily agenda, Agenda files, Agenda views
 @section The agenda dispatcher
 @cindex agenda dispatcher
 @cindex dispatching agenda commands
@@ -2400,7 +2431,7 @@
 following default commands:
 @table @kbd
 @item a
-Create the calendar-like agenda (@pxref{Weekly/Daily Agenda}).
+Create the calendar-like agenda (@pxref{Weekly/Daily agenda}).
 @item t / T
 Create a list of all TODO items (@pxref{Global TODO list}).
 @item m / M
@@ -2438,7 +2469,7 @@
 @samp{FIXME}.  For more information, look at the documentation string
 of the variable @code{org-agenda-custom-commands}.
 
-@node Weekly/Daily Agenda, Global TODO list, Agenda dispatcher, Agenda Views
+@node Weekly/Daily agenda, Global TODO list, Agenda dispatcher, Agenda views
 @section The weekly/daily agenda
 @cindex agenda
 
@@ -2468,7 +2499,7 @@
 * Sorting of agenda items::     The order of things
 @end menu
 
-@node Categories, Time-of-day specifications, Weekly/Daily Agenda, Weekly/Daily Agenda
+@node Categories, Time-of-day specifications, Weekly/Daily agenda, Weekly/Daily agenda
 @subsection Categories
 
 @cindex category
@@ -2485,7 +2516,7 @@
 before the first CATEGORY line).  The display in the agenda buffer looks
 best if the category is not longer than 10 characters.
 
-@node Time-of-day specifications, Calendar/Diary integration, Categories, Weekly/Daily Agenda
+@node Time-of-day specifications, Calendar/Diary integration, Categories, Weekly/Daily agenda
 @subsection Time-of-Day Specifications
 
 Org-mode checks each agenda item for a time-of-day specification.  The
@@ -2533,7 +2564,7 @@
 @code{org-agenda-time-grid}.
 
 
-@node Calendar/Diary integration, Sorting of agenda items, Time-of-day specifications, Weekly/Daily Agenda
+@node Calendar/Diary integration, Sorting of agenda items, Time-of-day specifications, Weekly/Daily agenda
 @subsection Calendar/Diary integration
 @cindex calendar integration
 @cindex diary integration
@@ -2564,7 +2595,7 @@
 calendars, respectively.  @kbd{c} can be used to switch back and forth
 between calendar and agenda.
 
-@node Sorting of agenda items,  , Calendar/Diary integration, Weekly/Daily Agenda
+@node Sorting of agenda items,  , Calendar/Diary integration, Weekly/Daily agenda
 @subsection Sorting of agenda items
 @cindex sorting, of agenda items
 @cindex priorities, of agenda items
@@ -2583,7 +2614,7 @@
 @code{org-agenda-sorting-strategy}.
 
 
-@node Global TODO list, Matching headline tags, Weekly/Daily Agenda, Agenda Views
+@node Global TODO list, Matching headline tags, Weekly/Daily agenda, Agenda views
 @section The global TODO list
 @cindex global TODO list
 @cindex TODO list, global
@@ -2595,7 +2626,7 @@
 @kindex C-c a t
 @item C-c a t
 Show the global TODO list.  This collects the TODO items from all
-agenda files (@pxref{Agenda Views}) into a single buffer.  The buffer is in
+agenda files (@pxref{Agenda views}) into a single buffer.  The buffer is in
 @code{agenda-mode}, so there are commands to examine and manipulate
 the TODO entries directly from that buffer (@pxref{Agenda commands}).
 @xref{Global TODO list}, for more information.
@@ -2616,7 +2647,7 @@
 TODO entry with a single key press.  The commands available in the
 TODO list are described in @ref{Agenda commands}.
 
-@node Matching headline tags, Timeline, Global TODO list, Agenda Views
+@node Matching headline tags, Timeline, Global TODO list, Agenda views
 @section Matching headline tags
 @cindex matching, of tags
 @cindex tags view
@@ -2643,7 +2674,7 @@
 The commands available in the tags list are described in @ref{Agenda
 commands}.
 
-@node Timeline, Agenda commands, Matching headline tags, Agenda Views
+@node Timeline, Agenda commands, Matching headline tags, Agenda views
 @section Timeline for a single file
 @cindex single file summary
 @cindex agenda, for single file
@@ -2669,7 +2700,7 @@
 The commands available in the timeline buffer are listed in
 @ref{Agenda commands}.
 
-@node Agenda commands,  , Timeline, Agenda Views
+@node Agenda commands,  , Timeline, Agenda views
 @section Commands in the agenda buffer
 @cindex commands, in agenda buffer
 
@@ -2886,7 +2917,7 @@
 
 @end table
 
-@node Exporting, Miscellaneous, Agenda Views, Top
+@node Exporting, Miscellaneous, Agenda views, Top
 @chapter Exporting
 @cindex exporting
 
@@ -3003,6 +3034,9 @@
 current buffer and forces Emacs to re-evaluate the local variables
 section in the buffer.
 
+@c FIXME: More about header and footer styles
+@c FIXME: Talk about links and targets.
+
 @node XML export, iCalendar export, HTML export, Exporting
 @section XML export
 @cindex XML export
@@ -3114,7 +3148,7 @@
 @item
 Plain lists @samp{-}, @samp{*} or @samp{+} as bullet, or with @samp{1.}
 or @samp{2)} as enumerator will be recognized and transformed if the
-backend supports lists.  See @xref{Plain Lists}.
+backend supports lists.  See @xref{Plain lists}.
 
 @cindex underlined text
 @cindex bold text
@@ -3323,7 +3357,7 @@
 @code{nil}. 
 @example
 align      @r{align all tables}
-noalign    @r{don't align table on startup}
+noalign    @r{don't align tables on startup}
 @end example
 Here are the options for hiding leading stars in outline headings.  The
 corresponding variables are @code{org-hide-leading-stars} and
@@ -3346,7 +3380,7 @@
 @item #+TBLFM:
 This line contains the formulas for the table directly above the line.
 @item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+TEXT:, #+OPTIONS:
-These line provide setting for exporting files.  For more details see
+These lines provide setting for exporting files.  For more details see
 @ref{Export options}.
 @end table
 
@@ -3534,10 +3568,24 @@
 @cindex FAQ
 
 @enumerate
+
+@cindex allout.el, conflict with
+@cindex @code{keymapp nil} error
+@item @b{When I try to use Org-mode, I always get
+@code{(wrong-type-argument keymapp nil)}}.@*
+This is a conflict with an outdated version of the @file{allout.el}
+package which pretends to be also the standard outline-mode but is not.
+This happens with older versions of @file{allout.el}, for example the
+one distributed with Emacs 21.  Upgrade to Emacs 22 and this problem
+will disappear.  If for some reason you cannot do this, make sure that
+org.el is loaded @emph{before} @file{allout.el}, for example by putting
+@code{(require 'org)} early enough into your @file{.emacs} file.
+
 @item @b{Org-mode seems to be a useful default mode for the various
 @file{README} files I have scattered through my directories.  How do I
-turn it on for all @file{README} files?}@*
-@c
+turn it on for all @file{README} files?}
+@c @*
+
 @example
 (add-to-list 'auto-mode-alist '("README$" . org-mode))
 @end example
@@ -3555,7 +3603,7 @@
 description part.  How can I convert my old links to this new format?}@*
 @c
 Execute once in each Org-mode file: @kbd{M-x org-upgrade-old-links}.
-The replaces angular brackets with the link format.
+This replaces angular brackets with the new link format.
 
 @item @b{I don't care if you find the new bracket links great, I am
 attached to the old style using angular brackets and no hiding of the
@@ -3861,6 +3909,9 @@
 @item
 Kevin Rogers contributed code to access VM files on remote hosts.
 @item
+Frank Ruell solved the mystery of the @code{keymapp nil} bug, a conflict
+with @file{allout.el}.
+@item
 Philip Rooke created the Org-mode reference card and provided lots of feedback.
 @item
 Christian Schlauer proposed angular brackets around links, among other
--- a/man/pgg.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/pgg.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -234,6 +234,14 @@
 Elapsed time for expiration in seconds.
 @end defvar
 
+@defvar pgg-gpg-use-agent
+When using GnuPG (gpg) as PGP scheme you can use @code{gpg-agent} for
+caching@footnote{Actually @code{gpg-agent} does not cache passphrases
+but private keys.  On the other hand, from a users point of view this
+technical difference isn't visible.}.  If non-@code{nil} try to use a
+running @code{gpg-agent}.  It defaults to @code{nil}.
+@end defvar
+
 @node Default user identity
 @section Default user identity
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/man/xresmini.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -0,0 +1,303 @@
+@c This is part of the Emacs manual.
+@c Copyright (C) 1987, 1993, 1994, 1995, 1997, 2001, 2002, 2003,
+@c   2004, 2005, 2006 Free Software Foundation, Inc.
+@c See file emacs.texi for copying conditions.
+@node X Resources, Antinews, Emacs Invocation, Top
+@appendix X Options and Resources
+
+  You can customize some X-related aspects of Emacs behavior using X
+resources, as is usual for programs that use X.  On MS-Windows, you
+can customize some of the same aspects using the system registry.
+@xref{MS-Windows Registry}.  Likewise, Emacs on MacOS Carbon emulates X
+resources using the Preferences system.  @xref{Mac Environment Variables}.
+
+  When Emacs is built using an ``X toolkit'', such as Lucid or
+LessTif, you need to use X resources to customize the appearance of
+the widgets, including the menu-bar, scroll-bar, and dialog boxes.
+This is because the libraries that implement these don't provide for
+customization through Emacs.  GTK+ widgets use a separate system of
+``GTK resources''.  In this chapter we describe the most commonly used
+resource specifications.  For full documentation, see the online
+manual.
+
+@c Add xref for LessTif/Motif menu resources.
+
+@menu
+* Resources::           Using X resources with Emacs (in general).
+* Table of Resources::  Table of specific X resources that affect Emacs.
+* Face Resources::      X resources for customizing faces.
+* Lucid Resources::     X resources for Lucid menus.
+* GTK resources::       Resources for GTK widgets.
+@end menu
+
+@node Resources
+@appendixsec X Resources
+@cindex resources
+@cindex X resources
+@cindex @file{~/.Xdefaults} file
+@cindex @file{~/.Xresources} file
+
+  Programs running under the X Window System organize their user
+options under a hierarchy of classes and resources.  You can specify
+default values for these options in your X resources file, usually
+named @file{~/.Xdefaults} or @file{~/.Xresources}.
+If changes in @file{~/.Xdefaults} do not
+take effect, it is because your X server stores its own list of
+resources; to update them, use the shell command @command{xrdb}---for
+instance, @samp{xrdb ~/.Xdefaults}.
+
+  Each line in the file specifies a value for one option or for a
+collection of related options, for one program or for several programs
+(optionally even for all programs).
+
+@cindex Registry (MS-Windows)
+  MS-Windows systems don't support @file{~/.Xdefaults} files, but
+Emacs compiled for Windows looks for X resources in the Windows
+Registry, under the key @samp{HKEY_CURRENT_USER\SOFTWARE\GNU\Emacs}
+and then under the key @samp{HKEY_LOCAL_MACHINE\SOFTWARE\GNU\Emacs}.
+The menu and scrollbars are native widgets on MS-Windows, so they are
+only customizable via the system-wide settings in the Display Control
+Panel.  You can also set resources using the @samp{-xrm} command line
+option (see below.)
+
+  Applications such as Emacs look for resources with specific names
+and their particular meanings.  Case distinctions are significant in
+these names.  Each resource specification in @file{~/.Xdefaults}
+states the name of the program and the name of the resource.  For
+Emacs, the program name is @samp{Emacs}.  It looks like this:
+
+@example
+Emacs.borderWidth: 2
+@end example
+
+  The order in which the lines appear in the file does not matter.
+Also, command-line options always override the X resources file.
+
+  You can experiment with the effect of different resource settings
+with the @code{editres} program.  Select @samp{Get Tree} from the
+@samp{Commands} menu, then click on an Emacs frame.  This will display
+a tree showing the structure of X toolkit widgets used in an Emacs
+frame.  Select one of them, such as @samp{menubar}, then select
+@samp{Show Resource Box} from the @samp{Commands} menu.  This displays
+a list of all the meaningful X resources for that widget, and allows
+you to edit them.  Changes take effect when you click on the
+@samp{Apply} button.  (See the @code{editres} man page for more
+details.)
+
+@node Table of Resources
+@appendixsec Table of X Resources for Emacs
+
+  This table lists the resource names that designate options for
+Emacs, not counting those for the appearance of the menu bar, each
+with the class that it belongs to:
+
+@table @asis
+@item @code{background} (class @code{Background})
+Background color name.
+
+@item @code{borderColor} (class @code{BorderColor})
+Color name for the external border.
+
+@item @code{cursorColor} (class @code{Foreground})
+Color name for text cursor (point).
+
+@item @code{font} (class @code{Font})
+Font name (or fontset name, @pxref{Fontsets}) for @code{default} font.
+
+@item @code{foreground} (class @code{Foreground})
+Color name for text.
+
+@item @code{geometry} (class @code{Geometry})
+Window size and position.  Be careful not to specify this resource as
+@samp{emacs*geometry}, because that may affect individual menus as well
+as the Emacs frame itself.
+
+If this resource specifies a position, that position applies only to the
+initial Emacs frame (or, in the case of a resource for a specific frame
+name, only that frame).  However, the size, if specified here, applies to
+all frames.
+
+@item @code{iconName} (class @code{Title})
+Name to display in the icon.
+
+@item @code{internalBorder} (class @code{BorderWidth})
+Width in pixels of the internal border.
+
+@item @code{lineSpacing} (class @code{LineSpacing})
+@cindex line spacing
+@cindex leading
+Additional space (@dfn{leading}) between lines, in pixels.
+
+@item @code{menuBar} (class @code{MenuBar})
+@cindex menu bar
+Give frames menu bars if @samp{on}; don't have menu bars if
+@samp{off}.  @xref{Lucid Resources}, and @ref{LessTif Resources}, for
+how to control the appearance of the menu bar if you have one.
+
+@item @code{pointerColor} (class @code{Foreground})
+Color of the mouse cursor.
+
+@item @code{screenGamma} (class @code{ScreenGamma})
+@cindex gamma correction
+Gamma correction for colors, equivalent to the frame parameter
+@code{screen-gamma}.
+
+@item @code{title} (class @code{Title})
+Name to display in the title bar of the initial Emacs frame.
+
+@item @code{toolBar} (class @code{ToolBar})
+@cindex tool bar
+Number of lines to reserve for the tool bar.  A zero value suppresses
+the tool bar.  If the value is non-zero and
+@code{auto-resize-tool-bars} is non-@code{nil}, the tool bar's size
+will be changed automatically so that all tool bar items are visible.
+
+@item @code{useXIM} (class @code{UseXIM})
+@cindex XIM
+@cindex X input methods
+@cindex input methods, X
+Turn off use of X input methods (XIM) if @samp{false} or @samp{off}.
+This is only relevant if your Emacs is actually built with XIM
+support.  It is potentially useful to turn off XIM for efficiency,
+especially slow X client/server links.
+
+@item @code{verticalScrollBars} (class @code{ScrollBars})
+Give frames scroll bars if @samp{on}; don't have scroll bars if
+@samp{off}.
+@end table
+
+@node Face Resources
+@appendixsec X Resources for Faces
+
+  You can use resources to customize the appearance of particular
+faces (@pxref{Faces}):
+
+@table @code
+@item @var{face}.attributeForeground
+Foreground color for face @var{face}.
+@item @var{face}.attributeBackground
+Background color for face @var{face}.
+@item @var{face}.attributeUnderline
+Underline flag for face @var{face}.  Use @samp{on} or @samp{true} for
+yes.
+@item @var{face}.attributeStrikeThrough
+@itemx @var{face}.attributeOverline
+@itemx @var{face}.attributeBox
+@itemx @var{face}.attributeInverse
+Likewise, for other boolean font attributes.
+@item @var{face}.attributeStipple
+The name of a pixmap data file to use for the stipple pattern, or
+@code{false} to not use stipple for the face @var{face}.
+@item @var{face}.attributeBackgroundPixmap
+The background pixmap for the face @var{face}.  Should be a name of a
+pixmap file or @code{false}.
+@item @var{face}.attributeFont
+Font name (full XFD name or valid X abbreviation) for face @var{face}.
+Instead of this, you can specify the font through separate attributes.
+@end table
+
+  Instead of using @code{attributeFont} to specify a font name, you can
+select a font through these separate attributes:
+
+@table @code
+@item @var{face}.attributeFamily
+Font family for face @var{face}.
+@item @var{face}.attributeHeight
+Height of the font to use for face @var{face}: either an integer
+specifying the height in units of 1/10@dmn{pt}, or a floating point
+number that specifies a scale factor to scale the underlying face's
+default font, or a function to be called with the default height which
+will return a new height.
+@item @var{face}.attributeWidth
+@itemx @var{face}.attributeWeight
+@itemx @var{face}.attributeSlant
+Each of these resources corresponds to a like-named font attribute,
+and you write the resource value the same as the symbol you would use
+for the font attribute value.
+@item @var{face}.attributeBold
+Bold flag for face @var{face}---instead of @code{attributeWeight}.  Use @samp{on} or @samp{true} for
+yes.
+@item @var{face}.attributeItalic
+Italic flag for face @var{face}---instead of @code{attributeSlant}.
+@end table
+
+@node Lucid Resources
+@appendixsec Lucid Menu X Resources
+@cindex Menu X Resources (Lucid widgets)
+@cindex Lucid Widget X Resources
+
+  If the Emacs installed at your site was built to use the X toolkit
+with the Lucid menu widgets, then the menu bar is a separate widget
+and has its own resources.  The resource specifications start with
+@samp{Emacs.pane.menubar}---for instance, to specify the font
+@samp{8x16} for the menu-bar items, write this:
+
+@example
+Emacs.pane.menubar.font:  8x16
+@end example
+
+@noindent
+Resources for @emph{non-menubar} toolkit pop-up menus have
+@samp{menu*} instead of @samp{pane.menubar}.  For example, to specify
+the font @samp{8x16} for the pop-up menu items, write this:
+
+@example
+Emacs.menu*.font:	8x16
+@end example
+
+@noindent
+For dialog boxes, use @samp{dialog*}:
+
+@example
+Emacs.dialog*.font:	8x16
+@end example
+
+@noindent
+The Lucid menus can display multilingual text in your locale.  For
+more information about fontsets see the man page for
+@code{XCreateFontSet}.  To enable multilingual menu text you specify a
+@code{fontSet} resource instead of the font resource.  If both
+@code{font} and @code{fontSet} resources are specified, the
+@code{fontSet} resource is used.
+
+  Thus, to specify @samp{-*-helvetica-medium-r-*--*-120-*-*-*-*-*-*,*}
+for both the popup and menu bar menus, write this:
+
+@example
+Emacs*menu*fontSet:  -*-helvetica-medium-r-*--*-120-*-*-*-*-*-*,*
+@end example
+
+@noindent
+The @samp{*menu*} as a wildcard matches @samp{pane.menubar} and
+@samp{menu@dots{}}.
+
+  Experience shows that on some systems you may need to add
+@samp{shell.}@: before the @samp{pane.menubar} or @samp{menu*}.  On
+some other systems, you must not add @samp{shell.}.  The generic wildcard
+approach should work on both kinds of systems.
+
+  Here is a list of the specific resources for menu bars and pop-up menus:
+
+@table @code
+@item font
+Font for menu item text.
+@item fontSet
+Fontset for menu item text.
+@item foreground
+Color of the foreground.
+@item background
+Color of the background.
+@item buttonForeground
+In the menu bar, the color of the foreground for a selected item.
+@item margin
+The margin of the menu bar, in characters.  Default is 1.
+@end table
+
+@node GTK resources
+@appendixsec GTK resources
+
+@c  Waiting for contents
+
+@ignore
+   arch-tag: e1856f29-2482-42c0-a990-233cdccd1f21
+@end ignore
--- a/man/xresources.texi	Thu Apr 20 16:09:11 2006 +0000
+++ b/man/xresources.texi	Fri Apr 28 14:48:18 2006 +0000
@@ -301,12 +301,10 @@
 @node Face Resources
 @appendixsec X Resources for Faces
 
-  You can also use resources to customize the appearance of particular
+  You can use resources to customize the appearance of particular
 faces (@pxref{Faces}):
 
 @table @code
-@item @var{face}.attributeFont
-Font for face @var{face}.
 @item @var{face}.attributeForeground
 Foreground color for face @var{face}.
 @item @var{face}.attributeBackground
@@ -314,49 +312,45 @@
 @item @var{face}.attributeUnderline
 Underline flag for face @var{face}.  Use @samp{on} or @samp{true} for
 yes.
+@item @var{face}.attributeStrikeThrough
+@itemx @var{face}.attributeOverline
+@itemx @var{face}.attributeBox
+@itemx @var{face}.attributeInverse
+Likewise, for other boolean font attributes.
+@item @var{face}.attributeStipple
+The name of a pixmap data file to use for the stipple pattern, or
+@code{false} to not use stipple for the face @var{face}.
+@item @var{face}.attributeBackgroundPixmap
+The background pixmap for the face @var{face}.  Should be a name of a
+pixmap file or @code{false}.
+@item @var{face}.attributeFont
+Font name (full XFD name or valid X abbreviation) for face @var{face}.
+Instead of this, you can specify the font through separate attributes.
+@end table
+
+  Instead of using @code{attributeFont} to specify a font name, you can
+select a font through these separate attributes:
+
+@table @code
 @item @var{face}.attributeFamily
 Font family for face @var{face}.
-@item @var{face}.attributeWidth
-Relative proportional width of the font to use for face @var{face}.
-It should be one of @code{ultra-condensed}, @code{extra-condensed},
-@code{condensed}, @code{semi-condensed}, @code{normal},
-@code{semi-expanded}, @code{expanded}, @code{extra-expanded}, or
-@code{ultra-expanded}.
 @item @var{face}.attributeHeight
 Height of the font to use for face @var{face}: either an integer
 specifying the height in units of 1/10@dmn{pt}, or a floating point
 number that specifies a scale factor to scale the underlying face's
 default font, or a function to be called with the default height which
 will return a new height.
-@item @var{face}.attributeWeight
-A weight to use for the face @var{face}.  It must be one of
-@code{ultra-bold}, @code{extra-bold}, @code{bold},
-@code{semi-bold}, @code{normal}, @code{semi-light}, @code{light},
-@code{extra-light}, @code{ultra-light}.
-@item @var{face}.attributeSlant
-The slant to use for the font of face @var{face}.  It must be one of
-@code{italic}, @code{oblique}, @code{normal},
-@code{reverse-italic}, or @code{reverse-oblique}.
-@item @var{face}.attributeStrikeThrough
-Whether the face @var{face} should be drawn with a line striking
-through the characters.
-@item @var{face}.attributeOverline
-Whether the characters in the face @var{face} should be overlined.
-@item @var{face}.attributeBox
-Whether to draw a box around the characters in face @var{face}.
-@item @var{face}.attributeInverse
-Whether to display the characters in face @var{face} in inverse
-video.
-@item @var{face}.attributeStipple
-The name of a pixmap data file to use for the stipple pattern, or
-@code{false} to not use stipple for the face @var{face}.
-@item @var{face}.attributeBackgroundPixmap
-The background pixmap for the face @var{face}.  Should be a name of a
-pixmap file or @code{false}.
+@item @var{face}.attributeWidth
+@itemx @var{face}.attributeWeight
+@itemx @var{face}.attributeSlant
+Each of these resources corresponds to a like-named font attribute,
+and you write the resource value the same as the symbol you would use
+for the font attribute value.
 @item @var{face}.attributeBold
-Whether to draw the characters in the face @var{face} as bold.
+Bold flag for face @var{face}---instead of @code{attributeWeight}.  Use @samp{on} or @samp{true} for
+yes.
 @item @var{face}.attributeItalic
-Whether to draw the characters in the face @var{face} as italic.
+Italic flag for face @var{face}---instead of @code{attributeSlant}.
 @end table
 
 @node Lucid Resources
--- a/src/.gdbinit	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/.gdbinit	Fri Apr 28 14:48:18 2006 +0000
@@ -88,15 +88,13 @@
 # Print out s-expressions from tool bar
 define pp1
   set $tmp = $arg0
-  echo $arg0
-  printf " = "
   set $output_debug = print_output_debug_flag
   set print_output_debug_flag = 0
   set safe_debug_print ($tmp)
   set print_output_debug_flag = $output_debug
 end
 document pp1
-Print the argument as an emacs s-expression
+Print the argument as an emacs s-expression.
 Works only when an inferior emacs is executing.
 For use on tool bar when debugging in Emacs
 where the variable name would not otherwise
@@ -119,8 +117,6 @@
 # Print value of lisp variable
 define pv1
   set $tmp = "$arg0"
-  echo $arg0
-  printf " = "
   set $output_debug = print_output_debug_flag
   set print_output_debug_flag = 0
   set safe_debug_print (find_symbol_value (intern ($tmp)))
@@ -129,9 +125,8 @@
 document pv1
 Print the value of the lisp variable given as argument.
 Works only when an inferior emacs is executing.
-For use on tool bar when debugging in Emacs
-where the variable name would not otherwise
-be recorded in the GUD buffer.
+For use when debugging in Emacs where the variable
+name would not otherwise be recorded in the GUD buffer.
 end
 
 # Print out current buffer point and boundaries
--- a/src/ChangeLog	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/ChangeLog	Fri Apr 28 14:48:18 2006 +0000
@@ -1,9 +1,128 @@
+2006-04-27  Nick Roberts  <nickrob@snap.net.nz>
+
+	* .gdbinit (pp1, pv1): Only print value as expression is now
+	printed out by gud-print.
+	(pv1): Correct doc string.
+
+2006-04-26  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* keymap.c (store_in_keymap): Change `def' arg to not be `register'.
+	Seems to trigger a bug in gcc-amd64 4.0.2 20051125 (Red Hat 4.0.2-8):
+	keymap.c:895: error: address of register variable `def' requested.
+
+2006-04-26  Jason Rumney  <jasonr@gnu.org>
+
+	* w32term.c (construct_mouse_wheel): Handle negative coordinates.
+
+	* w32fns.c (w32_wnd_proc) <WM_LBUTTONDOWN, WM_RBUTTONDOWN>:
+	<WM_LBUTTONUP, WM_RBUTTONUP>: Call signal_user_input in the cases
+	where we preempt mouse_button_timer.
+
+2006-04-25  Miles Bader  <miles@gnu.org>
+
+	* editfns.c (Ffield_beginning, find_field): Undo change of 2006-04-23.
+
+2006-04-24  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* process.h: Include headers for pid_t.
+
+2006-04-24  Kim F. Storm  <storm@cua.dk>
+
+	* xdisp.c (fill_stretch_glyph_string): Set s->nchars = 1 for code which
+	does last_glyph=s->first_glyph+s->nchars-1, e.g. if stretch has relief.
+	(produce_stretch_glyph): Assume that face box height and width is
+	already	included in in stretch glyph size so caller doesn't have to
+	consider the extra space otherwise added (fixes problem in ses.el).
+
+	* frame.c (x_set_font): Clear f->n_tool_bar_rows and current frame
+	matrices to force recalculation of tool-bar height after font change.
+
+	* xdisp.c (tool_bar_lines_needed): New local `temp_row' for clarity.
+	Clear it when done, so we don't accidentally draw a second copy of
+	the tool-bar after resetting f->n_tool_bar_rows.
+	(redisplay_tool_bar): Update tool-bar-lines frame parameter whenever
+	we recalculate f->n_tool_bar_rows.
+
+2006-04-23  Lars Hansen  <larsh@soem.dk>
+
+	* editfns.c (find_field): Fix comment.
+	(Ffield_beginning): Fix bug when POS is at field beginning.
+
+2006-04-22  Eli Zaretskii  <eliz@gnu.org>
+
+	* puresize.h (BASE_PURESIZE): Increase to 1205000.
+
+2006-04-21  Kim F. Storm  <storm@cua.dk>
+
+	* xdisp.c (redisplay_window): Fix last change.  Don't recenter if
+	window start is at BEGV.
+
+	* dispextern.h (struct image): New member `corners'.
+	(TOP_CORNER, LEFT_CORNER, BOT_CORNER, RIGHT_CORNER): New macros.
+
+	* image.c (four_corners_best): New arg CORNERS specifies what pixels
+	to look at in case image has margin.
+	(x_create_bitmap_mask): Pass NULL for CORNERS to four_corners_best.
+	(image_background, image_background_transparent)
+	(x_build_heuristic_mask): Pass img->corners to four_corners_best.
+	(gif_load): Set img->corners according to image's margin spec.
+	Use img->corners values directly where applicable.
+	Save image extension data in img->data.lisp_val.
+	(gif_clear_image): New function to free img->data.lisp_val.
+	(gif_type): Use it instead of generic x_clear_image.
+	(Fimage_extension_data): New defun.
+	(syms_of_image): Defsubr it.
+
+2006-04-21  John Sullivan  <john@wjsullivan.net>  (tiny change)
+
+	* window.c (Fdisplay_buffer): Doc fix.
+
+2006-04-21  Eli Zaretskii  <eliz@gnu.org>
+
+	* s/ms-w32.h (SYSTEM_PURESIZE_EXTRA): Increase to 25000.
+
+2006-04-21  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* image.c [MAC_OS] (xpm_load_image): Fill in background field
+	while we have ximg handy.
+
+	* macmenu.c (restore_menu_items, save_menu_items): New functions
+	from xmenu.c.
+	(set_frame_menubar, digest_single_submenu): Apply 2006-04-18
+	changes for xmenu.c.
+
+	* macterm.c (x_per_char_metric): Return NULL if glyph width is 0.
+	(add_mac_font_name): New function.
+	(init_font_name_table): Use it.  Adopt the first found font from
+	those having the same family name.
+
+2006-04-21  Nick Roberts  <nickrob@snap.net.nz>
+
+	* xdisp.c (note_mouse_highlight): Use build_string.
+
+2006-04-20  Lars Hansen  <larsh@soem.dk>
+
+	* textprop.c (Fremove_list_of_text_properties):
+	Ensure modify_region is called only when buffer is modified and that
+	signal_after_change is allways called in that case.
+
+	* print.c (PRINTFINISH): Call signal_after_change.
+
+2006-04-20  Kim F. Storm  <storm@cua.dk>
+
+	* xdisp.c (redisplay_window): Fix last change.
+
+	* xdisp.c (redisplay_window): If current window start is not at	the
+	beginning of a line, select a new window start if buffer is modified
+	and window start is in the modified region, but the first change is
+	before window start.
+
 2006-04-18  Richard Stallman  <rms@gnu.org>
 
 	* xmenu.c (restore_menu_items, save_menu_items): New fns.
 	(set_frame_menubar): Use save_menu_items.  Save updated vector in
-	the frame before unwinding it.  Don't use unuse_menu_items.  Don't
-	use discard_menu_items.
+	the frame before unwinding it.  Don't use unuse_menu_items.
+	Don't use discard_menu_items.
 	(digest_single_submenu): Abort if an item is not in a pane.
 	(init_menu_items): Put the error check at the top.
 
@@ -30,8 +149,8 @@
 
 	* macterm.c (XCreateGC, x_per_char_metric, xlfdpat_create)
 	(init_font_name_table, init_font_name_table, mac_do_list_fonts)
-	(XLoadQueryFont, mac_store_apple_event): Don't check
-	return value of xmalloc.
+	(XLoadQueryFont, mac_store_apple_event): Don't check return value
+	of xmalloc.
 
 2006-04-17  Kim F. Storm  <storm@cua.dk>
 
@@ -75,8 +194,7 @@
 2006-04-13  Kenichi Handa  <handa@m17n.org>
 
 	* coding.c (setup_coding_system): Fix previous change.
-	(encode_coding): If eol_type is not yet decided, use
-	system_eol_type.
+	(encode_coding): If eol_type is not yet decided, use system_eol_type.
 	(shrink_encoding_region): If eol_type is not yet decided and
 	system_eol_type is not LF, don't shrink.
 
@@ -176,8 +294,8 @@
 	within ||.  Add explicit braces to avoid ambiguous `else'.
 	(dump_glyph_row): Remove label for `inverse_p' from legend.
 
-	* xfaces.c (Finternal_merge_in_global_face, try_font_list): Add
-	explicit braces to avoid ambiguous `else'.
+	* xfaces.c (Finternal_merge_in_global_face, try_font_list):
+	Add explicit braces to avoid ambiguous `else'.
 
 2006-04-11  Micha,Ak(Bl Cadilhac  <michael.cadilhac@lrde.org>  (tiny change)
 
@@ -886,11 +1004,6 @@
 	(mac_set_clip_rectangles): When resetting clip region, make it
 	empty instead of disposing of it.
 
-2006-02-20  Stefan Monnier  <monnier@iro.umontreal.ca>
-
-	* keymap.c (store_in_keymap): Change `def' arg to not be `register'.
-	Seems to trigger a bug in gcc-amd64 4.0.2 20051125 (Red Hat 4.0.2-8).
-
 2006-02-20  Kim F. Storm  <storm@cua.dk>
 
 	* Makefile.in: Add fringe.elc to WINDOW_SUPPORT.
--- a/src/dispextern.h	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/dispextern.h	Fri Apr 28 14:48:18 2006 +0000
@@ -2412,6 +2412,15 @@
 #define DEFAULT_IMAGE_WIDTH 30
 #define DEFAULT_IMAGE_HEIGHT 30
 
+  /* Top/left and bottom/right corner pixel of actual image data.
+     Used by four_corners_best to consider the real image data,
+     rather than looking at the optional image margin.  */
+  int corners[4];
+#define TOP_CORNER 0
+#define LEFT_CORNER 1
+#define BOT_CORNER 2
+#define RIGHT_CORNER 3
+
   /* Percent of image height used as ascent.  A value of
      CENTERED_IMAGE_ASCENT means draw the image centered on the
      line.  */
--- a/src/editfns.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/editfns.c	Fri Apr 28 14:48:18 2006 +0000
@@ -491,7 +491,7 @@
 }
 
 /* Find the field surrounding POS in *BEG and *END.  If POS is nil,
-   the value of point is used instead.  If BEG or END null,
+   the value of point is used instead.  If BEG or END is null,
    means don't store the beginning or end of the field.
 
    BEG_LIMIT and END_LIMIT serve to limit the ranged of the returned
--- a/src/frame.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/frame.c	Fri Apr 28 14:48:18 2006 +0000
@@ -3399,6 +3399,11 @@
       else if (!NILP (Fequal (result, oldval)))
         return;
 
+      /* Recalculate toolbar height.  */
+      f->n_tool_bar_rows = 0;
+      /* Ensure we redraw it.  */
+      clear_current_matrices (f);
+
       store_frame_param (f, Qfont, result);
       recompute_basic_faces (f);
     }
--- a/src/image.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/image.c	Fri Apr 28 14:48:18 2006 +0000
@@ -603,7 +603,9 @@
 /* Useful functions defined in the section
    `Image type independent image structures' below. */
 
-static unsigned long four_corners_best P_ ((XImagePtr ximg, unsigned long width,
+static unsigned long four_corners_best P_ ((XImagePtr ximg,
+					    int *corners,
+					    unsigned long width,
 					    unsigned long height));
 
 static int x_create_x_image_and_pixmap P_ ((struct frame *f, int width, int height,
@@ -657,7 +659,7 @@
       return -1;
     }
 
-  bg = four_corners_best (ximg, width, height);
+  bg = four_corners_best (ximg, NULL, width, height);
 
   for (y = 0; y < ximg->height; ++y)
     {
@@ -732,7 +734,7 @@
 /* Keywords.  */
 
 extern Lisp_Object QCwidth, QCheight, QCforeground, QCbackground, QCfile;
-extern Lisp_Object QCdata, QCtype;
+extern Lisp_Object QCdata, QCtype, Qcount;
 extern Lisp_Object Qcenter;
 Lisp_Object QCascent, QCmargin, QCrelief;
 Lisp_Object QCconversion, QCcolor_symbols, QCheuristic_mask;
@@ -1141,6 +1143,27 @@
   return mask;
 }
 
+DEFUN ("image-extension-data", Fimage_extension_data, Simage_extension_data, 1, 2, 0,
+       doc: /* Return extension data for image SPEC.
+FRAME is the frame on which the image will be displayed.  FRAME nil
+or omitted means use the selected frame.  */)
+     (spec, frame)
+     Lisp_Object spec, frame;
+{
+  Lisp_Object ext;
+
+  ext = Qnil;
+  if (valid_image_p (spec))
+    {
+      struct frame *f = check_x_frame (frame);
+      int id = lookup_image (f, spec);
+      struct image *img = IMAGE_FROM_ID (f, id);
+      ext = img->data.lisp_val;
+    }
+
+  return ext;
+}
+
 
 /***********************************************************************
 		 Image type independent image structures
@@ -1171,6 +1194,7 @@
   img->data.lisp_val = Qnil;
   img->ascent = DEFAULT_IMAGE_ASCENT;
   img->hash = hash;
+  img->corners[BOT_CORNER] = -1;  /* Full image */
   return img;
 }
 
@@ -1322,30 +1346,41 @@
    On W32, XIMG is assumed to a device context with the bitmap selected.  */
 
 static RGB_PIXEL_COLOR
-four_corners_best (ximg, width, height)
+four_corners_best (ximg, corners, width, height)
      XImagePtr_or_DC ximg;
+     int *corners;
      unsigned long width, height;
 {
-  RGB_PIXEL_COLOR corners[4], best;
+  RGB_PIXEL_COLOR corner_pixels[4], best;
   int i, best_count;
 
-  /* Get the colors at the corners of ximg.  */
-  corners[0] = GET_PIXEL (ximg, 0, 0);
-  corners[1] = GET_PIXEL (ximg, width - 1, 0);
-  corners[2] = GET_PIXEL (ximg, width - 1, height - 1);
-  corners[3] = GET_PIXEL (ximg, 0, height - 1);
-
+  if (corners && corners[BOT_CORNER] >= 0)
+    {
+      /* Get the colors at the corner_pixels of ximg.  */
+      corner_pixels[0] = GET_PIXEL (ximg, corners[LEFT_CORNER], corners[TOP_CORNER]);
+      corner_pixels[1] = GET_PIXEL (ximg, corners[RIGHT_CORNER] - 1, corners[TOP_CORNER]);
+      corner_pixels[2] = GET_PIXEL (ximg, corners[RIGHT_CORNER] - 1, corners[BOT_CORNER] - 1);
+      corner_pixels[3] = GET_PIXEL (ximg, corners[LEFT_CORNER], corners[BOT_CORNER] - 1);
+    }
+  else
+    {
+      /* Get the colors at the corner_pixels of ximg.  */
+      corner_pixels[0] = GET_PIXEL (ximg, 0, 0);
+      corner_pixels[1] = GET_PIXEL (ximg, width - 1, 0);
+      corner_pixels[2] = GET_PIXEL (ximg, width - 1, height - 1);
+      corner_pixels[3] = GET_PIXEL (ximg, 0, height - 1);
+    }
   /* Choose the most frequently found color as background.  */
   for (i = best_count = 0; i < 4; ++i)
     {
       int j, n;
 
       for (j = n = 0; j < 4; ++j)
-	if (corners[i] == corners[j])
+	if (corner_pixels[i] == corner_pixels[j])
 	  ++n;
 
       if (n > best_count)
-	best = corners[i], best_count = n;
+	best = corner_pixels[i], best_count = n;
     }
 
   return best;
@@ -1404,7 +1439,7 @@
 #endif /* !HAVE_NTGUI */
 	}
 
-      img->background = four_corners_best (ximg, img->width, img->height);
+      img->background = four_corners_best (ximg, img->corners, img->width, img->height);
 
       if (free_ximg)
 	Destroy_Image (ximg, prev);
@@ -1449,7 +1484,7 @@
 	    }
 
 	  img->background_transparent
-	    = (four_corners_best (mask, img->width, img->height) == PIX_MASK_RETAIN);
+	    = (four_corners_best (mask, img->corners, img->width, img->height) == PIX_MASK_RETAIN);
 
 	  if (free_mask)
 	    Destroy_Image (mask, prev);
@@ -4462,6 +4497,10 @@
   img->width = width;
   img->height = height;
 
+  /* Maybe fill in the background field while we have ximg handy. */
+  if (NILP (image_spec_value (img->spec, QCbackground, NULL)))
+    IMAGE_BACKGROUND (img, f, ximg);
+
   x_put_x_image (f, ximg, img->pixmap, width, height);
   x_destroy_x_image (ximg);
   if (have_mask)
@@ -5356,7 +5395,7 @@
     }
 
   if (use_img_background)
-    bg = four_corners_best (ximg, img->width, img->height);
+    bg = four_corners_best (ximg, img->corners, img->width, img->height);
 
   /* Set all bits in mask_img to 1 whose color in ximg is different
      from the background color bg.  */
@@ -7449,6 +7488,7 @@
 
 static int gif_image_p P_ ((Lisp_Object object));
 static int gif_load P_ ((struct frame *f, struct image *img));
+static void gif_clear_image P_ ((struct frame *f, struct image *img));
 
 /* The symbol `gif' identifying images of this type.  */
 
@@ -7497,10 +7537,22 @@
   &Qgif,
   gif_image_p,
   gif_load,
-  x_clear_image,
+  gif_clear_image,
   NULL
 };
 
+/* Free X resources of GIF image IMG which is used on frame F.  */
+
+static void
+gif_clear_image (f, img)
+     struct frame *f;
+     struct image *img;
+{
+  /* IMG->data.ptr_val may contain extension data.  */
+  img->data.lisp_val = Qnil;
+  x_clear_image (f, img);
+}
+
 /* Return non-zero if OBJECT is a valid GIF image specification.  */
 
 static int
@@ -7621,7 +7673,7 @@
   GifFileType *gif;
   struct gcpro gcpro1;
   Lisp_Object image;
-  int ino, image_left, image_top, image_width, image_height;
+  int ino, image_height, image_width;
   gif_memory_source memsrc;
   unsigned char *raster;
 
@@ -7698,17 +7750,19 @@
       return 0;
     }
 
-  image_top = gif->SavedImages[ino].ImageDesc.Top;
-  image_left = gif->SavedImages[ino].ImageDesc.Left;
+  img->corners[TOP_CORNER] = gif->SavedImages[ino].ImageDesc.Top;
+  img->corners[LEFT_CORNER] = gif->SavedImages[ino].ImageDesc.Left;
+  image_height = gif->SavedImages[ino].ImageDesc.Height;
+  img->corners[BOT_CORNER] = img->corners[TOP_CORNER] + image_height;
   image_width = gif->SavedImages[ino].ImageDesc.Width;
-  image_height = gif->SavedImages[ino].ImageDesc.Height;
+  img->corners[RIGHT_CORNER] = img->corners[LEFT_CORNER] + image_width;
 
   width = img->width = max (gif->SWidth,
 			    max (gif->Image.Left + gif->Image.Width,
-				 image_left + image_width));
+				 img->corners[RIGHT_CORNER]));
   height = img->height = max (gif->SHeight,
 			      max (gif->Image.Top + gif->Image.Height,
-				   image_top + image_height));
+				   img->corners[BOT_CORNER]));
 
   if (!check_image_size (f, width, height))
     {
@@ -7751,19 +7805,19 @@
      requires more than can be done here (see the gif89 spec,
      disposal methods).  Let's simply assume that the part
      not covered by a sub-image is in the frame's background color.  */
-  for (y = 0; y < image_top; ++y)
+  for (y = 0; y < img->corners[TOP_CORNER]; ++y)
     for (x = 0; x < width; ++x)
       XPutPixel (ximg, x, y, FRAME_BACKGROUND_PIXEL (f));
 
-  for (y = image_top + image_height; y < height; ++y)
+  for (y = img->corners[BOT_CORNER]; y < height; ++y)
     for (x = 0; x < width; ++x)
       XPutPixel (ximg, x, y, FRAME_BACKGROUND_PIXEL (f));
 
-  for (y = image_top; y < image_top + image_height; ++y)
-    {
-      for (x = 0; x < image_left; ++x)
+  for (y = img->corners[TOP_CORNER]; y < img->corners[BOT_CORNER]; ++y)
+    {
+      for (x = 0; x < img->corners[LEFT_CORNER]; ++x)
 	XPutPixel (ximg, x, y, FRAME_BACKGROUND_PIXEL (f));
-      for (x = image_left + image_width; x < width; ++x)
+      for (x = img->corners[RIGHT_CORNER]; x < width; ++x)
 	XPutPixel (ximg, x, y, FRAME_BACKGROUND_PIXEL (f));
     }
 
@@ -7793,8 +7847,8 @@
 	  for (x = 0; x < image_width; x++)
 	    {
 	      int i = raster[(y * image_width) + x];
-	      XPutPixel (ximg, x + image_left, row + image_top,
-			 pixel_colors[i]);
+	      XPutPixel (ximg, x + img->corners[LEFT_CORNER],
+			 row + img->corners[TOP_CORNER], pixel_colors[i]);
 	    }
 
 	  row += interlace_increment[pass];
@@ -7806,10 +7860,29 @@
 	for (x = 0; x < image_width; ++x)
 	  {
 	    int i = raster[y * image_width + x];
-	    XPutPixel (ximg, x + image_left, y + image_top, pixel_colors[i]);
+	    XPutPixel (ximg, x + img->corners[LEFT_CORNER],
+		       y + img->corners[TOP_CORNER], pixel_colors[i]);
 	  }
     }
 
+  /* Save GIF image extension data for `image-extension-data'.
+     Format is (count IMAGES FUNCTION "BYTES" ...).  */
+  img->data.lisp_val = Qnil;
+  if (gif->SavedImages[ino].ExtensionBlockCount > 0)
+    {
+      ExtensionBlock *ext = gif->SavedImages[ino].ExtensionBlocks;
+      for (i = 0; i < gif->SavedImages[ino].ExtensionBlockCount; i++, ext++)
+	/* Append (... FUNCTION "BYTES") */
+	img->data.lisp_val = Fcons (make_unibyte_string (ext->Bytes, ext->ByteCount),
+				    Fcons (make_number (ext->Function),
+					   img->data.lisp_val));
+      img->data.lisp_val = Fnreverse (img->data.lisp_val);
+    }
+  if (gif->ImageCount > 1)
+    img->data.lisp_val = Fcons (Qcount,
+				Fcons (make_number (gif->ImageCount),
+				       img->data.lisp_val));
+
   fn_DGifCloseFile (gif);
 
   /* Maybe fill in the background field while we have ximg handy. */
@@ -8555,6 +8628,7 @@
   defsubr (&Sclear_image_cache);
   defsubr (&Simage_size);
   defsubr (&Simage_mask_p);
+  defsubr (&Simage_extension_data);
 
 #if GLYPH_DEBUG
   defsubr (&Simagep);
--- a/src/keymap.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/keymap.c	Fri Apr 28 14:48:18 2006 +0000
@@ -859,7 +859,7 @@
 store_in_keymap (keymap, idx, def)
      Lisp_Object keymap;
      register Lisp_Object idx;
-     register Lisp_Object def;
+     Lisp_Object def;
 {
   /* Flush any reverse-map cache.  */
   where_is_cache = Qnil;
--- a/src/macmenu.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/macmenu.c	Fri Apr 28 14:48:18 2006 +0000
@@ -303,6 +303,37 @@
     }
 }
 
+/* This undoes save_menu_items, and it is called by the specpdl unwind
+   mechanism.  */
+
+static Lisp_Object
+restore_menu_items (saved)
+     Lisp_Object saved;
+{
+  menu_items = XCAR (saved);
+  menu_items_allocated = (VECTORP (menu_items) ? ASIZE (menu_items) : 0);
+  saved = XCDR (saved);
+  menu_items_used = XINT (XCAR (saved));
+  saved = XCDR (saved);
+  menu_items_n_panes = XINT (XCAR (saved));
+  saved = XCDR (saved);  
+  menu_items_submenu_depth = XINT (XCAR (saved));
+}
+
+/* Push the whole state of menu_items processing onto the specpdl.
+   It will be restored when the specpdl is unwound.  */
+
+static void
+save_menu_items ()
+{
+  Lisp_Object saved = list4 (menu_items,
+			     make_number (menu_items_used),
+			     make_number (menu_items_n_panes),
+			     make_number (menu_items_submenu_depth));
+  record_unwind_protect (restore_menu_items, saved);
+  menu_items = Qnil;
+}
+
 /* Make the menu_items vector twice as large.  */
 
 static void
@@ -313,6 +344,7 @@
   old = menu_items;
 
   menu_items_allocated *= 2;
+
   menu_items = Fmake_vector (make_number (menu_items_allocated), Qnil);
   bcopy (XVECTOR (old)->contents, XVECTOR (menu_items)->contents,
 	 old_size * sizeof (Lisp_Object));
@@ -1185,6 +1217,7 @@
   int i;
   int submenu_depth = 0;
   widget_value **submenu_stack;
+  int panes_seen = 0;
 
   submenu_stack
     = (widget_value **) alloca (menu_items_used * sizeof (widget_value *));
@@ -1231,6 +1264,8 @@
 	  Lisp_Object pane_name, prefix;
 	  char *pane_string;
 
+	  panes_seen++;
+
 	  pane_name = XVECTOR (menu_items)->contents[i + MENU_ITEMS_PANE_NAME];
 	  prefix = XVECTOR (menu_items)->contents[i + MENU_ITEMS_PANE_PREFIX];
 
@@ -1278,6 +1313,10 @@
 	  Lisp_Object item_name, enable, descrip, def, type, selected;
 	  Lisp_Object help;
 
+	  /* All items should be contained in panes.  */
+	  if (panes_seen == 0)
+	    abort ();
+
 	  item_name = AREF (menu_items, i + MENU_ITEMS_ITEM_NAME);
 	  enable = AREF (menu_items, i + MENU_ITEMS_ITEM_ENABLE);
 	  descrip = AREF (menu_items, i + MENU_ITEMS_ITEM_EQUIV_KEY);
@@ -1529,6 +1568,8 @@
 
       /* Fill in menu_items with the current menu bar contents.
 	 This can evaluate Lisp code.  */
+      save_menu_items ();
+
       menu_items = f->menu_bar_vector;
       menu_items_allocated = VECTORP (menu_items) ? ASIZE (menu_items) : 0;
       submenu_start = (int *) alloca (XVECTOR (items)->size * sizeof (int *));
@@ -1588,23 +1629,33 @@
 	}
 
       set_buffer_internal_1 (prev);
-      unbind_to (specpdl_count, Qnil);
 
       /* If there has been no change in the Lisp-level contents
 	 of the menu bar, skip redisplaying it.  Just exit.  */
 
+      /* Compare the new menu items with the ones computed last time.  */
       for (i = 0; i < previous_menu_items_used; i++)
 	if (menu_items_used == i
 	    || (!EQ (previous_items[i], XVECTOR (menu_items)->contents[i])))
 	  break;
       if (i == menu_items_used && i == previous_menu_items_used && i != 0)
 	{
+	  /* The menu items have not changed.  Don't bother updating
+	     the menus in any form, since it would be a no-op.  */
 	  free_menubar_widget_value_tree (first_wv);
 	  discard_menu_items ();
-
+	  unbind_to (specpdl_count, Qnil);
 	  return;
 	}
 
+      /* The menu items are different, so store them in the frame.  */
+      f->menu_bar_vector = menu_items;
+      f->menu_bar_items_used = menu_items_used;
+
+      /* This calls restore_menu_items to restore menu_items, etc.,
+	 as they were outside.  */
+      unbind_to (specpdl_count, Qnil);
+
       /* Now GC cannot happen during the lifetime of the widget_value,
 	 so it's safe to store data from a Lisp_String.  */
       wv = first_wv->contents;
@@ -1619,9 +1670,6 @@
 	  wv = wv->next;
 	}
 
-      f->menu_bar_vector = menu_items;
-      f->menu_bar_items_used = menu_items_used;
-      discard_menu_items ();
     }
   else
     {
--- a/src/macterm.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/macterm.c	Fri Apr 28 14:48:18 2006 +0000
@@ -2230,7 +2230,11 @@
 #endif
 
   return ((pcm == NULL
-	   || (pcm->width == 0 && (pcm->rbearing - pcm->lbearing) == 0))
+	   || (pcm->width == 0
+#if 0 /* Show hollow boxes for zero-width glyphs such as combining diacritics.  */
+	       && (pcm->rbearing - pcm->lbearing) == 0
+#endif
+	       ))
 	  ? NULL : pcm);
 }
 
@@ -7042,6 +7046,25 @@
   font_name_table[font_name_count++] = font_name;
 }
 
+static void
+add_mac_font_name (name, size, style, charset)
+     char *name;
+     int size;
+     Style style;
+     char *charset;
+{
+  if (size > 0)
+    add_font_name_table_entry (mac_to_x_fontname (name, size, style, charset));
+  else
+    {
+      add_font_name_table_entry (mac_to_x_fontname (name, 0, style, charset));
+      add_font_name_table_entry (mac_to_x_fontname (name, 0, italic, charset));
+      add_font_name_table_entry (mac_to_x_fontname (name, 0, bold, charset));
+      add_font_name_table_entry (mac_to_x_fontname (name, 0, italic | bold,
+						    charset));
+    }
+}
+
 /* Sets up the table font_name_table to contain the list of all fonts
    in the system the first time the table is used so that the Resource
    Manager need not be accessed every time this information is
@@ -7067,16 +7090,21 @@
 			   text_encoding_info_alist)))
     {
       OSErr err;
+      struct Lisp_Hash_Table *h;
+      unsigned hash_code;
       ItemCount nfonts, i;
       ATSUFontID *font_ids = NULL;
-      Ptr name, prev_name = NULL;
+      Ptr name;
       ByteCount name_len;
+      Lisp_Object family;
 
       atsu_font_id_hash =
 	make_hash_table (Qequal, make_number (DEFAULT_HASH_SIZE),
 			 make_float (DEFAULT_REHASH_SIZE),
 			 make_float (DEFAULT_REHASH_THRESHOLD),
 			 Qnil, Qnil, Qnil);;
+      h = XHASH_TABLE (atsu_font_id_hash);
+
       err = ATSUFontCount (&nfonts);
       if (err == noErr)
 	{
@@ -7098,32 +7126,19 @@
 				    kFontNoLanguage, name_len, name,
 				    NULL, NULL);
 	    if (err == noErr)
-	      decode_mac_font_name (name, name_len + 1, Qnil);
-	    if (err == noErr
-		&& *name != '.'
-		&& (prev_name == NULL
-		    || strcmp (name, prev_name) != 0))
 	      {
-		static char *cs = "iso10646-1";
-
-		add_font_name_table_entry (mac_to_x_fontname (name, 0,
-							      normal, cs));
-		add_font_name_table_entry (mac_to_x_fontname (name, 0,
-							      italic, cs));
-		add_font_name_table_entry (mac_to_x_fontname (name, 0,
-							      bold, cs));
-		add_font_name_table_entry (mac_to_x_fontname (name, 0,
-							      italic | bold, cs));
-		Fputhash (make_unibyte_string (name, name_len),
-			  long_to_cons (font_ids[i]), atsu_font_id_hash);
-		xfree (prev_name);
-		prev_name = name;
+		decode_mac_font_name (name, name_len + 1, Qnil);
+		family = make_unibyte_string (name, name_len);
+		if (*name != '.'
+		    && hash_lookup (h, family, &hash_code) < 0)
+		  {
+		    add_mac_font_name (name, 0, normal, "iso10646-1");
+		    hash_put (h, family, long_to_cons (font_ids[i]),
+			      hash_code);
+		  }
 	      }
-	    else
-	      xfree (name);
+	    xfree (name);
 	  }
-      if (prev_name)
-	xfree (prev_name);
       if (font_ids)
 	xfree (font_ids);
     }
@@ -7151,16 +7166,16 @@
       FMFontSize size;
       TextEncoding encoding;
       TextEncodingBase sc;
-      Lisp_Object text_encoding_info;
+      Lisp_Object text_encoding_info, family;
 
       if (FMGetFontFamilyName (ff, name) != noErr)
-	break;
+	continue;
       p2cstr (name);
       if (*name == '.')
 	continue;
 
       if (FMGetFontFamilyTextEncoding (ff, &encoding) != noErr)
-	break;
+	continue;
       sc = GetTextEncodingBase (encoding);
       text_encoding_info = assq_no_quit (make_number (sc),
 					 text_encoding_info_alist);
@@ -7169,13 +7184,15 @@
 					   text_encoding_info_alist);
       decode_mac_font_name (name, sizeof (name),
 			    XCAR (XCDR (text_encoding_info)));
-      fm_font_family_alist = Fcons (Fcons (build_string (name),
-					   make_number (ff)),
+      family = build_string (name);
+      if (!NILP (Fassoc (family, fm_font_family_alist)))
+	continue;
+      fm_font_family_alist = Fcons (Fcons (family, make_number (ff)),
 				    fm_font_family_alist);
 
       /* Point the instance iterator at the current font family.  */
       if (FMResetFontFamilyInstanceIterator (ff, &ffii) != noErr)
-	break;
+	continue;
 
       while (FMGetNextFontFamilyInstance (&ffii, &font, &style, &size)
 	     == noErr)
@@ -7184,27 +7201,7 @@
 
 	  if (size > 0 || style == normal)
 	    for (; !NILP (rest); rest = XCDR (rest))
-	      {
-		char *cs = SDATA (XCAR (rest));
-
-		if (size == 0)
-		  {
-		    add_font_name_table_entry (mac_to_x_fontname (name, size,
-								  style, cs));
-		    add_font_name_table_entry (mac_to_x_fontname (name, size,
-								  italic, cs));
-		    add_font_name_table_entry (mac_to_x_fontname (name, size,
-								  bold, cs));
-		    add_font_name_table_entry (mac_to_x_fontname (name, size,
-								  italic | bold,
-								  cs));
-		  }
-		else
-		  {
-		    add_font_name_table_entry (mac_to_x_fontname (name, size,
-								  style, cs));
-		  }
-	      }
+	      add_mac_font_name (name, size, style, SDATA (XCAR (rest)));
 	}
     }
 
@@ -7224,7 +7221,7 @@
   Str255 name;
   struct FontAssoc *fat;
   struct AsscEntry *assc_entry;
-  Lisp_Object text_encoding_info_alist, text_encoding_info;
+  Lisp_Object text_encoding_info_alist, text_encoding_info, family;
   struct gcpro gcpro1;
 
   GetPort (&port);  /* save the current font number used */
@@ -7243,7 +7240,7 @@
       GetResInfo (font_handle, &id, &type, name);
       GetFNum (name, &fontnum);
       p2cstr (name);
-      if (fontnum == 0)
+      if (fontnum == 0 || *name == '.')
 	continue;
 
       TextFont (fontnum);
@@ -7255,8 +7252,10 @@
 					   text_encoding_info_alist);
       decode_mac_font_name (name, sizeof (name),
 			    XCAR (XCDR (text_encoding_info)));
-      fm_font_family_alist = Fcons (Fcons (build_string (name),
-					   make_number (fontnum)),
+      family = build_string (name);
+      if (!NILP (Fassoc (family, fm_font_family_alist)))
+	continue;
+      fm_font_family_alist = Fcons (Fcons (family, make_number (fontnum)),
 				    fm_font_family_alist);
       do
 	{
@@ -7277,14 +7276,9 @@
 		  Lisp_Object rest = XCDR (XCDR (text_encoding_info));
 
 		  for (; !NILP (rest); rest = XCDR (rest))
-		    {
-		      char *cs = SDATA (XCAR (rest));
-
-		      add_font_name_table_entry (mac_to_x_fontname (name,
-								    assc_entry->fontSize,
-								    assc_entry->fontStyle,
-								    cs));
-		    }
+		    add_mac_font_name (name, assc_entry->fontSize,
+				       assc_entry->fontStyle,
+				       SDATA (XCAR (rest)));
 		}
 	    }
 
--- a/src/print.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/print.c	Fri Apr 28 14:48:18 2006 +0000
@@ -275,6 +275,7 @@
        else								\
 	 insert_1_both (print_buffer, print_buffer_pos,			\
 			print_buffer_pos_byte, 0, 1, 0);		\
+       signal_after_change (PT - print_buffer_pos, 0, print_buffer_pos);\
      }									\
    if (free_print_buffer)						\
      {									\
--- a/src/process.h	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/process.h	Fri Apr 28 14:48:18 2006 +0000
@@ -19,6 +19,12 @@
 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 Boston, MA 02110-1301, USA.  */
 
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
 
 /* This structure records information about a subprocess
    or network connection.
--- a/src/s/ms-w32.h	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/s/ms-w32.h	Fri Apr 28 14:48:18 2006 +0000
@@ -466,9 +466,9 @@
 #include <string.h>
 
 /* We need a little extra space, see ../../lisp/loadup.el.
-   The number below comes from 22038 bytes worth (as of 2006-04)
-   of w32-specific files loaded by loadup.el, plus 2K spare.  */
-#define SYSTEM_PURESIZE_EXTRA 24000
+   The number below comes from 23923 bytes worth (as of 2006-04)
+   of w32-specific files loaded by loadup.el, plus 1K spare.  */
+#define SYSTEM_PURESIZE_EXTRA 25000
 
 /* For unexec to work on Alpha systems, we need to put Emacs'
    initialized data into a separate section from the CRT initialized
--- a/src/textprop.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/textprop.c	Fri Apr 28 14:48:18 2006 +0000
@@ -1602,10 +1602,12 @@
 	}
     }
 
-  if (BUFFERP (object))
-    modify_region (XBUFFER (object), XINT (start), XINT (end));
-
-  /* We are at the beginning of an interval, with len to scan */
+  /* We are at the beginning of an interval, with len to scan.
+     The flag `modified' records if changes have been made.
+     When object is a buffer, we must call modify_region before changes are
+     made and signal_after_change when we are done.
+     We call modify_region before calling remove_properties iff modified == 0,
+     and we call signal_after_change before returning iff modified != 0. */
   for (;;)
     {
       if (i == 0)
@@ -1614,10 +1616,20 @@
       if (LENGTH (i) >= len)
 	{
 	  if (! interval_has_some_properties_list (properties, i))
-	    return modified ? Qt : Qnil;
+	    if (modified)
+	      {
+		if (BUFFERP (object))
+		  signal_after_change (XINT (start), XINT (end) - XINT (start),
+				       XINT (end) - XINT (start));
+		return Qt;
+	      }
+	    else
+	      return Qnil;
 
 	  if (LENGTH (i) == len)
 	    {
+	      if (!modified && BUFFERP (object))
+		modify_region (XBUFFER (object), XINT (start), XINT (end));
 	      remove_properties (Qnil, properties, i, object);
 	      if (BUFFERP (object))
 		signal_after_change (XINT (start), XINT (end) - XINT (start),
@@ -1629,6 +1641,8 @@
 	  unchanged = i;
 	  i = split_interval_left (i, len);
 	  copy_properties (unchanged, i);
+	  if (!modified && BUFFERP (object))
+	    modify_region (XBUFFER (object), XINT (start), XINT (end));
 	  remove_properties (Qnil, properties, i, object);
 	  if (BUFFERP (object))
 	    signal_after_change (XINT (start), XINT (end) - XINT (start),
@@ -1636,8 +1650,14 @@
 	  return Qt;
 	}
 
+      if (interval_has_some_properties_list (properties, i))
+	{
+	  if (!modified && BUFFERP (object))
+	    modify_region (XBUFFER (object), XINT (start), XINT (end));
+	  remove_properties (Qnil, properties, i, object);
+	  modified = 1;
+	}
       len -= LENGTH (i);
-      modified += remove_properties (Qnil, properties, i, object);
       i = next_interval (i);
     }
 }
--- a/src/w32fns.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/w32fns.c	Fri Apr 28 14:48:18 2006 +0000
@@ -3190,6 +3190,7 @@
 	      }
 	    wmsg.dwModifiers = w32_get_modifiers ();
 	    my_post_msg (&wmsg, hwnd, msg, wParam, lParam);
+	    signal_user_input ();
 
 	    /* Clear message buffer. */
 	    saved_mouse_button_msg.msg.hwnd = 0;
@@ -3247,6 +3248,7 @@
 	  }
 	wmsg.dwModifiers = w32_get_modifiers ();
 	my_post_msg (&wmsg, hwnd, msg, wParam, lParam);
+	signal_user_input ();
 
 	/* Always clear message buffer and cancel timer. */
 	saved_mouse_button_msg.msg.hwnd = 0;
--- a/src/w32term.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/w32term.c	Fri Apr 28 14:48:18 2006 +0000
@@ -3131,8 +3131,10 @@
   result->modifiers = (msg->dwModifiers
                        | ((delta < 0 ) ? down_modifier : up_modifier));
 
-  p.x = LOWORD (msg->msg.lParam);
-  p.y = HIWORD (msg->msg.lParam);
+  /* With multiple monitors, we can legitimately get negative
+     coordinates, so cast to short to interpret them correctly.  */
+  p.x = (short) LOWORD (msg->msg.lParam);
+  p.y = (short) HIWORD (msg->msg.lParam);
   ScreenToClient (msg->msg.hwnd, &p);
   XSETINT (result->x, p.x);
   XSETINT (result->y, p.y);
--- a/src/window.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/window.c	Fri Apr 28 14:48:18 2006 +0000
@@ -3439,7 +3439,7 @@
 The variables `special-display-buffer-names',
 `special-display-regexps', `same-window-buffer-names', and
 `same-window-regexps' customize how certain buffer names are handled.
-The latter two take effect only if NOT-THIS-WINDOW is t.
+The latter two take effect only if NOT-THIS-WINDOW is nil.
 
 If optional argument FRAME is `visible', search all visible frames.
 If FRAME is 0, search all visible and iconified frames.
--- a/src/xdisp.c	Thu Apr 20 16:09:11 2006 +0000
+++ b/src/xdisp.c	Fri Apr 28 14:48:18 2006 +0000
@@ -9563,20 +9563,22 @@
 {
   struct window *w = XWINDOW (f->tool_bar_window);
   struct it it;
+  struct glyph_row *temp_row = w->desired_matrix->rows;
 
   /* Initialize an iterator for iteration over
      F->desired_tool_bar_string in the tool-bar window of frame F.  */
-  init_iterator (&it, w, -1, -1, w->desired_matrix->rows, TOOL_BAR_FACE_ID);
+  init_iterator (&it, w, -1, -1, temp_row, TOOL_BAR_FACE_ID);
   it.first_visible_x = 0;
   it.last_visible_x = FRAME_TOTAL_COLS (f) * FRAME_COLUMN_WIDTH (f);
   reseat_to_string (&it, NULL, f->desired_tool_bar_string, 0, 0, 0, -1);
 
   while (!ITERATOR_AT_END_P (&it))
     {
-      it.glyph_row = w->desired_matrix->rows;
-      clear_glyph_row (it.glyph_row);
+      clear_glyph_row (temp_row);
+      it.glyph_row = temp_row;
       display_tool_bar_line (&it, -1);
     }
+  clear_glyph_row (temp_row);
 
   /* f->n_tool_bar_rows == 0 means "unknown"; -1 means no tool-bar.  */
   if (n_rows)
@@ -9656,7 +9658,29 @@
   reseat_to_string (&it, NULL, f->desired_tool_bar_string, 0, 0, 0, -1);
 
   if (f->n_tool_bar_rows == 0)
-    (void)tool_bar_lines_needed (f, &f->n_tool_bar_rows);
+    {
+      int nlines;
+
+      if ((nlines = tool_bar_lines_needed (f, &f->n_tool_bar_rows),
+	   nlines != WINDOW_TOTAL_LINES (w)))
+	{
+	  extern Lisp_Object Qtool_bar_lines;
+	  Lisp_Object frame;
+	  int old_height = WINDOW_TOTAL_LINES (w);
+
+	  XSETFRAME (frame, f);
+	  clear_glyph_matrix (w->desired_matrix);
+	  Fmodify_frame_parameters (frame,
+				    Fcons (Fcons (Qtool_bar_lines,
+						  make_number (nlines)),
+					   Qnil));
+	  if (WINDOW_TOTAL_LINES (w) != old_height)
+	    {
+	      fonts_changed_p = 1;
+	      return 1;
+	    }
+	}
+    }
 
   /* Display as many lines as needed to display all tool-bar items.  */
 
@@ -12697,8 +12721,6 @@
       /* IT may overshoot PT if text at PT is invisible.  */
       else if (IT_CHARPOS (it) > PT && CHARPOS (startp) <= PT)
 	w->force_start = Qt;
-
-
     }
 
   /* Handle case where place to start displaying has been specified,
@@ -12868,6 +12890,36 @@
 	       || (XFASTINT (w->last_modified) >= MODIFF
 		   && XFASTINT (w->last_overlay_modified) >= OVERLAY_MODIFF)))
     {
+
+      /* If first window line is a continuation line, and window start
+	 is inside the modified region, but the first change is before
+	 current window start, we must select a new window start.*/
+      if (NILP (w->start_at_line_beg)
+	  && CHARPOS (startp) > BEGV)
+	{
+	  /* Make sure beg_unchanged and end_unchanged are up to date.
+	     Do it only if buffer has really changed.  This may or may
+	     not have been done by try_window_id (see which) already. */
+	  if (MODIFF > SAVE_MODIFF
+	      /* This seems to happen sometimes after saving a buffer.  */
+	      || BEG_UNCHANGED + END_UNCHANGED > Z_BYTE)
+	    {
+	      if (GPT - BEG < BEG_UNCHANGED)
+		BEG_UNCHANGED = GPT - BEG;
+	      if (Z - GPT < END_UNCHANGED)
+		END_UNCHANGED = Z - GPT;
+	    }
+
+	  if (CHARPOS (startp) > BEG + BEG_UNCHANGED
+	      && CHARPOS (startp) <= Z - END_UNCHANGED)
+	    {
+	      /* There doesn't seems to be a simple way to find a new
+		 window start that is near the old window start, so
+		 we just recenter.  */
+	      goto recenter;
+	    }
+	}
+
 #if GLYPH_DEBUG
       debug_method_add (w, "same window start");
 #endif
@@ -18694,6 +18746,7 @@
   s->font = s->face->font;
   s->font_info = FONT_INFO_FROM_ID (s->f, s->face->font_info_id);
   s->width = glyph->pixel_width;
+  s->nchars = 1;
   voffset = glyph->voffset;
 
   for (++glyph;
@@ -19839,20 +19892,6 @@
   it->descent = it->phys_descent = height - it->ascent;
   it->nglyphs = width > 0 && height > 0 ? 1 : 0;
 
-  if (width > 0 && height > 0 && face->box != FACE_NO_BOX)
-    {
-      if (face->box_line_width > 0)
-	{
-	  it->ascent += face->box_line_width;
-	  it->descent += face->box_line_width;
-	}
-
-      if (it->start_of_box_run_p)
-	it->pixel_width += abs (face->box_line_width);
-      if (it->end_of_box_run_p)
-	it->pixel_width += abs (face->box_line_width);
-    }
-
   take_vertical_position_into_account (it);
 }
 
@@ -22373,7 +22412,7 @@
   if (part == ON_VERTICAL_BORDER)
     {
       cursor = FRAME_X_OUTPUT (f)->horizontal_drag_cursor;
-      help_echo_string = make_string ("drag-mouse-1: resize", 20);
+      help_echo_string = build_string ("drag-mouse-1: resize");
     }
   else if (part == ON_LEFT_FRINGE || part == ON_RIGHT_FRINGE
 	   || part == ON_SCROLL_BAR)
--- a/update-subdirs	Thu Apr 20 16:09:11 2006 +0000
+++ b/update-subdirs	Fri Apr 28 14:48:18 2006 +0000
@@ -1,7 +1,7 @@
 #!/bin/sh
 # Write into $1/subdirs.el a list of subdirs of directory $1.
 
-# Copyright (C) 1994,95,97,1999,2001,2004  Free Software Foundation, Inc.
+# Copyright (C) 1994,95,97,1999,2001,2004,2006  Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
 #