changeset 83404:69e184bbba16

Merged from miles@gnu.org--gnu-2005 (patch 656-658) Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-656 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-657 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-658 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-444
author Karoly Lorentey <lorentey@elte.hu>
date Wed, 23 Nov 2005 01:35:21 +0000
parents 51eb0aa362f3 (current diff) 251a74c1f668 (diff)
children 1955a4462bf9
files lisp/ChangeLog lisp/faces.el lisp/international/mule-cmds.el lisp/net/rcirc.el lisp/progmodes/gdb-ui.el lisp/simple.el lisp/startup.el lisp/subr.el lisp/url/url-http.el lispref/ChangeLog man/ChangeLog src/.gdbinit src/keymap.c src/lisp.h src/macterm.c src/xfaces.c
diffstat 53 files changed, 1425 insertions(+), 709 deletions(-) [+]
line wrap: on
line diff
--- a/etc/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/etc/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,7 @@
+2005-11-18  Carsten Dominik  <dominik@science.uva.nl>
+
+	* orgcard.tex: Version 3.20
+
 2005-11-16  Nick Roberts  <nickrob@snap.net.nz> 
 
 	* images/gud/go.xpm, images/gud/go.pbm: Old gud-remove icons.
--- a/etc/NEWS	Sat Nov 19 19:17:56 2005 +0000
+++ b/etc/NEWS	Wed Nov 23 01:35:21 2005 +0000
@@ -300,36 +300,6 @@
 On 32bit machines, it is now 256M (i.e. 268435455).
 
 +++
-** M-g is now a prefix key.
-M-g g and M-g M-g run goto-line.
-M-g n and M-g M-n run next-error (like C-x `).
-M-g p and M-g M-p run previous-error.
-
-+++
-** C-u M-g M-g switches to the most recent previous buffer,
-and goes to the specified line in that buffer.
-
-When goto-line starts to execute, if there's a number in the buffer at
-point then it acts as the default argument for the minibuffer.
-
-+++
-** The old bindings C-M-delete and C-M-backspace have been deleted,
-since there are situations where one or the other will shut down
-the operating system or your X server.
-
-+++
-** line-move-ignore-invisible now defaults to t.
-
-+++
-** When the undo information of the current command gets really large
-(beyond the value of `undo-outer-limit'), Emacs discards it and warns
-you about it.
-
-+++
-** `apply-macro-to-region-lines' now operates on all lines that begin
-in the region, rather than on all complete lines in the region.
-
-+++
 ** You can now switch buffers in a cyclic order with C-x C-left and
 (prev-buffer) and C-x C-right (next-buffer).  C-x left and C-x right
 can be used as well.
@@ -4935,11 +4905,6 @@
 *** `set-fontset-font', `fontset-info', `fontset-font' now operate on
 the default fontset if the argument NAME is nil..
 
-+++
-*** In `set-face-attribute', you can assign any attribute the value
-`:ignore-defface'.  This forces the attribute value to be acquired
-from some other face during face merging.
-
 ** Font-Lock changes:
 
 +++
--- a/etc/orgcard.tex	Sat Nov 19 19:17:56 2005 +0000
+++ b/etc/orgcard.tex	Wed Nov 23 01:35:21 2005 +0000
@@ -1,4 +1,4 @@
-% Reference Card for Org Mode 3.19
+% Reference Card for Org Mode 3.20
 %
 %**start of header
 \newcount\columnsperpage
@@ -32,8 +32,8 @@
 
 % You should have received a copy of the GNU General Public License
 % along with GNU Emacs; see the file COPYING.  If not, write to
-% the Free Software Foundation, 51 Franklin Street, Fifth Floor,
-% Boston, MA 02110-1301, USA.
+% the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+% Boston, MA 02111-1307, USA.
 
 % This file is intended to be processed by plain TeX (TeX82).
 %
@@ -58,7 +58,7 @@
 % Thanks to Paul Rubin, Bob Chassell, Len Tower, and Richard Mlynarik
 % for their many good ideas.
 
-\def\orgversionnumber{3.19}
+\def\orgversionnumber{3.20}
 \def\year{2005}
 
 \def\shortcopyrightnotice{\vskip 1ex plus 2 fill
@@ -449,9 +449,9 @@
 \key{move the current row down}{M-DOWN}
 \key{kill the current row or horizontal line}{M-S-UP}
 \key{insert new row above the current row}{M-S-DOWN}
-
 \key{insert horizontal line below the current row}{C-c -}
 \key{insert horizontal line above the current row}{C-u C-c -}
+\key{sort lines in region}{C-c \^{}}
 
 {\bf Regions}
 
@@ -462,8 +462,7 @@
 
 {\bf Calculations}
 
-Except for the summation commands, these need the Emacs calc package
-installed.
+These need the Emacs calc package installed.
 
 \key{set and eval column formula}{C-c =}
 \key{set and eval named-field formula}{C-u C-c =}
@@ -512,8 +511,9 @@
 \key{show timeline of current org file}{C-c C-r}
 \key{... include past dates}{C-u C-c C-r}
 
-\key{add current file to your agenda}{C-c [}
+\key{add/move current file to front of agenda}{C-c [}
 \key{remove current file from your agenda}{C-c ]}
+\key{cycle through agenda file list}{C-,}
 \key{compile agenda for the current week}{C-c a$^2$}
 \key{agenda for date at cursor}{C-c C-o}
 \vskip 1mm
--- a/lib-src/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/lib-src/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,8 @@
+2005-11-18  Hideki IWAMOTO <h-iwamoto@kit.hi-ho.ne.jp>  (tiny change)
+
+	* etags.c (main): Cxref mode writes to stdout: do not close tagf,
+	which was never opened.
+
 2005-10-20  Olli Savia  <ops@iki.fi>  (tiny change)
 
 	* etags.c: Undef STDIN if defined.  (LynxOS defines it in system
--- a/lib-src/etags.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/lib-src/etags.c	Wed Nov 23 01:35:21 2005 +0000
@@ -41,7 +41,7 @@
  * configuration file containing regexp definitions for etags.
  */
 
-char pot_etags_version[] = "@(#) pot revision number is 17.14";
+char pot_etags_version[] = "@(#) pot revision number is 17.15";
 
 #define	TRUE	1
 #define	FALSE	0
@@ -479,7 +479,7 @@
 
 /* STDIN is defined in LynxOS system headers */
 #ifdef STDIN
-#undef STDIN
+# undef STDIN
 #endif
 
 #define STDIN 0x1001		/* returned by getopt_long on --parse-stdin */
@@ -994,9 +994,9 @@
   if (CTAGS)
     {
       puts ("-v, --vgrind\n\
-        Generates an index of items intended for human consumption,\n\
-        similar to the output of vgrind.  The index is sorted, and\n\
-        gives the page number of each item.");
+        Print on the standard output an index of items intended for\n\
+        human consumption, similar to the output of vgrind.  The index\n\
+        is sorted, and gives the page number of each item.");
       puts ("-w, --no-warn\n\
         Suppress warning messages about entries defined in multiple\n\
         files.");
@@ -1428,7 +1428,8 @@
 
   if (!CTAGS || cxref_style)
     {
-      put_entries (nodehead);	/* write the remaining tags (ETAGS) */
+      /* Write the remaining tags to tagf (ETAGS) or stdout (CXREF). */
+      put_entries (nodehead);
       free_tree (nodehead);
       nodehead = NULL;
       if (!CTAGS)
@@ -1442,10 +1443,11 @@
 
 	  while (nincluded_files-- > 0)
 	    fprintf (tagf, "\f\n%s,include\n", *included_files++);
+
+	  if (fclose (tagf) == EOF)
+	    pfatal (tagfile);
 	}
 
-      if (fclose (tagf) == EOF)
-	pfatal (tagfile);
       exit (EXIT_SUCCESS);
     }
 
--- a/lisp/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,151 @@
+2005-11-21  Luc Teirlinck  <teirllm@auburn.edu>
+
+	* startup.el (command-line): Make sure that loaddefs.el is handled
+	correctly in load-history.
+
+2005-11-22  Nick Roberts  <nickrob@snap.net.nz>
+
+	* progmodes/gdb-ui.el (gdb-locals-watch-keymap): New local map.
+	(gdb-struct-string, gdb-array-string): New constants.
+	(gdb-info-locals-handler): Use them.
+	(gdb-reset): Reset gdb-var-list to nil.
+
+2005-11-21  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* progmodes/sh-script.el (sh-font-lock-paren): Handle continued lines
+	in patterns.
+
+2005-11-21  Juri Linkov  <juri@jurta.org>
+
+	* custom.el (defcustom): Update link types in docstring.
+
+2005-11-20  Martin Rudalics  <rudalics@gmx.at>  (tiny change)
+
+	* custom.el (defgroup): Add doc-string-elt info.
+
+	* widget.el (define-widget): Don't use declare for the doc-string-elt.
+
+2005-11-20  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* newcomment.el (comment-enter-backward): Fix last fix.
+
+	* simple.el (blink-matching-open):
+	* paren.el (show-paren-function): Allow new paren-class info.
+
+2005-11-20  Chong Yidong  <cyd@stupidchicken.com>
+
+	* faces.el: Revert 2005-11-17 change.  :ignore-defface is now
+	handled automagically.
+
+2005-11-20  Juri Linkov  <juri@jurta.org>
+
+	* simple.el (what-cursor-position):
+	* descr-text.el (describe-char): Use Lisp-readable syntax
+	for octal and hex.  Reorder decimal, octal and hex values.
+	Remove excess whitespace in the output.  Use `=' in `column='
+	like in `point=' and `Hscroll='.
+
+	* international/mule-cmds.el (encoded-string-description):
+	Use Lisp-readable syntax for hex.
+
+2005-11-19  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* newcomment.el (comment-enter-backward): Handle the case where the
+	comment is closed by EOB.
+
+2005-11-19  Chong Yidong  <cyd@stupidchicken.com>
+
+	* longlines.el (longlines-before-revert-hook)
+	(longlines-after-revert-hook): New functions.
+	(longlines-mode): Turn off longlines temporarily when reverting.
+	Add a message-setup-hook.
+	(longlines-decode-buffer): New function.
+	(longlines-wrap-line): Preserve marker positions.
+
+2005-11-19  Andreas Schwab  <schwab@suse.de>
+
+	* emacs-lisp/shadow.el: Handle compressed files.
+
+2005-11-19  Romain Francoise  <romain@orebokech.com>
+
+	* net/browse-url.el (browse-url-default-browser): Signal an error
+	if no usable browser can be found, rather than try to load w3.
+
+2005-11-16  Ryan Yeske  <rcyeske@gmail.com>
+
+	* net/rcirc.el (rcirc-mangle-text): Add bold face property without
+	replacing existing properties.
+	(rcirc-my-nick, rcirc-other-nick, rcirc-server)
+	(rcirc-nick-in-message, rcirc-prompt): Use min-colors and remove
+	tty specs.
+	(rcirc-server-prefix, rcirc-server): New faces.
+	(rcirc-url-regexp): Generate with rx macro.
+	(rcirc-last-server-message-time): New variable.
+	(rcirc-filter): Record time of last message.
+	(rcirc-keepalive): Kill processes that did not send a message
+	since the last ping.
+	(rcirc-mode): Give rcirc-topic a local binding here.
+
+2005-11-19  Michael Cadilhac  <michael.cadilhac@lrde.org>  (tiny change)
+
+	* subr.el (read-passwd): Fontify the prompt as we do with other
+	prompts.
+
+2005-11-19  Ryan Yeske  <rcyeske@gmail.com>
+
+	* ffap.el (ffap-menu-rescan): Use inhibit-read-only instead of
+	binding buffer-read-only to nil.
+
+2005-11-19  Eli Zaretskii  <eliz@gnu.org>
+
+	* complete.el (partial-completion-mode):
+	Mention completion-auto-help in the doc string.
+
+	* man.el (Man-highlight-references): Doc fix.  Reformat code in a
+	more Lisp-ish way.
+
+2005-11-19  Slawomir Nowaczyk  <slawomir.nowaczyk.847@student.lu.se> (tiny change)
+
+	* ls-lisp.el (ls-lisp-format-file-size): Format file size with 9
+	digits, not 8, to avoid misalignment for files larger than 100MB.
+
+2005-11-19  Eli Zaretskii  <eliz@gnu.org>
+
+	* menu-bar.el (menu-bar-describe-menu) <list-keybindings>:
+	Mention "keyboard shortcuts" in the help text.
+
+2005-11-19  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* startup.el (fancy-splash-default-action): Discard only
+	mouse-down and succeeding mouse-up events in the splash screen
+	window so that drag-n-drop event can be processed.
+
+2005-11-18  Chong Yidong  <cyd@stupidchicken.com>
+
+	* longlines.el (longlines-mode): Add hacks for mail-mode and
+	message-mode.
+
+2005-11-18  Carsten Dominik  <dominik@science.uva.nl>
+
+	* textmodes/org.el: (org-table-sort-lines): New command.
+	(org-tbl-menu): Add entry for `org-table-sort-lines'.
+	(org-add-file): Command removed, use `org-agenda-file-to-front'
+	instead.
+	(org-export-icalendar): Use `org-icalendar-combined-name'.
+	(org-cycle-agenda-files, org-agenda-file-to-end)
+	(org-agenda-file-to-front): New commands.
+	(org-table-tab-jumps-over-hlines,org-export-html-style): New
+	options.
+	(org-table-next-field): Use `org-table-tab-jumps-over-hlines'.
+	(org-at-table.el-p, org-set-autofill-regexps,org-html-protect):
+	New functions.
+	(org-fill-paragraph): Call `org-table-align' in tables.
+	(org-mode): Call `org-set-autofill-regexps'.
+	(org-export-as-html): Support for local handformatted lists.
+	Modified to produce valid HTML 4.0. Use `org-export-html-style'.
+	(org-export-local-list-max-depth): New option.
+	(org-html-expand): Use `org-html-protect'.
+
 2005-11-18  Nick Roberts  <nickrob@snap.net.nz>
 
 	* progmodes/gud.el (gud-install-speedbar-variables): Bind gud-pp
@@ -7,7 +155,7 @@
 	* progmodes/gdb-ui.el (gdb-ann3): ...here.  Make it work in the
 	speedbar.
 	(gdb-find-watch-expression): New function.
-	
+
 2005-11-17  Chong Yidong  <cyd@stupidchicken.com>
 
 	* faces.el (face-attribute, set-face-attribute): Mention existence
@@ -2033,14 +2181,6 @@
 
 2005-10-19  Stefan Monnier  <monnier@iro.umontreal.ca>
 
-	* simple.el (eval-expression-print-format): Put the char-string
-	inside the parenthesis, like the other alternative notations.
-	(kill-new): Use push.
-	(copy-to-buffer): Use with-current-buffer.
-	(completion-setup-function): Simplify.
-	(minibuffer-local-must-match-map): Don't add redundant bindings which
-	are already present in its parent (minibuffer-local-completion-map).
-
 	* savehist.el (savehist-coding-system): Revert to checking XEmacs.
 
 2005-10-19  Jay Belanger  <belanger@truman.edu>
@@ -2448,7 +2588,7 @@
 2005-10-12  Kim F. Storm  <storm@cua.dk>
 
 	* startup.el (fancy-splash-default-action): Discard mouse click in
-	the spash screen window, as it has no sensible meaning in the
+	the splash screen window, as it has no sensible meaning in the
 	next window to be selected.  Fixes error reported by Jan D.
 
 2005-10-12  Reiner Steib  <Reiner.Steib@gmx.de>
--- a/lisp/complete.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/complete.el	Wed Nov 23 01:35:21 2005 +0000
@@ -203,7 +203,14 @@
 Unless `PC-disable-includes' is non-nil, the `<...>' sequence is interpreted
 specially in \\[find-file].  For example,
 \\[find-file] <sys/time.h> RET finds the file `/usr/include/sys/time.h'.
-See also the variable `PC-include-file-path'."
+See also the variable `PC-include-file-path'.
+
+Partial Completion mode extends the meaning of `completion-auto-help' (which
+see) so that if it is neither nil nor t, Emacs will show the  *Completions*
+buffer only on the second attempt to complete.  I.e. if TAB finds nothing
+to complete, the first TAB will just say \"Next char not unique\" without
+bringing up the *Completions* buffer, and the second TAB will then bring up
+the *Completions* buffer."
   :global t :group 'partial-completion
   ;; Deal with key bindings...
   (PC-bindings partial-completion-mode)
--- a/lisp/custom.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/custom.el	Wed Nov 23 01:35:21 2005 +0000
@@ -210,12 +210,11 @@
         item.  This is a sentence containing an active field which
         references some other documentation.
 
-        There are three alternatives you can use for LINK-DATA:
+        There are several alternatives you can use for LINK-DATA:
 
         (custom-manual INFO-NODE)
              Link to an Info node; INFO-NODE is a string which specifies
-             the node name, as in \"(emacs)Top\".  The link appears as
-             `[manual]' in the customization buffer.
+             the node name, as in \"(emacs)Top\".
 
         (info-link INFO-NODE)
              Like `custom-manual' except that the link appears in the
@@ -223,7 +222,24 @@
 
         (url-link URL)
              Link to a web page; URL is a string which specifies the URL.
-             The link appears in the customization buffer as URL.
+
+        (emacs-commentary-link LIBRARY)
+             Link to the commentary section of LIBRARY.
+
+        (emacs-library-link LIBRARY)
+             Link to an Emacs Lisp LIBRARY file.
+
+        (file-link FILE)
+             Link to FILE.
+
+        (function-link FUNCTION)
+             Link to the documentation of FUNCTION.
+
+        (variable-link VARIABLE)
+             Link to the documentation of VARIABLE.
+
+        (custom-group-link GROUP)
+             Link to another customization GROUP.
 
         You can specify the text to use in the customization buffer by
         adding `:tag NAME' after the first element of the LINK-DATA; for
@@ -420,6 +436,7 @@
 
 Read the section about customization in the Emacs Lisp manual for more
 information."
+  (declare (doc-string 3))
   ;; It is better not to use backquote in this file,
   ;; because that makes a bootstrapping problem
   ;; if you need to recompile all the Lisp files using interpreted code.
--- a/lisp/descr-text.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/descr-text.el	Wed Nov 23 01:35:21 2005 +0000
@@ -458,6 +458,12 @@
 	 (multibyte-p enable-multibyte-characters)
 	 (overlays (mapcar #'(lambda (o) (overlay-properties o))
 			   (overlays-at pos)))
+	 (char-description (if (not multibyte-p)
+			       (single-key-description char)
+			     (if (< char 128)
+				 (single-key-description char)
+			       (string-to-multibyte
+				(char-to-string char)))))
 	 item-list max-width unicode)
 
     (if (or (< char 256)
@@ -467,13 +473,8 @@
 			  (encode-char char 'ucs))))
     (setq item-list
 	  `(("character"
-	    ,(format "%s (0%o, %d, 0x%x%s)"
-		     (apply 'propertize (if (not multibyte-p)
-					    (single-key-description char)
-					  (if (< char 128)
-					      (single-key-description char)
-					    (string-to-multibyte
-					     (char-to-string char))))
+	    ,(format "%s (%d, #o%o, #x%x%s)"
+		     (apply 'propertize char-description
 			    (text-properties-at pos))
 		     char char char
 		     (if unicode
@@ -510,7 +511,7 @@
 	     ,@(let ((category-set (char-category-set char)))
 		 (if (not category-set)
 		     '("-- none --")
-		   (mapcar #'(lambda (x) (format "%c:%s  "
+		   (mapcar #'(lambda (x) (format "%c:%s"
 						 x (category-docstring x)))
 			   (category-set-mnemonics category-set)))))
 	    ,@(let ((props (aref char-code-property-table char))
@@ -583,7 +584,7 @@
 		      (if display
 			  (concat
 			   "by this font (glyph code)\n"
-			   (format "     %s (0x%02X)"
+			   (format "     %s (#x%02X)"
 				   (car display) (cdr display)))
 			"no font available")
 		    (if display
@@ -639,13 +640,14 @@
 	  (goto-char (point-min))
 	  (re-search-forward "character:[ \t\n]+")
 	  (setq pos (point)))
-	(if overlays
-	    (mapc #'(lambda (props)
-		      (let ((o (make-overlay pos (1+ pos))))
-			(while props
-			  (overlay-put o (car props) (nth 1 props))
-			  (setq props (cddr props)))))
-		  overlays))
+	(let ((end (+ pos (length char-description))))
+	  (if overlays
+	      (mapc #'(lambda (props)
+			(let ((o (make-overlay pos end)))
+			  (while props
+			    (overlay-put o (car props) (nth 1 props))
+			    (setq props (cddr props)))))
+		    overlays)))
 
 	(when disp-vector
 	  (insert
@@ -657,7 +659,7 @@
 		  (insert (logand (car (aref disp-vector i)) #x7ffff) ?:
 			  (propertize " " 'display '(space :align-to 5))
 			  (if (cdr (aref disp-vector i))
-			      (format "%s (0x%02X)" (cadr (aref disp-vector i))
+			      (format "%s (#x%02X)" (cadr (aref disp-vector i))
 				      (cddr (aref disp-vector i)))
 			    "-- no font --")
 			  "\n")
@@ -708,7 +710,7 @@
 		  (insert "\n " (car elt) ?:
 			  (propertize " " 'display '(space :align-to 5))
 			  (if (cdr elt)
-			      (format "%s (0x%02X)" (cadr elt) (cddr elt))
+			      (format "%s (#x%02X)" (cadr elt) (cddr elt))
 			    "-- no font --"))))
 	    (insert "these terminal codes:")
 	    (dolist (elt component-chars)
--- a/lisp/emacs-lisp/shadow.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/emacs-lisp/shadow.el	Wed Nov 23 01:35:21 2005 +0000
@@ -104,7 +104,7 @@
 	(setq true-names (append true-names (list dir)))
 	(setq dir (directory-file-name (or (car path) ".")))
 	(setq curr-files (if (file-accessible-directory-p dir)
-			     (directory-files dir nil ".\\.elc?$" t)))
+			     (directory-files dir nil ".\\.elc?\\(\\.gz\\)?$" t)))
 	(and curr-files
 	     (not noninteractive)
 	     (message "Checking %d files in %s..." (length curr-files) dir))
@@ -114,6 +114,8 @@
 	(while curr-files
 
 	  (setq file (car curr-files))
+	  (if (string-match "\\.gz$" file)
+	      (setq file (substring file 0 -3)))
 	  (setq file (substring
 		      file 0 (if (string= (substring file -1) "c") -4 -3)))
 
@@ -209,7 +211,8 @@
 	toplevs)
     ;; If we can find simple.el in two places,
     (while tem
-      (if (file-exists-p (expand-file-name "simple.el" (car tem)))
+      (if (or (file-exists-p (expand-file-name "simple.el" (car tem)))
+	      (file-exists-p (expand-file-name "simple.el.gz" (car tem))))
 	  (setq toplevs (cons (car tem) toplevs)))
       (setq tem (cdr tem)))
     (if (> (length toplevs) 1)
--- a/lisp/faces.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/faces.el	Wed Nov 23 01:35:21 2005 +0000
@@ -357,12 +357,11 @@
 If FRAME is t, report on the defaults for face FACE (for new frames).
 If FRAME is omitted or nil, use the selected frame.
 
-If INHERIT is nil, only attributes directly defined by FACE are
-  considered, so the return value may be `unspecified',
-  `:ignore-defface', or a relative value.
+If INHERIT is nil, only attributes directly defined by FACE are considered,
+  so the return value may be `unspecified', or a relative value.
 If INHERIT is non-nil, FACE's definition of ATTRIBUTE is merged with the
   faces specified by its `:inherit' attribute; however the return value
-  may still be relative.
+  may still be `unspecified' or relative.
 If INHERIT is a face or a list of faces, then the result is further merged
   with that face (or faces), until it becomes specified and absolute.
 
@@ -561,13 +560,8 @@
 attribute is changed on all frames).
 
 ARGS must come in pairs ATTRIBUTE VALUE.  ATTRIBUTE must be a valid
-face attribute name.
-
-Unless you're certain you know what you're doing, don't set an
-attribute to `unspecified' .  To make a face ignore the attribute
-given in the defface spec, assign it the value `:ignore-defface'.
-You can do this for any attribute; this fact is not further
-mentioned below.
+face attribute name. All attributes can be set to `unspecified';
+this fact is not further mentioned below.
 
 The following attributes are recognized:
 
--- a/lisp/ffap.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/ffap.el	Wed Nov 23 01:35:21 2005 +0000
@@ -1519,7 +1519,9 @@
   (let ((ffap-next-regexp (or ffap-menu-regexp ffap-next-regexp))
 	(range (- (point-max) (point-min)))
 	(mod (buffer-modified-p))	; was buffer modified?
-	buffer-read-only		; to set text-properties
+	;; inhibit-read-only works on read-only text properties
+	;; as well as read-only buffers.
+	(inhibit-read-only t)		; to set text-properties
 	item
 	;; Avoid repeated searches of the *mode-alist:
 	(major-mode (if (assq major-mode ffap-string-at-point-mode-alist)
--- a/lisp/gnus/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/gnus/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,8 @@
+2005-11-19  Chong Yidong  <cyd@stupidchicken.com>
+
+	* message.el: Revert last changes.
+	(message-insert-citation-line): Use newlines.
+
 2005-11-17  Chong Yidong  <cyd@stupidchicken.com>
 
 	* message.el (message-courtesy-message)
--- a/lisp/gnus/message.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/gnus/message.el	Wed Nov 23 01:35:21 2005 +0000
@@ -141,11 +141,7 @@
   :group 'message-sending)
 
 (defcustom message-courtesy-message
-  (concat
-   "The following message is a courtesy copy of an article"
-   hard-newline
-   "that has been posted to %s as well."
-   hard-newline hard-newline)
+  "The following message is a courtesy copy of an article\nthat has been posted to %s as well.\n\n"
   "*This is inserted at the start of a mailed copy of a posted message.
 If the string contains the format spec \"%s\", the Newsgroups
 the article has been posted to will be inserted there.
@@ -343,9 +339,7 @@
 ;;; marking inserted text
 
 (defcustom message-mark-insert-begin
-  (concat
-   "--8<---------------cut here---------------start------------->8---"
-   hard-newline)
+  "--8<---------------cut here---------------start------------->8---\n"
   "How to mark the beginning of some inserted text."
   :version "22.1"
   :type 'string
@@ -353,16 +347,14 @@
   :group 'message-various)
 
 (defcustom message-mark-insert-end
-  (concat
-   "--8<---------------cut here---------------end--------------->8---"
-   hard-newline)
+  "--8<---------------cut here---------------end--------------->8---\n"
   "How to mark the end of some inserted text."
   :version "22.1"
   :type 'string
   :link '(custom-manual "(message)Insertion Variables")
   :group 'message-various)
 
-(defcustom message-archive-header "X-No-Archive: Yes"
+(defcustom message-archive-header "X-No-Archive: Yes\n"
   "Header to insert when you don't want your article to be archived.
 Archives \(such as groups.google.com\) respect this header."
   :version "22.1"
@@ -426,8 +418,7 @@
   :link '(custom-manual "(message)Various Message Variables")
   :group 'message-various)
 
-(defcustom message-elide-ellipsis
-  (concat hard-newline "[...]" hard-newline hard-newline)
+(defcustom message-elide-ellipsis "\n[...]\n\n"
   "*The string which is inserted for elided text."
   :type 'string
   :link '(custom-manual "(message)Various Commands")
@@ -587,8 +578,7 @@
   :link '(custom-manual "(message)Insertion Variables")
   :type 'regexp)
 
-(defcustom message-cancel-message 
-  (concat "I am canceling my own article." hard-newline)
+(defcustom message-cancel-message "I am canceling my own article.\n"
   "Message to be inserted in the cancel message."
   :group 'message-interface
   :link '(custom-manual "(message)Canceling News")
@@ -1744,7 +1734,7 @@
 	  (goto-char (point-max))
 	  (if (string-match "\n$" (car headers))
 	      (insert (car headers))
-	    (insert (car headers) hard-newline)))))
+	    (insert (car headers) ?\n)))))
     (setq headers (cdr headers))))
 
 (defmacro message-with-reply-buffer (&rest forms)
@@ -1851,7 +1841,7 @@
 		    (insert (concat "Subject: "
 				    new-subject
 				    " (was: "
-				    old-subject ")" hard-newline)))))))))
+				    old-subject ")\n")))))))))
 
 (defun message-mark-inserted-region (beg end)
   "Mark some region in the current article with enclosing tags.
@@ -1935,7 +1925,7 @@
 				 target-group
 				 "[ \t]*$")
 			 (message-fetch-field "Newsgroups")))
-      (insert (concat hard-newline "Followup-To: " target-group)))
+      (insert (concat "\nFollowup-To: " target-group)))
   (setq message-cross-post-old-target target-group))
 
 (defun message-cross-post-insert-note (target-group cross-post in-old
@@ -1967,8 +1957,8 @@
     (if (or in-old
 	    (not cross-post)
 	    (string-match "^[ \t]*poster[ \t]*$" target-group))
-	(insert message-followup-to-note target-group hard-newline)
-      (insert message-cross-post-note target-group hard-newline))))
+	(insert (concat message-followup-to-note target-group "\n"))
+      (insert (concat message-cross-post-note target-group "\n")))))
 
 (defun message-cross-post-followup-to (target-group)
   "Crossposts message and set Followup-To to TARGET-GROUP.
@@ -2028,7 +2018,7 @@
 	  (save-excursion
 	    (message-goto-to)
 	    (message-delete-line)
-	    (insert (concat "To: " cc-content hard-newline))
+	    (insert (concat "To: " cc-content "\n"))
 	    (save-restriction
 	      (message-narrow-to-headers)
 	      (message-remove-header (if bcc
@@ -2793,7 +2783,7 @@
 	  (message-remove-header (symbol-name (car elem)))
 	  (goto-char (point-min))
 	  (insert (symbol-name (car elem)) ": "
-		  (cdr elem) hard-newline))))))
+		  (cdr elem) "\n"))))))
 
 (defun message-insert-newsgroups ()
   "Insert the Newsgroups header from the article being replied to."
@@ -2823,7 +2813,7 @@
 				 (point)
 			       (forward-line -2)
 			       (point)))
-      (insert hard-newline)
+      (insert "\n")
       (goto-char beg)
       (delete-region beg (progn (message-goto-body)
 				(forward-line 2)
@@ -2842,7 +2832,7 @@
       (end-of-line -1))
     (kill-region point (point))
     (unless (bolp)
-      (insert hard-newline))))
+      (insert "\n"))))
 
 (defun message-newline-and-reformat (&optional arg not-break)
   "Insert four newlines, and then reformat if inside quoted text.
@@ -2984,15 +2974,15 @@
       (goto-char (point-max))
       ;; Insert the signature.
       (unless (bolp)
-	(insert hard-newline))
+	(insert "\n"))
       (when message-signature-insert-empty-line
-	(insert hard-newline))
-      (insert "-- " hard-newline)
+	(insert "\n"))
+      (insert "-- \n")
       (if (eq signature t)
 	  (insert-file-contents message-signature-file)
 	(insert signature))
       (goto-char (point-max))
-      (or (bolp) (insert hard-newline)))))
+      (or (bolp) (insert "\n")))))
 
 (defun message-insert-importance-high ()
   "Insert header to mark message as important."
@@ -3002,7 +2992,7 @@
       (message-narrow-to-headers)
       (message-remove-header "Importance"))
     (message-goto-eoh)
-    (insert "Importance: high" hard-newline)))
+    (insert "Importance: high\n")))
 
 (defun message-insert-importance-low ()
   "Insert header to mark message as unimportant."
@@ -3012,7 +3002,7 @@
       (message-narrow-to-headers)
       (message-remove-header "Importance"))
     (message-goto-eoh)
-    (insert "Importance: low" hard-newline)))
+    (insert "Importance: low\n")))
 
 (defun message-insert-or-toggle-importance ()
   "Insert a \"Importance: high\" header, or cycle through the header values.
@@ -3034,7 +3024,7 @@
 			  (t
 			   "high")))))
       (message-goto-eoh)
-      (insert (format "Importance: %s" new) hard-newline))))
+      (insert (format "Importance: %s\n" new)))))
 
 (defun message-insert-disposition-notification-to ()
   "Request a disposition notification (return receipt) to this message.
@@ -3045,11 +3035,10 @@
       (message-narrow-to-headers)
       (message-remove-header "Disposition-Notification-To"))
     (message-goto-eoh)
-    (insert (format "Disposition-Notification-To: %s"
+    (insert (format "Disposition-Notification-To: %s\n"
 		    (or (message-field-value "Reply-to")
 			(message-field-value "From")
-			(message-make-from)))
-	    hard-newline)))
+			(message-make-from))))))
 
 (defun message-elide-region (b e)
   "Elide the text in the region.
@@ -3184,7 +3173,7 @@
     ;; Delete blank lines at the end of the buffer.
     (goto-char (point-max))
     (unless (eolp)
-      (insert hard-newline))
+      (insert "\n"))
     (while (and (zerop (forward-line -1))
 		(looking-at "$"))
       (message-delete-line))
@@ -3222,7 +3211,7 @@
 	(funcall message-cite-function))
       (message-exchange-point-and-mark)
       (unless (bolp)
-	(insert hard-newline))
+	(insert ?\n))
       (unless modified
 	(setq message-checksum (message-checksum))))))
 
@@ -3280,13 +3269,13 @@
       (delete-region (point) end)
       (unless (search-backward "\n\n" start t)
 	;; Insert a blank line if it is peeled off.
-	(insert hard-newline)))
+	(insert "\n")))
     (goto-char start)
     (while functions
       (funcall (pop functions)))
     (when message-citation-line-function
       (unless (bolp)
-	(insert hard-newline))
+	(insert "\n"))
       (funcall message-citation-line-function))))
 
 (eval-when-compile (defvar mail-citation-hook))	;Compiler directive
@@ -3322,14 +3311,15 @@
 	(funcall (pop functions)))
       (when message-citation-line-function
 	(unless (bolp)
-	  (insert hard-newline))
+	  (insert "\n"))
 	(funcall message-citation-line-function)))))
 
 (defun message-insert-citation-line ()
   "Insert a simple citation line."
   (when message-reply-headers
-    (insert (mail-header-from message-reply-headers)
-	    " writes:" hard-newline hard-newline)))
+    (insert (mail-header-from message-reply-headers) " writes:")
+    (newline)
+    (newline)))
 
 (defun message-position-on-field (header &rest afters)
   (let ((case-fold-search t))
@@ -3355,7 +3345,7 @@
 	(when afters
 	  (re-search-forward "^[^ \t]" nil 'move)
 	  (beginning-of-line))
-	(insert header ": " hard-newline)
+	(insert header ": \n")
 	(forward-char -1)
 	nil))))
 
@@ -3551,7 +3541,7 @@
   ;; Make sure there's a newline at the end of the message.
   (goto-char (point-max))
   (unless (bolp)
-    (insert hard-newline))
+    (insert "\n"))
   ;; Make the hidden headers visible.
   (let ((points (message-text-with-property 'message-hidden)))
     (when points
@@ -3656,7 +3646,7 @@
   (goto-char (point-min))
   (re-search-forward
    (concat "^" (regexp-quote mail-header-separator) "\n"))
-  (replace-match hard-newline)
+  (replace-match "\n")
   (run-hooks 'message-send-mail-hook)
   (let ((p (goto-char (point-min)))
 	(tembuf (message-generate-new-buffer-clone-locals " message temp"))
@@ -3698,18 +3688,17 @@
 	      (message-remove-header "Message-ID")
 	      (message-remove-header "Lines")
 	      (goto-char (point-max))
-	      (insert "Mime-Version: 1.0" hard-newline)
+	      (insert "Mime-Version: 1.0\n")
 	      (setq header (buffer-string)))
 	    (goto-char (point-max))
-	    (insert (format "Content-Type: message/partial; id=\"%s\"; number=%d; total=%d"
-			    id n total)
-		    hard-newline hard-newline)
+	    (insert (format "Content-Type: message/partial; id=\"%s\"; number=%d; total=%d\n\n"
+			    id n total))
 	    (forward-char -1)
 	    (let ((mail-header-separator ""))
 	      (when (memq 'Message-ID message-required-mail-headers)
-		(insert "Message-ID: " (message-make-message-id) hard-newline))
+		(insert "Message-ID: " (message-make-message-id) "\n"))
 	      (when (memq 'Lines message-required-mail-headers)
-		(insert "Lines: " (message-make-lines) hard-newline))
+		(insert "Lines: " (message-make-lines) "\n"))
 	      (message-goto-subject)
 	      (end-of-line)
 	      (insert (format " (%d/%d)" n total))
@@ -3774,7 +3763,7 @@
 	  (goto-char (point-max))
 	  ;; require one newline at the end.
 	  (or (= (preceding-char) ?\n)
-	      (insert hard-newline))
+	      (insert ?\n))
 	  (message-cleanup-headers)
 	  ;; FIXME: we're inserting the courtesy copy after encoding.
 	  ;; This is wrong if the courtesy copy string contains
@@ -3850,7 +3839,7 @@
 	    (goto-char (point-min))
 	    (re-search-forward
 	     (concat "^" (regexp-quote mail-header-separator) "\n"))
-	    (replace-match hard-newline)
+	    (replace-match "\n")
 	    (backward-char 1)
 	    (setq delimline (point-marker))
 	    (run-hooks 'message-send-mail-hook)
@@ -3912,7 +3901,7 @@
   (goto-char (point-min))
   (re-search-forward
    (concat "^" (regexp-quote mail-header-separator) "\n"))
-  (replace-match hard-newline)
+  (replace-match "\n")
   (run-hooks 'message-send-mail-hook)
   ;; send the message
   (case
@@ -4080,13 +4069,13 @@
 	      (goto-char (point-max))
 	      ;; require one newline at the end.
 	      (or (= (preceding-char) ?\n)
-		  (insert hard-newline))
+		  (insert ?\n))
 	      (let ((case-fold-search t))
 		;; Remove the delimiter.
 		(goto-char (point-min))
 		(re-search-forward
 		 (concat "^" (regexp-quote mail-header-separator) "\n"))
-		(replace-match hard-newline)
+		(replace-match "\n")
 		(backward-char 1))
 	      (run-hooks 'message-send-news-hook)
 	      (gnus-open-server method)
@@ -4213,7 +4202,7 @@
 					     (message-tokenize-header
 					      newsgroups)))))))))
 	 (goto-char (point-min))
-	 (insert "Followup-To: " to hard-newline))
+	 (insert "Followup-To: " to "\n"))
        t))
    ;; Check "Shoot me".
    (message-check 'shoot
@@ -5112,7 +5101,7 @@
 		      ;; We check whether the value was ended by a
 		      ;; newline.  If now, we insert one.
 		      (unless (bolp)
-			(insert hard-newline))
+			(insert "\n"))
 		      (forward-line -1)))
 		;; The value of this header was empty, so we clear
 		;; totally and insert the new value.
@@ -5152,7 +5141,7 @@
 	    (beginning-of-line))
 	  (when (or (message-news-p)
 		    (string-match "@.+\\.." secure-sender))
-	    (insert "Sender: " secure-sender hard-newline))))
+	    (insert "Sender: " secure-sender "\n"))))
       ;; Check for IDNA
       (message-idna-to-ascii-rhs))))
 
@@ -5164,7 +5153,7 @@
 	(message-narrow-to-headers)
 	(when (setq newsgroups (message-fetch-field "newsgroups"))
 	  (goto-char (point-max))
-	  (insert "Posted-To: " newsgroups hard-newline)))
+	  (insert "Posted-To: " newsgroups "\n")))
       (forward-line 1)
       (when message-courtesy-message
 	(cond
@@ -5183,7 +5172,7 @@
     (insert (capitalize (symbol-name header))
 	    ": "
 	    (if (consp value) (car value) value)
-	    hard-newline)
+	    "\n")
     (narrow-to-region (point-min) (1- (point-max)))
     (let (quoted last)
       (goto-char (point-min))
@@ -5197,7 +5186,7 @@
 		  (progn
 		    (save-excursion
 		      (goto-char last)
-		      (insert hard-newline "\t"))
+		      (insert "\n\t"))
 		    (setq last (1+ (point))))
 		(setq last (1+ (point)))))
 	  (setq quoted (not quoted)))
@@ -5223,7 +5212,7 @@
     (insert (capitalize (symbol-name header))
 	    ": "
 	    (if (consp value) (car value) value)
-	    hard-newline)
+	    "\n")
     (save-restriction
       (narrow-to-region begin (point))
       (fill-region-as-paragraph begin (point))
@@ -5292,7 +5281,7 @@
     (let ((refstring (mapconcat #'identity refs " ")))
       (if (and message-this-is-news message-cater-to-broken-inn)
 	  (insert (capitalize (symbol-name header)) ": "
-		  refstring hard-newline)
+		  refstring "\n")
 	(message-fill-header header refstring)))))
 
 (defun message-position-point ()
@@ -5521,18 +5510,18 @@
   (delete-region (point) (progn (forward-line -1) (point)))
   (when message-default-headers
     (insert message-default-headers)
-    (or (bolp) (insert hard-newline)))
+    (or (bolp) (insert ?\n)))
   (put-text-property
    (point)
    (progn
-     (insert mail-header-separator hard-newline)
+     (insert mail-header-separator "\n")
      (1- (point)))
    'read-only nil)
   (forward-line -1)
   (when (message-news-p)
     (when message-default-news-headers
       (insert message-default-news-headers)
-      (or (bolp) (insert hard-newline)))
+      (or (bolp) (insert ?\n)))
     (when message-generate-headers-first
       (message-generate-headers
        (message-headers-to-generate
@@ -5543,7 +5532,7 @@
   (when (message-mail-p)
     (when message-default-mail-headers
       (insert message-default-mail-headers)
-      (or (bolp) (insert hard-newline)))
+      (or (bolp) (insert ?\n)))
     (save-restriction
       (message-narrow-to-headers)
       (if message-alternative-emails
@@ -6025,14 +6014,14 @@
 	    (message-news)
 	  (setq buf (set-buffer (get-buffer-create " *message cancel*"))))
 	(erase-buffer)
-	(insert "Newsgroups: " newsgroups hard-newline
-		"From: " from hard-newline
-		"Subject: cmsg cancel " message-id hard-newline
-		"Control: cancel " message-id hard-newline
+	(insert "Newsgroups: " newsgroups "\n"
+		"From: " from "\n"
+		"Subject: cmsg cancel " message-id "\n"
+		"Control: cancel " message-id "\n"
 		(if distribution
-		    (concat "Distribution: " distribution hard-newline)
+		    (concat "Distribution: " distribution "\n")
 		  "")
-		mail-header-separator hard-newline
+		mail-header-separator "\n"
 		message-cancel-message)
 	(run-hooks 'message-cancel-hook)
 	(unless arg
@@ -6221,9 +6210,7 @@
 
 (defun message-forward-make-body-plain (forward-buffer)
   (insert
-   hard-newline
-   "-------------------- Start of forwarded message --------------------"
-   hard-newline)
+   "\n-------------------- Start of forwarded message --------------------\n")
   (let ((b (point)) e)
     (insert
      (with-temp-buffer
@@ -6239,9 +6226,7 @@
        (buffer-string)))
     (setq e (point))
     (insert
-     hard-newline
-     "-------------------- End of forwarded message --------------------"
-     hard-newline)
+     "\n-------------------- End of forwarded message --------------------\n")
     (when message-forward-ignored-headers
       (save-restriction
 	(narrow-to-region b e)
@@ -6251,10 +6236,7 @@
 	(message-remove-header message-forward-ignored-headers t)))))
 
 (defun message-forward-make-body-mime (forward-buffer)
-  (insert 
-   hard-newline hard-newline
-   "<#part type=message/rfc822 disposition=inline raw=t>"
-   hard-newline)
+  (insert "\n\n<#part type=message/rfc822 disposition=inline raw=t>\n")
   (let ((b (point)) e)
     (save-restriction
       (narrow-to-region (point) (point))
@@ -6264,13 +6246,10 @@
 	(replace-match "X-From-Line: "))
       (goto-char (point-max)))
     (setq e (point))
-    (insert "<#/part>" hard-newline)))
+    (insert "<#/part>\n")))
 
 (defun message-forward-make-body-mml (forward-buffer)
-  (insert 
-   hard-newline hard-newline
-   "<#mml type=message/rfc822 disposition=inline>"
-   hard-newline)
+  (insert "\n\n<#mml type=message/rfc822 disposition=inline>\n")
   (let ((b (point)) e)
     (if (not message-forward-decoded-p)
 	(insert
@@ -6293,7 +6272,7 @@
 	  (replace-match "X-From-Line: "))
 	(goto-char (point-max))))
     (setq e (point))
-    (insert "<#/mml>" hard-newline)
+    (insert "<#/mml>\n")
     (when (and (not message-forward-decoded-p)
 	       message-forward-ignored-headers)
       (save-restriction
@@ -6305,23 +6284,19 @@
 
 (defun message-forward-make-body-digest-plain (forward-buffer)
   (insert
-   hard-newline
-   "-------------------- Start of forwarded message --------------------"
-   hard-newline)
+   "\n-------------------- Start of forwarded message --------------------\n")
   (let ((b (point)) e)
     (mml-insert-buffer forward-buffer)
     (setq e (point))
     (insert
-     hard-newline
-     "-------------------- End of forwarded message --------------------"
-     hard-newline)))
+     "\n-------------------- End of forwarded message --------------------\n")))
 
 (defun message-forward-make-body-digest-mime (forward-buffer)
-  (insert hard-newline "<#multipart type=digest>" hard-newline)
+  (insert "\n<#multipart type=digest>\n")
   (let ((b (point)) e)
     (insert-buffer-substring forward-buffer)
     (setq e (point))
-    (insert "<#/multipart>" hard-newline)
+    (insert "<#/multipart>\n")
     (save-restriction
       (narrow-to-region b e)
       (goto-char b)
@@ -6826,7 +6801,7 @@
 	(message-narrow-to-headers-or-head)
 	(message-remove-header "Mime-Version")
 	(goto-char (point-max))
-	(insert "MIME-Version: 1.0" hard-newline)
+	(insert "MIME-Version: 1.0\n")
 	(when lines
 	  (insert lines))
 	(setq content-type-p
@@ -6846,7 +6821,7 @@
 	;; For unknown reason, MIME-Version doesn't exist.
 	(when (re-search-forward "^MIME-Version:" nil t)
 	  (forward-line 1)
-	  (insert "Content-Type: text/plain; charset=us-ascii" hard-newline))))))
+	  (insert "Content-Type: text/plain; charset=us-ascii\n"))))))
 
 (defun message-read-from-minibuffer (prompt &optional initial-contents)
   "Read from the minibuffer while providing abbrev expansion."
@@ -6875,7 +6850,7 @@
       (pop emails))
     (unless (or (not email) (equal email user-mail-address))
       (goto-char (point-max))
-      (insert "From: " email hard-newline))))
+      (insert "From: " email "\n"))))
 
 (defun message-options-get (symbol)
   (cdr (assq symbol message-options)))
--- a/lisp/international/mule-cmds.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/international/mule-cmds.el	Wed Nov 23 01:35:21 2005 +0000
@@ -2659,8 +2659,8 @@
    (if (and coding-system (eq (coding-system-type coding-system) 2))
        ;; Try to get a pretty description for ISO 2022 escape sequences.
        (function (lambda (x) (or (cdr (assq x iso-2022-control-alist))
-				 (format "0x%02X" x))))
-     (function (lambda (x) (format "0x%02X" x))))
+				 (format "#x%02X" x))))
+     (function (lambda (x) (format "#x%02X" x))))
    str " "))
 
 (defun encode-coding-char (char coding-system)
--- a/lisp/longlines.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/longlines.el	Wed Nov 23 01:35:21 2005 +0000
@@ -108,6 +108,7 @@
         (set (make-local-variable 'require-final-newline) nil)
         (add-to-list 'buffer-file-format 'longlines)
         (add-hook 'change-major-mode-hook 'longlines-mode-off nil t)
+	(add-hook 'before-revert-hook 'longlines-before-revert-hook nil t)
         (make-local-variable 'buffer-substring-filters)
 	(set (make-local-variable 'isearch-search-fun-function)
 	     'longlinges-search-function)
@@ -126,12 +127,27 @@
           ;; longlines-wrap-lines that we'll never encounter from here
 	  (save-restriction
 	    (widen)
-	    (longlines-decode-region (point-min) (point-max)))
+	    (longlines-decode-buffer))
           (longlines-wrap-region (point-min) (point-max))
           (set-buffer-modified-p mod))
         (when (and longlines-show-hard-newlines
                    (not longlines-showing))
           (longlines-show-hard-newlines))
+
+	;; Hacks to make longlines play nice with various modes.
+	(cond ((eq major-mode 'mail-mode)
+	       (or mail-citation-hook
+		   (add-hook 'mail-citation-hook 'mail-indent-citation nil t))
+	       (add-hook 'mail-citation-hook 'longlines-decode-region nil t))
+	      ((eq major-mode 'message-mode)
+	       (add-hook 'message-setup-hook 'longlines-decode-buffer nil t)
+	       (make-local-variable 'message-indent-citation-function)
+	       (if (not (listp message-indent-citation-function))
+		   (setq message-indent-citation-function
+			 (list message-indent-citation-function)))
+	       (add-to-list 'message-indent-citation-function
+			    'longlines-decode-region t)))
+
         (when longlines-auto-wrap
           (auto-fill-mode 0)
           (add-hook 'after-change-functions
@@ -152,6 +168,7 @@
     (remove-hook 'before-kill-functions 'longlines-encode-region t)
     (remove-hook 'after-change-functions 'longlines-after-change-function t)
     (remove-hook 'post-command-hook 'longlines-post-command-function t)
+    (remove-hook 'before-revert-hook 'longlines-before-revert-hook t)
     (remove-hook 'window-configuration-change-hook
                  'longlines-window-change-function t)
     (when longlines-wrap-follows-window-size
@@ -222,9 +239,10 @@
 If wrapping is performed, point remains on the line.  If the line does
 not need to be wrapped, move point to the next line and return t."
   (if (longlines-set-breakpoint)
-      (progn (backward-char 1)
-             (delete-char 1)
-             (insert-char ?\n 1)
+      (progn (insert-before-markers ?\n)
+	     (backward-char 1)
+             (delete-char -1)
+	     (forward-char 1)
              nil)
     (if (longlines-merge-lines-p)
         (progn (end-of-line)
@@ -298,14 +316,21 @@
                    (1+ (current-column)))
                  space))))))
 
-(defun longlines-decode-region (beg end)
-  "Turn all newlines between BEG and END into hard newlines."
+(defun longlines-decode-region (&optional beg end)
+  "Turn all newlines between BEG and END into hard newlines.
+If BEG and END are nil, the point and mark are used."
+  (if (null beg) (setq beg (point)))
+  (if (null end) (setq end (mark t)))
   (save-excursion
     (goto-char (min beg end))
     (while (search-forward "\n" (max beg end) t)
       (set-hard-newline-properties
        (match-beginning 0) (match-end 0)))))
 
+(defun longlines-decode-buffer ()
+  "Turn all newlines in the buffer into hard newlines."
+  (longlines-decode-region (point-min) (point-max)))
+
 (defun longlines-encode-region (beg end &optional buffer)
   "Replace each soft newline between BEG and END with exactly one space.
 Hard newlines are left intact.  The optional argument BUFFER exists for
@@ -413,10 +438,18 @@
 
 ;; Loading and saving
 
+(defun longlines-before-revert-hook ()
+  (add-hook 'after-revert-hook 'longlines-after-revert-hook nil t)
+  (longlines-mode 0))
+
+(defun longlines-after-revert-hook ()
+  (remove-hook 'after-revert-hook 'longlines-after-revert-hook t)
+  (longlines-mode 1))
+
 (add-to-list
  'format-alist
- (list 'longlines "Automatically wrap long lines." nil
-       'longlines-decode-region 'longlines-encode-region t nil))
+ (list 'longlines "Automatically wrap long lines." nil nil
+       'longlines-encode-region t nil))
 
 (provide 'longlines)
 
--- a/lisp/ls-lisp.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/ls-lisp.el	Wed Nov 23 01:35:21 2005 +0000
@@ -588,11 +588,11 @@
 (defun ls-lisp-format-file-size (file-size human-readable)
   (if (or (not human-readable)
           (< file-size 1024))
-      (format (if (floatp file-size) " %8.0f" " %8d") file-size)
+      (format (if (floatp file-size) " %9.0f" " %9d") file-size)
     (do ((file-size (/ file-size 1024.0) (/ file-size 1024.0))
          ;; kilo, mega, giga, tera, peta, exa
          (post-fixes (list "k" "M" "G" "T" "P" "E") (cdr post-fixes)))
-        ((< file-size 1024) (format " %7.0f%s"  file-size (car post-fixes))))))
+        ((< file-size 1024) (format " %8.0f%s"  file-size (car post-fixes))))))
 
 (provide 'ls-lisp)
 
--- a/lisp/man.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/man.el	Wed Nov 23 01:35:21 2005 +0000
@@ -919,35 +919,30 @@
 (defun Man-highlight-references (&optional xref-man-type)
   "Highlight the references on mouse-over.
 References include items in the SEE ALSO section,
-header file (#include <foo.h>) and files in FILES.
-If XREF-MAN-TYPE is used as the button type for items
-in SEE ALSO section. If it is nil, default type, 
-`Man-xref-man-page' is used."
+header file (#include <foo.h>), and files in FILES.
+If optional argument XREF-MAN-TYPE is non-nil, it used as the
+button type for items in SEE ALSO section.  If it is nil, the
+default type, `Man-xref-man-page' is used for the buttons."
   ;; `Man-highlight-references' is used from woman.el, too.
   ;; woman.el doesn't set `Man-arguments'.
   (unless Man-arguments
     (setq Man-arguments ""))
   (if (string-match "-k " Man-arguments)
       (progn
-	(Man-highlight-references0
-	 nil Man-reference-regexp 1 nil
-	 (or xref-man-type 'Man-xref-man-page))
-	(Man-highlight-references0
-	 nil Man-apropos-regexp 1 (lambda () 
-				    (format "%s(%s)"
-					    (match-string 1)
-					    (match-string 2)))
-	 (or xref-man-type 'Man-xref-man-page))
-	)
-    (Man-highlight-references0
-     Man-see-also-regexp Man-reference-regexp 1 nil
-     (or xref-man-type 'Man-xref-man-page))
-    (Man-highlight-references0
-     Man-synopsis-regexp Man-header-regexp 0 2
-     'Man-xref-header-file)
-    (Man-highlight-references0
-     Man-files-regexp Man-normal-file-regexp 0 0
-     'Man-xref-normal-file)))
+	(Man-highlight-references0 nil Man-reference-regexp 1 nil
+				   (or xref-man-type 'Man-xref-man-page))
+	(Man-highlight-references0 nil Man-apropos-regexp 1
+				   (lambda ()
+				     (format "%s(%s)"
+					     (match-string 1)
+					     (match-string 2)))
+				   (or xref-man-type 'Man-xref-man-page)))
+    (Man-highlight-references0 Man-see-also-regexp Man-reference-regexp 1 nil
+			       (or xref-man-type 'Man-xref-man-page))
+    (Man-highlight-references0 Man-synopsis-regexp Man-header-regexp 0 2
+			       'Man-xref-header-file)
+    (Man-highlight-references0 Man-files-regexp Man-normal-file-regexp 0 0
+			       'Man-xref-normal-file)))
 
 (defun Man-highlight-references0 (start-section regexp button-pos target type)
   ;; Based on `Man-build-references-alist'
--- a/lisp/menu-bar.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/menu-bar.el	Wed Nov 23 01:35:21 2005 +0000
@@ -1239,7 +1239,7 @@
 
 (define-key menu-bar-describe-menu [list-keybindings]
   '(menu-item "List Key Bindings" describe-bindings
-	      :help "Display a list of all current keybindings"))
+	      :help "Display all current keybindings (keyboard shortcuts)"))
 (define-key menu-bar-describe-menu [describe-current-display-table]
   '(menu-item "Describe Display Table" describe-current-display-table
 	      :help "Describe the current display table"))
--- a/lisp/net/browse-url.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/net/browse-url.el	Wed Nov 23 01:35:21 2005 +0000
@@ -864,7 +864,9 @@
      ((executable-find "tellw3b") 'browse-url-iximosaic)
      ((executable-find browse-url-xterm-program) 'browse-url-lynx-xterm)
      ((executable-find "mmm") 'browse-url-mmm)
-     (t 'browse-url-w3))
+     ((locate-library "w3") 'browse-url-w3)
+     (t
+      (lambda (&ignore args) (error "No usable browser found"))))
      url args))
 
 ;;;###autoload
--- a/lisp/net/rcirc.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/net/rcirc.el	Wed Nov 23 01:35:21 2005 +0000
@@ -257,7 +257,7 @@
 (defvar rcirc-process-output nil)
 (defvar rcirc-topic nil)
 (defvar rcirc-keepalive-timer nil)
-(make-variable-buffer-local 'rcirc-topic)
+(defvar rcirc-last-server-message-time nil)
 (defun rcirc-connect (server port nick user-name full-name startup-channels)
   "Return a connection to SERVER on PORT.
 
@@ -290,6 +290,8 @@
       (setq rcirc-process-output nil)
       (make-local-variable 'rcirc-startup-channels)
       (setq rcirc-startup-channels startup-channels)
+      (make-local-variable 'rcirc-last-server-message-time)
+      (setq rcirc-last-server-message-time (current-time))
 
       ;; identify
       (rcirc-send-string process (concat "NICK " nick))
@@ -313,11 +315,16 @@
      ,@body))
 
 (defun rcirc-keepalive ()
-  "Send keep alive pings to active rcirc processes."
+  "Send keep alive pings to active rcirc processes.
+Kill processes that have not received a server message since the
+last ping."
   (if (rcirc-process-list)
       (mapc (lambda (process)
               (with-rcirc-process-buffer process
-                (rcirc-send-string process (concat "PING " rcirc-server))))
+		(if (> (cadr (time-since rcirc-last-server-message-time))
+		       rcirc-keepalive-seconds)
+		    (kill-process process)
+		  (rcirc-send-string process (concat "PING " rcirc-server)))))
             (rcirc-process-list))
     (cancel-timer rcirc-keepalive-timer)
     (setq rcirc-keepalive-timer nil)))
@@ -380,6 +387,7 @@
   "Called when PROCESS receives OUTPUT."
   (rcirc-debug process output)
   (with-rcirc-process-buffer process
+    (setq rcirc-last-server-message-time (current-time))
     (setq rcirc-process-output (concat rcirc-process-output output))
     (when (= (aref rcirc-process-output
                    (1- (length rcirc-process-output))) ?\n)
@@ -582,6 +590,8 @@
   (setq rcirc-process process)
   (make-local-variable 'rcirc-target)
   (setq rcirc-target target)
+  (make-local-variable 'rcirc-topic)
+  (setq rcirc-topic nil)
 
   (make-local-variable 'rcirc-short-buffer-name)
   (setq rcirc-short-buffer-name nil)
@@ -850,8 +860,8 @@
       (process-buffer process))))
 
 (defun rcirc-format-response-string (process sender response target text)
-  (concat (when rcirc-time-format
-            (format-time-string rcirc-time-format (current-time)))
+  (concat (rcirc-facify (format-time-string rcirc-time-format (current-time))
+			'rcirc-timestamp)
           (cond ((or (string= response "PRIVMSG")
                      (string= response "NOTICE")
                      (string= response "ACTION"))
@@ -880,14 +890,15 @@
                 (t
                  (rcirc-mangle-text
                   process
-                  (rcirc-facify
-                   (concat "*** "
-			   (when (not (string= sender (rcirc-server process)))
-			     (concat (rcirc-user-nick sender) " "))
-			   (when (zerop (string-to-number response))
-			     (concat response " "))
-                           text)
-                   'rcirc-server))))))
+		  (concat (rcirc-facify "*** " 'rcirc-server-prefix)
+			  (rcirc-facify
+			   (concat
+			    (when (not (string= sender (rcirc-server process)))
+			      (concat (rcirc-user-nick sender) " "))
+			    (when (zerop (string-to-number response))
+			      (concat response " "))
+			    text)
+			   'rcirc-server)))))))
 
 (defvar rcirc-activity-type nil)
 (make-variable-buffer-local 'rcirc-activity-type)
@@ -1446,11 +1457,16 @@
   "Return a copy of STRING with FACE property added."
   (propertize (or string "") 'face face 'rear-nonsticky t))
 
-;; shy grouping must be used within this regexp
 (defvar rcirc-url-regexp
-  "\\b\\(?:\\(?:www\\.\\|\\(?:s?https?\\|ftp\\|file\\|gopher\\|news\\|telnet\
-\\|wais\\|mailto\\):\\)\\(?://[-a-zA-Z0-9_.]+:[0-9]*\\)?\\(?:[-a-zA-Z0-9_=!?#$\
-@~`%&*+|\\/:;.,]\\|\\w\\)+\\(?:[-a-zA-Z0-9_=#$@~`%&*+|\\/]\\|\\w\\)\\)"
+  (rx word-boundary 
+      (or "www."
+	  (and (or "http" "https" "ftp" "file" "gopher" "news" "telnet" "wais" 
+		   "mailto")
+	       "://"
+	       (1+ (char "a-zA-Z0-9_."))
+	       (optional ":" (1+ (char "0-9")))))
+      (1+ (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;.,"))
+      (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;"))
   "Regexp matching URL's.  Set to nil to disable URL features in rcirc.")
 
 (defun rcirc-browse-url (&optional arg)
@@ -1498,14 +1514,21 @@
   "Return TEXT with properties added based on various patterns."
   ;; ^B
   (setq text
-        (rcirc-map-regexp (lambda (start end string)
-                            (add-text-properties
-                             start end
-                             (list 'face 'bold 'rear-nonsticky t)
-                             string))
-                          ".*?"
-                          text))
-  (while (string-match "\\(.*\\)[]\\(.*\\)" text) ; deal with 
+        (rcirc-map-regexp 
+	 (lambda (start end string)
+	   (let ((orig-face (get-text-property start 'face string)))
+	       (add-text-properties
+		start end
+		(list 'face (if (listp orig-face)
+				(append orig-face 
+					(list 'bold))
+			      (list orig-face 'bold))
+		      'rear-nonsticky t)
+		string)))
+	   ".*?"
+	   text))
+  ;; TODO: deal with ^_ and ^C colors sequences
+  (while (string-match "\\(.*\\)[]\\(.*\\)" text) 
     (setq text (concat (match-string 1 text)
                        (match-string 2 text))))
   ;; my nick
@@ -1527,7 +1550,10 @@
 	 (lambda (start end string)
 	   (let ((orig-face (get-text-property start 'face string)))
 	     (add-text-properties start end
-				  (list 'face (list orig-face 'bold)
+				  (list 'face (if (listp orig-face)
+						  (append orig-face 
+							  (list 'bold))
+						(list orig-face 'bold))
 					'rear-nonsticky t
 					'mouse-face 'highlight
 					'keymap rcirc-browse-url-map)
@@ -1836,51 +1862,82 @@
   :group 'rcirc
   :group 'faces)
 
-(defface rcirc-my-nick
-  '((((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)))
+(defface rcirc-my-nick			; font-lock-function-name-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" :weight bold))
+    (t (:inverse-video t :weight bold)))
   "The face used to highlight my messages."
   :group 'rcirc-faces)
 
-(defface rcirc-other-nick
-  '((((type tty) (class color)) (:foreground "yellow" :weight light))
-    (((class grayscale) (background light))
-     (:foreground "Gray90" :bold t :italic t))
+(defface rcirc-other-nick	     ; font-lock-variable-name-face
+  '((((class grayscale) (background light))
+     (:foreground "Gray90" :weight bold :slant italic))
     (((class grayscale) (background dark))
-     (:foreground "DimGray" :bold t :italic t))
-    (((class color) (background light)) (:foreground "DarkGoldenrod"))
-    (((class color) (background dark)) (:foreground "LightGoldenrod"))
-    (t (:bold t :italic t)))
+     (:foreground "DimGray" :weight bold :slant italic))
+    (((class color) (min-colors 88) (background light)) (:foreground "DarkGoldenrod"))
+    (((class color) (min-colors 88) (background dark)) (:foreground "LightGoldenrod"))
+    (((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))
+    (t (:weight bold :slant italic)))
   "The face used to highlight other messages."
   :group 'rcirc-faces)
 
-(defface rcirc-server
-  '((((type tty pc) (class color) (background light)) (:foreground "red"))
-    (((type tty pc) (class color) (background dark)) (:foreground "red1"))
-    (((class grayscale) (background light))
-     (:foreground "DimGray" :bold t :italic t))
+(defface rcirc-server			; font-lock-comment-face
+  '((((class grayscale) (background light))
+     (:foreground "DimGray" :weight bold :slant italic))
     (((class grayscale) (background dark))
-     (:foreground "LightGray" :bold t :italic t))
-    (((class color) (background light)) (:foreground "gray40"))
-    (((class color) (background dark)) (:foreground "chocolate1"))
-    (t (:bold t :italic t)))
+     (:foreground "LightGray" :weight bold :slant italic))
+    (((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))
+     )
+    (((class color) (min-colors 8) (background dark))
+     )
+    (t (:weight bold :slant italic)))
   "The face used to highlight server messages."
   :group 'rcirc-faces)
 
-(defface rcirc-nick-in-message
-  '((((type tty) (class color)) (:foreground "cyan" :weight bold))
-    (((class grayscale) (background light)) (:foreground "LightGray" :bold t))
-    (((class grayscale) (background dark)) (:foreground "DimGray" :bold t))
-    (((class color) (background light)) (:foreground "Purple"))
-    (((class color) (background dark)) (:foreground "Cyan"))
-    (t (:bold t)))
+(defface rcirc-server-prefix	 ; font-lock-comment-delimiter-face
+  '((default :inherit font-lock-comment-face)
+    (((class grayscale)))
+    (((class color) (min-colors 16)))
+    (((class color) (min-colors 8) (background light))
+     :foreground "red")
+    (((class color) (min-colors 8) (background dark))
+     :foreground "red1"))
+  "The face used to highlight server prefixes."
+  :group 'rcirc-faces)
+
+(defface rcirc-timestamp
+  '((t (:inherit default)))
+  "The face used to highlight timestamps."
+  :group 'rcirc-faces)
+
+(defface rcirc-nick-in-message		; font-lock-keyword-face
+  '((((class grayscale) (background light)) (:foreground "LightGray" :weight bold))
+    (((class grayscale) (background dark)) (:foreground "DimGray" :weight bold))
+    (((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)) (:foreground "cyan" :weight bold))
+    (t (:weight bold)))
   "The face used to highlight instances of nick within messages."
   :group 'rcirc-faces)
 
-(defface rcirc-prompt
-  '((((background dark)) (:foreground "cyan"))
+(defface rcirc-prompt			; comint-highlight-prompt
+  '((((min-colors 88) (background dark)) (:foreground "cyan1"))
+    (((background dark)) (:foreground "cyan"))
     (t (:foreground "dark blue")))
   "The face to use to highlight prompts."
   :group 'rcirc-faces)
--- a/lisp/newcomment.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/newcomment.el	Wed Nov 23 01:35:21 2005 +0000
@@ -478,19 +478,22 @@
   (if (bolp)
       ;; comment-end = ""
       (progn (backward-char) (skip-syntax-backward " "))
-    (let ((end (point)))
-      (beginning-of-line)
-      (save-restriction
-	(narrow-to-region (point) end)
-	(if (re-search-forward (concat comment-end-skip "\\'") nil t)
-	    (goto-char (match-beginning 0))
-	  ;; comment-end-skip not found probably because it was not set right.
-	  ;; Since \\s> should catch the single-char case, we'll blindly
-	  ;; assume we're at the end of a two-char comment-end.
-	  (goto-char (point-max))
-	  (backward-char 2)
-	  (skip-chars-backward (string (char-after)))
-	  (skip-syntax-backward " "))))))
+    (cond
+     ((save-restriction
+        (narrow-to-region (line-beginning-position) (point))
+        (goto-char (point-min))
+        (re-search-forward (concat comment-end-skip "\\'") nil t))
+      (goto-char (match-beginning 0)))
+     ;; comment-end-skip not found.  Maybe we're at EOB which implicitly
+     ;; closes the comment.
+     ((eobp) (skip-syntax-backward " "))
+     (t
+      ;; else comment-end-skip was not found probably because it was not
+      ;; set right.  Since \\s> should catch the single-char case, we'll
+      ;; blindly assume we're at the end of a two-char comment-end.
+      (backward-char 2)
+      (skip-chars-backward (string (char-after)))
+      (skip-syntax-backward " ")))))
 
 ;;;;
 ;;;; Commands
--- a/lisp/paren.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/paren.el	Wed Nov 23 01:35:21 2005 +0000
@@ -181,7 +181,12 @@
 				       (cdr (syntax-after beg)))
 				   (eq (char-after beg)
 				       ;; This can give nil.
-				       (cdr (syntax-after (1- end)))))))))))))
+				       (cdr (syntax-after (1- end))))
+                                   ;; The cdr might hold a new paren-class
+                                   ;; info rather than a matching-char info,
+                                   ;; in which case the two CDRs should match.
+                                   (eq (cdr (syntax-after (1- end)))
+                                       (cdr (syntax-after beg))))))))))))
 	;;
 	;; Highlight the other end of the sexp, or unhighlight if none.
 	(if (not pos)
--- a/lisp/progmodes/gdb-ui.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/progmodes/gdb-ui.el	Wed Nov 23 01:35:21 2005 +0000
@@ -75,9 +75,11 @@
 ;;    of 'info registers'.
 ;; 3) Use tree-widget.el instead of the speedbar for watch-expressions?
 ;; 4) Mark breakpoint locations on scroll-bar of source buffer?
-;; 5) After release of 22.1 use '-var-list-children --all-values'
-;;    and '-stack-list-locals 2' which need GDB 6.1 onwards.
-;; 6) With gud-print and gud-pstar, print the variable name in the GUD
+;; 5) After release of 22.1, use "-var-list-children --all-values"
+;;    and "-stack-list-locals --simple-values" which need GDB 6.1 onwards.
+;; 6) After release of 22.1, use "-var-update --all-values" which needs
+;;    GDB 6.4 onwards.
+;; 7) With gud-print and gud-pstar, print the variable name in the GUD
 ;;    buffer instead of the value's history number.
 
 ;;; Code:
@@ -2230,6 +2232,30 @@
   "server info locals\n"
   gdb-info-locals-handler)
 
+(defvar gdb-locals-watch-keymap
+  (let ((map (make-sparse-keymap)))
+    (define-key map "\r" '(lambda () (interactive)
+			    (beginning-of-line)
+			    (gud-watch)))
+    (define-key map [mouse-2] '(lambda (event) (interactive "e")
+				 (mouse-set-point event)
+				 (beginning-of-line)
+				 (gud-watch)))
+    map)
+ "Keymap to create watch expression of a complex data type local variable.")
+
+(defconst gdb-struct-string
+  (concat (propertize "[struct/union];"
+		      'mouse-face 'highlight
+		      'help-echo "mouse-2: create watch expression"
+		      'local-map gdb-locals-watch-keymap) "\n"))
+
+(defconst gdb-array-string
+  (concat " " (propertize "[array];"
+			  'mouse-face 'highlight
+			  'help-echo "mouse-2: create watch expression"
+			  'local-map gdb-locals-watch-keymap) "\n"))
+
 ;; Abbreviate for arrays and structures.
 ;; These can be expanded using gud-display.
 (defun gdb-info-locals-handler ()
@@ -2242,10 +2268,10 @@
 	(replace-match "" nil nil))
       (goto-char (point-min))
       (while (re-search-forward "{\\(.*=.*\n\\|\n\\)" nil t)
-	(replace-match "(structure);\n" nil nil))
+	(replace-match gdb-struct-string nil nil))
       (goto-char (point-min))
       (while (re-search-forward "\\s-*{.*\n" nil t)
-	(replace-match " (array);\n" nil nil))))
+	(replace-match gdb-array-string nil nil))))
   (let ((buf (gdb-get-buffer 'gdb-locals-buffer)))
     (and buf
 	 (with-current-buffer buf
@@ -2504,6 +2530,7 @@
 	(delq 'gdb-overlay-arrow-position overlay-arrow-variable-list))
   (setq gud-running nil)
   (setq gdb-active-process nil)
+  (setq gdb-var-list nil)
   (remove-hook 'after-save-hook 'gdb-create-define-alist t))
 
 (defun gdb-source-info ()
--- a/lisp/progmodes/sh-script.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/progmodes/sh-script.el	Wed Nov 23 01:35:21 2005 +0000
@@ -986,7 +986,11 @@
 		  (when (memq (char-before) '(?\" ?\'))
 		    (condition-case nil (progn (backward-sexp 1) t)
 		      (error nil)))))
-	  (forward-comment (- (point-max)))
+          (while (progn
+                   (forward-comment (- (point-max)))
+                   ;; Maybe we've bumped into an escaped newline.
+                   (sh-is-quoted-p (point)))
+            (backward-char 1))
 	  (when (eq (char-before) ?|)
 	    (backward-char 1) t)))
     (when (save-excursion (backward-char 2) (looking-at ";;\\|in"))
--- a/lisp/simple.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/simple.el	Wed Nov 23 01:35:21 2005 +0000
@@ -893,9 +893,9 @@
 	 (col (current-column)))
     (if (= pos end)
 	(if (or (/= beg 1) (/= end (1+ total)))
-	    (message "point=%d of %d (%d%%) <%d - %d> column %d %s"
+	    (message "point=%d of %d (%d%%) <%d-%d> column=%d%s"
 		     pos total percent beg end col hscroll)
-	  (message "point=%d of %d (EOB) column %d %s"
+	  (message "point=%d of %d (EOB) column=%d%s"
 		   pos total col hscroll))
       (let ((coding buffer-file-coding-system)
 	    encoded encoding-msg display-prop under-display)
@@ -904,7 +904,7 @@
 	    (setq coding default-buffer-file-coding-system))
 	(if (not (char-valid-p char))
 	    (setq encoding-msg
-		  (format "(0%o, %d, 0x%x, invalid)" char char char))
+		  (format "(%d, #o%o, #x%x, invalid)" char char char))
 	  ;; Check if the character is displayed with some `display'
 	  ;; text property.  In that case, set under-display to the
 	  ;; buffer substring covered by that property.
@@ -923,27 +923,27 @@
 	  (setq encoding-msg
 		(if display-prop
 		    (if (not (stringp display-prop))
-			(format "(0%o, %d, 0x%x, part of display \"%s\")"
+			(format "(%d, #o%o, #x%x, part of display \"%s\")"
 				char char char under-display)
-		      (format "(0%o, %d, 0x%x, part of display \"%s\"->\"%s\")"
+		      (format "(%d, #o%o, #x%x, part of display \"%s\"->\"%s\")"
 			      char char char under-display display-prop))
 		  (if encoded
-		      (format "(0%o, %d, 0x%x, file %s)"
+		      (format "(%d, #o%o, #x%x, file %s)"
 			      char char char
 			      (if (> (length encoded) 1)
 				  "..."
 				(encoded-string-description encoded coding)))
-		    (format "(0%o, %d, 0x%x)" char char char)))))
+		    (format "(%d, #o%o, #x%x)" char char char)))))
 	(if detail
 	    ;; We show the detailed information about CHAR.
 	    (describe-char (point)))
 	(if (or (/= beg 1) (/= end (1+ total)))
-	    (message "Char: %s %s point=%d of %d (%d%%) <%d - %d> column %d %s"
+	    (message "Char: %s %s point=%d of %d (%d%%) <%d-%d> column=%d%s"
 		     (if (< char 256)
 			 (single-key-description char)
 		       (buffer-substring-no-properties (point) (1+ (point))))
 		     encoding-msg pos total percent beg end col hscroll)
-	  (message "Char: %s %s point=%d of %d (%d%%) column %d %s"
+	  (message "Char: %s %s point=%d of %d (%d%%) column=%d%s"
 		   (if enable-multibyte-characters
 		       (if (< char 128)
 			   (single-key-description char)
@@ -4320,7 +4320,11 @@
 			  (eq (syntax-class syntax) 4)
 			  (cdr syntax)))))
 	(cond
-	 ((not (eq matching-paren (char-before oldpos)))
+	 ((not (or (eq matching-paren (char-before oldpos))
+                   ;; The cdr might hold a new paren-class info rather than
+                   ;; a matching-char info, in which case the two CDRs
+                   ;; should match.
+                   (eq matching-paren (cdr (syntax-after oldpos)))))
 	  (message "Mismatched parentheses"))
 	 ((not blinkpos)
 	  (if (not blink-matching-paren-distance)
--- a/lisp/startup.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/startup.el	Wed Nov 23 01:35:21 2005 +0000
@@ -653,7 +653,7 @@
 		  (if (and (stringp (car elt))
 			   (not (file-name-absolute-p (car elt))))
 		      (cons (locate-file (car elt) load-path
-					 load-suffixes)
+					 (append load-suffixes '("")))
 			    (cdr elt))
 		    elt))
 		load-history))
@@ -1285,7 +1285,7 @@
 the user caused an input event by hitting a key or clicking with the
 mouse."
   (interactive)
-  (if (and (consp last-command-event)
+  (if (and (memq 'down (event-modifiers last-command-event))
 	   (eq (posn-window (event-start last-command-event))
 	       (selected-window)))
       ;; This is a mouse-down event in the spash screen window.
--- a/lisp/subr.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/subr.el	Wed Nov 23 01:35:21 2005 +0000
@@ -1541,6 +1541,8 @@
 	    (c 0)
 	    (echo-keystrokes 0)
 	    (cursor-in-echo-area t))
+	(add-text-properties 0 (length prompt)
+			     minibuffer-prompt-properties prompt)
 	(while (progn (message "%s%s"
 			       prompt
 			       (make-string (length pass) ?.))
--- a/lisp/textmodes/org.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/textmodes/org.el	Wed Nov 23 01:35:21 2005 +0000
@@ -1,11 +1,11 @@
-;;; org.el --- Outline-based notes management and organizer
+;;; org.el --- Outline-based notes management and organize
 ;; Carstens outline-mode for keeping track of everything.
 ;; Copyright (c) 2004, 2005 Free Software Foundation
 ;;
 ;; Author: Carsten Dominik <dominik at science dot uva dot nl>
 ;; Keywords: outlines, hypermedia, calendar
 ;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/
-;; Version: 3.19
+;; Version: 3.20
 ;;
 ;; This file is part of GNU Emacs.
 ;;
@@ -80,6 +80,20 @@
 ;;
 ;; Changes:
 ;; -------
+;; Version 3.20
+;;    - There is finally an option to make TAB jump over horizontal lines
+;;      in tables instead of creating a new line before that line.
+;;      The option is `org-table-tab-jumps-over-hlines', default nil.
+;;    - New command for sorting tables, on `C-c ^'.
+;;    - Changes to the HTML exporter
+;;      - hand-formatted lists are exported correctly, similar to
+;;        markdown lists.  Nested lists are possible.  See the docstring
+;;        of the variable `org-export-local-list-max-depth'.
+;;      - cleaned up to produce valid HTML 4.0 (transitional).
+;;      - support for cascading style sheets.
+;;    - New command to cycle through all agenda files, on C-,
+;;    - C-c [ can now also be used to change the sequence of agenda files.
+;;
 ;; Version 3.19
 ;;    - Bug fixes
 ;;
@@ -220,7 +234,7 @@
 
 ;;; Customization variables
 
-(defvar org-version "3.19"
+(defvar org-version "3.20"
   "The version number of the file org.el.")
 (defun org-version ()
   (interactive)
@@ -530,7 +544,7 @@
 
 (defcustom org-agenda-files nil
   "A list of org files for agenda/diary display.
-Entries are added to this list with \\[org-add-file] and removed with
+Entries are added to this list with \\[org-agenda-file-to-front] and removed with
 \\[org-remove-file].  You can also use customize to edit the list."
   :group 'org-agenda
   :type '(repeat file))
@@ -1128,6 +1142,17 @@
 	  (const :tag "on" t)
 	  (const :tag "on, optimized" optimized)))
 
+;; FIXME: We could have a third option which makes it jump onle over the first
+;; hline in a table.
+(defcustom org-table-tab-jumps-over-hlines t
+  "Non-nil means, tab in the last column of a table with jump over a hline.
+If a horizontal separator line is following the current line,
+`org-table-next-field' can either create a new row before that line, or jump
+over the line.  When this option is nil, a new line will be created before
+this line."
+  :group 'org-table
+  :type 'boolean)
+
 (defcustom org-table-auto-blank-field t
   "Non-nil means, automatically blank table field when starting to type into it.
 This only happens when typing immediately after a field motion
@@ -1313,7 +1338,28 @@
 
 (defcustom org-export-default-language "en"
   "The default language of HTML export, as a string.
-This should have an association in `org-export-language-setup'"
+This should have an association in `org-export-language-setup'."
+  :group 'org-export
+  :type 'string)
+
+(defcustom org-export-html-style ""
+  "The default style specification for exported HTML files.
+Since there are different ways of setting style information, this variable
+needs to contain the full HTML structure to provide a style, including the
+surrounding HTML tags.  For example, legal values would be
+
+   <style type=\"text/css\">
+       p {font-weight: normal; color: gray; }
+       h1 {color: black; }
+   </style>
+
+or
+
+   <link rel=\"stylesheet\" type=\"text/css\" href=\"mystyles.css\">
+
+As the value of this option simply gets inserted into the HTML <head> header,
+you can \"misuse\" it to add arbitrary text to the header.
+"
   :group 'org-export
   :type 'string)
 
@@ -1347,6 +1393,30 @@
   :group 'org-export
   :type 'boolean)
 
+(defcustom org-export-local-list-max-depth 1
+  "Maximum depth of hand-formatted lists in HTML export.
+Org-mode parses hand-formatted enumeration and bullet lists and
+transforms them to HTML open export.  Different indentation of the bullet
+or number indicates different list nesting levels.  To avoid confusion,
+only a single level is allowed by default.  This means that a list is started
+with an item, and that all further items are consitered as long as the
+indentation is larger or equal to the indentation of the first item.  When this
+is larger than 1, deeper indentation leads to deeper list nesting.
+If you are careful with hand formatting, you can increase this limit and
+get lists of arbitrary depth.  For example, by setting this option to 3, the
+following list would look correct in HTML:
+
+  * Fruit
+    - Apple
+    - Banana
+      1. from Africa
+      2. from South America
+    - Pineapple
+  * Bread
+  * Dairy products"
+  :group 'org-export
+  :type 'integer)
+
 (defcustom org-export-preserve-breaks nil
   "Non-nil means, preserve all line breaks when exporting.
 Normally, in HTML output paragraphs will be reformatted.  In ASCII
@@ -1874,19 +1944,8 @@
   (make-local-hook 'before-change-functions)  ;; needed for XEmacs
   (add-hook 'before-change-functions 'org-before-change-function nil
 	    'local)
-  ;; Paragraph regular expressions
-  (set (make-local-variable 'paragraph-separate) "\f\\|[ 	]*$\\|\\([*\f]+\\)")
-  (set (make-local-variable 'paragraph-start) "\f\\|[ 	]*$\\|\\([*\f]+\\)")
-  ;; Inhibit auto-fill for headers, tables and fixed-width lines.
-  (set (make-local-variable 'auto-fill-inhibit-regexp)
-       (concat "\\*\\|#"
-	       (if (or org-enable-table-editor org-enable-fixed-width-editor)
-		   (concat
-		    "\\|[ \t]*["
-		    (if org-enable-table-editor "|" "")
-		   (if org-enable-fixed-width-editor ":"  "")
-		   "]"))))
-  (set (make-local-variable 'fill-paragraph-function) 'org-fill-paragraph)
+  ;; Paragraphs and auto-filling
+  (org-set-autofill-regexps)
   ;; Settings for Calc embedded mode
   (set (make-local-variable 'calc-embedded-open-formula) "|\\|\n")
   (set (make-local-variable 'calc-embedded-close-formula) "|\\|\n")
@@ -1918,12 +1977,6 @@
 	(let ((this-command 'org-cycle) (last-command 'org-cycle))
 	  (org-cycle '(4)) (org-cycle '(4))))))))
 
-(defun org-fill-paragraph (&optional justify)
-  "Re-align a table, pass through to fill-paragraph if no table."
-  (save-excursion
-    (beginning-of-line 1)
-    (looking-at "\\s-*\\(|\\|\\+-+\\)")))
-
 (defsubst org-current-line (&optional pos)
   (+ (if (bolp) 1 0) (count-lines (point-min) (or pos (point)))))
 
@@ -4230,34 +4283,53 @@
       (error
        (add-to-diary-list original-date  "Org-mode dummy" "" nil)))))
 
-(defun org-add-file (&optional file)
-  "Add current file to the list of files in variable `org-agenda-files'.
-These are the files which are being checked for agenda entries.
-Optional argument FILE means, use this file instead of the current.
-It is possible (but not recommended) to add this function to the
-`org-mode-hook'."
-  (interactive)
-  (catch 'exit
-    (let* ((file (or file (buffer-file-name)
-		     (if (interactive-p)
-			 (error "Buffer is not visiting a file")
-		       (throw 'exit nil))))
-	   (true-file (file-truename file))
-	   (afile (abbreviate-file-name file))
-	   (present (delq nil (mapcar
-			       (lambda (x)
-				 (equal true-file (file-truename x)))
-			       org-agenda-files))))
-      (if (not present)
-	  (progn
-	    (setq org-agenda-files
-		  (cons afile org-agenda-files))
-	    ;; Make sure custom.el does not end up with Org-mode
-	    (let ((org-mode-hook nil) (default-major-mode 'fundamental-mode))
-	      (customize-save-variable 'org-agenda-files org-agenda-files))
-	    (org-install-agenda-files-menu)
-	    (message "Added file: %s" afile))
-	(message "File was already in list: %s" afile)))))
+(defun org-cycle-agenda-files ()
+  "Cycle through the files in `org-agenda-files'.
+If the current buffer visits an agenda file, find the next one in the list.
+If the current buffer does not, find the first agenda file."
+  (interactive)
+  (let ((files (append org-agenda-files (list (car org-agenda-files))))
+	(tcf (if (buffer-file-name) (file-truename (buffer-file-name))))
+	file)
+    (unless files (error "No agenda files"))
+    (catch 'exit
+      (while (setq file (pop files))
+	(if (equal (file-truename file) tcf)
+	    (when (car files)
+	      (find-file (car files))
+	      (throw 'exit t))))
+      (find-file (car org-agenda-files)))))
+
+(defun org-agenda-file-to-end (&optional file)
+  "Move/add the current file to the end of the agenda fiole list.
+I the file is not present in the list, it is appended ot the list.  If it is
+present, it is moved there."
+  (interactive)
+  (org-agenda-file-to-front 'to-end file))
+
+(defun org-agenda-file-to-front (&optional to-end file)
+  "Move/add the current file to the top of the agenda file list.
+If the file is not present in the list, it is added to the front.  If it is
+present, it is moved there.  With optional argument TO-END, add/move to the
+end of the list."
+  (interactive "P")
+  (let ((file-alist (mapcar (lambda (x)
+			      (cons (file-truename x) x))
+			    org-agenda-files))
+	(ctf (file-truename (buffer-file-name)))
+	x had)
+    (setq x (assoc ctf file-alist) had x)
+
+    (if (not x) (setq x (cons ctf (abbreviate-file-name (buffer-file-name)))))
+    (if to-end
+	(setq file-alist (append (delq x file-alist) (list x)))
+      (setq file-alist (cons x (delq x file-alist))))
+    (setq org-agenda-files (mapcar 'cdr file-alist))
+    (let ((org-mode-hook nil) (default-major-mode 'fundamental-mode))
+      (customize-save-variable 'org-agenda-files org-agenda-files))
+    (org-install-agenda-files-menu)
+    (message "File %s to %s of agenda file list"
+	     (if had "moved" "added") (if to-end "end" "front"))))
 
 (defun org-remove-file (&optional file)
   "Remove current file from the list of files in variable `org-agenda-files'.
@@ -6300,7 +6372,7 @@
 	(goto-char pos))))))
 
 (defun org-table-next-field ()
-  "Go to the next field in the current table.
+  "Go to the next field in the current table, creating new lines as needed.
 Before doing so, re-align the table if necessary."
   (interactive)
   (org-table-maybe-eval-formula)
@@ -6308,20 +6380,25 @@
   (if (and org-table-automatic-realign
 	   org-table-may-need-update)
       (org-table-align))
-  (if (org-at-table-hline-p)
-      (end-of-line 1))
-  (condition-case nil
-      (progn
-	(re-search-forward "|" (org-table-end))
-	(if (looking-at "[ \t]*$")
-	    (re-search-forward "|" (org-table-end)))
-	(if (looking-at "-")
-	    (progn
-	      (beginning-of-line 0)
-	      (org-table-insert-row 'below))
-	  (if (looking-at " ") (forward-char 1))))
-    (error
-     (org-table-insert-row 'below))))
+  (let ((end (org-table-end)))
+    (if (org-at-table-hline-p)
+	(end-of-line 1))
+    (condition-case nil
+	(progn
+	  (re-search-forward "|" end)
+	  (if (looking-at "[ \t]*$")
+	      (re-search-forward "|" end))
+	  (if (and (looking-at "-")
+		   org-table-tab-jumps-over-hlines
+		   (re-search-forward "^[ \t]*|\\([^-]\\)" end t))
+	      (goto-char (match-beginning 1)))
+	  (if (looking-at "-")
+	      (progn
+		(beginning-of-line 0)
+		(org-table-insert-row 'below))
+	    (if (looking-at " ") (forward-char 1))))
+      (error
+       (org-table-insert-row 'below)))))
 
 (defun org-table-previous-field ()
   "Go to the previous field in the table.
@@ -6472,6 +6549,7 @@
 of the field.
 If there are less than N fields, just go to after the last delimiter.
 However, when FORCE is non-nil, create new columns if necessary."
+  (interactive "p")
   (let ((pos (point-at-eol)))
     (beginning-of-line 1)
     (when (> n 0)
@@ -6490,7 +6568,7 @@
 
 (defun org-at-table-p (&optional table-type)
   "Return t if the cursor is inside an org-type table.
-If TABLE-TYPE is non-nil, also chack for table.el-type tables."
+If TABLE-TYPE is non-nil, also check for table.el-type tables."
   (if org-enable-table-editor
       (save-excursion
 	(beginning-of-line 1)
@@ -6498,6 +6576,13 @@
 		      org-table-line-regexp)))
     nil))
 
+(defun org-at-table.el-p ()
+  "Return t if and only if we are at a table.el table."
+  (and (org-at-table-p 'any)
+       (save-excursion
+	 (goto-char (org-table-begin 'any))
+	 (looking-at org-table1-hline-regexp))))
+
 (defun org-table-recognize-table.el ()
   "If there is a table.el table nearby, recognize it and move into it."
   (if org-table-tab-recognizes-table.el
@@ -6524,15 +6609,6 @@
 	nil)
     nil))
 
-(defun org-at-table.el-p ()
-  "Return t if the cursor is inside a table.el-type table."
-  (save-excursion
-    (if (org-at-table-p 'any)
-	(progn
-	  (goto-char (org-table-begin 'any))
-	  (looking-at org-table1-hline-regexp))
-      nil)))
-
 (defun org-at-table-hline-p ()
   "Return t if the cursor is inside a hline in a table."
   (if org-enable-table-editor
@@ -6745,6 +6821,49 @@
     (if (not (org-at-table-p)) (beginning-of-line 0))
     (move-to-column col)))
 
+(defun org-table-sort-lines (beg end numericp)
+  "Sort table lines in region.
+Point and mark define the first and last line to include.  Both point and
+mark should be in the column that is used for sorting.  For example, to
+sort according to column 3, put the mark in the first line to sort, in
+table column 3.  Put point into the last line to be included in the sorting,
+also in table column 3. The command will prompt for the sorting method (n for
+numerical, a for alphanumeric)."
+  (interactive "r\nsSorting method: [n]=numeric [a]=alpha: ")
+  (setq numericp (string-match "[nN]" numericp))
+  (org-table-align) ;; Just to be safe
+  (let* (bcol ecol cmp column lns)
+    (goto-char beg)
+    (org-table-check-inside-data-field)
+    (setq column (org-table-current-column)
+	  beg (move-marker (make-marker) (point-at-bol)))
+    (goto-char end)
+    (org-table-check-inside-data-field)
+    (setq end (move-marker (make-marker) (1+ (point-at-eol))))
+    (untabify beg end)
+    (goto-char beg)
+    (org-table-goto-column column)
+    (skip-chars-backward "^|")
+    (setq bcol (current-column))
+    (org-table-goto-column (1+ column))
+    (skip-chars-backward "^|")
+    (setq ecol (1- (current-column)))
+    (setq cmp (if numericp
+		  (lambda (a b) (< (car a) (car b)))
+		(lambda (a b) (string< (car a) (car b)))))
+    (setq lns (mapcar (lambda(x) (cons (org-trim (substring x bcol ecol)) x))
+		      (split-string (buffer-substring beg end) "\n")))
+    (if numericp
+	(setq lns (mapcar (lambda(x)
+			      (cons (string-to-number (car x)) (cdr x)))
+			    lns)))
+    (delete-region beg end)
+    (move-marker beg nil)
+    (move-marker end nil)
+    (insert (mapconcat 'cdr (setq lns (sort lns cmp)) "\n") "\n")
+    (message "%d lines sorted %s based on column %d"
+	     (length lns)
+	     (if numericp "numerically" "alphabetically") column)))
 
 (defun org-table-cut-region (beg end)
   "Copy region in table to the clipboard and blank all relevant fields."
@@ -8013,6 +8132,7 @@
 	  '("\C-c="              org-table-eval-formula)
 	  '("\C-c'"              org-table-edit-formulas)
 	  '("\C-c*"              org-table-recalculate)
+	  '("\C-c^"              org-table-sort-lines)
 	  '([(control ?#)]       org-table-rotate-recalc-marks)))
 	elt key fun cmd)
     (while (setq elt (pop bindings))
@@ -8063,6 +8183,7 @@
 	 ["Move Row Down" org-metadown :active (org-at-table-p) :keys "M-<down>"]
 	 ["Delete Row" org-shiftmetaup :active (org-at-table-p) :keys "M-S-<up>"]
 	 ["Insert Row" org-shiftmetadown :active (org-at-table-p) :keys "M-S-<down>"]
+	 ["Sort lines in region" org-table-sort-lines (org-at-table-p) :keys "C-c ^"]
 	 "--"
 	 ["Insert Hline" org-table-insert-hline :active (org-at-table-p) :keys "C-c -"])
 	("Rectangle"
@@ -8838,7 +8959,8 @@
   (setq-default org-todo-line-regexp org-todo-line-regexp)
   (setq-default org-deadline-line-regexp org-deadline-line-regexp)
   (setq-default org-done-string org-done-string)
-  (let* ((region-p (org-region-active-p))
+  (let* ((style org-export-html-style)
+	 (region-p (org-region-active-p))
          (region
           (buffer-substring
            (if region-p (region-beginning) (point-min))
@@ -8859,6 +8981,10 @@
          (options     nil)
 	 (quote-re    (concat "^\\*+[ \t]*" org-quote-string "\\>"))
 	 (inquote     nil)
+	 (infixed     nil)
+	 (in-local-list nil)
+	 (local-list-num nil)
+	 (local-list-indent nil)
 	 (email       user-mail-address)
          (language    org-export-default-language)
 	 (text        nil)
@@ -8875,6 +9001,7 @@
 		       (coding-system-get coding-system 'mime-charset)))
 	 table-open type
 	 table-buffer table-orig-buffer
+	 ind start-is-num starter
 	 )
     (message "Exporting...")
 
@@ -8899,16 +9026,19 @@
 
       ;; File header
       (insert (format
-               "<html lang=\"%s\"><head>
+               "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\"
+ \"http://www.w3.org/TR/REC-html40/loose.dtd\">
+<html lang=\"%s\"><head>
 <title>%s</title>
 <meta http-equiv=\"Content-Type\" content=\"text/html;charset=%s\">
 <meta name=generator content=\"Org-mode\">
 <meta name=generated content=\"%s %s\">
 <meta name=author content=\"%s\">
+%s
 </head><body>
 "
 	       language (org-html-expand title) (or charset "iso-8859-1")
-	       date time author))
+	       date time author style))
       (if title     (insert (concat "<H1 align=\"center\">"
 				    (org-html-expand title) "</H1>\n")))
       (if author    (insert (concat (nth 1 lang-words) ": " author "\n")))
@@ -8959,8 +9089,8 @@
 				   (insert
 				    (format
 				     (if todo
-					 "<li><a href=\"#sec-%d\"><span style='color:red'>%s</span></a></li>\n"
-				       "<li><a href=\"#sec-%d\">%s</a></li>\n")
+					 "<li><a href=\"#sec-%d\"><span style='color:red'>%s</span></a>\n"
+				       "<li><a href=\"#sec-%d\">%s</a>\n")
 				     head-count txt))
 				   (setq org-last-level level))
 			       ))))
@@ -8973,15 +9103,30 @@
       (org-init-section-numbers)
 
       (while (setq line (pop lines) origline line)
-	;; end of quote?
-	(when (and inquote (string-match "^\\*+" line))
-	  (insert "</pre>\n")
-	  (setq inquote nil))
-	;; inquote
-	(if inquote
-	    (progn
-	      (insert line "\n")
-	      (setq line (org-html-expand line))) ;;????? FIXME: not needed?
+	(catch 'nextline
+
+	  ;; end of quote section?
+	  (when (and inquote (string-match "^\\*+" line))
+	    (insert "</pre>\n")
+	    (setq inquote nil))
+	  ;; inside a quote section?
+	  (when inquote
+	    (insert (org-html-protect line) "\n")
+	    (throw 'nextline nil))
+
+	  ;; verbatim lines
+	  (when (and org-export-with-fixed-width
+		     (string-match "^[ \t]*:\\(.*\\)" line))
+	    (when (not infixed)
+	      (setq infixed t)
+	      (insert "<pre>\n"))
+	    (insert (org-html-protect (match-string 1 line)) "\n")
+	    (when (and lines
+		       (not (string-match "^[ \t]+\\(:.*\\)"
+					  (car lines))))
+	      (setq infixed nil)
+	      (insert "</pre>\n"))
+	    (throw 'nextline nil))
 
 	  ;; Protect the links
 	  (setq start 0)
@@ -8991,121 +9136,145 @@
 			(concat "\000" (match-string 1 line) "\000")
 			t t line)))
 
-	  ;; replace "<" and ">" by "&lt;" and "&gt;"
+	  ;; replace "&" by "&amp;", "<" and ">" by "&lt;" and "&gt;"
 	  ;; handle @<..> HTML tags (replace "@&gt;..&lt;" by "<..>")
 	  (setq line (org-html-expand line))
 
-	  ;; Verbatim lines
-	  (if (and org-export-with-fixed-width
-		   (string-match "^[ \t]*:\\(.*\\)" line))
-	      (progn
-		(let ((l (match-string 1 line)))
-		  (while (string-match " " l)
-		    (setq l (replace-match "&nbsp;" t t l)))
-		  (insert "\n<span style='font-family:Courier'>"
-			  l "</span>"
-			  (if (and lines
-				   (not (string-match "^[ \t]+\\(:.*\\)"
-						      (car lines))))
-			      "<br>\n" "\n"))))
-
-	    (setq start 0)
-	    (while (string-match org-protected-link-regexp line start)
-	      (setq start (- (match-end 0) 2))
-	      (setq type (match-string 1 line))
-	      (cond
-	       ((member type '("http" "https" "ftp" "mailto" "news"))
-		;; standard URL
-		(setq line (replace-match
+	  ;; Format the links
+	  (setq start 0)
+	  (while (string-match org-protected-link-regexp line start)
+	    (setq start (- (match-end 0) 2))
+	    (setq type (match-string 1 line))
+	    (cond
+	     ((member type '("http" "https" "ftp" "mailto" "news"))
+	      ;; standard URL
+	      (setq line (replace-match
 					;                          "<a href=\"\\1:\\2\">&lt;\\1:\\2&gt;</a>"
-			    "<a href=\"\\1:\\2\">\\1:\\2</a>"
-			    nil nil line)))
-	       ((string= type "file")
-		;; FILE link
-		(let* ((filename (match-string 2 line))
-		       (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))))
-		  (setq line (replace-match
-			      (if (and org-export-html-inline-images
-				       file-is-image-p)
-				  (concat "<img src=\"" thefile "\"/>")
-				(concat "<a href=\"" thefile "\">\\1:\\2</a>"))
-			      nil nil line))))
-
-	       ((member type '("bbdb" "vm" "wl" "rmail" "gnus" "shell"))
+			  "<a href=\"\\1:\\2\">\\1:\\2</a>"
+			  nil nil line)))
+	     ((string= type "file")
+	      ;; FILE link
+	      (let* ((filename (match-string 2 line))
+		     (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))))
 		(setq line (replace-match
-			    "<i>&lt;\\1:\\2&gt;</i>" nil nil line)))))
-
-	    ;; TODO items
-	    (if (and (string-match org-todo-line-regexp line)
-		     (match-beginning 2))
-		(if (equal (match-string 2 line) org-done-string)
-		    (setq line (replace-match
-				"<span style='color:green'>\\2</span>"
-				nil nil line 2))
-		  (setq line (replace-match "<span style='color:red'>\\2</span>"
-					    nil nil line 2))))
-
-	    ;; DEADLINES
-	    (if (string-match org-deadline-line-regexp line)
-		(progn
-		  (if (save-match-data
-			(string-match "<a href"
-				      (substring line 0 (match-beginning 0))))
-		      nil     ; Don't do the replacement - it is inside a link
-		    (setq line (replace-match "<span style='color:red'>\\&</span>"
-					      nil nil line 1)))))
-
-
-	    (cond
-	     ((string-match "^\\(\\*+\\)[ \t]*\\(.*\\)" line)
-	      ;; This is a headline
-	      (setq level (- (match-end 1) (match-beginning 1))
-		    txt (match-string 2 line))
-	      (if (<= level umax) (setq head-count (+ head-count 1)))
-	      (org-html-level-start level txt umax
-				    (and org-export-with-toc (<= level umax))
-				    head-count)
-	      ;; QUOTES
-	      (when (string-match quote-re line)
-		(insert "<pre>")
-		(setq inquote t)))
-
-	     ((and org-export-with-tables
-		   (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)" line))
-	      (if (not table-open)
-		  ;; New table starts
-		  (setq table-open t table-buffer nil table-orig-buffer nil))
-	      ;; Accumulate lines
-	      (setq table-buffer (cons line table-buffer)
-		    table-orig-buffer (cons origline table-orig-buffer))
-	      (when (or (not lines)
-			(not (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)"
-					   (car lines))))
-		(setq table-open nil
-		      table-buffer (nreverse table-buffer)
-		      table-orig-buffer (nreverse table-orig-buffer))
-		(insert (org-format-table-html table-buffer table-orig-buffer))))
-	     (t
-	      ;; Normal lines
-	      ;; Lines starting with "-", and empty lines make new paragraph.
-	      ;; FIXME: Should we add + and *?
-	      (if (string-match "^ *-\\|^[ \t]*$" line) (insert "<p>"))
-	      (insert line (if org-export-preserve-breaks "<br>\n" "\n"))))
-	    )))
-	(if org-export-html-with-timestamp
-	    (insert org-export-html-html-helper-timestamp))
-	(insert "</body>\n</html>\n")
-	(normal-mode)
-	(save-buffer)
-	(goto-char (point-min)))))
+			    (if (and org-export-html-inline-images
+				     file-is-image-p)
+				(concat "<img src=\"" thefile "\"/>")
+			      (concat "<a href=\"" thefile "\">\\1:\\2</a>"))
+			    nil nil line))))
+
+	     ((member type '("bbdb" "vm" "wl" "rmail" "gnus" "shell"))
+	      (setq line (replace-match
+			  "<i>&lt;\\1:\\2&gt;</i>" nil nil line)))))
+
+	  ;; TODO items
+	  (if (and (string-match org-todo-line-regexp line)
+		   (match-beginning 2))
+	      (if (equal (match-string 2 line) org-done-string)
+		  (setq line (replace-match
+			      "<span style='color:green'>\\2</span>"
+			      nil nil line 2))
+		(setq line (replace-match "<span style='color:red'>\\2</span>"
+					  nil nil line 2))))
+
+	  ;; DEADLINES
+	  (if (string-match org-deadline-line-regexp line)
+	      (progn
+		(if (save-match-data
+		      (string-match "<a href"
+				    (substring line 0 (match-beginning 0))))
+		    nil     ; Don't do the replacement - it is inside a link
+		  (setq line (replace-match "<span style='color:red'>\\&</span>"
+					    nil nil line 1)))))
+
+	  (cond
+	   ((string-match "^\\(\\*+\\)[ \t]*\\(.*\\)" line)
+	    ;; This is a headline
+	    (setq level (- (match-end 1) (match-beginning 1))
+		  txt (match-string 2 line))
+	    (if (<= level umax) (setq head-count (+ head-count 1)))
+	    (when in-local-list
+	      ;; Close any local lists before inserting a new header line
+	      (while local-list-num
+		(insert (if (car local-list-num) "</ol>\n" "</ul>"))
+		(pop local-list-num))
+	      (setq local-list-indent nil
+		    in-local-list nil))
+	    (org-html-level-start level txt umax
+				  (and org-export-with-toc (<= level umax))
+				  head-count)
+	    ;; QUOTES
+	    (when (string-match quote-re line)
+	      (insert "<pre>")
+	      (setq inquote t)))
+
+	   ((and org-export-with-tables
+		 (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)" line))
+	    (if (not table-open)
+		;; New table starts
+		(setq table-open t table-buffer nil table-orig-buffer nil))
+	    ;; Accumulate lines
+	    (setq table-buffer (cons line table-buffer)
+		  table-orig-buffer (cons origline table-orig-buffer))
+	    (when (or (not lines)
+		      (not (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)"
+					 (car lines))))
+	      (setq table-open nil
+		    table-buffer (nreverse table-buffer)
+		    table-orig-buffer (nreverse table-orig-buffer))
+	      (insert (org-format-table-html table-buffer table-orig-buffer))))
+	   (t
+	    ;; Normal lines
+	    (when (and (> org-export-local-list-max-depth 0)
+		       (string-match
+			"^\\( *\\)\\(\\([-+*]\\)\\|\\([0-9]+\\.\\)\\)? *\\([^ \t\n\r]\\)"
+			line))
+	      (setq ind (- (match-end 1) (match-beginning 1))
+		    start-is-num (match-beginning 4)
+		    starter (if (match-beginning 2) (match-string 2 line)))
+	      (while (and in-local-list
+			  (or (and (= ind (car local-list-indent))
+				   (not starter))
+			      (< ind (car local-list-indent))))
+		(insert (if (car local-list-num) "</ol>\n" "</ul>"))
+		(pop local-list-num) (pop local-list-indent)
+		(setq in-local-list local-list-indent))
+
+	      (cond
+	       ((and starter
+		     (or (not in-local-list)
+			 (> ind (car local-list-indent)))
+		     (< (length local-list-indent)
+			org-export-local-list-max-depth))
+		;; Start new (level of ) list
+		(insert (if start-is-num "<ol>\n<li>\n" "<ul>\n<li>\n"))
+		(push start-is-num local-list-num)
+		(push ind local-list-indent)
+		(setq in-local-list t))
+	       (starter
+		;; continue current list
+		(insert "<li>\n")))
+	      (setq line (substring line (match-beginning 5))))
+	    ;; Empty lines start a new paragraph.  If hand-formatted lists
+	    ;; are not fully interpreted, lines starting with "-", "+", "*"
+	    ;; also start a new paragraph.
+	    (if (string-match "^ [-+*]-\\|^[ \t]*$" line) (insert "<p>"))
+	    (insert line (if org-export-preserve-breaks "<br>\n" "\n"))))
+	  ))
+      (if org-export-html-with-timestamp
+	  (insert org-export-html-html-helper-timestamp))
+      (insert "</body>\n</html>\n")
+      (normal-mode)
+      (save-buffer)
+      (goto-char (point-min)))))
 
 (defun org-format-table-html (lines olines)
   "Find out which HTML converter to use and return the HTML code."
@@ -9235,18 +9404,28 @@
     (set-buffer " org-tmp2 ")
     (buffer-substring (point-min) (point-max))))
 
+(defun org-html-protect (s)
+  ;; convert & to &amp;, < to &lt; and > to &gt;
+  (let ((start 0))
+    (while (string-match "&" s start)
+      (setq s (replace-match "&amp;" t t s)
+	    start (1+ (match-beginning 0))))
+    (while (string-match "<" s)
+      (setq s (replace-match "&lt;" t t s)))
+    (while (string-match ">" s)
+      (setq s (replace-match "&gt;" t t s))))
+  s)
+
 (defun org-html-expand (string)
   "Prepare STRING for HTML export.  Applies all active conversions."
   ;; First check if there is a link in the line - if yes, apply conversions
   ;; only before the start of the link.
+  ;; FIXME: This is no longer correct, because links now have an end.
   (let* ((m (string-match org-link-regexp string))
 	 (s (if m (substring string 0 m) string))
 	 (r (if m (substring string m) "")))
-    ;; convert < to &lt; and > to &gt;
-    (while (string-match "<" s)
-      (setq s (replace-match "&lt;" t t s)))
-    (while (string-match ">" s)
-      (setq s (replace-match "&gt;" t t s)))
+    ;; convert & to &amp;, < to &lt; and > to &gt;
+    (setq s (org-html-protect s))
     (if org-export-html-expand
 	(while (string-match "@&lt;\\([^&]*\\)&gt;" s)
 	  (setq s (replace-match "<\\1>" nil nil s))))
@@ -9446,9 +9625,6 @@
     string))
 
 
-
-
-
 (defun org-export-icalendar-this-file ()
   "Export current file as an iCalendar file.
 The iCalendar file will be located in the same directory as the Org-mode
@@ -9496,7 +9672,7 @@
 	  (let ((standard-output ical-buffer))
 	    (if combine
 		(and (not started) (setq started t)
-		     (org-start-icalendar-file "OrgMode"))
+		     (org-start-icalendar-file org-icalendar-combined-name))
 	      (org-start-icalendar-file category))
 	    (org-print-icalendar-entries combine category)
 	    (when (or (and combine (not files)) (not combine))
@@ -9540,7 +9716,7 @@
 		donep (org-entry-is-done-p)))
 	(if (or (string-match org-tr-regexp hd)
 		(string-match org-ts-regexp hd))
-	    (setq hd (replace-match "" t t hd)))		
+	    (setq hd (replace-match "" t t hd)))
 	(if combine
 	    (setq hd (concat hd " (category " category ")")))
 	(if deadlinep (setq hd (concat "DL: " hd " This is a deadline")))
@@ -9693,10 +9869,12 @@
 (define-key org-mode-map "\C-c\C-y" 'org-evaluate-time-range)
 (define-key org-mode-map "\C-c>"    'org-goto-calendar)
 (define-key org-mode-map "\C-c<"    'org-date-from-calendar)
-(define-key org-mode-map "\C-c["    'org-add-file)
+(define-key org-mode-map [(control ?,)]     'org-cycle-agenda-files)
+(define-key org-mode-map "\C-c["    'org-agenda-file-to-front)
 (define-key org-mode-map "\C-c]"    'org-remove-file)
 (define-key org-mode-map "\C-c\C-r"       'org-timeline)
 (define-key org-mode-map "\C-c-"          'org-table-insert-hline)
+(define-key org-mode-map "\C-c^"          'org-table-sort-lines)
 (define-key org-mode-map "\C-c\C-c"       'org-ctrl-c-ctrl-c)
 (define-key org-mode-map "\C-m"           'org-return)
 (define-key org-mode-map "\C-c?"          'org-table-current-column)
@@ -9807,7 +9985,7 @@
       (if (fboundp 'command-remapping)
 	  (define-key map (vector 'remap old) new)
 	(substitute-key-definition old new map global-map)))))
-  
+
 (when (eq org-enable-table-editor 'optimized)
   ;; If the user wants maximum table support, we need to hijack
   ;; some standard editing functions
@@ -10044,6 +10222,7 @@
      ["Move Row Down" org-metadown (org-at-table-p)]
      ["Delete Row" org-shiftmetaup (org-at-table-p)]
      ["Insert Row" org-shiftmetadown (org-at-table-p)]
+     ["Sort lines in region" org-table-sort-lines (org-at-table-p)]
      "--"
      ["Insert Hline" org-table-insert-hline (org-at-table-p)])
     ("Rectangle"
@@ -10185,8 +10364,9 @@
    (append
     (list
      ["Edit File List" (customize-variable 'org-agenda-files) t]
-     ["Add Current File to List" org-add-file t]
+     ["Add/Move Current File to Front of List" org-agenda-file-to-front t]
      ["Remove Current File from List" org-remove-file t]
+     ["Cycle through agenda files" org-cycle-agenda-files t]
      "--")
     (mapcar 'org-file-menu-entry org-agenda-files))))
 
@@ -10243,6 +10423,58 @@
     (goto-char pos)
     (move-to-column col)))
 
+;; Paragraph filling stuff.
+;; We want this to be just right, so use the full arsenal.
+;; FIXME:  This very likely does not work correctly for XEmacs, because the
+;; filladapt package works slightly differently.
+
+(defun org-set-autofill-regexps ()
+  (interactive)
+  ;; In the paragraph separator we include headlines, because filling
+  ;; text in a line directly attached to a headline would otherwise
+  ;; fill the headline as well.
+  (set (make-local-variable 'paragraph-separate) "\f\\|\\*\\|[ 	]*$\\|[ \t]*[:|]")
+  ;; The paragraph starter includes hand-formatted lists.
+  (set (make-local-variable 'paragraph-start)
+       "\f\\|[ 	]*$\\|\\([*\f]+\\)\\|[ \t]*\\([-+*]\\|[0-9]+\\.[ \t]+\\)\\|[ \t]*[:|]")
+  ;; Inhibit auto-fill for headers, tables and fixed-width lines.
+  ;; But only if the user has not turned off tables or fixed-width regions
+  (set (make-local-variable 'auto-fill-inhibit-regexp)
+       (concat "\\*\\|#"
+	       (if (or org-enable-table-editor org-enable-fixed-width-editor)
+		   (concat
+		    "\\|[ \t]*["
+		    (if org-enable-table-editor "|" "")
+		    (if org-enable-fixed-width-editor ":"  "")
+		    "]"))))
+  ;; We use our own fill-paragraph function, to make sure that tables
+  ;; and fixed-width regions are not wrapped.  That function will pass
+  ;; through to `fill-paragraph' when appropriate.
+  (set (make-local-variable 'fill-paragraph-function) 'org-fill-paragraph)
+  ;; Adaptive filling: To get full control, first make sure that
+  ;; `adaptive-fill-regexp' never matches.  Then install our won matcher.
+  (setq adaptive-fill-regexp "\000")
+  (setq adaptive-fill-function 'org-adaptive-fill-function))
+
+(defun org-fill-paragraph (&optional justify)
+  "Re-align a table, pass through to fill-paragraph if no table."
+  (let ((table-p (org-at-table-p))
+	(table.el-p (org-at-table.el-p)))
+    (cond ((equal (char-after (point-at-bol)) ?*) t) ; skip headlines
+	  (table.el-p t)                             ; skip table.el tables
+	  (table-p (org-table-align) t)              ; align org-mode tables
+	  (t nil))))                                 ; call paragraph-fill
+
+;; For reference, this is the default value of adaptive-fill-regexp
+;;  "[ \t]*\\([-|#;>*]+[ \t]*\\|(?[0-9]+[.)][ \t]*\\)*"
+
+(defun org-adaptive-fill-function ()
+  "Return a fill prefix for org-mode files.
+In particular, this makes sure hanging paragraphs for hand-formatted lists
+work correctly."
+  (if (looking-at " *\\([-*+] \\|[0-9]+\\. \\)?")
+      (make-string (- (match-end 0) (match-beginning 0)) ?\ )))
+
 ;; Functions needed for Emacs/XEmacs region compatibility
 
 (defun org-region-active-p ()
@@ -10474,3 +10706,4 @@
 
 ;; arch-tag: e77da1a7-acc7-4336-b19e-efa25af3f9fd
 ;;; org.el ends here
+
--- a/lisp/url/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/url/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,10 @@
+2005-11-18  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* url-http.el: Use with-current-buffer.
+	(url-http-target-url): Rename from url-http-cookies-sources.
+	(url-http-parse-headers): Use it.
+	(url-http-handle-authentication): Use subst-char-in-string.
+
 2005-11-16  Juergen Hoetzel  <emacs@hoetzel.info>  (tiny change)
 
 	* url-handlers.el (url-insert-file-contents): Use the charset info
--- a/lisp/url/url-http.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/url/url-http.el	Wed Nov 23 01:35:21 2005 +0000
@@ -26,10 +26,9 @@
 
 ;;; Code:
 
-(eval-when-compile
-  (require 'cl)
-  (defvar url-http-extra-headers)
-  (defvar url-http-cookies-sources))
+(eval-when-compile (require 'cl))
+(defvar url-http-extra-headers)
+(defvar url-http-target-url)
 (require 'url-gw)
 (require 'url-util)
 (require 'url-parse)
@@ -320,16 +319,9 @@
 		  " authentication.  If you'd like to write it,"
 		  " send it to " url-bug-address ".<hr>")
 	  (setq status t))
-      (let* ((args auth)
-	     (ctr (1- (length args)))
-	     auth)
-	(while (/= 0 ctr)
-	  (if (char-equal ?, (aref args ctr))
-	      (aset args ctr ?\;))
-	  (setq ctr (1- ctr)))
-	(setq args (url-parse-args args)
-	      auth (url-get-authentication url (cdr-safe (assoc "realm" args))
-					   type t args))
+      (let* ((args (url-parse-args (subst-char-in-string ?, ?\; auth)))
+	     (auth (url-get-authentication url (cdr-safe (assoc "realm" args))
+					   type t args)))
 	(if (not auth)
 	    (setq success t)
 	  (push (cons (if proxy "Proxy-Authorization" "Authorization") auth)
@@ -358,7 +350,7 @@
 work correctly."
   (let ((cookies (mail-fetch-field "Set-Cookie" nil nil t))
 	(cookies2 (mail-fetch-field "Set-Cookie2" nil nil t))
-	(url-current-object url-http-cookies-sources))
+	(url-current-object url-http-target-url))
     (and cookies (url-http-debug "Found %d Set-Cookie headers" (length cookies)))
     (and cookies2 (url-http-debug "Found %d Set-Cookie2 headers" (length cookies2)))
     (while cookies
@@ -510,8 +502,11 @@
 	   ;; non-fully-qualified URL (ie: /), which royally confuses
 	   ;; the URL library.
 	   (if (not (string-match url-nonrelative-link redirect-uri))
-	       (setq redirect-uri (url-expand-file-name redirect-uri)))
-	   (let ((url-request-method url-http-method)
+               ;; Be careful to use the real target URL, otherwise we may
+               ;; compute the redirection relative to the URL of the proxy.
+	       (setq redirect-uri
+		     (url-expand-file-name redirect-uri url-http-target-url)))
+           (let ((url-request-method url-http-method)
 		 (url-request-data url-http-data)
 		 (url-request-extra-headers url-http-extra-headers))
 	     (url-retrieve redirect-uri url-callback-function
@@ -727,8 +722,7 @@
   (url-http-debug "url-http-end-of-document-sentinel in buffer (%s)"
 		  (process-buffer proc))
   (url-http-idle-sentinel proc why)
-  (save-excursion
-    (set-buffer (process-buffer proc))
+  (with-current-buffer (process-buffer proc)
     (goto-char (point-min))
     (if (not (looking-at "HTTP/"))
 	;; HTTP/0.9 just gets passed back no matter what
@@ -1039,8 +1033,7 @@
 	  (setq buffer nil)
 	  (error "Could not create connection to %s:%d" (url-host url)
 		 (url-port url)))
-      (save-excursion
-	(set-buffer buffer)
+      (with-current-buffer buffer
 	(mm-disable-multibyte)
 	(setq url-current-object url
 	      mode-line-format "%b [%s]")
@@ -1060,7 +1053,7 @@
 		       url-http-method
 		       url-http-extra-headers
 		       url-http-data
-		       url-http-cookies-sources))
+		       url-http-target-url))
 	  (set (make-local-variable var) nil))
 
 	(setq url-http-method (or url-request-method "GET")
@@ -1073,9 +1066,9 @@
 	      url-callback-function callback
 	      url-callback-arguments cbargs
 	      url-http-after-change-function 'url-http-wait-for-headers-change-function
-	      url-http-cookies-sources (if (boundp 'proxy-object)
-					   proxy-object
-					 url-current-object))
+	      url-http-target-url (if (boundp 'proxy-object)
+                                      proxy-object
+                                    url-current-object))
 
 	(set-process-buffer connection buffer)
 	(set-process-sentinel connection 'url-http-end-of-document-sentinel)
@@ -1096,8 +1089,7 @@
   (declare (special url-http-after-change-function))
   (and (process-buffer proc)
        (/= (length data) 0)
-       (save-excursion
-	 (set-buffer (process-buffer proc))
+       (with-current-buffer (process-buffer proc)
 	 (url-http-debug "Calling after change function `%s' for `%S'" url-http-after-change-function proc)
 	 (funcall url-http-after-change-function
 		  (point-max)
@@ -1114,8 +1106,7 @@
     (defun url-http-symbol-value-in-buffer (symbol buffer
 						   &optional unbound-value)
       "Return the value of SYMBOL in BUFFER, or UNBOUND-VALUE if it is unbound."
-      (save-excursion
-	(set-buffer buffer)
+      (with-current-buffer buffer
 	(if (not (boundp symbol))
 	    unbound-value
 	  (symbol-value symbol))))
@@ -1198,10 +1189,9 @@
     (when (and buffer (= 2 (/ (url-http-symbol-value-in-buffer
 			       'url-http-response-status buffer 0) 100)))
       ;; Only parse the options if we got a 2xx response code!
-      (save-excursion
+      (with-current-buffer buffer
 	(save-restriction
 	  (save-match-data
-	    (set-buffer buffer)
 	    (mail-narrow-to-head)
 
 	    ;; Figure out what methods are supported.
--- a/lisp/widget.el	Sat Nov 19 19:17:56 2005 +0000
+++ b/lisp/widget.el	Wed Nov 23 01:35:21 2005 +0000
@@ -71,6 +71,7 @@
 ;;  :button-face-get :button-face :value-face :keymap :entry-from
 ;;  :entry-to :help-echo :documentation-property :tab-order)
 
+(put 'define-widget 'doc-string-elt 3)  ;`declare' doesn't work in functions.
 (defun define-widget (name class doc &rest args)
   "Define a new widget type named NAME from CLASS.
 
@@ -85,7 +86,6 @@
 * (apply 'widget-create CLASS ARGS)
 
 The third argument DOC is a documentation string for the widget."
-  (declare (doc-string 3))
   (put name 'widget-type (cons class args))
   (put name 'widget-documentation doc)
   name)
--- a/lispref/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/lispref/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,23 @@
+2005-11-21  Juri Linkov  <juri@jurta.org>
+
+	* customize.texi (Common Keywords): Update links types
+	custom-manual and url-link.  Add link types emacs-library-link,
+	file-link, function-link, variable-link, custom-group-link.
+
+2005-11-20  Chong Yidong  <cyd@stupidchicken.com>
+
+	* display.texi: Revert 2005-11-20 change.
+
+2005-11-20  Thien-Thi Nguyen  <ttn@gnu.org>
+
+	* processes.texi (Bindat Functions):
+	Say "third" to refer to zero-based index "2".
+
+2005-11-18  Luc Teirlinck  <teirllm@auburn.edu>
+
+	* loading.texi (Library Search): Update the default value of
+	`load-suffixes'.
+
 2005-11-17  Chong Yidong  <cyd@stupidchicken.com>
 
 	* display.texi (Attribute Functions): Mention :ignore-defface.
--- a/lispref/customize.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/lispref/customize.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -51,25 +51,50 @@
 This is a sentence containing an active field which references some
 other documentation.
 
-There are four alternatives you can use for @var{link-data}:
+There are several alternatives you can use for @var{link-data}:
 
 @table @code
 @item (custom-manual @var{info-node})
 Link to an Info node; @var{info-node} is a string which specifies the
 node name, as in @code{"(emacs)Top"}.  The link appears as
-@samp{[manual]} in the customization buffer.
+@samp{[Manual]} in the customization buffer and enters the built-in
+Info reader on @var{info-node}.
 
 @item (info-link @var{info-node})
 Like @code{custom-manual} except that the link appears
 in the customization buffer with the Info node name.
 
 @item (url-link @var{url})
-Link to a web page; @var{url} is a string which specifies the @acronym{URL}.
-The link appears in the customization buffer as @var{url}.
+Link to a web page; @var{url} is a string which specifies the
+@acronym{URL}.  The link appears in the customization buffer as
+@var{url} and invokes the WWW browser specified by
+@var{browse-url-browser-function}.
 
 @item (emacs-commentary-link @var{library})
 Link to the commentary section of a library; @var{library} is a string
 which specifies the library name.
+
+@item (emacs-library-link @var{library})
+Link to an Emacs Lisp library file; @var{library} is a string which
+specifies the library name.
+
+@item (file-link @var{file})
+Link to a file; @var{file} is a string which specifies the name of the
+file to visit with @code{find-file} when the user invokes this link.
+
+@item (function-link @var{function})
+Link to the documentation of a function; @var{function} is a string
+which specifies the name of the function to describe with
+@code{describe-function} when the user invokes this link.
+
+@item (variable-link @var{variable})
+Link to the documentation of a variable; @var{variable} is a string
+which specifies the name of the variable to describe with
+@code{describe-variable} when the user invokes this link.
+
+@item (custom-group-link @var{group})
+Link to another customization group.  Invoking it creates a new
+customization buffer for @var{group}.
 @end table
 
 You can specify the text to use in the customization buffer by adding
--- a/lispref/display.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/lispref/display.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -1859,11 +1859,6 @@
 next face gets a chance.  However, the @code{default} face must
 specify all attributes.
 
-  Any attribute can have the value @code{:ignore-defface}.  The effect
-of this is identical to @code{unspecified}.  It exists because of an
-technical ambiguity in giving attributes the value @code{unspecified}.
-@xref{Attribute Functions}.
-
   Some of these font attributes are meaningful only on certain kinds of
 displays---if your display cannot handle a certain attribute, the
 attribute is ignored.  (The attributes @code{:family}, @code{:width},
@@ -2056,14 +2051,6 @@
 for frame @var{frame}.  If @var{frame} is @code{nil}, it sets
 the attribute for all frames, and the defaults for new frames.
 
-Unless you know what you're doing, don't set an attribute to
-@code{unspecified}.  This is ambiguous---it is unclear whether it
-means to unspecify the value stored in the frame-local copies of the
-face (which means reverting to the original face spec), or the value
-in the face spec itself.  What you probably want is to set the
-attribute to @code{:ignore-defface}.  This forces the attribute value
-to be acquired from some other face during face merging.
-
 The extra arguments @var{arguments} specify the attributes to set, and
 the values for them.  They should consist of alternating attribute names
 (such as @code{:family} or @code{:underline}) and corresponding values.
--- a/lispref/loading.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/lispref/loading.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -291,7 +291,8 @@
 @defvar load-suffixes
 This variable is a list of suffixes (strings) that @code{load} should
 try adding to the specified file name.  The default value is
-@code{(".elc" ".el")}.  There is no need to include the null suffix.
+@code{(".elc" ".elc.gz" ".el" ".el.gz" ".gz")}.  There is no need to
+include the null suffix.
 @end defvar
 
 @node Loading Non-ASCII
--- a/lispref/processes.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/lispref/processes.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -2244,7 +2244,7 @@
 acts as an array index.
 
 For example, if @var{name} is @code{(a b 2 c)}, that means to find
-field @code{c} in the second element of subfield @code{b} of field
+field @code{c} in the third element of subfield @code{b} of field
 @code{a}.  (This corresponds to @code{struct.a.b[2].c} in C.)
 @end defun
 
--- a/man/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,45 @@
+2005-11-22  Nick Roberts  <nickrob@snap.net.nz>
+
+	* building.texi (Watch Expressions): Expand description.
+	(Other GDB User Interface Buffers): Describe local map for
+	gud-watch.
+
+2005-11-21  Chong Yidong  <cyd@stupidchicken.com>
+
+	* display.texi (Font Lock): Font lock is enabled by default now.
+
+2005-11-20  Juri Linkov  <juri@jurta.org>
+
+	* basic.texi (Position Info): Update examples of the output.
+	Remove the fact that examples are produced in the TeXinfo buffer,
+	because in the Info reader users will get a different output from
+	`C-x ='.
+
+	* building.texi (Compilation Mode): Remove paragraph duplicated
+	from the node `Compilation'.  Add `compilation-skip-threshold'.
+
+	* display.texi (Font Lock): Suggest more user-friendly method of
+	finding all Font Lock faces (M-x customize-group RET font-lock-faces).
+
+2005-11-18  Richard M. Stallman  <rms@gnu.org>
+
+	* files.texi (Registering): Mention @@ in mode line.
+
+	* mini.texi (Minibuffer File): Clarify previous change.  Add @findex.
+
+2005-11-08  Aaron S. Hawley  <Aaron.Hawley@uvm.edu>  (tiny change)
+
+	* files.texi (Renaming and VC): Some back-ends don't
+	handle renaming.
+
+2005-11-18  Carsten Dominik  <dominik@science.uva.nl>
+
+	* org.texi: (FAQ): Document `org-table-tab-jumps-over-hlines'.
+	(Agenda): Document commands `org-cycle-agenda-files' and
+	`org-agenda-file-to-front'
+	(Built-in table editor): Document `org-table-sort-lines'.
+	(HTML formatting): Export of hand-formatted lists.
+
 2005-11-17  Juri Linkov  <juri@jurta.org>
 
 	* emacs.texi (Top):
@@ -71,7 +113,7 @@
 	(Installation): No installation necessary when using autoload.
 	(Configuration): Rename "RSS" to "news".
 
-2005-11-04 Ken Manheimer  <ken.manheimer@gmail.com>
+2005-11-04  Ken Manheimer  <ken.manheimer@gmail.com>
 
 	* pgg.texi (User Commands): Document additional passphrase
 	argument for pgg-encrypt-*, pgg-decrypt-*, and pgg-sign-* functions.
--- a/man/basic.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/basic.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -626,16 +626,12 @@
 that looks like this:
 
 @smallexample
-Char: c (0143, 99, 0x63)  point=21044 of 26883(78%)  column 53
+Char: c (99, #o143, #x63) point=28062 of 36168 (78%) column=53
 @end smallexample
 
-@noindent
-(In fact, this is the output produced when point is before the
-@samp{column} in the example.)
-
   The four values after @samp{Char:} describe the character that follows
 point, first by showing it and then by giving its character code in
-octal, decimal and hex.  For a non-@acronym{ASCII} multibyte character, these are
+decimal, octal and hex.  For a non-@acronym{ASCII} multibyte character, these are
 followed by @samp{file} and the character's representation, in hex, in
 the buffer's coding system, if that coding system encodes the character
 safely and with a single byte (@pxref{Coding Systems}).  If the
@@ -654,7 +650,7 @@
 in the buffer.  Afterward in parentheses comes the position expressed as a
 percentage of the total size.
 
-  @samp{column} is followed by the horizontal position of point, in
+  @samp{column=} is followed by the horizontal position of point, in
 columns from the left edge of the window.
 
   If the buffer has been narrowed, making some of the text at the
@@ -663,7 +659,7 @@
 might display this:
 
 @smallexample
-Char: C (0103, 67, 0x43)  point=252 of 889(28%) <231 - 599>  column 0
+Char: C (67, #o103, #x43) point=252 of 889 (28%) <231-599> column=0
 @end smallexample
 
 @noindent
@@ -676,7 +672,7 @@
 point.  The output might look like this:
 
 @smallexample
-point=26957 of 26956(100%)  column 0
+point=36169 of 36168 (EOB) column=0
 @end smallexample
 
 @cindex character set of character at point
@@ -720,16 +716,16 @@
 (@pxref{Font Lock}) enabled:
 
 @smallexample
-  character: @`A (04300, 2240, 0x8c0, U+00C0)
-    charset: latin-iso8859-1
+  character: @`A (2240, #o4300, #x8c0, U+00C0)
+    charset: [latin-iso8859-1]
              (Right-Hand Part of Latin Alphabet 1@dots{}
- code point: 64
+ code point: [64]
      syntax: w 	which means: word
    category: l:Latin
-   to input: type "`A"
-buffer code: 0x81 0xC0
-  file code: ESC 2C 41 40 (encoded by coding system iso-2022-7bit)
-    display: terminal code 0xC0
+   to input: type "`A" with [latin-1-prefix]
+buffer code: #x81 #xC0
+  file code: ESC #x2C #x41 #x40 (encoded by coding system iso-2022-7bit)
+    display: terminal code #xC0
 
 There are text properties here:
   fontified            t
--- a/man/building.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/building.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -153,10 +153,6 @@
 mode, whose main feature is to provide a convenient way to look at the
 source line where the error happened.
 
-  If you set the variable @code{compilation-scroll-output} to a
-non-@code{nil} value, then the compilation buffer always scrolls to
-follow output as it comes in.
-
 @table @kbd
 @item M-g M-n
 @itemx M-g n
@@ -215,6 +211,12 @@
 buffer and finds no more error messages to visit, it fails and signals
 an Emacs error.
 
+@vindex compilation-skip-threshold
+  By default, @kbd{C-x `} skips less important messages.  The variable
+@code{compilation-skip-threshold} controls this.  If its value is 2,
+@kbd{C-x `} skips anything less than error, 1 skips anything less
+than warning, and 0 doesn't skip any messages.
+
 When the left fringe is displayed, an arrow points to the
 current message in the compilation buffer. The variable
 @code{compilation-context-lines} controls the number of lines of
@@ -900,7 +902,11 @@
 
 Each watch expression is displayed in the speedbar.  Complex data
 types, such as arrays, structures and unions are represented in a tree
-format.  To expand or contract a complex data type, click @kbd{Mouse-2}
+format.  Leaves and simple data types show the name of the expression
+and its value, and display the type as a tooltip.  Higher levels
+just show the name and the data type.
+
+To expand or contract a complex data type, click @kbd{Mouse-2}
 on the tag to the left of the expression.
 
 @findex gdb-var-delete
@@ -947,8 +953,10 @@
 current frame for simple data types (@pxref{Frame Info, Frame Info,
 Information on a frame, gdb, The GNU debugger}).
 
-Arrays and structures display their type only.  You must display them
-separately to examine their values.  @xref{Watch Expressions}.
+Arrays and structures display their type only.  Move point to their
+type description ([struct/union] or [array]) and press @key{RET}, or
+alternatively click @kbd{Mouse-2} there, to examine their values.
+@xref{Watch Expressions}.
 
 @item Registers Buffer
 @findex toggle-gdb-all-registers
--- a/man/display.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/display.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -258,37 +258,40 @@
 specialized ways of assigning fonts for Font Lock mode.
 
 @findex font-lock-mode
+  Font Lock mode is turned on by default in all modes which support it.
+You can toggle font-lock for each buffer with the command @kbd{M-x
+font-lock-mode}.  Using a positive argument unconditionally turns Font
+Lock mode on, and a negative or zero argument turns it off.
+
+@findex global-font-lock-mode
+@vindex global-font-lock-mode
+  If you do not wish Font Lock mode to be turned on by default,
+customize the variable @code{global-font-lock-mode} using the Customize
+interface (@pxref{Easy Customization}), or use the function
+@code{global-font-lock-mode} in your @file{.emacs} file, like this:
+
+@example
+(global-font-lock-mode 0)
+@end example
+
+@noindent
+Global Font Lock mode can also be set using the menu bar Options menu,
+specifying first Syntax Highlighting and then Save Options.
+
 @findex turn-on-font-lock
-  The command @kbd{M-x font-lock-mode} turns Font Lock mode on with
-positive argument, off with negative or zero argument, and toggles the
-mode when it has no argument.  The function @code{turn-on-font-lock}
-unconditionally enables Font Lock mode.  This is useful in mode-hook
-functions.  For example, to enable Font Lock mode whenever you edit a
-C file, you can do this:
+  If you have disabled Global Font Lock mode, you can still enable font
+lock for specific major modes by adding the function
+@code{turn-on-font-lock} to the mode hooks (@pxref{Hooks}).  For
+example, to enable Font Lock mode for editing C files, you can do this:
 
 @example
 (add-hook 'c-mode-hook 'turn-on-font-lock)
 @end example
 
-@findex global-font-lock-mode
-@vindex global-font-lock-mode
-  To turn on Font Lock mode automatically in all modes which support
-it, customize the variable @code{global-font-lock-mode} using the
-Customize interface (@pxref{Easy Customization}) or use the function
-@code{global-font-lock-mode} in your @file{.emacs} file, like this:
-
-@example
-(global-font-lock-mode 1)
-@end example
-
-@noindent
-You can also specify this using the menu bar Options menu, specifying
-first Syntax Highlighting and then Save Options.
-
   Font Lock mode uses several specifically named faces to do its job,
 including @code{font-lock-string-face}, @code{font-lock-comment-face},
-and others.  The easiest way to find them all is to use completion
-on the face name in @code{set-face-foreground}.
+and others.  The easiest way to find them all is to use
+@kbd{M-x customize-group @key{RET} font-lock-faces @key{RET}}.
 
   To change the colors or the fonts used by Font Lock mode to fontify
 different parts of text, just change these faces.  There are
--- a/man/files.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/files.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -1762,7 +1762,8 @@
   If locking is in use, @kbd{C-x v i} leaves the file unlocked and
 read-only.  Type @kbd{C-x v v} if you wish to start editing it.  After
 registering a file with CVS, you must subsequently commit the initial
-version by typing @kbd{C-x v v}.
+version by typing @kbd{C-x v v}.  Until you do that, the version
+appears as @samp{@@@@} in the mode line.
 
 @vindex vc-default-init-version
 @cindex initial version number to register
@@ -2573,6 +2574,11 @@
 snapshot thus modified may not completely work (@pxref{Snapshot
 Caveats}).
 
+  Some backends do not provide an explicit rename operation to their
+repositories.  After issuing @code{vc-rename-file}, use @kbd{C-x v v}
+on the original and renamed buffers and provide the necessary edit
+log.
+
   You cannot use @code{vc-rename-file} on a file that is locked by
 someone else.
 
--- a/man/mini.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/mini.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -105,12 +105,13 @@
 @cindex // in file name
 @cindex double slash in file name
 @cindex slashes repeated in file name
+@findex file-name-shadow-mode
 GNU Emacs gives a special meaning to a double slash (which is not
-normally a useful thing to write): it means, ``ignore everything before
-the second slash in the pair.''  Thus, @samp{/u2/emacs/src/} is ignored
-in the example above, and you get the file @file{/etc/termcap}.
-By default the ignored part of the file name is made dim if the
-terminal allows it.  This is affected by the
+normally a useful thing to write): it means, ``ignore everything
+before the second slash in the pair.''  Thus, @samp{/u2/emacs/src/} is
+ignored in the example above, and you get the file
+@file{/etc/termcap}.  The ignored part of the file name is dimmed if
+the terminal allows it; to disable this, turn off
 @code{file-name-shadow-mode} minor mode.
 
   If you set @code{insert-default-directory} to @code{nil}, the default
--- a/man/org.texi	Sat Nov 19 19:17:56 2005 +0000
+++ b/man/org.texi	Wed Nov 23 01:35:21 2005 +0000
@@ -4,7 +4,7 @@
 @setfilename ../info/org
 @settitle Org Mode Manual
 
-@set VERSION 3.19
+@set VERSION 3.20
 @set DATE October 2005
 
 @dircategory Emacs
@@ -698,6 +698,13 @@
 Insert a horizontal line below current row. With prefix arg, the line
 is created above the current line.
 
+@kindex C-c ^
+@item C-c ^
+Sort the table lines in the region.  Point and mark must be in the first
+and last line to be included, and must be in the column that should be
+used for sorting.  The command prompts for numerical versus
+alphnumerical sorting.
+
 @tsubheading{Regions}
 @kindex C-c C-x M-w
 @item C-c C-x M-w
@@ -859,13 +866,13 @@
 @end example
 
 The range vectors can be directly fed into the calc vector functions
-like functions @samp{vmean} and @samp{vsum}.
+like @samp{vmean} and @samp{vsum}.
 
 @samp{$name} is interpreted as the name of a column, parameter or
 constant.  Constants are defined globally through the variable
 @code{org-table-formula-constants}.  If you have the
 @file{constants.el} package, it will also be used to resolve
-constants, including natural constants like @samp{$k} for Planck's
+constants, including natural constants like @samp{$h} for Planck's
 constant, units like @samp{$km} for kilometers.  Column names and
 parameters can be specified in special table lines.  These are
 described below, see @ref{Advanced features}.
@@ -972,7 +979,7 @@
 The fields in this line define names for the columns, so that you may
 refer to a column as @samp{$Tot} instead of @samp{$6}.
 @item ^
-This row define names for the fields @emph{above} the row.  With such
+This row defines names for the fields @emph{above} the row.  With such
 a definition, any formula in the table may use @samp{$m1} to refer to
 the value @samp{10}.  Also, named fields can have their own formula
 associated with them.
@@ -1762,10 +1769,15 @@
 @table @kbd
 @kindex C-c [
 @item C-c [
-Add current file to the list of agenda files
+Add current file to the list of agenda files.  The file is added to
+the front of the list.  If it was already in the list, it is moved to
+the front.  With prefix arg, file is added/moved to the end.
 @kindex C-c ]
 @item C-c ]
 Remove current file from the list of agenda files.
+@kindex C-,
+@item C-,
+Cycle through agenda file list.
 @end table
 @noindent
 The Org menu contains the list of all files and can be used to quickly
@@ -2202,7 +2214,9 @@
 @section HTML export
 @cindex HTML export
 
-Org-mode contains an HTML exporter with extensive HTML formatting.
+Org-mode contains an HTML exporter with extensive HTML formatting, in
+ways similar to John Grubers @emph{markdown} language, but with
+additional support for tables.
 
 @cindex region, active
 @cindex active region
@@ -2246,6 +2260,34 @@
 exporter implements the following interpretation:
 
 @itemize @bullet
+
+@cindex hand-formatted lists
+@cindex lists, hand-formatted
+@item
+Hand-formatted lists with @samp{-}, @samp{*} or @samp{+} as
+bullet@footnote{When using @samp{*} as a bullet, lines must be
+indented or they will be seen as top-level headlines.}, or
+with @samp{1.}, @samp{2.} as enumerator will be recognized and
+transformed into HTML lists.  The
+lists is terminated by the next headline, or by a line that is
+indented like the bullet/enumerator in the first line, or less.  For
+example: 
+@example
+** Lord of the Rings
+Some of my favorite scenes are
+- Eowyns fight
+- The attack of the Roherim
+  (this may be favorite one)
+- Peter Jackson being shot by Legolas,
+  in the extended DVD edition only  
+My favorite characters are (in this sequence):
+  1. Sam
+  2. Eowyn
+  3. Aragorn
+Among the others I don't really have a preference.
+@end example
+By default, only no nesting of lists is allowed, but see the variable
+@code{org-export-local-list-max-depth}.
 @cindex underlined text
 @cindex bold text
 @cindex italic text
@@ -2337,6 +2379,26 @@
 TeX:    @r{turn on/off @TeX{} macros}
 @end example
 
+You can also give style information for the exported file.  The
+default specification can be configured through the option
+@code{org-export-html-style}.  If you want to use a file-local style,
+you may use file variables, best wrapped into a COMMENT section at the
+end of the outline tree.  For example:
+
+@example
+* COMMENT HTML style specifications
+
+# Local Variables: 
+# org-export-html-style: "   <style type=\"text/css\">
+       p @{font-weight: normal; color: gray; @}
+       h1 @{color: black; @}
+   </style>"
+# End: ***
+@end example
+
+Remember to execute @kbd{M-x normal-mode} after changing this to make
+the new style visible to Emacs.
+
 @node Comment lines,  , Export options, HTML export
 @subsection Comment lines
 @cindex comment lines
@@ -2532,6 +2594,7 @@
 @i{before} the horizontal line.  How can I quickly move to the line
 @i{below} the horizontal line instead?}@*
 Press @key{down} (to get on the separator line) and then @key{TAB}.
+Or configure the variable @code{org-table-tab-jumps-over-hlines}.
 
 @item @b{How can I change the indentation of an entire table without
 fixing every line by hand?}@*
@@ -2649,13 +2712,13 @@
 have found too hard to fix.
 
 @itemize @bullet
-@item
-If you call @code{fill-paragraph} (bound to @kbd{M-q}) in a table, the
-filling is correctly disabled.  However, if some text directly
-(without an empty line in between) precedes or follows a table, calling
-@code{fill-paragraph} in that text will also fill the table like
-normal text.  Also, @code{fill-region} does bypass the
-@code{fill-paragraph} code and will fill tables like normal text.
+@c @item
+@c If you call @code{fill-paragraph} (bound to @kbd{M-q}) in a table, the
+@c filling is correctly disabled.  However, if some text directly
+@c (without an empty line in between) precedes or follows a table, calling
+@c @code{fill-paragraph} in that text will also fill the table like
+@c normal text.  Also, @code{fill-region} does bypass the
+@c @code{fill-paragraph} code and will fill tables like normal text.
 @item
 Text in an entry protected with the @samp{QUOTE} keyword should not
 autowrap.
--- a/nt/INSTALL	Sat Nov 19 19:17:56 2005 +0000
+++ b/nt/INSTALL	Wed Nov 23 01:35:21 2005 +0000
@@ -29,11 +29,55 @@
 
   To compile Emacs, you will need either Microsoft Visual C++ 2.0 or
   later and nmake, or a Windows port of GCC 2.95 or later with MinGW
-  and W32 API support and a port of GNU make.  You can use the Cygwin
+  and W32 API support and a port of GNU Make.  You can use the Cygwin
   ports of GCC, but Emacs requires the MinGW headers and libraries to
   build (latest versions of the Cygwin toolkit, at least since v1.3.3,
   include the MinGW headers and libraries as an integral part).
 
+  If you use the MinGW port of GCC and GNU Make to build Emacs, there
+  are some compatibility issues wrt Make and the shell that is run by
+  Make, either the standard COMMAND.COM/CMD.EXE supplied with Windows
+  or sh.exe., a port of a Unixy shell.  For reference, here is a list
+  of which builds of GNU Make are known to work or not, and whether
+  they work in the presence and/or absence of sh.exe, the Cygwin port
+  of Bash. Note that any version of Make that is compiled with Cygwin
+  will only work with Cygwin tools, due to the use of cygwin style
+  paths.  This means Cygwin Make is unsuitable for building parts of
+  Emacs that need to invoke Emacs itself (leim and "make bootstrap",
+  for example).  Also see the Trouble-shooting section below if you
+  decide to go ahead and use Cygwin make.
+
+  In addition, using 4NT as your shell is known to fail the build process,
+  at least for 4NT version 3.01.  Use CMD.EXE, the default Windows shell,
+  instead. MSYS sh.exe also appears to cause various problems. If you have
+  MSYS installed, try "make SHELL=cmd.exe" to force the use of cmd.exe
+  instead of sh.exe.
+
+                                         sh exists     no sh
+
+    cygwin b20.1 make (3.75):            fails[1, 5]   fails[2, 5]
+    MSVC compiled gmake 3.77:            okay          okay
+    MSVC compiled gmake 3.78.1:          okay          okay
+    MSVC compiled gmake 3.79.1:          okay          okay
+    mingw32/gcc-2.92.2 make (3.77):      okay          okay[4]
+    cygwin compiled gmake 3.77:          fails[1, 5]   fails[2, 5]
+    cygwin compiled make 3.78.1:         fails[5]      fails[2, 5]
+    cygwin compiled make 3.79.1:         fails[3, 5]   fails[2?, 5]
+    mingw32 compiled make 3.79.1:        okay          okay
+    mingw32 compiled make 3.80:          okay          unknown[6]
+
+  Notes:
+
+    [1] doesn't cope with makefiles with DOS line endings, so must mount
+        emacs source with text!=binary.
+    [2] fails when needs to invoke shell commands; okay invoking gcc etc.
+    [3] requires LC_MESSAGES support to build; cannot build with early
+        versions of cygwin.
+    [4] may fail on Windows 9X and Windows ME; if so, install Bash.
+    [5] fails when building leim due to the use of cygwin style paths.
+        May work if building emacs without leim.
+    [6] please report if you try this combination.
+
   Other compilers may work, but specific reports from people that have
   tried suggest that the Intel C compiler (for example) may produce an
   Emacs executable with strange filename completion behaviour.  Unless
@@ -62,46 +106,6 @@
 
   http://ourcomments.org/Emacs/w32-build-emacs.html
 
-  For reference, here is a list of which builds of GNU make are known
-  to work or not, and whether they work in the presence and/or absence
-  of sh.exe, the Cygwin port of Bash. Note that any version of make
-  that is compiled with Cygwin will only work with Cygwin tools, due to
-  the use of cygwin style paths. This means Cygwin make is unsuitable
-  for building parts of Emacs that need to invoke Emacs itself (leim and
-  "make bootstrap", for example). Also see the Trouble-shooting section
-  below if you decide to go ahead and use Cygwin make.
-
-  In addition, using 4NT as your shell is known to fail the build process,
-  at least for 4NT version 3.01.  Use cmd.exe, the default NT shell,
-  instead. MSYS sh.exe also appears to cause various problems. If you have
-  MSYS installed, try "make SHELL=cmd.exe" to force the use of cmd.exe
-  instead of sh.exe.
-
-                                         sh exists     no sh
-
-    cygwin b20.1 make (3.75):            fails[1, 5]   fails[2, 5]
-    MSVC compiled gmake 3.77:            okay          okay
-    MSVC compiled gmake 3.78.1:          okay          okay
-    MSVC compiled gmake 3.79.1:          okay          okay
-    mingw32/gcc-2.92.2 make (3.77):      okay          okay[4]
-    cygwin compiled gmake 3.77:          fails[1, 5]   fails[2, 5]
-    cygwin compiled make 3.78.1:         fails[5]      fails[2, 5]
-    cygwin compiled make 3.79.1:         fails[3, 5]   fails[2?, 5]
-    mingw32 compiled make 3.79.1:        okay          okay
-    mingw32 compiled make 3.80:          okay          unknown[6]
-
-  Notes:
-
-    [1] doesn't cope with makefiles with DOS line endings, so must mount
-        emacs source with text!=binary.
-    [2] fails when needs to invoke shell commands; okay invoking gcc etc.
-    [3] requires LC_MESSAGES support to build; cannot build with early
-        versions of cygwin.
-    [4] may fail on Windows 9X and Windows ME; if so, install Bash.
-    [5] fails when building leim due to the use of cygwin style paths.
-        May work if building emacs without leim.
-    [6] please report if you try this combination.
-
 * Configuring
 
   Configuration of Emacs is now handled by running configure.bat in the
--- a/src/.gdbinit	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/.gdbinit	Wed Nov 23 01:35:21 2005 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998, 2000, 01, 2004
+# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998, 2000, 01, 2004, 2005
 #   Free Software Foundation, Inc.
 #
 # This file is part of GNU Emacs.
@@ -628,7 +628,7 @@
 end
 
 define nextcons
-  p $.cdr
+  p $.u.cdr
   xcons
 end
 document nextcons
@@ -648,7 +648,7 @@
 define xcdr
   xgetptr $
   xgettype $
-  print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->cdr : 0)
+  print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->u.cdr : 0)
 end
 document xcdr
 Print the cdr of $, assuming it is an Emacs Lisp pair.
@@ -656,7 +656,7 @@
 
 define xfloat
   xgetptr $
-  print ((struct Lisp_Float *) $ptr)->data
+  print ((struct Lisp_Float *) $ptr)->u.data
 end
 document xfloat
 Print $ assuming it is a lisp floating-point number.
--- a/src/ChangeLog	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/ChangeLog	Wed Nov 23 01:35:21 2005 +0000
@@ -1,3 +1,46 @@
+2005-11-21  Ken Raeburn  <raeburn@mit.edu>
+
+	* keymap.c (shadow_lookup): Use make_number to pass a number to
+	Fsubstring.
+
+2005-11-21  Juri Linkov  <juri@jurta.org>
+
+	* puresize.h (BASE_PURESIZE): Increment to 1180000.
+
+2005-11-20  Chong Yidong  <cyd@stupidchicken.com>
+
+	* xfaces.c (Finternal_set_lisp_face_attribute): Use
+	:ignore-defface for new frame defaults when `unspecified' is
+	supplied.
+	(Finternal_get_lisp_face_attribute): Hide :ignore-defface.
+	(merge_face_vectors): Don't do :ignore-defface overwriting here.
+	(Finternal_merge_in_global_face): Do it here.
+
+2005-11-20  Juri Linkov  <juri@jurta.org>
+
+	* charset.c (invalid_character): Use Lisp-readable syntax
+	for octal and hex.  Reorder decimal, octal and hex values.
+
+2005-11-20  Nick Roberts  <nickrob@snap.net.nz>
+
+	* lisp.h: Use typedef when Lisp_Object is EMACS_INT so that
+	this type is recognised when debugging.
+
+2005-11-19  Andreas Schwab  <schwab@suse.de>
+
+	* .gdbinit (nextcons, xcdr, xfloat): Update for changes in
+	Lisp_Cons and Lisp_Float.
+
+2005-11-19  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* macterm.c [USE_CG_TEXT_DRAWING] (cg_text_anti_aliasing_threshold):
+	New variable.
+	[USE_CG_TEXT_DRAWING] (init_cg_text_anti_aliasing_threshold): New
+	function.
+	(init_font_name_table) [USE_ATSUI && USE_CG_TEXT_DRAWING]: Use it.
+	[USE_CG_TEXT_DRAWING] (mac_draw_string_cg): Don't do antialiasing if
+	font size is smaller than or equal to cg_text_anti_aliasing_threshold.
+
 2005-11-17  Chong Yidong  <cyd@stupidchicken.com>
 
 	* image.c (x_create_bitmap_from_xpm_data): Free attributes on
--- a/src/charset.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/charset.c	Wed Nov 23 01:35:21 2005 +0000
@@ -115,7 +115,7 @@
 invalid_character (c)
      int c;
 {
-  error ("Invalid character: 0%o, %d, 0x%x", c, c, c);
+  error ("Invalid character: %d, #o%o, #x%x", c, c, c);
 }
 
 /* Parse string STR of length LENGTH and fetch information of a
--- a/src/image.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/image.c	Wed Nov 23 01:35:21 2005 +0000
@@ -3755,7 +3755,7 @@
   XpmFreeAttributes (&attrs);
   return id;
 }
-#endif /* HAVE_X_WINDOWS */
+#endif /* defined (HAVE_XPM) && defined (HAVE_X_WINDOWS) */
 
 /* Load image IMG which will be displayed on frame F.  Value is
    non-zero if successful.  */
--- a/src/keymap.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/keymap.c	Wed Nov 23 01:35:21 2005 +0000
@@ -2372,7 +2372,8 @@
       value = Flookup_key (XCAR (tail), key, flag);
       if (NATNUMP (value))
 	{
-	  value = Flookup_key (XCAR (tail), Fsubstring (key, 0, value), flag);
+	  value = Flookup_key (XCAR (tail),
+			       Fsubstring (key, make_number (0), value), flag);
 	  if (!NILP (value))
 	    return Qnil;
 	}
--- a/src/lisp.h	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/lisp.h	Wed Nov 23 01:35:21 2005 +0000
@@ -253,7 +253,7 @@
 /* If union type is not wanted, define Lisp_Object as just a number.  */
 
 #ifdef NO_UNION_TYPE
-#define Lisp_Object EMACS_INT
+typedef EMACS_INT Lisp_Object;
 #define LISP_MAKE_RVALUE(o) (0+(o))
 #endif /* NO_UNION_TYPE */
 
--- a/src/macterm.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/macterm.c	Wed Nov 23 01:35:21 2005 +0000
@@ -867,6 +867,19 @@
 #if USE_CG_TEXT_DRAWING
 static XCharStruct *x_per_char_metric P_ ((XFontStruct *, XChar2b *));
 
+static int cg_text_anti_aliasing_threshold = 8;
+
+static void
+init_cg_text_anti_aliasing_threshold ()
+{
+  Lisp_Object val =
+    Fmac_get_preference (build_string ("AppleAntiAliasingThreshold"),
+			 Qnil, Qnil, Qnil);
+
+  if (INTEGERP (val))
+    cg_text_anti_aliasing_threshold = XINT (val);
+}
+
 static int
 mac_draw_string_cg (f, gc, x, y, buf, nchars)
      struct frame *f;
@@ -915,6 +928,8 @@
 			    1.0);
   CGContextSetFont (context, GC_FONT (gc)->cg_font);
   CGContextSetFontSize (context, GC_FONT (gc)->mac_fontsize);
+  if (GC_FONT (gc)->mac_fontsize <= cg_text_anti_aliasing_threshold)
+    CGContextSetShouldAntialias (context, false);
 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1030
   CGContextSetTextPosition (context, gx, gy);
   CGContextShowGlyphsWithAdvances (context, glyphs, advances, nchars);
@@ -6784,6 +6799,9 @@
   text_encoding_info_alist = create_text_encoding_info_alist ();
 
 #if USE_ATSUI
+#if USE_CG_TEXT_DRAWING
+  init_cg_text_anti_aliasing_threshold ();
+#endif
   if (!NILP (assq_no_quit (make_number (kTextEncodingMacUnicode),
 			   text_encoding_info_alist)))
     {
--- a/src/xfaces.c	Sat Nov 19 19:17:56 2005 +0000
+++ b/src/xfaces.c	Wed Nov 23 01:35:21 2005 +0000
@@ -3593,8 +3593,6 @@
       {
 	if (i == LFACE_HEIGHT_INDEX && !INTEGERP (from[i]))
 	  to[i] = merge_face_heights (from[i], to[i], to[i]);
-	else if (IGNORE_DEFFACE_P (from[i]))
-	  to[i] = Qunspecified;
 	else
 	  to[i] = from[i];
       }
@@ -4071,7 +4069,18 @@
 
   /* Set lface to the Lisp attribute vector of FACE.  */
   if (EQ (frame, Qt))
-    lface = lface_from_face_name (NULL, face, 1);
+    {
+      lface = lface_from_face_name (NULL, face, 1);
+
+      /* When updating face-new-frame-defaults, we put :ignore-defface
+	 where the caller wants `unspecified'.  This forces the frame
+	 defaults to ignore the defface value.  Otherwise, the defface
+	 will take effect, which is generally not what is intended.
+	 The value of that attribute will be inherited from some other
+	 face during face merging.  See internal_merge_in_global_face. */
+      if (UNSPECIFIEDP (value))
+      	value = Qignore_defface;
+    }
   else
     {
       if (NILP (frame))
@@ -4897,6 +4906,9 @@
   else
     signal_error ("Invalid face attribute name", keyword);
 
+  if (IGNORE_DEFFACE_P (value))
+    return Qunspecified;
+
   return value;
 }
 
@@ -4979,7 +4991,10 @@
   gvec = XVECTOR (global_lface)->contents;
   for (i = 1; i < LFACE_VECTOR_SIZE; ++i)
     if (! UNSPECIFIEDP (gvec[i]))
-      lvec[i] = gvec[i];
+      if (IGNORE_DEFFACE_P (gvec[i]))
+	lvec[i] = Qunspecified;
+      else
+	lvec[i] = gvec[i];
 
   return Qnil;
 }