changeset 83269:48ba3f89c89f

Merged from miles@gnu.org--gnu-2005 (patch 37-38, 162-182) Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-162 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-163 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-164 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-165 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-166 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-167 Tweak obsolete function/variable warning message * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-168 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-169 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-170 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-171 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-172 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-173 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-174 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-175 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-176 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-177 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-178 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-179 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-180 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-181 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-182 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-37 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-38 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-309
author Karoly Lorentey <lorentey@elte.hu>
date Wed, 16 Mar 2005 16:06:15 +0000
parents 7ea3d7198adc (current diff) 6e0e511d2c69 (diff)
children 42406ecdf5bf
files ChangeLog admin/FOR-RELEASE etc/TODO lisp/ChangeLog lisp/bindings.el lisp/emacs-lisp/bytecomp.el lisp/faces.el lisp/international/mule-cmds.el lisp/progmodes/gdb-ui.el lisp/simple.el lisp/subr.el lispref/ChangeLog man/ChangeLog src/coding.c src/dispextern.h src/fileio.c src/fontset.c src/frame.c src/keyboard.c src/macterm.c src/xdisp.c src/xfns.c src/xmenu.c
diffstat 74 files changed, 1841 insertions(+), 1092 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,8 @@
+2005-03-10  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
+
+	* configure.in: Only add XASSERTS to cppflags.
+	* configure: Regenerate.
+
 2005-03-04  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
 	* configure.in: Added --enable-asserts.
--- a/admin/FOR-RELEASE	Wed Mar 16 16:03:44 2005 +0000
+++ b/admin/FOR-RELEASE	Wed Mar 16 16:06:15 2005 +0000
@@ -178,14 +178,14 @@
 
 SECTION             READERS
 -----------------------------
-man/abbrevs.texi    Chong Yidong
+man/abbrevs.texi    Chong Yidong    Joakim Verona
 man/anti.texi
 man/basic.texi      "Luc Teirlinck"  Chong Yidong
 man/buffers.texi    "Luc Teirlinck"  Chong Yidong
 man/building.texi   "Ted Zlatanov" <tzz@lifelogs.com>
-man/calendar.texi   joakim@verona.se
+man/calendar.texi   joakim@verona.se  Chong Yidong
 man/cmdargs.texi    Chong Yidong
-man/commands.texi   "Luc Teirlinck"
+man/commands.texi   "Luc Teirlinck"  Chong Yidong
 man/custom.texi     Chong Yidong
 man/dired.texi      Chong Yidong     joakim@verona.se
 man/display.texi    "Luc Teirlinck"  Chong Yidong
@@ -194,7 +194,7 @@
 man/files.texi      "Luc Teirlinck"  Chong Yidong
 man/fixit.texi      "Luc Teirlinck"  Chong Yidong
 man/frames.texi     "Luc Teirlinck"  Chong Yidong
-man/glossary.texi
+man/glossary.texi   Chong Yidong
 man/help.texi       "Luc Teirlinck"  Chong Yidong
 man/indent.texi     "Luc Teirlinck"  Chong Yidong
 man/killing.texi    "Luc Teirlinck"  Chong Yidong
@@ -204,17 +204,17 @@
 man/major.texi      "Luc Teirlinck"  Chong Yidong
 man/mark.texi       "Luc Teirlinck"  Chong Yidong
 man/mini.texi       "Luc Teirlinck"  Chong Yidong
-man/misc.texi
+man/misc.texi       Chong Yidong
 man/msdog.texi      Chong Yidong
 man/mule.texi       "Luc Teirlinck"
 man/m-x.texi        "Luc Teirlinck"  Chong Yidong
 man/picture.texi    Joakim Verona <joakim@verona.se>
 man/programs.texi   "Stephen Eglen"  Chong Yidong
 man/regs.texi       "Luc Teirlinck"   Chong Yidong
-man/rmail.texi
+man/rmail.texi      Chong Yidong
 man/screen.texi     "Luc Teirlinck"  Chong Yidong
 man/search.texi     "Luc Teirlinck"
-man/sending.texi
+man/sending.texi    Chong Yidong
 man/text.texi       "Luc Teirlinck"   Chong Yidong
 man/trouble.texi    Chong Yidong
 man/windows.texi    "Luc Teirlinck"   Chong Yidong
@@ -234,14 +234,14 @@
 lispref/anti.texi
 lispref/backups.texi     "Luc Teirlinck"   Chong Yidong
 lispref/buffers.texi     "Luc Teirlinck"   Chong Yidong
-lispref/calendar.texi    Joakim Verona <joakim@verona.se>
+lispref/calendar.texi    Joakim Verona <joakim@verona.se>  Chong Yidong
 lispref/commands.texi    "Luc Teirlinck"   Chong Yidong
 lispref/compile.texi     "Luc Teirlinck"   Chong Yidong
 lispref/control.texi     "Luc Teirlinck"   Chong Yidong
-lispref/customize.texi
+lispref/customize.texi   Chong Yidong
 lispref/debugging.texi   Joakim Verona <joakim@verona.se>   Lute Kamstra
-lispref/display.texi
-lispref/edebug.texi
+lispref/display.texi     Chong Yidong
+lispref/edebug.texi      Chong Yidong
 lispref/elisp.texi       "Luc Teirlinck"
 lispref/errors.texi      "Luc Teirlinck"
 lispref/eval.texi        "Luc Teirlinck"   Chong Yidong
@@ -251,7 +251,7 @@
 lispref/hash.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/help.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/hooks.texi
-lispref/internals.texi	 "Luc Teirlinck"
+lispref/internals.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/intro.texi	 "Luc Teirlinck"
 lispref/keymaps.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/lists.texi	 "Luc Teirlinck"   Chong Yidong
@@ -262,7 +262,7 @@
 lispref/markers.texi     "Luc Teirlinck"   Chong Yidong
 lispref/minibuf.texi     "Luc Teirlinck"   Chong Yidong
 lispref/modes.texi	 Chong Yidong
-lispref/nonascii.texi    "Luc Teirlinck"
+lispref/nonascii.texi    "Luc Teirlinck"   Chong Yidong
 lispref/numbers.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/objects.texi	 "Luc Teirlinck"   Chong Yidong
 lispref/os.texi		 "Luc Teirlinck"   Chong Yidong
--- a/configure	Wed Mar 16 16:03:44 2005 +0000
+++ b/configure	Wed Mar 16 16:06:15 2005 +0000
@@ -21987,7 +21987,6 @@
 
 if test $USE_XASSERTS = yes; then
    echo "  Compiling with asserts turned on."
-   CFLAGS="$CFLAGS -DXASSERTS=1"
    CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
    echo
 fi
--- a/configure.in	Wed Mar 16 16:03:44 2005 +0000
+++ b/configure.in	Wed Mar 16 16:06:15 2005 +0000
@@ -3103,7 +3103,6 @@
 
 if test $USE_XASSERTS = yes; then
    echo "  Compiling with asserts turned on."
-   CFLAGS="$CFLAGS -DXASSERTS=1"
    CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
    echo
 fi
--- a/etc/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/etc/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,7 +1,11 @@
+2005-03-10  Michael Albinus  <michael.albinus@gmx.de>
+
+	* NEWS: Explain how to default Tramp to FTP.
+
 2005-03-05  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
 
 	* NEWS: Mention Carbon build on Mac OS 9.
-	
+
 2005-03-01  David Kastrup  <dak@gnu.org>
 
 	* DEBUG: Add information about `-fno-crossjumping' for GCC.
@@ -49,7 +53,7 @@
 2005-01-13  Cheng Gao  <chenggao@gmail.com>
 
 	* MORE.STUFF: Add entries of some well known and widely used packages.
-	
+
 2005-01-07  Lars Hansen  <larsh@math.ku.dk>
 
 	* NEWS: Describe desktop package lazy restore feature.
--- a/etc/NEWS	Wed Mar 16 16:03:44 2005 +0000
+++ b/etc/NEWS	Wed Mar 16 16:06:15 2005 +0000
@@ -103,6 +103,13 @@
 
 * Changes in Emacs 22.1
 
+** The commands copy-file, rename-file, make-symbolic-link and
+add-name-to-file, when given a directory as the "new name" argument,
+convert it to a file name by merging in the within-directory part of
+the existing file's name.  (This is the same convention that shell
+commands cp, mv, and ln follow.)  Thus, M-x copy-file RET ~/foo RET
+/tmp RET copies ~/foo to /tmp/foo.
+
 ** C-u M-x goto-line now switches to the most recent previous buffer,
 and goes to the specified line in that buffer.
 
@@ -2445,7 +2452,11 @@
 `rsync' to do the copying).
 
 Shell connections can be acquired via `rsh', `ssh', `telnet' and also
-`su' and `sudo'.
+`su' and `sudo'.  Ange-FTP is still supported via the `ftp' method.
+
+If you want to disable Tramp you should set
+
+  (setq tramp-default-method "ftp")
 
 ---
 ** The new global minor mode `file-name-shadow-mode' modifies the way
--- a/etc/TODO	Wed Mar 16 16:03:44 2005 +0000
+++ b/etc/TODO	Wed Mar 16 16:06:15 2005 +0000
@@ -82,6 +82,12 @@
   to save their changes. If the user says yes, show them
   in a Custom buffer using customize-customized.
 
+** Emacs Lisp mode could put an overlay on the defun for every
+  function that has advice.  The overlay could have `after-text' like "
+  [Function has advice]".  It might look like
+     (defun foo [Function has advice] (x y) 
+  The overlay could also be a button that you could use to view the advice.
+
 ** ange-ftp
 *** understand sftp
 *** Use MLS for ange-ftp-insert-directory if a list of files is specified.
--- a/leim/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/leim/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,12 @@
+2005-03-15  Kenichi Handa  <handa@m17n.org>
+
+	* quail/thai.el (thai-generate-quail-map): Fix the kesmanee layout.
+
+2005-03-08  Kenichi Handa  <handa@m17n.org>
+
+	* quail/latin-pre.el ("latin-1-prefix"): Add rule "__"->"_".
+	("latin-9-prefix"): Add rules "__"->"_", "_ "->NBSP.
+
 2004-12-04  Kenichi Handa  <handa@m17n.org>
 
 	* quail/lao.el (lao-key-alist): Declare it by defvar.
--- a/leim/quail/latin-pre.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/leim/quail/latin-pre.el	Wed Mar 16 16:06:15 2005 +0000
@@ -154,6 +154,7 @@
  ("_+" ?,A1(B)
  ("_y" ?,A%(B)
  ("_:" ?,Aw(B)
+ ("__" ?_)
  ("/c" ?,A"(B)
  ("/\\" ?,AW(B)
  ("/2" ?,A=(B)
@@ -834,6 +835,8 @@
  ("_+" ?,b1(B)
  ("_y" ?,b%(B)
  ("_:" ?,bw(B)
+ ("_ " ?,b (B)
+ ("__" ?_)
  ("/c" ?,b"(B)
  ("/\\" ?,bW(B)
  ("/o" ?,b=(B)				; clash with ,bx(B, but ,bf(B uses /
--- a/leim/quail/thai.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/leim/quail/thai.el	Wed Mar 16 16:06:15 2005 +0000
@@ -87,18 +87,32 @@
   [
    0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0	; control codes
    0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0	; control codes
-   0   "#" "." ",Tr(B" ",Ts(B" ",Tt(B" ",TQi(B" ",T'(B"	; SPC .. '
+;; This data is quite old.
+;;    0   "#" "." ",Tr(B" ",Ts(B" ",Tt(B" ",TQi(B" ",T'(B"	; SPC .. '
+;;    ",Tv(B" ",Tw(B" ",Tu(B" ",Ty(B" ",TA(B" ",T"(B" ",Tc(B" ",T=(B"	; ( .. /
+;;    ",T((B" ",TE(B" "/" "_" ",T@(B" ",T6(B" ",TX(B" ",TV(B"	; 0 .. 7
+;;    ",T$(B" ",T5(B" ",T+(B" ",TG(B" ",T2(B" ",T*(B" ",TL(B" ",TF(B"	; 8 .. ?
+;;    ",Tq(B" ",TD(B" ",TZ(B" ",T)(B" ",T/(B" ",T.(B" ",Tb(B" ",T,(B"	; @ .. G
+;;    ",Tg(B" ",T3(B" ",Tk(B" ",TI(B" ",TH(B" ",Tn(B" ",Tl(B" ",TO(B"	; H .. O
+;;    ",T-(B" ",Tp(B" ",T1(B" ",T&(B" ",T8(B" ",Tj(B" ",TN(B" "\""	; P .. W
+;;    ")" ",Tm(B" "(" ",T:(B" ",T_(B" ",TE(B" ",TY(B" ",Tx(B"	; X .. _
+;;    ",T#(B" ",T?(B" ",TT(B" ",Ta(B" ",T!(B" ",TS(B" ",T4(B" ",T`(B"	; ` .. g
+;;    ",Ti(B" ",TC(B" ",Th(B" ",TR(B" ",TJ(B" ",T7(B" ",TW(B" ",T9(B"	; h .. o
+;;    ",TB(B" ",Tf(B" ",T>(B" ",TK(B" ",TP(B" ",TU(B" ",TM(B" ",Td(B"	; p .. w
+;;    ",T;(B" ",TQ(B" ",T<(B" ",T0(B" ",To(B" "," ",T%(B" 0	; x .. DEL
+;; This is the correct data nowadays.
+   0  "+" "." ",Tr(B" ",Ts(B" ",Tt(B" ",T_(B" ",T'(B"	; SPC .. '
    ",Tv(B" ",Tw(B" ",Tu(B" ",Ty(B" ",TA(B" ",T"(B" ",Tc(B" ",T=(B"	; ( .. /
-   ",T((B" ",TE(B" "/" "_" ",T@(B" ",T6(B" ",TX(B" ",TV(B"	; 0 .. 7
+   ",T((B" ",Te(B" "/" "-" ",T@(B" ",T6(B" ",TX(B" ",TV(B"	; 0 .. 7
    ",T$(B" ",T5(B" ",T+(B" ",TG(B" ",T2(B" ",T*(B" ",TL(B" ",TF(B"	; 8 .. ?
    ",Tq(B" ",TD(B" ",TZ(B" ",T)(B" ",T/(B" ",T.(B" ",Tb(B" ",T,(B"	; @ .. G
-   ",Tg(B" ",T3(B" ",Tk(B" ",TI(B" ",TH(B" ",Tn(B" ",Tl(B" ",TO(B"	; H .. O
+   ",Tg(B" ",T3(B" ",Tk(B" ",TI(B" ",TH(B" "?" ",Tl(B" ",TO(B"	; H .. O
    ",T-(B" ",Tp(B" ",T1(B" ",T&(B" ",T8(B" ",Tj(B" ",TN(B" "\""	; P .. W
-   ")" ",Tm(B" "(" ",T:(B" ",T_(B" ",TE(B" ",TY(B" ",Tx(B"	; X .. _
-   ",T#(B" ",T?(B" ",TT(B" ",Ta(B" ",T!(B" ",TS(B" ",T4(B" ",T`(B"	; ` .. g
+   "\)" ",Tm(B" "\(" ",T:(B" ",T#(B" ",TE(B" ",TY(B" ",Tx(B"	; X .. _
+   "_" ",T?(B" ",TT(B" ",Ta(B" ",T!(B" ",TS(B" ",T4(B" ",T`(B"	; ` .. g
    ",Ti(B" ",TC(B" ",Th(B" ",TR(B" ",TJ(B" ",T7(B" ",TW(B" ",T9(B"	; h .. o
    ",TB(B" ",Tf(B" ",T>(B" ",TK(B" ",TP(B" ",TU(B" ",TM(B" ",Td(B"	; p .. w
-   ",T;(B" ",TQ(B" ",T<(B" ",T0(B" ",To(B" "," ",T%(B" 0	; x .. DEL
+   ",T;(B" ",TQ(B" ",T<(B" ",T0(B" ",T%(B" "," "%" 0	; x .. DEL
    ]))
 
 
--- a/lisp/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,270 @@
+2005-03-15  Juri Linkov  <juri@jurta.org>
+
+	* isearch.el (isearch-error): New variable.
+	(isearch-invalid-regexp, isearch-within-brackets): Remove.
+	(isearch-error-state): Renamed from `isearch-invalid-regexp-state'.
+	(isearch-within-brackets-state): Remove.
+	(isearch-case-fold-search-state, isearch-pop-fun-state):
+	Decrease frame index.
+	(isearch-mode, isearch-top-state, isearch-push-state)
+	(isearch-edit-string, isearch-abort, isearch-search-and-update)
+	(isearch-fallback, isearch-message-prefix, isearch-message-suffix)
+	(isearch-search, isearch-lazy-highlight-new-loop):
+	Replace `isearch-invalid-regexp' with `isearch-error'.
+	Remove `isearch-within-brackets'.
+	(isearch-search): Add `search-failed' handler to `condition-case'.
+	(isearch-lazy-highlight-search): Add `condition-case' to catch
+	errors and allow `isearch-lazy-highlight-update' to try
+	highlighting from the beginning of the window.
+	(isearch-repeat): Move up code to set isearch-wrapped to t
+	before calling isearch-wrap-function.
+
+	* info.el (Info-isearch-initial-node): New internal variable.
+	(Info-search): Signal an error in isearch mode when search leaves
+	the initial node.  Signal an error when `bound' is non-nil and
+	nothing was found in the current subfile.
+	(Info-isearch-search): Remove `condition-case'.
+	(Info-isearch-wrap): Don't wrap when search failed during leaving
+	the initial node.  If `Info-isearch-search' is nil, wrap around
+	the current node.
+	(Info-isearch-start): New fun.
+	(Info-mode): Add buffer-local hook `Info-isearch-start' to
+	`isearch-mode-hook'.
+
+2005-03-15  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* simple.el (normal-erase-is-backspace): Set default to t if
+	running on Mac.
+
+	* term/mac-win.el (function-key-map): Sync with x-win.el.
+
+2005-03-15  Kenichi Handa  <handa@m17n.org>
+
+	* international/mule-cmds.el (locale-language-names): Modify the
+	format of elements and add more entries.
+	(locale-preferred-coding-systems): Add more entries.
+	(set-locale-environment): Adjusted for the change of
+	locale-language-names.
+
+2005-03-14  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* pcvs.el (smerge-ediff): Remove bogus autoload.
+
+2005-03-14  Lute Kamstra  <lute@gnu.org>
+
+	* emacs-lisp/debug.el (debugger-make-xrefs): Docstring fix.
+	Ignore a `*' at the beginning of a line.
+
+	* subr.el (macro-declaration-function): Move to emacs-lisp/byte-run.el.
+	* emacs-lisp/byte-run.el (macro-declaration-function): Move from
+	subr.el.
+	(dont-compile, eval-when-compile, eval-and-compile): Use declare
+	to specify indentation.
+
+	* generic.el (define-generic-mode): Let generic-mode-list be a
+	list of strings; test membership with equal.
+
+2005-03-14  Kim F. Storm  <storm@cua.dk>
+
+	* simple.el (next-line, previous-line): Add optional try-vscroll
+	arg to recognize interactive use.  Pass it on to line-move.
+	(line-move): Don't perform auto-window-vscroll when defining or
+	executing keyboard macro to ensure consistent behaviour.
+
+2005-03-13  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* pcvs-util.el (cvs-string->strings): Strip trailing whitespace.
+
+2005-03-13  Lute Kamstra  <lute@gnu.org>
+
+	* emacs-lisp/debug.el (debug): Set debug-on-exit before calling
+	debugger-setup-buffer so that backtrace marks the frames set to
+	debug-on-exit and we don't have to do it manually.  Set an extra
+	debug-on-exit for macro's.
+	(debugger-setup-buffer): Don't mark the top frame manually.
+
+2005-03-12  Lute Kamstra  <lute@gnu.org>
+
+	* emacs-lisp/byte-run.el: Replace lisp-indent-hook with
+	lisp-indent-function throughout.
+	(with-no-warnings): Set lisp-indent-function property.
+
+2005-03-12  Thien-Thi Nguyen  <ttn@gnu.org>
+
+	* progmodes/dcl-mode.el (dcl-mode-syntax-table):
+	Add entry for backslash.
+
+2005-03-12  Juri Linkov  <juri@jurta.org>
+
+	* info.el (Info-search): Four fixes for backward search.
+
+2005-03-11  Jay Belanger  <belanger@truman.edu>
+
+	* calc/calc.el (calc-language-alist): New variable.
+	* calc/calc-embed.el (calc-embedded-language-alist): Remove.
+	(calc-embedded-find-modes): Use calc-language-alist instead of
+	calc-embedded-language-alist.
+
+2005-03-11  Glenn Morris  <gmorris@ast.cam.ac.uk>
+
+	* calendar/calendar.el (calendar-redrawing): New internal
+	variable.
+	(redraw-calendar): Remove bogus save-excursion from previous
+	change.  Bind calendar-redrawing to t for mark-diary-entries.
+	* calendar/diary-lib.el (mark-diary-entries): No need to redraw
+	calendar if that is why we were called.
+
+2005-03-11  Kenichi Handa  <handa@m17n.org>
+
+	* international/mule.el (make-coding-system): Set property
+	'coding-system-define-form to nil.
+	(define-coding-system-alias): Likewise.
+
+2005-03-11  Kenichi Handa  <handa@m17n.org>
+
+	These changes are suggested by Dave Love <fx@gnu.org>.
+
+	* textmodes/fill.el: Change encoding to iso-2022-7bit and add
+	coding: tag.
+	(adaptive-fill-regexp): Add more bullets.
+	(fill-french-nobreak-p): Add Latin-1 and Latin-9 guillemets in
+	regexps.
+
+2005-03-10  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* help.el (describe-mode): Properly handle non-trivial lighters.
+	Don't ignore minor modes that are not listed in minor-mode-list.
+
+	* tooltip.el (tooltip-mode): Don't complain that you can't turn the
+	feature ON when the user requests to turn it OFF.
+
+2005-03-10  Lute Kamstra  <lute@gnu.org>
+
+	* emacs-lisp/debug.el (debug-entry-code): Delete it.
+	(implement-debug-on-entry): New function to replace debug-entry-code.
+	(debug-on-entry-1): Use implement-debug-on-entry.  Delete the
+	second argument as the 2005-03-07 change makes it obsolete.
+	(debug-on-entry, cancel-debug-on-entry): Update call to
+	debug-on-entry-1.
+	(debug, debugger-setup-buffer): Comment update.
+	(debugger-frame-number): Update to work with implement-debug-on-entry.
+
+2005-03-10  Jay Belanger  <belanger@truman.edu>
+
+	* calc/calc-embed.el (math-ms-args): Declare it.
+	(calc-embedded-eval-expr, calc-embedded-eval-get-var): Use variable
+	math-ms-args.
+	(calc-embedded-subst): Use math-multi-subst-rec to substitute
+	variables.
+
+2005-03-10  Nick Roberts  <nickrob@snap.net.nz>
+
+	* progmodes/gdb-ui.el (gdb-var-create-handler, gdb-get-location):
+	Use message-box.
+
+	* tooltip.el (tooltip-mode): Use define-minor-mode and simplify.
+	(tooltip-activate-mouse-motions-if-enabled): Use dolist.
+	(tooltip-gud-tips): Simplify.
+	(tooltip-gud-tips-p): Remove superflouous :set.
+	(tooltip-gud-modes): Add fortran-mode.
+	(gdb-tooltip-print): Remove newline for tooltip-use-echo-area.
+
+	* bindings.el (mode-line-mode-menu): Add tooltip-mode to mode-line.
+
+2005-03-09  Kim F. Storm  <storm@cua.dk>
+
+	* play/animate.el (animate-place-char): Use forward-line instead
+	of next-line to improve performance.
+
+2005-03-09  Simon Josefsson  <jas@extundo.com>
+
+	* net/browse-url.el (browse-url-default-browser): Doc fix.
+
+2005-03-09  Miles Bader  <miles@gnu.org>
+
+	* emacs-lisp/bytecomp.el (byte-compile-variable-ref)
+	(byte-compile-obsolete): Change " since VER" to " (as of Emacs VER)".
+
+2005-03-09  Kenichi Handa  <handa@m17n.org>
+
+	* international/latin-1.el: Set case and syntax for 255 only if
+	set-case-syntax-set-multibyte is nil.
+
+	* textmodes/ispell.el (ispell-insert-word): New function.
+	(ispell-word): Use ispell-insert-word to insert a new word.
+	(ispell-process-line): Likewise.
+	(ispell-complete-word): Likewise.
+
+2005-03-09  Glenn Morris  <gmorris@ast.cam.ac.uk>
+
+	* calendar/calendar.el (redraw-calendar): Preserve point.
+	Reported by Matt Hodges <MPHodges@member.fsf.org>.
+	(calendar-week-start-day): Move after definition of
+	redraw-calendar.  Delete buffer test, since redraw-calendar has
+	that now.
+
+	* calendar/diary-lib.el (mark-diary-entries): Only call
+	redraw-calendar in the first of any recursive calls.
+	Reported by Alan Shutko <ats@acm.org>.
+
+2005-03-08  Juri Linkov  <juri@jurta.org>
+
+	* textmodes/sgml-mode.el (sgml-tag, html-tag-alist)
+	(html-horizontal-rule, html-line, html-image, html-checkboxes)
+	(html-radio-buttons): Add a space before the trailing `/>' where
+	sgml-xml-mode is non-nil.
+	(sgml-delete-tag): Check if the tag ends with `/>' to not delete
+	the subsequent tag of the empty XML tag.
+	(html-href-anchor): Don't set initial input to "http:".
+	(html-image): Ask for the image URL and set point inside alt="".
+	(html-name-anchor): Duplicate the name in the `id' attribute when
+	sgml-xml-mode is non-nil.
+	(html-paragraph): Remove \n before <p>.
+	(html-checkboxes, html-radio-buttons): Insert `checked="checked"'
+	instead of `checked' when sgml-xml-mode is non-nil.
+
+	* facemenu.el (list-colors-print): Print #RRGGBB in default face.
+	Remove 1 space before #RRGGBB to not truncate it on terminal
+	windows w/o fringes.  Remove 1 space between bg and fg examples
+	to get more space.
+	(list-colors-duplicates): Replace `and' with `if' for `boundp' to
+	avoid byte-compile warnings.
+
+	* image-file.el (image-file-handler): Put `safe-magic' property to
+	`image-file-handler'.
+
+	* info.el (Info-isearch-search): Emulate word search in
+	isearching through multiple Info nodes with Info-search.
+	(Info-isearch-wrap): Allow isearch-word.
+
+2005-03-08  Lute Kamstra  <lute@gnu.org>
+
+	* emacs-lisp/debug.el (debugger-step-through): Make sure that
+	stepping into the debugger's code is not possible.
+	(debugger-jumping-flag): Docstring update.
+
+2005-03-08  Jay Belanger  <belanger@truman.edu>
+
+	* calc/calc-embed.el (calc-do-embedded): Reset mode line when
+	embedded mode begins.
+	(calc-embedded-language-alist): New variable.
+	(calc-embedded-find-modes): Use calc-embedded-language-alist to
+	set default language mode.
+
+2005-03-08  Kenichi Handa  <handa@m17n.org>
+
+	* international/ccl.el (define-ccl-program): Fix docstring about
+	extra 256 bytes assured for the output buffer.
+
+	* international/utf-16.el (ccl-encode-mule-utf-16le-with-signature):
+	Fix BUFFER_MAGNIFICATION to 2.
+	(ccl-encode-mule-utf-16be-with-signature): Likewise.
+
+2005-03-07  Karl Chen  <quarl@cs.berkeley.edu>
+
+	* align.el (align-rules-list): Added an alignment rule for CSS
+	declarations (applies to css-mode and html-mode buffers).
+
 2005-03-07  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	* emacs-lisp/debug.el (debug-on-entry-1): Fix handling of macros.
@@ -191,8 +458,7 @@
 	that debug-entry-code can be safely removed from a function while
 	this code is being evaluated.  Revert the 2005-02-27 change as the
 	new implementation no longer requires it.  Make sure that a
-	function body containing just a string is not mistaken for a
-	docstring.
+	function body containing just a string is not mistaken for a docstring.
 	(debug): Skip one more frame in case of debug on entry.
 	(debugger-setup-buffer): Delete one more frame line in case of
 	debug on entry.
--- a/lisp/align.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/align.el	Wed Mar 16 16:06:15 2005 +0000
@@ -466,13 +466,13 @@
      (repeat   . t)
      (modes    . align-c++-modes)
      (run-if   . ,(function (lambda () current-prefix-arg))))
-;      (valid
-;       . ,(function
-;	  (lambda ()
-;	    (memq (caar (c-guess-basic-syntax))
-;		  '(brace-list-intro
-;		    brace-list-entry
-;		    brace-entry-open))))))
+					;      (valid
+					;       . ,(function
+					;	  (lambda ()
+					;	    (memq (caar (c-guess-basic-syntax))
+					;		  '(brace-list-intro
+					;		    brace-list-entry
+					;		    brace-entry-open))))))
 
     ;; With a prefix argument, comma delimiter will be aligned.  Since
     ;; perl-mode doesn't give us enough syntactic information (and we
@@ -525,11 +525,11 @@
      (regexp   . "\\(\\s-*\\)\\\\$")
      (modes    . align-c++-modes)
      (column   . c-backslash-column))
-;      (valid
-;       . ,(function
-;	  (lambda ()
-;	    (memq (caar (c-guess-basic-syntax))
-;		  '(cpp-macro cpp-macro-cont))))))
+					;      (valid
+					;       . ,(function
+					;	  (lambda ()
+					;	    (memq (caar (c-guess-basic-syntax))
+					;		  '(cpp-macro cpp-macro-cont))))))
 
     (basic-line-continuation
      (regexp   . "\\(\\s-*\\)\\\\$")
@@ -578,7 +578,12 @@
      (justify  . t)
      (run-if   . ,(function
 		   (lambda ()
-		     (eq '- current-prefix-arg))))))
+		     (eq '- current-prefix-arg)))))
+
+    (css-declaration
+     (regexp . "^\\s-*\\w+:\\(\\s-*\\).*;")
+     (group . (1))
+     (modes . '(css-mode html-mode))))
   "*A list describing all of the available alignment rules.
 The format is:
 
--- a/lisp/bindings.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/bindings.el	Wed Mar 16 16:06:15 2005 +0000
@@ -392,6 +392,9 @@
   "Return the value of symbol VAR if it is bound, else nil."
   `(and (boundp (quote ,var)) ,var))
 
+(define-key mode-line-mode-menu [tooltip-mode]
+  `(menu-item ,(purecopy "Tooltip") tooltip-mode
+	      :button (:toggle . tooltip-mode)))
 (define-key mode-line-mode-menu [overwrite-mode]
   `(menu-item ,(purecopy "Overwrite (Ovwrt)") overwrite-mode
 	      :button (:toggle . overwrite-mode)))
--- a/lisp/calc/calc-embed.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/calc/calc-embed.el	Wed Mar 16 16:06:15 2005 +0000
@@ -244,6 +244,13 @@
       (use-local-map calc-mode-map)
       (setq calc-no-refresh-evaltos nil)
       (and chg calc-any-evaltos (calc-wrapper (calc-refresh-evaltos)))
+      (let (str)
+        (save-excursion
+          (calc-select-buffer)
+          (setq str mode-line-buffer-identification))
+        (unless (equal str mode-line-buffer-identification)
+          (setq mode-line-buffer-identification str)
+          (set-buffer-modified-p (buffer-modified-p))))
       (or (eq calc-embedded-quiet t)
 	  (message "Embedded Calc mode enabled; %s to return to normal"
 		   (if calc-embedded-quiet
@@ -717,6 +724,11 @@
 	       (setq no-defaults nil)))
       (backward-char 6))
     (goto-char save-pt)
+    (unless (assq 'the-language modes)
+      (let ((lang (assoc major-mode calc-language-alist)))
+        (if lang
+            (setq modes (cons (cons 'the-language (cdr lang))
+                              modes)))))
     (list modes emodes pmodes)))
 
 ;; The variable calc-embed-vars-used is local to calc-embedded-make-info,
@@ -857,13 +869,13 @@
 	 (while (setq x (cdr x))
 	   (calc-embedded-find-vars (car x))))))
 
-
+(defvar math-ms-args)
 (defun calc-embedded-evaluate-expr (x)
   (let ((calc-embed-vars-used (aref calc-embedded-info 10)))
     (or calc-embed-vars-used (calc-embedded-find-vars x))
     (if calc-embed-vars-used
 	(let ((active (assq (aref calc-embedded-info 0) calc-embedded-active))
-	      (args nil))
+	      (math-ms-args nil))
 	  (save-excursion
 	    (calc-embedded-original-buffer t)
 	    (or active
@@ -887,7 +899,7 @@
 	(list 'calcFunc-assign
 	      (nth 1 x)
 	      (calc-embedded-subst (nth 2 x)))
-      (calc-normalize (math-evaluate-expr-rec (math-multi-subst x nil nil))))))
+      (calc-normalize (math-evaluate-expr-rec (math-multi-subst-rec x))))))
 
 (defun calc-embedded-eval-get-var (var base)
   (let ((entry base)
@@ -914,7 +926,7 @@
 		    (setq val (nth 2 val)))
 		(if (eq (car-safe val) 'calcFunc-assign)
 		    (setq val (nth 2 val)))
-		(setq args (cons (cons var val) args)))
+		(setq math-ms-args (cons (cons var val) math-ms-args)))
 	    (calc-embedded-activate)
 	    (calc-embedded-eval-get-var var base))))))
 
--- a/lisp/calc/calc.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/calc/calc.el	Wed Mar 16 16:06:15 2005 +0000
@@ -717,6 +717,20 @@
 (defvar var-gamma '(special-const (math-gamma-const)))
 (defvar var-Modes '(special-const (math-get-modes-vec)))
 
+(defvar calc-language-alist
+  '((latex-mode . latex)
+    (tex-mode   . tex)
+    (plain-tex-mode . tex)
+    (context-mode . tex)
+    (nroff-mode . eqn)
+    (pascal-mode . pascal)
+    (c-mode . c)
+    (c++-mode . c)
+    (fortran-mode . fortran)
+    (f90-mode . fortran))
+  "Alist of major modes with appropriate Calc languages.")
+
+
 (mapcar (lambda (v) (or (boundp v) (set v nil)))
 	  calc-local-var-list)
 
--- a/lisp/calendar/calendar.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/calendar/calendar.el	Wed Mar 16 16:06:15 2005 +0000
@@ -145,24 +145,6 @@
   "Name of the buffer used for the calendar.")
 
 ;;;###autoload
-(defcustom calendar-week-start-day 0
-  "*The day of the week on which a week in the calendar begins.
-0 means Sunday (default), 1 means Monday, and so on.
-
-If you change this variable directly (without using customize)
-after starting `calendar', you should call `redraw-calendar' to
-update the calendar display to reflect the change, otherwise
-movement commands will not work correctly."
-  :type 'integer
-  :set (lambda (sym val)
-         (set sym val)
-         (let ((buffer (get-buffer calendar-buffer)))
-           (when (buffer-live-p buffer)
-             (with-current-buffer buffer
-               (redraw-calendar)))))
-  :group 'calendar)
-
-;;;###autoload
 (defcustom calendar-offset 0
   "*The offset of the principal month from the center of the calendar window.
 0 means the principal month is in the center (default), -1 means on the left,
@@ -2168,15 +2150,34 @@
 	  (forward-line 1))))
   t)
 
+(defvar calendar-redrawing nil
+  "Internal calendar variable, non-nil if inside redraw-calendar.")
+
 (defun redraw-calendar ()
   "Redraw the calendar display, if `calendar-buffer' is live."
   (interactive)
   (if (get-buffer calendar-buffer)
       (with-current-buffer calendar-buffer
-        (let ((cursor-date (calendar-cursor-to-nearest-date)))
+        (let ((cursor-date (calendar-cursor-to-nearest-date))
+              (calendar-redrawing t))
           (generate-calendar-window displayed-month displayed-year)
           (calendar-cursor-to-visible-date cursor-date)))))
 
+;;;###autoload
+(defcustom calendar-week-start-day 0
+  "*The day of the week on which a week in the calendar begins.
+0 means Sunday (default), 1 means Monday, and so on.
+
+If you change this variable directly (without using customize)
+after starting `calendar', you should call `redraw-calendar' to
+update the calendar display to reflect the change, otherwise
+movement commands will not work correctly."
+  :type 'integer
+  :set (lambda (sym val)
+         (set sym val)
+         (redraw-calendar))
+  :group 'calendar)
+
 (defcustom calendar-debug-sexp nil
   "*Turn debugging on when evaluating a sexp in the diary or holiday list."
   :type 'boolean
@@ -2920,40 +2921,40 @@
       (save-excursion
         (set-buffer calendar-buffer)
         (calendar-cursor-to-visible-date date)
-	(let ((mark (or (and (stringp mark) (= (length mark) 1) mark) ; single-char
-			(and (listp mark) (> (length mark) 0) mark) ; attr list
-			(and (facep mark) mark) ; face-name
-			diary-entry-marker)))
-	  (if (facep mark)
-	      (progn ; face or an attr-list that contained a face
-		(overlay-put
-		 (make-overlay (1- (point)) (1+ (point))) 'face mark))
-	    (if (and (stringp mark)
-		     (= (length mark) 1)) ; single-char
-		(let ((buffer-read-only nil))
-		  (forward-char 1)
-		  (delete-char 1)
-		  (insert mark)
-		  (forward-char -2))
-              (let ; attr list 
-                  ((temp-face 
-                    (make-symbol (apply 'concat "temp-face-" 
-                                        (mapcar '(lambda (sym) 
+        (let ((mark (or (and (stringp mark) (= (length mark) 1) mark) ; single-char
+                        (and (listp mark) (> (length mark) 0) mark) ; attr list
+                        (and (facep mark) mark) ; face-name
+                        diary-entry-marker)))
+          (if (facep mark)
+              (progn      ; face or an attr-list that contained a face
+                (overlay-put
+                 (make-overlay (1- (point)) (1+ (point))) 'face mark))
+            (if (and (stringp mark)
+                     (= (length mark) 1)) ; single-char
+                (let ((buffer-read-only nil))
+                  (forward-char 1)
+                  (delete-char 1)
+                  (insert mark)
+                  (forward-char -2))
+              (let                      ; attr list
+                  ((temp-face
+                    (make-symbol (apply 'concat "temp-face-"
+                                        (mapcar '(lambda (sym)
                                                    (cond ((symbolp sym) (symbol-name sym))
                                                          ((numberp sym) (int-to-string sym))
                                                          (t sym))) mark))))
                    (faceinfo mark))
-		(make-face temp-face)
-		;; Remove :face info from the mark, copy the face info into temp-face
-		(while (setq faceinfo (memq :face faceinfo))
-		  (copy-face (read (nth 1 faceinfo)) temp-face)
-		  (setcar faceinfo nil)
-		  (setcar (cdr faceinfo) nil))
-		(setq mark (delq nil mark))
-		;; Apply the font aspects
-		(apply 'set-face-attribute temp-face nil mark)
-		(overlay-put
-		 (make-overlay (1- (point)) (1+ (point))) 'face temp-face))))))))
+                (make-face temp-face)
+                ;; Remove :face info from the mark, copy the face info into temp-face
+                (while (setq faceinfo (memq :face faceinfo))
+                  (copy-face (read (nth 1 faceinfo)) temp-face)
+                  (setcar faceinfo nil)
+                  (setcar (cdr faceinfo) nil))
+                (setq mark (delq nil mark))
+                ;; Apply the font aspects
+                (apply 'set-face-attribute temp-face nil mark)
+                (overlay-put
+                 (make-overlay (1- (point)) (1+ (point))) 'face temp-face))))))))
 
 (defun calendar-star-date ()
   "Replace the date under the cursor in the calendar window with asterisks.
--- a/lisp/calendar/diary-lib.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/calendar/diary-lib.el	Wed Mar 16 16:06:15 2005 +0000
@@ -842,7 +842,14 @@
 `mark-diary-entries-hook' are run."
   (interactive)
   ;; To remove any deleted diary entries.
-  (when mark-diary-entries-in-calendar
+  (when (and mark-diary-entries-in-calendar
+             ;; Avoid redrawing when called recursively, eg through
+             ;; mark-diary-entries-hook for #include's, else only get
+             ;; the last set of diary marks.
+             (not marking-diary-entries)
+             ;; If called from redraw-calendar, the calendar has been
+             ;; erased, so no need to unmark the diary entries.
+             (not calendar-redrawing))
     (setq mark-diary-entries-in-calendar nil)
     (redraw-calendar))
   (let ((marking-diary-entries t)
--- a/lisp/emacs-lisp/byte-run.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/emacs-lisp/byte-run.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,6 +1,6 @@
 ;;; byte-run.el --- byte-compiler support for inlining
 
-;; Copyright (C) 1992, 2004  Free Software Foundation, Inc.
+;; Copyright (C) 1992, 2004, 2005  Free Software Foundation, Inc.
 
 ;; Author: Jamie Zawinski <jwz@lucid.com>
 ;;	Hallvard Furuseth <hbf@ulrik.uio.no>
@@ -31,11 +31,35 @@
 
 ;;; Code:
 
+;; We define macro-declaration-function here because it is needed to
+;; handle declarations in macro definitions and this is the first file
+;; loaded by loadup.el that uses declarations in macros.
+
+(defun macro-declaration-function (macro decl)
+  "Process a declaration found in a macro definition.
+This is set as the value of the variable `macro-declaration-function'.
+MACRO is the name of the macro being defined.
+DECL is a list `(declare ...)' containing the declarations.
+The return value of this function is not used."
+  ;; We can't use `dolist' or `cadr' yet for bootstrapping reasons.
+  (let (d)
+    ;; Ignore the first element of `decl' (it's always `declare').
+    (while (setq decl (cdr decl))
+      (setq d (car decl))
+      (cond ((and (consp d) (eq (car d) 'indent))
+	     (put macro 'lisp-indent-function (car (cdr d))))
+	    ((and (consp d) (eq (car d) 'debug))
+	     (put macro 'edebug-form-spec (car (cdr d))))
+	    (t
+	     (message "Unknown declaration %s" d))))))
+
+(setq macro-declaration-function 'macro-declaration-function)
+
+
 ;; Redefined in byte-optimize.el.
 ;; This is not documented--it's not clear that we should promote it.
 (fset 'inline 'progn)
-(put 'inline 'lisp-indent-hook 0)
-
+(put 'inline 'lisp-indent-function 0)
 
 ;;; Interface to inline functions.
 
@@ -105,11 +129,10 @@
   (put variable 'byte-obsolete-variable (cons new when))
   variable)
 
-(put 'dont-compile 'lisp-indent-hook 0)
 (defmacro dont-compile (&rest body)
   "Like `progn', but the body always runs interpreted (not compiled).
 If you think you need this, you're probably making a mistake somewhere."
-  (declare (debug t))
+  (declare (debug t) (indent 0))
   (list 'eval (list 'quote (if (cdr body) (cons 'progn body) (car body)))))
 
 
@@ -118,22 +141,21 @@
 ;;; definition in the file overrides the magic definitions on the
 ;;; byte-compile-macro-environment.
 
-(put 'eval-when-compile 'lisp-indent-hook 0)
 (defmacro eval-when-compile (&rest body)
   "Like `progn', but evaluates the body at compile time.
 The result of the body appears to the compiler as a quoted constant."
-  (declare (debug t))
+  (declare (debug t) (indent 0))
   ;; Not necessary because we have it in b-c-initial-macro-environment
   ;; (list 'quote (eval (cons 'progn body)))
   (cons 'progn body))
 
-(put 'eval-and-compile 'lisp-indent-hook 0)
 (defmacro eval-and-compile (&rest body)
   "Like `progn', but evaluates the body at compile time and at load time."
-  (declare (debug t))
+  (declare (debug t) (indent 0))
   ;; Remember, it's magic.
   (cons 'progn body))
 
+(put 'with-no-warnings 'lisp-indent-function 0)
 (defun with-no-warnings (&rest body)
   "Like `progn', but prevents compiler warnings in the body."
   ;; The implementation for the interpreter is basically trivial.
@@ -147,7 +169,7 @@
 ;;; There is hardly any reason to change these parameters, anyway.
 ;;; --rms.
 
-;; (put 'byte-compiler-options 'lisp-indent-hook 0)
+;; (put 'byte-compiler-options 'lisp-indent-function 0)
 ;; (defmacro byte-compiler-options (&rest args)
 ;;   "Set some compilation-parameters for this file.  This will affect only the
 ;; file in which it appears; this does nothing when evaluated, and when loaded
--- a/lisp/emacs-lisp/bytecomp.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/emacs-lisp/bytecomp.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,7 +1,7 @@
 ;;; bytecomp.el --- compilation of Lisp code into byte code
 
 ;; Copyright (C) 1985, 1986, 1987, 1992, 1994, 1998, 2000, 2001, 2002,
-;;   2003, 2004  Free Software Foundation, Inc.
+;;   2003, 2004, 2005  Free Software Foundation, Inc.
 
 ;; Author: Jamie Zawinski <jwz@lucid.com>
 ;;	Hallvard Furuseth <hbf@ulrik.uio.no>
@@ -1039,7 +1039,7 @@
     (byte-compile-set-symbol-position (car form))
     (if (memq 'obsolete byte-compile-warnings)
 	(byte-compile-warn "`%s' is an obsolete function%s; %s" (car form)
-			   (if when (concat " since " when) "")
+			   (if when (concat " (as of Emacs " when ")") "")
 			   (if (stringp (car new))
 			       (car new)
 			     (format "use `%s' instead." (car new)))))
@@ -2779,7 +2779,7 @@
 	(let* ((ob (get var 'byte-obsolete-variable))
 	       (when (cdr ob)))
 	  (byte-compile-warn "`%s' is an obsolete variable%s; %s" var
-			     (if when (concat " since " when) "")
+			     (if when (concat " (as of Emacs " when ")") "")
 			     (if (stringp (car ob))
 				 (car ob)
 			       (format "use `%s' instead." (car ob))))))
--- a/lisp/emacs-lisp/debug.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/emacs-lisp/debug.el	Wed Mar 16 16:06:15 2005 +0000
@@ -94,15 +94,8 @@
 
 (defvar debugger-jumping-flag nil
   "Non-nil means that debug-on-entry is disabled.
-This variable is used by `debugger-jump' and `debugger-reenable'.")
-
-;; When you change this, you may also need to change the number of
-;; frames that the debugger skips.
-(defconst debug-entry-code
-  '(if (or inhibit-debug-on-entry debugger-jumping-flag)
-       nil
-     (debug 'debug))
-  "Code added to a function to cause it to call the debugger upon entry.")
+This variable is used by `debugger-jump', `debugger-step-through',
+and `debugger-reenable' to temporarily disable debug-on-entry.")
 
 ;;;###autoload
 (setq debugger 'debug)
@@ -177,7 +170,14 @@
 	    (save-excursion
 	      (save-window-excursion
 		(with-no-warnings
-		 (setq unread-command-char -1))
+		  (setq unread-command-char -1))
+		(when (eq (car debugger-args) 'debug)
+		  ;; Skip the frames for backtrace-debug, byte-code,
+		  ;; and implement-debug-on-entry.
+		  (backtrace-debug 4 t)
+		  ;; Place an extra debug-on-exit for macro's.
+		  (when (eq 'lambda (car-safe (cadr (backtrace-frame 4))))
+		    (backtrace-debug 5 t)))
 		(pop-to-buffer debugger-buffer)
 		(debugger-mode)
 		(debugger-setup-buffer debugger-args)
@@ -197,10 +197,6 @@
 		  (goto-char (point-min))
 		  (message "%s" (buffer-string))
 		  (kill-emacs))
-		(if (eq (car debugger-args) 'debug)
-		    ;; Skip the frames for backtrace-debug, byte-code,
-		    ;; and debug-entry-code.
-		    (backtrace-debug 4 t))
 		(message "")
 		(let ((standard-output nil)
 		      (buffer-read-only t))
@@ -232,7 +228,7 @@
       (setq last-command debugger-outer-last-command)
       (setq this-command debugger-outer-this-command)
       (with-no-warnings
-       (setq unread-command-char debugger-outer-unread-command-char))
+	(setq unread-command-char debugger-outer-unread-command-char))
       (setq unread-command-events debugger-outer-unread-command-events)
       (setq unread-post-input-method-events
 	    debugger-outer-unread-post-input-method-events)
@@ -263,19 +259,14 @@
 		 (progn
 		   (search-forward "\n  debug(")
 		   (forward-line (if (eq (car debugger-args) 'debug)
-				     2	; Remove debug-entry-code frame.
+				     2	; Remove implement-debug-on-entry frame.
 				   1))
 		   (point)))
   (insert "Debugger entered")
   ;; lambda is for debug-on-call when a function call is next.
   ;; debug is for debug-on-entry function called.
   (cond ((memq (car debugger-args) '(lambda debug))
-	 (insert "--entering a function:\n")
-	 (if (eq (car debugger-args) 'debug)
-	     (progn
-	       (delete-char 1)
-	       (insert ?*)
-	       (beginning-of-line))))
+	 (insert "--entering a function:\n"))
 	;; Exiting a function.
 	((eq (car debugger-args) 'exit)
 	 (insert "--returning value: ")
@@ -311,7 +302,7 @@
   (debugger-make-xrefs))
 
 (defun debugger-make-xrefs (&optional buffer)
-  "Attach cross-references to symbol names in the `*Backtrace*' buffer."
+  "Attach cross-references to function names in the `*Backtrace*' buffer."
   (interactive "b")
   (save-excursion
     (set-buffer (or buffer (current-buffer)))
@@ -362,6 +353,7 @@
       ;; Scan the new part of the backtrace, inserting xrefs.
       (goto-char (point-min))
       (while (progn
+	       (goto-char (+ (point) 2))
 	       (skip-syntax-forward "^w_")
 	       (not (eobp)))
 	(let* ((beg (point))
@@ -373,8 +365,8 @@
 	    (goto-char beg)
 	    ;; help-xref-button needs to operate on something matched
 	    ;; by a regexp, so set that up for it.
-	    (re-search-forward "\\(\\(\\sw\\|\\s_\\)+\\)")
-	    (help-xref-button 1 'help-function-def sym file)))
+	    (re-search-forward "\\(\\sw\\|\\s_\\)+")
+	    (help-xref-button 0 'help-function-def sym file)))
 	(forward-line 1))
       (widen))
     (setq debugger-previous-backtrace (buffer-string))))
@@ -384,6 +376,8 @@
 Enter another debugger on next entry to eval, apply or funcall."
   (interactive)
   (setq debugger-step-after-exit t)
+  (setq debugger-jumping-flag t)
+  (add-hook 'post-command-hook 'debugger-reenable)
   (message "Proceeding, will debug on next eval or call.")
   (exit-recursive-edit))
 
@@ -429,8 +423,8 @@
 	  (count 0))
       (while (not (eq (cadr (backtrace-frame count)) 'debug))
 	(setq count (1+ count)))
-      ;; Skip debug-entry-code frame.
-      (when (member '(debug (quote debug)) (cdr (backtrace-frame (1+ count))))
+      ;; Skip implement-debug-on-entry frame.
+      (when (eq 'implement-debug-on-entry (cadr (backtrace-frame (1+ count))))
 	(setq count (1+ count)))
       (goto-char (point-min))
       (when (looking-at "Debugger entered--\\(Lisp error\\|returning value\\):")
@@ -513,12 +507,12 @@
 	    (unwind-protect
 		(progn
 		  (with-no-warnings
-		   (setq unread-command-char debugger-outer-unread-command-char))
+		    (setq unread-command-char debugger-outer-unread-command-char))
 		  (prog1 (progn ,@body)
 		    (with-no-warnings
-		     (setq debugger-outer-unread-command-char unread-command-char))))
+		      (setq debugger-outer-unread-command-char unread-command-char))))
 	      (with-no-warnings
-	       (setq unread-command-char save-ucc))))
+		(setq unread-command-char save-ucc))))
         (setq debugger-outer-match-data (match-data))
         (setq debugger-outer-load-read-function load-read-function)
         (setq debugger-outer-overriding-terminal-local-map
@@ -620,6 +614,16 @@
   (use-local-map debugger-mode-map)
   (run-mode-hooks 'debugger-mode-hook))
 
+;; When you change this, you may also need to change the number of
+;; frames that the debugger skips.
+(defun implement-debug-on-entry ()
+  "Conditionally call the debugger.
+A call to this function is inserted by `debug-on-entry' to cause
+functions to break on entry."
+  (if (or inhibit-debug-on-entry debugger-jumping-flag)
+      nil
+    (funcall debugger 'debug)))
+
 ;;;###autoload
 (defun debug-on-entry (function)
   "Request FUNCTION to invoke debugger each time it is called.
@@ -644,7 +648,7 @@
       (debug-convert-byte-code function))
   (or (consp (symbol-function function))
       (error "Definition of %s is not a list" function))
-  (fset function (debug-on-entry-1 function (symbol-function function) t))
+  (fset function (debug-on-entry-1 function t))
   (or (memq function debug-function-list)
       (push function debug-function-list))
   function)
@@ -661,7 +665,7 @@
 	   (if name (intern name)))))
   (if (and function (not (string= function "")))
       (progn
-	(let ((f (debug-on-entry-1 function (symbol-function function) nil)))
+	(let ((f (debug-on-entry-1 function nil)))
 	  (condition-case nil
 	      (if (and (equal (nth 1 f) '(&rest debug-on-entry-args))
 		       (eq (car (nth 3 f)) 'apply))
@@ -692,8 +696,9 @@
 	      (setq body (cons (documentation function) body)))
 	  (fset function (cons 'lambda (cons (car contents) body)))))))
 
-(defun debug-on-entry-1 (function defn flag)
-  (let ((tail defn))
+(defun debug-on-entry-1 (function flag)
+  (let* ((defn (symbol-function function))
+	 (tail defn))
     (if (subrp tail)
 	(error "%s is a built-in function" function)
       (if (eq (car tail) 'macro) (setq tail (cdr tail)))
@@ -705,10 +710,10 @@
       ;; Skip the interactive form.
       (when (eq 'interactive (car-safe (cadr tail)))
 	(setq tail (cdr tail)))
-      (unless (eq flag (equal (cadr tail) debug-entry-code))
+      (unless (eq flag (equal (cadr tail) '(implement-debug-on-entry)))
 	;; Add/remove debug statement as needed.
 	(if flag
-	    (setcdr tail (cons debug-entry-code (cdr tail)))
+	    (setcdr tail (cons '(implement-debug-on-entry) (cdr tail)))
 	  (setcdr tail (cddr tail))))
       defn)))
 
--- a/lisp/facemenu.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/facemenu.el	Wed Mar 16 16:06:15 2005 +0000
@@ -513,17 +513,17 @@
      'face (cons 'background-color (car color)))
     (put-text-property
      (prog1 (point)
-       (insert "  " (if (cdr color)
-			(mapconcat 'identity (cdr color) ", ")
-		      (car color)))
-       (indent-to (max (- (window-width) 8) 44))
-       (insert (apply 'format " #%02x%02x%02x"
-		      (mapcar (lambda (c) (lsh c -8))
-			      (color-values (car color)))))
+       (insert " " (if (cdr color)
+		       (mapconcat 'identity (cdr color) ", ")
+		     (car color))))
+     (point)
+     'face (cons 'foreground-color (car color)))
+    (indent-to (max (- (window-width) 8) 44))
+    (insert (apply 'format "#%02x%02x%02x"
+		   (mapcar (lambda (c) (lsh c -8))
+			   (color-values (car color)))))
 
-       (insert "\n"))
-     (point)
-     'face (cons 'foreground-color (car color))))
+    (insert "\n"))
   (goto-char (point-min)))
 
 (defun list-colors-duplicates (&optional list)
@@ -539,8 +539,8 @@
 	 (l list))
     (while (cdr l)
       (if (and (facemenu-color-equal (car (car l)) (car (car (cdr l))))
-	       (not (and (boundp 'w32-default-color-map)
-			 (not (assoc (car (car l)) w32-default-color-map)))))
+	       (not (if (boundp 'w32-default-color-map)
+			(not (assoc (car (car l)) w32-default-color-map)))))
 	  (progn
 	    (setcdr (car l) (cons (car (car (cdr l))) (cdr (car l))))
 	    (setcdr l (cdr (cdr l))))
--- a/lisp/faces.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/faces.el	Wed Mar 16 16:06:15 2005 +0000
@@ -225,7 +225,8 @@
 
 (defun face-id (face &optional frame)
   "Return the internal ID of face with name FACE.
-If optional argument FRAME is nil or omitted, use the selected frame."
+The optional argument FRAME is ignored, since the internal face ID
+of a face name is the same for all frames."
   (check-face face)
   (get face 'face))
 
--- a/lisp/generic.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/generic.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,6 +1,6 @@
 ;;; generic.el --- defining simple major modes with comment and font-lock
 ;;
-;; Copyright (C) 1997, 1999, 2004 Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1999, 2004, 2005 Free Software Foundation, Inc.
 ;;
 ;; Author:  Peter Breton <pbreton@cs.umb.edu>
 ;; Created: Fri Sep 27 1996
@@ -215,8 +215,7 @@
 See the file generic-x.el for some examples of `define-generic-mode'."
 
   ;; Add a new entry
-  (unless (assq name generic-mode-list)
-    (push (list (symbol-name name)) generic-mode-list))
+  (add-to-list 'generic-mode-list (symbol-name name))
 
   ;; Add it to auto-mode-alist
   (dolist (re auto-mode-list)
--- a/lisp/gnus/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/gnus/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,14 +1,28 @@
+2005-03-10  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* nnimap.el (nnimap-retrieve-headers-from-server): Fix last change.
+
+2005-03-10  Arne J,Ax(Brgensen <arne@arnested.dk>  (tiny change)
+
+	* nnimap.el (nnimap-retrieve-headers-from-server): Fix off-by-one
+	flaw.
+
+2005-03-08  Bjorn Solberg <bjorn_ding@hekneby.org>  (tiny change)
+
+	* nnimap.el (nnimap-retrieve-headers-from-server): Sort NOV
+	buffer (since IMAP server might return FETCH response out of
+	order, and the nntp buffer must be sorted).
+
 2005-03-04  Reiner Steib  <Reiner.Steib@gmx.de>
 
 	* message.el: Don't autoload former message-utils variables.
-	(message-strip-subject-trailing-was): Changed doc string.
+	(message-strip-subject-trailing-was): Change doc string.
 
 	* nnweb.el: Fixes for `gnus-group-make-web-group'.
-	(nnweb-type-definition): Don't add "hl=en" in `address'.  Added
-	`base'.
+	(nnweb-type-definition): Don't add "hl=en" in `address'.  Add `base'.
 	(nnweb-google-search): Add "hl=en" here.
-	(nnweb-google-parse-1, nnweb-google-create-mapping): Don't
-	hardcode URL.
+	(nnweb-google-parse-1, nnweb-google-create-mapping):
+	Don't hardcode URL.
 
 2005-03-03  Reiner Steib  <Reiner.Steib@gmx.de>
 
--- a/lisp/gnus/nnimap.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/gnus/nnimap.el	Wed Mar 16 16:06:15 2005 +0000
@@ -665,6 +665,8 @@
 			    (if (imap-capability 'IMAP4rev1)
 				(format "BODY.PEEK[HEADER.FIELDS %s])" headers)
 			      (format "RFC822.HEADER.LINES %s)" headers)))))
+      (with-current-buffer nntp-server-buffer
+	(sort-numeric-fields 1 (point-min) (point-max)))
       (and (numberp nnmail-large-newsgroup)
 	   (> nnimap-length nnmail-large-newsgroup)
 	   (nnheader-message 6 "nnimap: Retrieving headers...done")))))
--- a/lisp/help.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/help.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,7 +1,7 @@
 ;;; help.el --- help commands for Emacs
 
-;; Copyright (C) 1985, 1986, 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2004
-;;   Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2004,
+;;   2005  Free Software Foundation, Inc.
 
 ;; Maintainer: FSF
 ;; Keywords: help, internal
@@ -685,34 +685,35 @@
 variable \(listed in `minor-mode-alist') must also be a function
 whose documentation describes the minor mode."
   (interactive)
-  (help-setup-xref (list #'describe-mode (or buffer (current-buffer)))
+  (unless buffer (setq buffer (current-buffer)))
+  (help-setup-xref (list #'describe-mode buffer)
 		   (interactive-p))
   ;; For the sake of help-do-xref and help-xref-go-back,
   ;; don't switch buffers before calling `help-buffer'.
   (with-output-to-temp-buffer (help-buffer)
-    (save-excursion
-      (when buffer (set-buffer buffer))
+    (with-current-buffer buffer
       (let (minor-modes)
+	;; Older packages do not register in minor-mode-list but only in
+	;; minor-mode-alist.
+	(dolist (x minor-mode-alist)
+	  (setq x (car x))
+	  (unless (memq x minor-mode-list)
+	    (push x minor-mode-list)))
 	;; Find enabled minor mode we will want to mention.
 	(dolist (mode minor-mode-list)
 	  ;; Document a minor mode if it is listed in minor-mode-alist,
 	  ;; non-nil, and has a function definition.
 	  (and (boundp mode) (symbol-value mode)
 	       (fboundp mode)
-	       (let ((pretty-minor-mode mode)
-		     indicator)
+	       (let ((pretty-minor-mode mode))
 		 (if (string-match "\\(-minor\\)?-mode\\'"
 				   (symbol-name mode))
 		     (setq pretty-minor-mode
 			   (capitalize
 			    (substring (symbol-name mode)
 				       0 (match-beginning 0)))))
-		 (setq indicator (cadr (assq mode minor-mode-alist)))
-		 (while (and indicator (symbolp indicator)
-			     (boundp indicator)
-			     (not (eq indicator (symbol-value indicator))))
-		   (setq indicator (symbol-value indicator)))
-		 (push (list pretty-minor-mode mode indicator)
+		 (push (list pretty-minor-mode mode
+			     (format-mode-line (assq mode minor-mode-alist)))
 		       minor-modes))))
 	(if auto-fill-function
 	    ;; copy pure string so we can add face property to it below.
@@ -729,6 +730,9 @@
 	      (let ((pretty-minor-mode (nth 0 mode))
 		    (mode-function (nth 1 mode))
 		    (indicator (nth 2 mode)))
+		(setq indicator (if (zerop (length indicator))
+				    "no indicator"
+				  (format "indicator%s" indicator)))
 		(add-text-properties 0 (length pretty-minor-mode)
 				     '(face bold) pretty-minor-mode)
 		(save-excursion
@@ -737,20 +741,14 @@
 		  (push (point-marker) help-button-cache)
 		  ;; Document the minor modes fully.
 		  (insert pretty-minor-mode)
-		  (princ (format " minor mode (%s):\n"
-				 (if indicator
-				     (format "indicator%s" indicator)
-				   "no indicator")))
+		  (princ (format " minor mode (%s):\n" indicator))
 		  (princ (documentation mode-function)))
 		(princ "  ")
 		(insert-button pretty-minor-mode
 			       'action (car help-button-cache)
 			       'follow-link t
 			       'help-echo "mouse-2, RET: show full information")
-		(princ (format " minor mode (%s):\n"
-			       (if indicator
-				   (format "indicator%s" indicator)
-				 "no indicator"))))))
+		(princ (format " minor mode (%s):\n" indicator)))))
 	  (princ "\n(Full information about these minor modes
 follows the description of the major mode.)\n\n"))
 	;; Document the major mode.
@@ -896,5 +894,5 @@
 ;; defcustoms which require 'help'.
 (provide 'help)
 
-;;; arch-tag: cf427352-27e9-49b7-9a6f-741ebab02423
+;; arch-tag: cf427352-27e9-49b7-9a6f-741ebab02423
 ;;; help.el ends here
--- a/lisp/image-file.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/image-file.el	Wed Mar 16 16:06:15 2005 +0000
@@ -135,6 +135,7 @@
 	  (setq truncate-lines t))))
     rval))
 
+(put 'image-file-handler 'safe-magic t)
 (defun image-file-handler (operation &rest args)
   "Filename handler for inserting image files.
 OPERATION is the operation to perform, on ARGS.
--- a/lisp/info.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/info.el	Wed Mar 16 16:06:15 2005 +0000
@@ -210,6 +210,8 @@
   :type 'boolean
   :group 'info)
 
+(defvar Info-isearch-initial-node nil)
+
 (defcustom Info-mode-hook
   ;; Try to obey obsolete Info-fontify settings.
   (unless (and (boundp 'Info-fontify) (null Info-fontify))
@@ -1502,7 +1504,7 @@
 			    ;; Skip node header line
 			    (and (save-excursion (forward-line -1)
 						 (looking-at "\^_"))
-				 (forward-line 1))
+				 (forward-line (if backward -1 1)))
 			    ;; Skip Tag Table node
 			    (save-excursion
 			      (and (search-backward "\^_" nil t)
@@ -1514,6 +1516,14 @@
 		  (setq found (point) beg-found (if backward (match-end 0)
 						  (match-beginning 0)))
 		(setq give-up t))))))
+
+      (when (and isearch-mode Info-isearch-search
+		 (not Info-isearch-initial-node)
+		 (not bound)
+		 (or give-up (and found (not (and (> found opoint-min)
+						  (< found opoint-max))))))
+	(signal 'search-failed (list regexp "initial node")))
+
       ;; If no subfiles, give error now.
       (if give-up
 	  (if (null Info-current-subfile)
@@ -1523,6 +1533,9 @@
 		  (re-search-forward regexp)))
 	    (setq found nil)))
 
+      (if (and bound (not found))
+	  (signal 'search-failed (list regexp)))
+
       (unless (or found bound)
 	(unwind-protect
 	    ;; Try other subfiles.
@@ -1540,6 +1553,7 @@
 		  (search-forward (concat "\n" osubfile ": "))
 		  ;; Skip that one.
 		  (forward-line (if backward 0 1))
+		  (if backward (forward-char -1))
 		  ;; Make a list of all following subfiles.
 		  ;; Each elt has the form (VIRT-POSITION . SUBFILENAME).
 		  (while (not (if backward (bobp) (eobp)))
@@ -1578,7 +1592,7 @@
 				  ;; Skip node header line
 				  (and (save-excursion (forward-line -1)
 						       (looking-at "\^_"))
-				       (forward-line 1))
+				       (forward-line (if backward -1 1)))
 				  ;; Skip Tag Table node
 				  (save-excursion
 				    (and (search-backward "\^_" nil t)
@@ -1615,7 +1629,8 @@
       ;; Use string-equal, not equal, to ignore text props.
       (or (and (string-equal onode Info-current-node)
 	       (equal ofile Info-current-file))
-          (and isearch-mode isearch-wrapped (eq opoint opoint-min))
+          (and isearch-mode isearch-wrapped
+	       (eq opoint (if isearch-forward opoint-min opoint-max)))
 	  (setq Info-history (cons (list ofile onode opoint)
 				   Info-history))))))
 
@@ -1646,21 +1661,30 @@
   (Info-search regexp bound noerror count 'backward))
 
 (defun Info-isearch-search ()
-  (if (and Info-isearch-search (not isearch-word))
+  (if Info-isearch-search
       (lambda (string &optional bound noerror count)
-	(condition-case nil
-	    (progn
-	      (Info-search (if isearch-regexp string (regexp-quote string))
-			   bound noerror count
-			   (unless isearch-forward 'backward))
-	      (point))
-	  (error nil)))
+	(if isearch-word
+	    (Info-search (concat "\\b" (replace-regexp-in-string
+					"\\W+" "\\\\W+"
+					(replace-regexp-in-string
+					 "^\\W+\\|\\W+$" "" string)) "\\b")
+			 bound noerror count
+			 (unless isearch-forward 'backward))
+	  (Info-search (if isearch-regexp string (regexp-quote string))
+		       bound noerror count
+		       (unless isearch-forward 'backward))
+	  (point)))
     (let ((isearch-search-fun-function nil))
       (isearch-search-fun))))
 
 (defun Info-isearch-wrap ()
-  (when (and Info-isearch-search (not isearch-word))
-    (if isearch-forward (Info-top-node) (Info-final-node))
+  (if Info-isearch-search
+      (if Info-isearch-initial-node
+	  (progn
+	    (if isearch-forward (Info-top-node) (Info-final-node))
+	    (goto-char (if isearch-forward (point-min) (point-max))))
+	(setq Info-isearch-initial-node Info-current-node)
+	(setq isearch-wrapped nil))
     (goto-char (if isearch-forward (point-min) (point-max)))))
 
 (defun Info-isearch-push-state ()
@@ -1672,6 +1696,8 @@
            (string= Info-current-node node))
       (progn (Info-find-node file node) (sit-for 0))))
 
+(defun Info-isearch-start ()
+  (setq Info-isearch-initial-node nil))
 
 (defun Info-extract-pointer (name &optional errorname)
   "Extract the value of the node-pointer named NAME.
@@ -3209,6 +3235,7 @@
   (setq desktop-save-buffer 'Info-desktop-buffer-misc-data)
   (add-hook 'clone-buffer-hook 'Info-clone-buffer-hook nil t)
   (add-hook 'change-major-mode-hook 'font-lock-defontify nil t)
+  (add-hook 'isearch-mode-hook 'Info-isearch-start nil t)
   (set (make-local-variable 'isearch-search-fun-function)
        'Info-isearch-search)
   (set (make-local-variable 'isearch-wrap-function)
--- a/lisp/international/ccl.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/international/ccl.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1305,7 +1305,9 @@
 
 BUFFER_MAGNIFICATION is an integer value specifying the approximate
 output buffer magnification size compared with the bytes of input data
-text.  If the value is zero, the CCL program can't execute `read' and
+text.  It is assured that the actual output buffer has 256 bytes
+more than the size calculated by BUFFER_MAGNIFICATION.
+If the value is zero, the CCL program can't execute `read' and
 `write' commands.
 
 CCL_MAIN_CODE and CCL_EOF_CODE are CCL program codes.  CCL_MAIN_CODE
--- a/lisp/international/latin-1.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/international/latin-1.el	Wed Mar 16 16:06:15 2005 +0000
@@ -104,7 +104,10 @@
   (set-case-syntax-pair 222 254 tbl)	;latin letter thorn (Icelandic)
   (set-case-syntax 223 "w" tbl)		;latin small letter sharp s (German)
   (set-case-syntax 247 "_" tbl)		;division sign
-  (set-case-syntax 255 "w" tbl))	;latin small letter y with diaeresis
+  ;; The following setting should be suppressed when we are loading
+  ;; this file for setting syntax of multibyte characters.
+  (or set-case-syntax-set-multibyte
+      (set-case-syntax 255 "w" tbl)))	;latin small letter y with diaeresis
 
 ;; When preloading this file, don't provide the feature.
 ;; Explicit `require' is used to load this for 8-bit characters.
--- a/lisp/international/mule-cmds.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/international/mule-cmds.el	Wed Mar 16 16:06:15 2005 +0000
@@ -2043,55 +2043,60 @@
      ;; and Chinese are exceptions, which are listed in the
      ;; non-standard section at the bottom of locale-language-names.
 
-    ; aa Afar
-    ; ab Abkhazian
+    ("aa_DJ" . "Latin-1") ; Afar
+    ("aa" . "UTF-8")
+    ;; ab Abkhazian
     ("af" . "Latin-1") ; Afrikaans
-    ("am" . "Ethiopic") ; Amharic
+    ("am" "Ethiopic" utf-8) ; Amharic
+    ("an" . "Latin-9") ; Aragonese
     ; ar Arabic glibc uses 8859-6
     ; as Assamese
     ; ay Aymara
-    ; az Azerbaijani
+    ("az" . "UTF-8") ; Azerbaijani
     ; ba Bashkir
-    ("be" . "Belarusian") ; Belarusian [Byelorussian until early 1990s]
-    ("bg" . "Bulgarian") ; Bulgarian
+    ("be" "Belarusian" cp1251) ; Belarusian [Byelorussian until early 1990s]
+    ("bg" "Bulgarian" cp1251) ; Bulgarian
     ; bh Bihari
     ; bi Bislama
-    ; bn Bengali, Bangla
+    ("bn" . "UTF-8") ; Bengali, Bangla
     ("bo" . "Tibetan")
     ("br" . "Latin-1") ; Breton
     ("bs" . "Latin-2") ; Bosnian
+    ("byn" . "UTF-8")  ; Bilin; Blin
     ("ca" . "Latin-1") ; Catalan
     ; co Corsican
-    ("cs" . "Czech")
-    ("cy" . "Welsh") ; Welsh [glibc uses Latin-8.  Did this change?]
+    ("cs" "Czech" iso-8859-2)
+    ("cy" "Welsh" iso-8859-14)
     ("da" . "Latin-1") ; Danish
-    ("de" . "German")
+    ("de" "German" iso-8859-1)
     ; dz Bhutani
-    ("el" . "Greek")
+    ("el" "Greek" iso-8859-7)
     ;; Users who specify "en" explicitly typically want Latin-1, not ASCII.
     ;; That's actually what the GNU locales define, modulo things like
     ;; en_IN -- fx.
+    ("en_IN" "English" utf-8) ; glibc uses utf-8 for English in India
     ("en" . "Latin-1") ; English
     ("eo" . "Latin-3") ; Esperanto
-    ("es" . "Spanish")
-    ("et" . "Latin-4") ; Estonian
+    ("es" "Spanish" iso-8859-1)
+    ("et" . "Latin-1") ; Estonian
     ("eu" . "Latin-1") ; Basque
-    ; fa Persian glibc uses utf-8
+    ("fa" . "UTF-8") ; Persian
     ("fi" . "Latin-1") ; Finnish
-    ; fj Fiji
+    ("fj" . "Latin-1") ; Fiji
     ("fo" . "Latin-1") ; Faroese
-    ("fr" . "French") ; French
+    ("fr" "French" iso-8859-1) ; French
     ("fy" . "Latin-1") ; Frisian
     ("ga" . "Latin-1") ; Irish Gaelic (new orthography)
-    ("gd" . "Latin-1") ; Scots Gaelic
-    ("gl" . "Latin-1") ; Galician
+    ("gd" . "Latin-9") ; Scots Gaelic
+    ("gez" "Ethiopic" utf-8) ; Geez
+    ("gl" . "Latin-1") ; Gallegan; Galician
     ; gn Guarani
-    ; gu Gujarati
-    ("gv" . "Latin-8") ; Manx Gaelic  glibc uses 8859-1
+    ("gu" . "UTF-8") ; Gujarati
+    ("gv" . "Latin-1") ; Manx Gaelic
     ; ha Hausa
-    ("he" . "Hebrew")
-    ("hi" . "Devanagari") ; Hindi  glibc uses utf-8
-    ("hr" . "Croatian") ; Croatian
+    ("he" "Hebrew" iso-8859-8)
+    ("hi" "Devanagari" utf-8) ; Hindi
+    ("hr" "Croatian" iso-8859-2) ; Croatian
     ("hu" . "Latin-2") ; Hungarian
     ; hy Armenian
     ; ia Interlingua
@@ -2099,110 +2104,114 @@
     ; ie Interlingue
     ; ik Inupiak
     ("is" . "Latin-1") ; Icelandic
-    ("it" . "Italian") ; Italian
+    ("it" "Italian" iso-8859-1) ; Italian
     ; iu Inuktitut
-    ("ja" . "Japanese")
+    ("iw" "Hebrew" iso-8859-8)
+    ("ja" "Japanese" euc-jp)
     ; jw Javanese
-    ("ka" . "Georgian") ; Georgian
+    ("ka" "Georgian" georgian-ps) ; Georgian
     ; kk Kazakh
     ("kl" . "Latin-1") ; Greenlandic
     ; km Cambodian
-    ; kn Kannada
-    ("ko" . "Korean")
+    ("kn" "Kannada" utf-8)
+    ("ko" "Korean" euc-kr)
     ; ks Kashmiri
     ; ku Kurdish
     ("kw" . "Latin-1") ; Cornish
     ; ky Kirghiz
     ("la" . "Latin-1") ; Latin
     ("lb" . "Latin-1") ; Luxemburgish
+    ("lg" . "Laint-6") ; Ganda
     ; ln Lingala
-    ("lo" . "Lao") ; Laothian
-    ("lt" . "Lithuanian")
+    ("lo" "Lao" utf-8) ; Laothian
+    ("lt" "Lithuanian" iso-8859-13)
     ("lv" . "Latvian") ; Latvian, Lettish
     ; mg Malagasy
     ("mi" . "Latin-7") ; Maori
-    ("mk" . "Cyrillic-ISO") ; Macedonian
-    ; ml Malayalam
-    ; mn Mongolian
+    ("mk" "Cyrillic-ISO" iso-8859-5) ; Macedonian
+    ("ml" "Malayalam" utf-8)
+    ("mn" . "UTF-8") ; Mongolian
     ; mo Moldavian
-    ("mr" . "Devanagari") ; Marathi  glibc uses utf-8
+    ("mr" "Devanagari" utf-8) ; Marathi
     ("ms" . "Latin-1") ; Malay
     ("mt" . "Latin-3") ; Maltese
     ; my Burmese
     ; na Nauru
-    ("ne" . "Devanagari") ; Nepali
-    ("nl" . "Dutch")
+    ("nb" . "Latin-1") ; Norwegian
+    ("ne" "Devanagari" utf-8) ; Nepali
+    ("nl" "Dutch" iso-8859-1)
     ("no" . "Latin-1") ; Norwegian
     ("oc" . "Latin-1") ; Occitan
-    ; om (Afan) Oromo
+    ("om_ET" . "UTF-8") ; (Afan) Oromo
+    ("om" . "Latin-1") ; (Afan) Oromo
     ; or Oriya
-    ; pa Punjabi
+    ("pa" . "UTF-8") ; Punjabi
     ("pl" . "Latin-2") ; Polish
     ; ps Pashto, Pushto
     ("pt" . "Latin-1") ; Portuguese
     ; qu Quechua
     ("rm" . "Latin-1") ; Rhaeto-Romanic
     ; rn Kirundi
-    ("ro" . "Romanian")
-    ("ru.*[_.]koi8" . "Russian")
-    ("ru" . "Cyrillic-ISO") ; Russian
+    ("ro" "Romanian" iso-8859-2)
+    ("ru_RU" "Russian" iso-8859-5)
+    ("ru_UA" "Russian" koi8-u)
     ; rw Kinyarwanda
     ("sa" . "Devanagari") ; Sanskrit
     ; sd Sindhi
-    ; se   Northern Sami
+    ("se" . "UTF-8") ; Northern Sami
     ; sg Sangho
     ("sh" . "Latin-2") ; Serbo-Croatian
     ; si Sinhalese
-    ("sk" . "Slovak")
-    ("sl" . "Slovenian")
+    ("sid" . "UTF-8") ; Sidamo
+    ("sk" "Slovak" iso-8859-2)
+    ("sl" "Slovenian" iso-8859-2)
     ; sm Samoan
     ; sn Shona
-    ; so Somali
+    ("so_ET" "UTF-8") ; Somali
+    ("so" "Latin-1") ; Somali
     ("sq" . "Latin-1") ; Albanian
+    ("sr_YU@cyrillic" . "Cyrillic-ISO")	; Serbian (Cyrillic alphabet)
     ("sr" . "Latin-2") ; Serbian (Latin alphabet)
-    ("sr_YU@cyrillic" . "Cyrillic-ISO")	; per glibc
     ; ss Siswati
-    ; st Sesotho
+    ("st" . "Latin-1") ;  Sesotho
     ; su Sundanese
-    ("sv" . "Swedish") ; Swedish
+    ("sv" "Swedish" iso-8859-1)		; Swedish
     ("sw" . "Latin-1") ; Swahili
-    ; ta Tamil  glibc uses utf-8
-    ; te Telugu  glibc uses utf-8
-    ("tg" . "Tajik")
-    ("th" . "Thai")
-    ; ti Tigrinya
+    ("ta" "Tamil" utf-8)
+    ("te" . "UTF-8") ; Telugu
+    ("tg" "Tajik" koi8-t)
+    ("th" "Thai" tis-620)
+    ("ti" "Ethiopic" utf-8) ; Tigrinya
+    ("tig_ER" . "UTF-8") ; Tigre
     ; tk Turkmen
     ("tl" . "Latin-1") ; Tagalog
     ; tn Setswana
     ; to Tonga
-    ("tr" . "Turkish")
+    ("tr" "Turkish" iso-8859-9)
     ; ts Tsonga
-    ; tt Tatar
+    ("tt" . "UTF-8") ; Tatar
     ; tw Twi
     ; ug Uighur
-    ("uk" . "Ukrainian") ; Ukrainian
-    ; ur Urdu  glibc uses utf-8
+    ("uk" "Ukrainian" koi8-u)
+    ("ur" . "UTF-8") ; Urdu
+    ("uz_UZ@cyrillic" . "UTF-8"); Uzbek
     ("uz" . "Latin-1") ; Uzbek
-    ("vi" . "Vietnamese") ;  glibc uses utf-8
+    ("vi" "Vietnamese" utf-8)
     ; vo Volapuk
     ("wa" . "Latin-1") ; Walloon
     ; wo Wolof
-    ; xh Xhosa
+    ("xh" . "Latin-1") ; Xhosa
     ("yi" . "Windows-1255") ; Yiddish
     ; yo Yoruba
     ; za Zhuang
-
-    ; glibc:
+    ("zh_HK" . "Chinese-Big5")
+    ("zh_TW" . "Chinese-Big5")
+    ("zh_CN" . "Chinese-GB")
+    ("zh" . "Chinese-GB")
     ; zh_CN.GB18030/GB18030 \
     ; zh_CN.GBK/GBK \
     ; zh_HK/BIG5-HKSCS \
-
-    ("zh.*[._]big5" . "Chinese-BIG5")
-    ("zh.*[._]gbk" . nil) ; Solaris 2.7; has gbk-0 as well as GB 2312.1980-0
-    ("zh_tw" . "Chinese-CNS") ; glibc uses big5
-    ("zh_tw[._]euc-tw" . "Chinese-EUC-TW")
-    ("zh" . "Chinese-GB")
-    ; zu Zulu
+    ("zu" . "Latin-1") ; Zulu
 
     ;; ISO standard locales
     ("c$" . "ASCII")
@@ -2222,10 +2231,16 @@
     ("chs" . "Chinese-GB") ; MS Windows Chinese Simplified
     ("cht" . "Chinese-BIG5") ; MS Windows Chinese Traditional
     ))
-  "List of pairs of locale regexps and language names.
-The first element whose locale regexp matches the start of a downcased locale
-specifies the language name corresponding to that locale.
-If the language name is nil, there is no corresponding language environment.")
+  "Alist of locale regexps vs the corresponding languages and coding systems.
+Each element has these form:
+  \(LOCALE-REGEXP LANG-ENV CODING-SYSTEM)
+The first element whose LOCALE-REGEXP matches the start of a
+downcased locale specifies the LANG-ENV \(language environtment)
+and CODING-SYSTEM corresponding to that locale.  If there is no
+appropriate language environment, the element may have this form:
+  \(LOCALE-REGEXP . LANG-ENV)
+In this case, LANG-ENV is one of generic language environments for an
+specific encoding such as \"Latin-1\" and \"UTF-8\".")
 
 (defconst locale-charset-language-names
   (purecopy
@@ -2243,20 +2258,43 @@
   "List of pairs of locale regexps and charset language names.
 The first element whose locale regexp matches the start of a downcased locale
 specifies the language name whose charset corresponds to that locale.
-This language name is used if its charsets disagree with the charsets of
-the language name that would otherwise be used for this locale.")
+This language name is used if the locale is not listed in
+`locale-language-names'")
 
 (defconst locale-preferred-coding-systems
   (purecopy
-   '(("ja.*[._]euc" . japanese-iso-8bit)
+   '((".*8859[-_]?1\\>" . iso-8859-1)
+     (".*8859[-_]?2\\>" . iso-8859-2)
+     (".*8859[-_]?3\\>" . iso-8859-3)
+     (".*8859[-_]?4\\>" . iso-8859-4)
+     (".*8859[-_]?9\\>" . iso-8859-9)
+     (".*8859[-_]?14\\>" . iso-8859-14)
+     (".*8859[-_]?15\\>" . iso-8859-15)
+     (".*utf\\(?:-?8\\)?" . utf-8)
+     ;; utf-8@euro exists, so put this after utf-8.  (@euro really
+     ;; specifies the currency, rather than the charset.)
+     (".*@euro" . iso-8859-15)
+     ("koi8-?r" . koi8-r)
+     ("koi8-?u" . koi8-u)
+     ("tcvn" . tcvn)
+     ("big5" . big5)
+     ("euc-?tw" . euc-tw)
+     ;; We don't support GBK, but as it is upper compatible with
+     ;; GB-2312, we setup the default coding system to gb2312.
+     ("gbk" . gb2312)
+     ;; We don't support BIG5-HKSCS, but as it is upper compatible with
+     ;; BIG5, we setup the default coding system to big5.
+     ("big5hkscs" . big5)
+     ("ja.*[._]euc" . japanese-iso-8bit)
      ("ja.*[._]jis7" . iso-2022-jp)
      ("ja.*[._]pck" . japanese-shift-jis)
      ("ja.*[._]sjis" . japanese-shift-jis)
      ("jpn" . japanese-shift-jis)   ; MS-Windows uses this.
-     (".*[._]utf" . utf-8)))
+     ))
   "List of pairs of locale regexps and preferred coding systems.
 The first element whose locale regexp matches the start of a downcased locale
-specifies the coding system to prefer when using that locale.")
+specifies the coding system to prefer when using that locale.
+This coding system is used if the locale specifies a specific charset.")
 
 (defun locale-name-match (key alist)
   "Search for KEY in ALIST, which should be a list of regexp-value pairs.
@@ -2462,12 +2500,17 @@
 	    (coding-system
 	     (get-locale-coding-system locale)))
 
-	;; Give preference to charset-language-name over language-name.
-	(if (and charset-language-name
-		 (not
-		  (equal (get-language-info language-name 'charset)
-			 (get-language-info charset-language-name 'charset))))
-	    (setq language-name charset-language-name))
+	(if (consp language-name)
+	    ;; locale-language-names specify both lang-env and coding.
+	    ;; But, what specified in locale-preferred-coding-systems
+	    ;; has higher priority.
+	    (setq coding-system (or coding-system
+				    (nth 1 language-name))
+		  language-name (car language-name))
+	  ;; Otherwise, if locale is not listed in locale-language-names,
+	  ;; use what listed in locale-charset-language-names.
+	  (if (not language-name)
+	      (setq language-name charset-language-name)))
 
 	(when language-name
 
@@ -2478,7 +2521,9 @@
 	  (setq locale-coding-system
 		(car (get-language-info language-name 'coding-priority))))
 
-	(when coding-system
+	(when (and coding-system
+		   (not (coding-system-equal coding-system
+					     locale-coding-system)))
 	  (prefer-coding-system coding-system)
 	  (setq locale-coding-system coding-system))))
 
--- a/lisp/international/mule.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/international/mule.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1041,6 +1041,7 @@
       (setq coding-category (plist-get plist 'coding-category))
       (aset coding-spec coding-spec-plist-idx plist))
     (put coding-system 'coding-system coding-spec)
+    (put coding-system 'coding-system-define-form nil)
     (put coding-category 'coding-systems
 	 (cons coding-system (get coding-category 'coding-systems))))
 
@@ -1102,6 +1103,7 @@
 (defun define-coding-system-alias (alias coding-system)
   "Define ALIAS as an alias for coding system CODING-SYSTEM."
   (put alias 'coding-system (coding-system-spec coding-system))
+  (put alias 'coding-system-define-form nil)
   (add-to-coding-system-list alias)
   (setq coding-system-alist (cons (list (symbol-name alias))
 				  coding-system-alist))
--- a/lisp/international/utf-16.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/international/utf-16.el	Wed Mar 16 16:06:15 2005 +0000
@@ -411,7 +411,7 @@
 Others are encoded as U+FFFD.")
 
 (define-ccl-program ccl-encode-mule-utf-16le-with-signature
-  `(4
+  `(2
     ((write #xFF)
      (write #xFE)
      ,@utf-16le-encode-loop))
@@ -423,7 +423,7 @@
 Others are encoded as U+FFFD.")
 
 (define-ccl-program ccl-encode-mule-utf-16be-with-signature
-  `(4
+  `(2
     ((write #xFE)
      (write #xFF)
      ,@utf-16be-encode-loop))
--- a/lisp/isearch.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/isearch.el	Wed Mar 16 16:06:15 2005 +0000
@@ -437,9 +437,8 @@
 (defvar isearch-string "")  ; The current search string.
 (defvar isearch-message "") ; text-char-description version of isearch-string
 
-(defvar isearch-success t)		; Searching is currently successful.
-(defvar isearch-invalid-regexp nil)	; Regexp not well formed.
-(defvar isearch-within-brackets nil)	; Regexp has unclosed [.
+(defvar isearch-success t)	; Searching is currently successful.
+(defvar isearch-error nil)	; Error message for failed search.
 (defvar isearch-other-end nil)	; Start (end) of match if forward (backward).
 (defvar isearch-wrapped nil)	; Searching restarted from the top (bottom).
 (defvar isearch-barrier 0)
@@ -640,8 +639,7 @@
 	isearch-barrier (point)
 	isearch-adjusted nil
 	isearch-yank-flag nil
-	isearch-invalid-regexp nil
-	isearch-within-brackets nil
+	isearch-error nil
 	isearch-slow-terminal-mode (and (<= baud-rate search-slow-speed)
 					(> (window-height)
 					   (* 4
@@ -867,7 +865,7 @@
 (defsubst isearch-word-state (frame)
   "Return the search-by-word flag in FRAME."
   (aref frame 6))
-(defsubst isearch-invalid-regexp-state (frame)
+(defsubst isearch-error-state (frame)
   "Return the regexp error message in FRAME, or nil if its regexp is valid."
   (aref frame 7))
 (defsubst isearch-wrapped-state (frame)
@@ -876,15 +874,12 @@
 (defsubst isearch-barrier-state (frame)
   "Return the barrier value in FRAME."
   (aref frame 9))
-(defsubst isearch-within-brackets-state (frame)
-  "Return the in-character-class flag in FRAME."
-  (aref frame 10))
 (defsubst isearch-case-fold-search-state (frame)
   "Return the case-folding flag in FRAME."
-  (aref frame 11))
+  (aref frame 10))
 (defsubst isearch-pop-fun-state (frame)
   "Return the function restoring the mode-specific isearch state in FRAME."
-  (aref frame 12))
+  (aref frame 11))
 
 (defun isearch-top-state ()
   (let ((cmd (car isearch-cmds)))
@@ -894,10 +889,9 @@
 	  isearch-forward (isearch-forward-state cmd)
 	  isearch-other-end (isearch-other-end-state cmd)
 	  isearch-word (isearch-word-state cmd)
-	  isearch-invalid-regexp (isearch-invalid-regexp-state cmd)
+	  isearch-error (isearch-error-state cmd)
 	  isearch-wrapped (isearch-wrapped-state cmd)
 	  isearch-barrier (isearch-barrier-state cmd)
-	  isearch-within-brackets (isearch-within-brackets-state cmd)
 	  isearch-case-fold-search (isearch-case-fold-search-state cmd))
     (if (functionp (isearch-pop-fun-state cmd))
 	(funcall (isearch-pop-fun-state cmd) cmd))
@@ -912,8 +906,8 @@
 	(cons (vector isearch-string isearch-message (point)
 		      isearch-success isearch-forward isearch-other-end
 		      isearch-word
-		      isearch-invalid-regexp isearch-wrapped isearch-barrier
-		      isearch-within-brackets isearch-case-fold-search
+		      isearch-error isearch-wrapped isearch-barrier
+		      isearch-case-fold-search
 		      (if isearch-push-state-function
 			  (funcall isearch-push-state-function)))
 	      isearch-cmds)))
@@ -976,8 +970,7 @@
 	      (isearch-barrier isearch-barrier)
 	      (isearch-adjusted isearch-adjusted)
 	      (isearch-yank-flag isearch-yank-flag)
-	      (isearch-invalid-regexp isearch-invalid-regexp)
-	      (isearch-within-brackets isearch-within-brackets)
+	      (isearch-error isearch-error)
   ;;; Don't bind this.  We want isearch-search, below, to set it.
   ;;; And the old value won't matter after that.
   ;;;	    (isearch-other-end isearch-other-end)
@@ -1124,7 +1117,7 @@
         (isearch-cancel))
     ;; If search is failing, or has an incomplete regexp,
     ;; rub out until it is once more successful.
-    (while (or (not isearch-success) isearch-invalid-regexp)
+    (while (or (not isearch-success) isearch-error)
       (isearch-pop-state))
     (isearch-update)))
 
@@ -1146,10 +1139,11 @@
 	;; If already have what to search for, repeat it.
 	(or isearch-success
 	    (progn
+	      ;; Set isearch-wrapped before calling isearch-wrap-function
+	      (setq isearch-wrapped t)
 	      (if isearch-wrap-function
 		  (funcall isearch-wrap-function)
-	        (goto-char (if isearch-forward (point-min) (point-max))))
-	      (setq isearch-wrapped t))))
+	        (goto-char (if isearch-forward (point-min) (point-max)))))))
     ;; C-s in reverse or C-r in forward, change direction.
     (setq isearch-forward (not isearch-forward)))
 
@@ -1384,8 +1378,7 @@
 		     (min isearch-opoint isearch-barrier))))
 	(progn
 	  (setq isearch-success t
-		isearch-invalid-regexp nil
-		isearch-within-brackets nil
+		isearch-error nil
 		isearch-other-end (match-end 0))
 	  (if (and (eq isearch-case-fold-search t) search-upper-case)
 	      (setq isearch-case-fold-search
@@ -1432,8 +1425,8 @@
 				(not want-backslash))
 	     ;; We have to check 2 stack frames because the last might be
 	     ;; invalid just because of a backslash.
-	     (or (not isearch-invalid-regexp)
-		 (not (isearch-invalid-regexp-state (cadr isearch-cmds)))
+	     (or (not isearch-error)
+		 (not (isearch-error-state (cadr isearch-cmds)))
 		 allow-invalid))
     (if to-barrier
 	(progn (goto-char isearch-barrier)
@@ -1448,7 +1441,7 @@
 	;; Also skip over postfix operators -- though horrid,
 	;; 'ab?\{5,6\}+\{1,2\}*' is perfectly legal.
 	(while (and previous
-		    (or (isearch-invalid-regexp-state frame)
+		    (or (isearch-error-state frame)
 			(let* ((string (isearch-string-state frame))
 			       (lchar (aref string (1- (length string)))))
 			  ;; The operators aren't always operators; check
@@ -1981,11 +1974,10 @@
   ;; If about to search, and previous search regexp was invalid,
   ;; check that it still is.  If it is valid now,
   ;; let the message we display while searching say that it is valid.
-  (and isearch-invalid-regexp ellipsis
+  (and isearch-error ellipsis
        (condition-case ()
 	   (progn (re-search-forward isearch-string (point) t)
-		  (setq isearch-invalid-regexp nil
-			isearch-within-brackets nil))
+		  (setq isearch-error nil))
 	 (error nil)))
   ;; If currently failing, display no ellipsis.
   (or isearch-success (setq ellipsis nil))
@@ -2011,8 +2003,8 @@
 
 (defun isearch-message-suffix (&optional c-q-hack ellipsis)
   (concat (if c-q-hack "^Q" "")
-	  (if isearch-invalid-regexp
-	      (concat " [" isearch-invalid-regexp "]")
+	  (if isearch-error
+	      (concat " [" isearch-error "]")
 	    "")))
 
 
@@ -2049,8 +2041,7 @@
 	    (case-fold-search isearch-case-fold-search)
 	    (search-spaces-regexp search-whitespace-regexp)
 	    (retry t))
-	(if isearch-regexp (setq isearch-invalid-regexp nil))
-	(setq isearch-within-brackets nil)
+	(setq isearch-error nil)
 	(while retry
 	  (setq isearch-success
 		(funcall
@@ -2074,16 +2065,19 @@
 	  (setq isearch-success nil))
 
     (invalid-regexp
-     (setq isearch-invalid-regexp (car (cdr lossage)))
-     (setq isearch-within-brackets (string-match "\\`Unmatched \\["
-						 isearch-invalid-regexp))
+     (setq isearch-error (car (cdr lossage)))
      (if (string-match
 	  "\\`Premature \\|\\`Unmatched \\|\\`Invalid "
-	  isearch-invalid-regexp)
-	 (setq isearch-invalid-regexp "incomplete input")))
+	  isearch-error)
+	 (setq isearch-error "incomplete input")))
+
+    (search-failed
+     (setq isearch-success nil)
+     (setq isearch-error (nth 2 lossage)))
+
     (error
      ;; stack overflow in regexp search.
-     (setq isearch-invalid-regexp (format "%s" lossage))))
+     (setq isearch-error (format "%s" lossage))))
 
   (if isearch-success
       nil
@@ -2315,7 +2309,7 @@
 ;;    `isearch-word' and `isearch-regexp';
 ;;  - the direction of the current search is expected to be given by
 ;;    `isearch-forward';
-;;  - the variable `isearch-invalid-regexp' is expected to be true
+;;  - the variable `isearch-error' is expected to be true
 ;;    iff `isearch-string' is an invalid regexp.
 
 (defvar isearch-lazy-highlight-overlays nil)
@@ -2369,7 +2363,7 @@
                          isearch-lazy-highlight-window-end))))
     ;; something important did indeed change
     (isearch-lazy-highlight-cleanup t) ;kill old loop & remove overlays
-    (when (not isearch-invalid-regexp)
+    (when (not isearch-error)
       (setq isearch-lazy-highlight-start-limit beg
 	    isearch-lazy-highlight-end-limit end)
       (setq isearch-lazy-highlight-window       (selected-window)
@@ -2391,18 +2385,20 @@
 Attempt to do the search exactly the way the pending isearch would."
   (let ((case-fold-search isearch-case-fold-search)
 	(search-spaces-regexp search-whitespace-regexp))
-    (funcall (isearch-search-fun)
-             isearch-string
-             (if isearch-forward
-                 (min (or isearch-lazy-highlight-end-limit (point-max))
-		      (if isearch-lazy-highlight-wrapped
-			  isearch-lazy-highlight-start
-			(window-end)))
-               (max (or isearch-lazy-highlight-start-limit (point-min))
-		    (if isearch-lazy-highlight-wrapped
-			isearch-lazy-highlight-end
-		      (window-start))))
-             t)))
+    (condition-case nil
+	(funcall (isearch-search-fun)
+		 isearch-string
+		 (if isearch-forward
+		     (min (or isearch-lazy-highlight-end-limit (point-max))
+			  (if isearch-lazy-highlight-wrapped
+			      isearch-lazy-highlight-start
+			    (window-end)))
+		   (max (or isearch-lazy-highlight-start-limit (point-min))
+			(if isearch-lazy-highlight-wrapped
+			    isearch-lazy-highlight-end
+			  (window-start))))
+		 t)
+      (error nil))))
 
 (defun isearch-lazy-highlight-update ()
   "Update highlighting of other matches for current search."
--- a/lisp/net/browse-url.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/net/browse-url.el	Wed Mar 16 16:06:15 2005 +0000
@@ -815,8 +815,9 @@
 When called non-interactively, optional second argument NEW-WINDOW is
 used instead of `browse-url-new-window-flag'.
 
-The order attempted is gnome-moz-remote, Mozilla, Galeon, Netscape,
-Mosaic, IXI Mosaic, Lynx in an xterm, MMM, Konqueror, and then W3."
+The order attempted is gnome-moz-remote, Mozilla, Galeon,
+Konqueror, Netscape, Mosaic, IXI Mosaic, Lynx in an xterm, MMM,
+and then W3."
   (apply
     (cond
      ((executable-find browse-url-gnome-moz-program) 'browse-url-gnome-moz)
--- a/lisp/pcvs-util.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/pcvs-util.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,7 +1,7 @@
 ;;; pcvs-util.el --- utility functions for PCL-CVS  -*- byte-compile-dynamic: t -*-
 
 ;; Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-;;   2000, 2001, 2004  Free Software Foundation, Inc.
+;;   2000, 2001, 2004, 2005  Free Software Foundation, Inc.
 
 ;; Author: Stefan Monnier <monnier@cs.yale.edu>
 ;; Keywords: pcl-cvs
@@ -205,8 +205,8 @@
 The SEPARATOR regexp defaults to \"\\s-+\"."
   (let ((sep (or separator "\\s-+"))
 	(i (string-match "[\"]" string)))
-    (if (null i) (split-string string sep)	; no quoting:  easy
-      (append (unless (eq i 0) (split-string (substring string 0 i) sep))
+    (if (null i) (split-string string sep t)	; no quoting:  easy
+      (append (unless (eq i 0) (split-string (substring string 0 i) sep t))
 	      (let ((rfs (read-from-string string i)))
 		(cons (car rfs)
 		      (cvs-string->strings (substring string (cdr rfs))
--- a/lisp/pcvs.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/pcvs.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1704,8 +1704,6 @@
 	    (message "Retrieving revision %s... Done" rev)
 	    (current-buffer))))))
 
-(eval-and-compile (autoload 'smerge-ediff "smerge-mode"))
-
 ;; FIXME: The user should be able to specify ancestor/head/backup and we should
 ;; provide sensible defaults when merge info is unavailable (rather than rely
 ;; on smerge-ediff).  Also provide sane defaults for need-merge files.
--- a/lisp/play/animate.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/play/animate.el	Wed Mar 16 16:06:15 2005 +0000
@@ -80,9 +80,11 @@
 ;;; Place the character CHAR at position VPOS, HPOS in the current buffer.
 (defun animate-place-char (char vpos hpos)
   (goto-char (window-start))
-  (let ((next-line-add-newlines t))
+  (let (abbrev-mode)
     (dotimes (i vpos)
-      (next-line 1)))
+      (end-of-line)
+      (if (= (forward-line 1) 1)
+	  (insert "\n"))))
   (beginning-of-line)
   (move-to-column (floor hpos) t)
   (unless (eolp) (delete-char 1))
--- a/lisp/progmodes/dcl-mode.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/progmodes/dcl-mode.el	Wed Mar 16 16:06:15 2005 +0000
@@ -284,13 +284,13 @@
 
 (defvar dcl-mode-syntax-table nil
   "Syntax table used in DCL-buffers.")
-(if dcl-mode-syntax-table
-    ()
+(unless dcl-mode-syntax-table
   (setq dcl-mode-syntax-table (make-syntax-table))
   (modify-syntax-entry ?!  "<" dcl-mode-syntax-table) ; comment start
   (modify-syntax-entry ?\n ">" dcl-mode-syntax-table) ; comment end
   (modify-syntax-entry ?< "(>" dcl-mode-syntax-table) ; < and ...
   (modify-syntax-entry ?> ")<" dcl-mode-syntax-table) ; > is a matching pair
+  (modify-syntax-entry ?\\ "_" dcl-mode-syntax-table) ; not an escape
 )
 
 
--- a/lisp/progmodes/gdb-ui.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/progmodes/gdb-ui.el	Wed Mar 16 16:06:15 2005 +0000
@@ -351,7 +351,7 @@
 				  ,(nth 1 var) nil))))
 	    (setq gdb-var-changed t)))
       (if (re-search-forward "Undefined command" nil t)
-	  (message "Watching expressions requires gdb 6.0 onwards")
+	  (message-box "Watching expressions requires gdb 6.0 onwards")
 	(message "No symbol %s in current context." expr)))))
 
 (defun gdb-var-evaluate-expression-handler (varnum changed)
@@ -2119,13 +2119,8 @@
 	    (push (cons bptno (match-string 0)) gdb-location-list))
       (gdb-resync)
       (push (cons bptno "File not found") gdb-location-list)
-      (if (eq window-system 'x)
-	  (x-popup-dialog
-	   t '("Cannot find source file for breakpoint location.\n\
-Add directory to search path for source files using the GDB command, dir."
-	       ("Ok" . nil)))
-	(message "Cannot find source file for breakpoint location.\n\
-Add directory to search path for source files using the GDB command, dir."))
+      (message-box "Cannot find source file for breakpoint location.\n\
+Add directory to search path for source files using the GDB command, dir.")
       (throw 'file-not-found nil))
     (with-current-buffer
 	(find-file-noselect (match-string 0))
--- a/lisp/simple.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/simple.el	Wed Mar 16 16:06:15 2005 +0000
@@ -3181,8 +3181,9 @@
   :version "21.1"
   :group 'editing-basics)
 
-(defun next-line (&optional arg)
+(defun next-line (&optional arg try-vscroll)
   "Move cursor vertically down ARG lines.
+Interactively, vscroll tall lines if `auto-window-vscroll' is enabled.
 If there is no character in the target line exactly under the current column,
 the cursor is positioned after the character in that line which spans this
 column, or at the end of the line if it is not long enough.
@@ -3201,7 +3202,7 @@
 If you are thinking of using this in a Lisp program, consider
 using `forward-line' instead.  It is usually easier to use
 and more reliable (no dependence on goal column, etc.)."
-  (interactive "p")
+  (interactive "p\np")
   (or arg (setq arg 1))
   (if (and next-line-add-newlines (= arg 1))
       (if (save-excursion (end-of-line) (eobp))
@@ -3209,16 +3210,17 @@
 	  (let ((abbrev-mode nil))
 	    (end-of-line)
 	    (insert "\n"))
-	(line-move arg nil nil t))
+	(line-move arg nil nil try-vscroll))
     (if (interactive-p)
 	(condition-case nil
-	    (line-move arg nil nil t)
+	    (line-move arg nil nil try-vscroll)
 	  ((beginning-of-buffer end-of-buffer) (ding)))
-      (line-move arg nil nil t)))
+      (line-move arg nil nil try-vscroll)))
   nil)
 
-(defun previous-line (&optional arg)
+(defun previous-line (&optional arg try-vscroll)
   "Move cursor vertically up ARG lines.
+Interactively, vscroll tall lines if `auto-window-vscroll' is enabled.
 If there is no character in the target line exactly over the current column,
 the cursor is positioned after the character in that line which spans this
 column, or at the end of the line if it is not long enough.
@@ -3233,13 +3235,13 @@
 If you are thinking of using this in a Lisp program, consider using
 `forward-line' with a negative argument instead.  It is usually easier
 to use and more reliable (no dependence on goal column, etc.)."
-  (interactive "p")
+  (interactive "p\np")
   (or arg (setq arg 1))
   (if (interactive-p)
       (condition-case nil
-	  (line-move (- arg) nil nil t)
+	  (line-move (- arg) nil nil try-vscroll)
 	((beginning-of-buffer end-of-buffer) (ding)))
-    (line-move (- arg) nil nil t))
+    (line-move (- arg) nil nil try-vscroll))
   nil)
 
 (defcustom track-eol nil
@@ -3278,8 +3280,11 @@
 	  (assq prop buffer-invisibility-spec)))))
 
 ;; Perform vertical scrolling of tall images if necessary.
+;; Don't vscroll in a keyboard macro.
 (defun line-move (arg &optional noerror to-end try-vscroll)
-  (if (and auto-window-vscroll try-vscroll)
+  (if (and auto-window-vscroll try-vscroll
+	   (not defining-kbd-macro)
+	   (not executing-kbd-macro))
       (let ((forward (> arg 0))
 	    (part (nth 2 (pos-visible-in-window-p (point) nil t))))
 	(if (and (consp part)
@@ -5068,6 +5073,7 @@
 (defcustom normal-erase-is-backspace
   (and (not noninteractive)
        (or (memq system-type '(ms-dos windows-nt))
+	   (eq initial-window-system 'mac)
 	   (and (memq initial-window-system '(x))
 		(fboundp 'x-backspace-delete-keys-p)
 		(x-backspace-delete-keys-p))
--- a/lisp/subr.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/subr.el	Wed Mar 16 16:06:15 2005 +0000
@@ -37,27 +37,6 @@
 	(cons arguments custom-declare-variable-list)))
 
 
-(defun macro-declaration-function (macro decl)
-  "Process a declaration found in a macro definition.
-This is set as the value of the variable `macro-declaration-function'.
-MACRO is the name of the macro being defined.
-DECL is a list `(declare ...)' containing the declarations.
-The return value of this function is not used."
-  ;; We can't use `dolist' or `cadr' yet for bootstrapping reasons.
-  (let (d)
-    ;; Ignore the first element of `decl' (it's always `declare').
-    (while (setq decl (cdr decl))
-      (setq d (car decl))
-      (cond ((and (consp d) (eq (car d) 'indent))
-	     (put macro 'lisp-indent-function (car (cdr d))))
-	    ((and (consp d) (eq (car d) 'debug))
-	     (put macro 'edebug-form-spec (car (cdr d))))
-	    (t
-	     (message "Unknown declaration %s" d))))))
-
-(setq macro-declaration-function 'macro-declaration-function)
-
-
 ;;;; Lisp language features.
 
 (defalias 'not 'null)
--- a/lisp/term/mac-win.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/term/mac-win.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1010,20 +1010,29 @@
 
 ;; Map certain keypad keys into ASCII characters
 ;; that people usually expect.
+(define-key function-key-map [backspace] [?\d])
+(define-key function-key-map [delete] [?\d])
+(define-key function-key-map [tab] [?\t])
+(define-key function-key-map [linefeed] [?\n])
+(define-key function-key-map [clear] [?\C-l])
 (define-key function-key-map [return] [?\C-m])
-(define-key function-key-map [M-return] [?\M-\C-m])
-(define-key function-key-map [tab] [?\t])
+(define-key function-key-map [escape] [?\e])
+(define-key function-key-map [M-backspace] [?\M-\d])
+(define-key function-key-map [M-delete] [?\M-\d])
 (define-key function-key-map [M-tab] [?\M-\t])
-(define-key function-key-map [backspace] [?\d])
-(define-key function-key-map [M-backspace] [?\M-\d])
-(define-key function-key-map [escape] [?\e])
+(define-key function-key-map [M-linefeed] [?\M-\n])
+(define-key function-key-map [M-clear] [?\M-\C-l])
+(define-key function-key-map [M-return] [?\M-\C-m])
 (define-key function-key-map [M-escape] [?\M-\e])
 
 ;; These tell read-char how to convert
 ;; these special chars to ASCII.
-(put 'return 'ascii-character ?\C-m)
+(put 'backspace 'ascii-character ?\d)
+(put 'delete 'ascii-character ?\d)
 (put 'tab 'ascii-character ?\t)
-(put 'backspace 'ascii-character ?\d)
+(put 'linefeed 'ascii-character ?\n)
+(put 'clear 'ascii-character ?\C-l)
+(put 'return 'ascii-character ?\C-m)
 (put 'escape 'ascii-character ?\e)
 
 
--- a/lisp/textmodes/fill.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/textmodes/fill.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,4 +1,4 @@
-;;; fill.el --- fill commands for Emacs
+;;; fill.el --- fill commands for Emacs		-*- coding: iso-2022-7bit -*-
 
 ;; Copyright (C) 1985,86,92,94,95,96,97,1999,2001,02,03,2004
 ;;               Free Software Foundation, Inc.
@@ -87,7 +87,7 @@
 (defcustom adaptive-fill-regexp
   ;; Added `!' for doxygen comments starting with `//!' or `/*!'.
   ;; Added `%' for TeX comments.
-  (purecopy "[ \t]*\\([-!|#%;>*]+[ \t]*\\|(?[0-9]+[.)][ \t]*\\)*")
+  (purecopy "[ \t]*\\([-!|#%;>*,A7$,1s"s#sC$,2"F(B]+[ \t]*\\|(?[0-9]+[.)][ \t]*\\)*")
   "*Regexp to match text at start of line that constitutes indentation.
 If Adaptive Fill mode is enabled, a prefix matching this pattern
 on the first and second lines of a paragraph is used as the
@@ -304,12 +304,12 @@
 mark such as `?' or `:'.  It is common in French writing to put a space
 at such places, which would normally allow breaking the line at those
 places."
-  (or (looking-at "[ \t]*[])}»?!;:-]")
+  (or (looking-at "[ \t]*[])},A;,b;(B?!;:-]")
       (save-excursion
 	(skip-chars-backward " \t")
 	(unless (bolp)
 	  (backward-char 1)
-	  (or (looking-at "[([{«]")
+	  (or (looking-at "[([{,A+,b+(B]")
 	      ;; Don't cut right after a single-letter word.
 	      (and (memq (preceding-char) '(?\t ?\ ))
 		   (eq (char-syntax (following-char)) ?w)))))))
--- a/lisp/textmodes/ispell.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/textmodes/ispell.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1406,6 +1406,14 @@
 			  (setq more-lines (= 0 (forward-line))))))))))))))
 
 
+;; Insert WORD while translating Latin characters to the equivalent
+;; characters that is supported by buffer-file-coding-system.
+
+(defun ispell-insert-word (word)
+  (let ((pos (point)))
+    (insert word)
+    (if (char-table-p translation-table-for-input)
+	(translate-region pos (point) translation-table-for-input))))
 
 ;;;###autoload
 (defun ispell-word (&optional following quietly continue)
@@ -1504,7 +1512,7 @@
 			  (progn
 			    (delete-region start end)
 			    (setq start (point))
-			    (insert new-word)
+			    (ispell-insert-word new-word)
 			    (setq end (point))))
 		      (if (not (atom replace)) ;recheck spelling of replacement
 			  (progn
@@ -2883,7 +2891,7 @@
 	      (delete-region (point) (+ word-len (point)))
 	      (if (not (listp replace))
 		  (progn
-		    (insert replace)	; insert dictionary word
+		    (ispell-insert-word replace) ; insert dictionary word
 		    (ispell-send-replacement (car poss) replace)
 		    (setq accept-list (cons replace accept-list)))
 		(let ((replace-word (car replace)))
@@ -3052,7 +3060,7 @@
 	     (setq word (if (atom replacement) replacement (car replacement))
 		   cursor-location (+ (- (length word) (- end start))
 				      cursor-location))
-	     (insert word)
+	     (ispell-insert-word word)
 	     (if (not (atom replacement)) ; recheck spelling of replacement.
 		 (progn
 		   (goto-char cursor-location)
--- a/lisp/textmodes/sgml-mode.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/textmodes/sgml-mode.el	Wed Mar 16 16:06:15 2005 +0000
@@ -350,7 +350,7 @@
   "*When non-nil, tag insertion functions will be XML-compliant.
 If this variable is customized, the custom value is used always.
 Otherwise, it is set to be buffer-local when the file has
- a DOCTYPE or an XML declaration."
+a DOCTYPE or an XML declaration."
   :type 'boolean
   :version "22.1"
   :group 'sgml)
@@ -629,7 +629,7 @@
       (backward-char)
       '(("") " [ " _ " ]]"))
      ((and (eq v2 t) sgml-xml-mode (member ,str sgml-empty-tags))
-      '(("") -1 "/>"))
+      '(("") -1 " />"))
      ((or (and (eq v2 t) (not sgml-xml-mode)) (string-match "^[/!?]" ,str))
       nil)
      ((symbolp v2)
@@ -818,7 +818,8 @@
 	      (goto-char close)
 	      (kill-sexp 1))
 	  (setq open (point))
-	  (when (sgml-skip-tag-forward 1)
+	  (when (and (sgml-skip-tag-forward 1)
+		     (not (looking-back "/>")))
 	    (kill-sexp -1)))
 	;; Delete any resulting empty line.  If we didn't kill-sexp,
 	;; this *should* do nothing, because we're right after the tag.
@@ -1572,7 +1573,7 @@
       ("dir" ,@list)
       ("font" nil "size" ("-1") ("+1") ("-2") ("+2") ,@1-7)
       ("form" (\n _ \n "<input type=\"submit\" value=\"\""
-	       (if sgml-xml-mode "/>" ">"))
+	       (if sgml-xml-mode " />" ">"))
        ("action" ,@(cdr href)) ("method" ("get") ("post")))
       ("h1" ,@align)
       ("h2" ,@align)
@@ -1891,13 +1892,15 @@
 (define-skeleton html-href-anchor
   "HTML anchor tag with href attribute."
   "URL: "
-  '(setq input "http:")
+  ;; '(setq input "http:")
   "<a href=\"" str "\">" _ "</a>")
 
 (define-skeleton html-name-anchor
   "HTML anchor tag with name attribute."
   "Name: "
-  "<a name=\"" str "\">" _ "</a>")
+  "<a name=\"" str "\""
+  (if sgml-xml-mode (concat " id=\"" str "\""))
+  ">" _ "</a>")
 
 (define-skeleton html-headline-1
   "HTML level 1 headline tags."
@@ -1932,18 +1935,18 @@
 (define-skeleton html-horizontal-rule
   "HTML horizontal rule tag."
   nil
-  (if sgml-xml-mode "<hr/>" "<hr>") \n)
+  (if sgml-xml-mode "<hr />" "<hr>") \n)
 
 (define-skeleton html-image
   "HTML image tag."
-  nil
-  "<img src=\"" _ "\""
-  (if sgml-xml-mode "/>" ">"))
+  "Image URL: "
+  "<img src=\"" str "\" alt=\"" _ "\""
+  (if sgml-xml-mode " />" ">"))
 
 (define-skeleton html-line
   "HTML line break tag."
   nil
-  (if sgml-xml-mode "<br/>" "<br>") \n)
+  (if sgml-xml-mode "<br />" "<br>") \n)
 
 (define-skeleton html-ordered-list
   "HTML ordered list tags."
@@ -1969,7 +1972,7 @@
   "HTML paragraph tag."
   nil
   (if (bolp) nil ?\n)
-  \n "<p>" _ (if sgml-xml-mode "</p>"))
+  "<p>" _ (if sgml-xml-mode "</p>"))
 
 (define-skeleton html-checkboxes
   "Group of connected checkbox inputs."
@@ -1981,12 +1984,13 @@
    "\" name=\"" (or v1 (setq v1 (skeleton-read "Name: ")))
    "\" value=\"" str ?\"
    (when (y-or-n-p "Set \"checked\" attribute? ")
-     (funcall skeleton-transformation " checked"))
-   (if sgml-xml-mode "/>" ">")
+     (funcall skeleton-transformation
+	      (if sgml-xml-mode " checked=\"checked\"" " checked")))
+   (if sgml-xml-mode " />" ">")
    (skeleton-read "Text: " (capitalize str))
    (or v2 (setq v2 (if (y-or-n-p "Newline after text? ")
 		       (funcall skeleton-transformation
-                                (if sgml-xml-mode "<br/>" "<br>"))
+                                (if sgml-xml-mode "<br />" "<br>"))
 		     "")))
    \n))
 
@@ -2000,12 +2004,13 @@
    "\" name=\"" (or (car v2) (setcar v2 (skeleton-read "Name: ")))
    "\" value=\"" str ?\"
    (when (and (not v1) (setq v1 (y-or-n-p "Set \"checked\" attribute? ")))
-     (funcall skeleton-transformation " checked"))
-   (if sgml-xml-mode "/>" ">")
+     (funcall skeleton-transformation
+	      (if sgml-xml-mode " checked=\"checked\"" " checked")))
+   (if sgml-xml-mode " />" ">")
    (skeleton-read "Text: " (capitalize str))
    (or (cdr v2) (setcdr v2 (if (y-or-n-p "Newline after text? ")
 			       (funcall skeleton-transformation
-                                        (if sgml-xml-mode "<br/>" "<br>"))
+                                        (if sgml-xml-mode "<br />" "<br>"))
 			     "")))
    \n))
 
--- a/lisp/tooltip.el	Wed Mar 16 16:03:44 2005 +0000
+++ b/lisp/tooltip.el	Wed Mar 16 16:06:15 2005 +0000
@@ -1,6 +1,6 @@
 ;;; tooltip.el --- show tooltip windows
 
-;; Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004
+;; Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004, 2005
 ;;        Free Software Foundation, Inc.
 
 ;; Author: Gerd Moellmann <gerd@acm.org>
@@ -41,8 +41,6 @@
   :version "21.1"
   :tag "Tool Tips")
 
-(defvar tooltip-mode)
-
 (defcustom tooltip-delay 0.7
   "Seconds to wait before displaying a tooltip the first time."
   :tag "Delay"
@@ -122,11 +120,9 @@
   "*Non-nil means show tooltips in GUD sessions."
   :type 'boolean
   :tag "GUD"
-  :set #'(lambda (symbol on)
-	   (setq tooltip-gud-tips-p on))
   :group 'tooltip)
 
-(defcustom tooltip-gud-modes '(gud-mode c-mode c++-mode)
+(defcustom tooltip-gud-modes '(gud-mode c-mode c++-mode fortran-mode)
   "List of modes for which to enable GUD tips."
   :type 'sexp
   :tag "GUD modes"
@@ -187,26 +183,23 @@
 ;; would be accompanied by a full redisplay.
 
 ;;;###autoload
-(defun tooltip-mode (&optional arg)
-  "Mode for tooltip display.
+(define-minor-mode tooltip-mode
+  "Toggle Tooltip display.
 With ARG, turn tooltip mode on if and only if ARG is positive."
-  (interactive "P")
-  (unless (fboundp 'x-show-tip)
+  :global t
+  :group 'tooltip
+  (unless (or (null tooltip-mode) (fboundp 'x-show-tip))
     (error "Sorry, tooltips are not yet available on this system"))
-  (let* ((on (if arg
-		 (> (prefix-numeric-value arg) 0)
-	       (not tooltip-mode)))
-	 (hook-fn (if on 'add-hook 'remove-hook)))
-    (setq tooltip-mode on)
+  (let ((hook-fn (if tooltip-mode 'add-hook 'remove-hook)))
     (funcall hook-fn 'change-major-mode-hook 'tooltip-change-major-mode)
     (tooltip-activate-mouse-motions-if-enabled)
     (funcall hook-fn 'pre-command-hook 'tooltip-hide)
     (funcall hook-fn 'tooltip-hook 'tooltip-gud-tips)
     (funcall hook-fn 'tooltip-hook 'tooltip-help-tips)
-    (setq show-help-function (if on 'tooltip-show-help-function nil))
+    (setq show-help-function (if tooltip-mode 'tooltip-show-help-function nil))
     ;; `ignore' is the default binding for mouse movements.
     (define-key global-map [mouse-movement]
-      (if on 'tooltip-mouse-motion 'ignore))))
+      (if tooltip-mode 'tooltip-mouse-motion 'ignore))))
 
 
 ;;; Timeout for tooltip display
@@ -246,16 +239,14 @@
 (defun tooltip-activate-mouse-motions-if-enabled ()
   "Reconsider for all buffers whether mouse motion events are desired."
   (remove-hook 'post-command-hook 'tooltip-activate-mouse-motions-if-enabled)
-  (let ((buffers (buffer-list)))
+  (dolist (buffer (buffer-list))
     (save-excursion
-      (while buffers
-	(set-buffer (car buffers))
-	(if (and tooltip-mode
-		 tooltip-gud-tips-p
-		 (memq major-mode tooltip-gud-modes))
-	    (tooltip-activate-mouse-motions t)
-	  (tooltip-activate-mouse-motions nil))
-	(setq buffers (cdr buffers))))))
+      (set-buffer buffer)
+      (if (and tooltip-mode
+	       tooltip-gud-tips-p
+	       (memq major-mode tooltip-gud-modes))
+	  (tooltip-activate-mouse-motions t)
+	(tooltip-activate-mouse-motions nil)))))
 
 (defvar tooltip-mouse-motions-active nil
   "Locally t in a buffer if tooltip processing of mouse motion is enabled.")
@@ -441,12 +432,11 @@
 add a `*' in front of the printed expression.
 
 This function must return nil if it doesn't handle EVENT."
-  (let (gud-buffer process)
+  (let (process)
     (when (and (eventp event)
 	       tooltip-gud-tips-p
 	       (boundp 'gud-comint-buffer)
-	       (setq gud-buffer gud-comint-buffer)
-	       (setq process (get-buffer-process gud-buffer))
+	       (setq process (get-buffer-process gud-comint-buffer))
 	       (posn-point (event-end event))
 	       (progn (setq tooltip-gud-event event)
 		      (eval (cons 'and tooltip-gud-display))))
@@ -464,9 +454,11 @@
 		    expr)))))))
 
 (defun gdb-tooltip-print ()
-  (tooltip-show
+  (tooltip-show 
    (with-current-buffer (gdb-get-buffer 'gdb-partial-output-buffer)
-     (buffer-string))))
+     (let ((string (buffer-string)))
+       ;; remove newline for tooltip-use-echo-area
+       (substring string 0 (- (length string) 1))))))
 
 
 ;;; Tooltip help.
@@ -520,23 +512,6 @@
     (tooltip-show tooltip-help-message)
     t))
 
-
-;;; Do this after all functions have been defined that are called from
-;;; `tooltip-mode'.  The actual default value of `tooltip-mode' is set
-;;; in startup.el.
-
-;;;###autoload
-(defcustom tooltip-mode nil
-  "Non-nil if Tooltip mode is enabled.
-Setting this variable directly does not take effect;
-use either \\[customize] or the function `tooltip-mode'."
-  :set (lambda (symbol value)
-	 (tooltip-mode (or value 0)))
-  :initialize 'custom-initialize-default
-  :type 'boolean
-  :require 'tooltip
-  :group 'tooltip)
-
 (provide 'tooltip)
 
 ;; arch-tag: 3d61135e-4618-4a78-af28-183f6df5636f
--- a/lispref/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,64 @@
+2005-03-15  Lute Kamstra  <lute@gnu.org>
+
+	* edebug.texi (Instrumenting Macro Calls): Fix typos.
+
+2005-03-08  Kim F. Storm  <storm@cua.dk>
+
+	* display.texi (Specified Space): Property :width is support on
+	non-graphic terminals, :height is not.
+
+2005-03-07  Richard M. Stallman  <rms@gnu.org>
+
+	* display.texi (Overlay Arrow, Fringe Bitmaps, Customizing Bitmaps):
+	Now subnodes of Fringes.
+	(Overlay Arrow): Document overlay-arrow-variable-list.
+	(Fringe Size/Pos): New node, broken out of Fringes.
+	(Display): Explain clearing vs redisplay better.
+	(Truncation): Clarify use of bitmaps.
+	(The Echo Area): Clarify the uses of the echo area.
+	Add max-mini-window-height.
+	(Progress): Clarify.
+	(Invisible Text): Explain that main loop moves point out.
+	(Selective Display): Say "hidden", not "invisible".
+	(Managing Overlays): Moved up.  Describe relation to Undo here.
+	(Overlay Properties): Clarify intro.
+	(Finding Overlays): Explain return values when nothing found.
+	(Width): truncate-string-to-width has added arg.
+	(Displaying Faces): Clarify and update mode line face handling.
+	(Face Functions): Minor cleanup.
+	(Conditional Display): Merged into Other Display Specs.
+	(Pixel Specification, Other Display Specs): Minor cleanups.
+	(Images, Image Descriptors): Minor cleanups.
+	(GIF Images): Patents have expired.
+	(Showing Images): Explain default text for insert-image.
+	(Manipulating Button Types): Merged into Manipulating Buttons.
+	(Making Buttons): Explain return values.
+	(Button Buffer Commands): Add xref.
+	(Inverse Video): Update mode-line-inverse-video.
+	(Display Table Format): Clarify.
+	(Active Display Table): Give defaults for window-display-table.
+
+	* calendar.texi (Calendar Customizing): calendar-holiday-marker
+	and calendar-today-marker are strings, not chars.
+	(Holiday Customizing): Minor fix.
+
+	* nonascii.texi (Text Representations): Clarify position-bytes.
+	(Character Sets): Add list-charset-chars.
+	(Scanning Charsets): Add charset-after.
+	(Encoding and I/O): Minor fix.
+
+	* internals.texi (Writing Emacs Primitives): Update `or' example.
+	Update limit on # args of subr.
+
+	* edebug.texi (Using Edebug): Arrow is in fringe.
+	(Instrumenting): Arg to eval-defun works without loading edebug.
+	(Edebug Execution Modes): Add xref.
+
+	* customize.texi (Common Keywords): Clarify :require.
+	Mention :version here.
+	(Variable Definitions, Group Definitions): Not here.
+	(Variable Definitions): Clarify symbol arg to :initialize and :set fns.
+
 2005-03-06  Richard M. Stallman  <rms@gnu.org>
 
 	* windows.texi (Vertical Scrolling): Get rid of "Emacs 21".
@@ -14,9 +75,9 @@
 	* os.texi (Translating Input): Replace flow-control example
 	with a less obsolete example that uses `keyboard-translate'.
 
-	* objects.texi (Hash Table Type, Circular Objects): 
+	* objects.texi (Hash Table Type, Circular Objects):
 	Get rid of "Emacs 21".
-	
+
 	* modes.texi (Mode Line Format): Get rid of "Emacs 21".
 	(Mode Line Data, Properties in Mode, Header Lines): Likewise.
 
--- a/lispref/calendar.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/calendar.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -62,12 +62,12 @@
 @vindex calendar-holiday-marker
 @vindex diary-entry-marker
   The variable @code{calendar-holiday-marker} specifies how to mark a
-date as being a holiday.  Its value may be a character to insert next to
-the date, or a face name to use for displaying the date.  Likewise, the
-variable @code{diary-entry-marker} specifies how to mark a date that has
-diary entries.  The calendar creates faces named @code{holiday-face} and
-@code{diary-face} for these purposes; those symbols are the default
-values of these variables.
+date as being a holiday.  Its value may be a single-character string
+to insert next to the date, or a face name to use for displaying the
+date.  Likewise, the variable @code{diary-entry-marker} specifies how
+to mark a date that has diary entries.  The calendar creates faces
+named @code{holiday-face} and @code{diary-face} for these purposes;
+those symbols are the default values of these variables.
 
 @vindex calendar-load-hook
   The variable @code{calendar-load-hook} is a normal hook run when the
@@ -103,11 +103,11 @@
 
 @noindent
 @vindex calendar-today-marker
-The variable @code{calendar-today-marker} specifies how to mark today's
-date.  Its value should be a character to insert next to the date or a
-face name to use for displaying the date.  A face named
-@code{calendar-today-face} is provided for this purpose; that symbol is
-the default for this variable.
+The variable @code{calendar-today-marker} specifies how to mark
+today's date.  Its value should be a single-character string to insert
+next to the date or a face name to use for displaying the date.  A
+face named @code{calendar-today-face} is provided for this purpose;
+that symbol is the default for this variable.
 
 @vindex today-invisible-calendar-hook
 @noindent
@@ -130,7 +130,7 @@
 deleting holidays.  The lists of holidays that Emacs uses are for
 general holidays (@code{general-holidays}), local holidays
 (@code{local-holidays}), Christian holidays (@code{christian-holidays}),
-Hebrew (Jewish) holidays (@code{hebrew-holidays}), Islamic (Moslem)
+Hebrew (Jewish) holidays (@code{hebrew-holidays}), Islamic (Muslim)
 holidays (@code{islamic-holidays}), and other holidays
 (@code{other-holidays}).
 
--- a/lispref/customize.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/customize.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -84,13 +84,17 @@
 not already loaded.
 
 @item :require @var{feature}
-Require feature @var{feature} (a symbol) when installing a value for
-this item (an option or a face) that was saved using the customization
-feature.  This is done by calling @code{require}.
+Execute @code{(require '@var{feature})} when your saved customizations
+set the value of this item.  @var{feature} should be a symbol.
 
 The most common reason to use @code{:require} is when a variable enables
 a feature such as a minor mode, and just setting the variable won't have
 any effect unless the code which implements the mode is loaded.
+
+@item :version @var{version}
+This option specifies that the item was first introduced in Emacs
+version @var{version}, or that its default value was changed in that
+version.  The value @var{version} must be a string.
 @end table
 
 @node Group Definitions
@@ -130,17 +134,9 @@
 Useful widgets are @code{custom-variable} for a variable,
 @code{custom-face} for a face, and @code{custom-group} for a group.
 
-When a new group is introduced into Emacs, use this keyword in
-@code{defgroup}:
-
-@table @code
-@item :version @var{version}
-This option specifies that the group was first introduced in Emacs
-version @var{version}.  The value @var{version} must be a string.
-@end table
-
-Tag the group with a version like this when it is introduced, rather
-than the individual members (@pxref{Variable Definitions}).
+When you introduce a new group into Emacs, use the @code{:version}
+keyword in the @code{defgroup}; then you need not use it for
+the individual members of the group.
 
 In addition to the common keywords (@pxref{Common Keywords}), you can
 also use this keyword in @code{defgroup}:
@@ -223,26 +219,13 @@
 @code{hook}, @code{plist} and @code{alist}.  See the definition of the
 individual types for a description of how to use @code{:options}.
 
-@item :version @var{version}
-This option specifies that the variable was first introduced, or its
-default value was changed, in Emacs version @var{version}.  The value
-@var{version} must be a string.  For example,
-
-@example
-(defcustom foo-max 34
-  "*Maximum number of foo's allowed."
-  :type 'integer
-  :group 'foo
-  :version "20.3")
-@end example
-
 @item :set @var{setfunction}
-Specify @var{setfunction} as the way to change the value of this option.
-The function @var{setfunction} should take two arguments, a symbol and
-the new value, and should do whatever is necessary to update the value
-properly for this option (which may not mean simply setting the option
-as a Lisp variable).  The default for @var{setfunction} is
-@code{set-default}.
+Specify @var{setfunction} as the way to change the value of this
+option.  The function @var{setfunction} should take two arguments, a
+symbol (the option name) and the new value, and should do whatever is
+necessary to update the value properly for this option (which may not
+mean simply setting the option as a Lisp variable).  The default for
+@var{setfunction} is @code{set-default}.
 
 @item :get @var{getfunction}
 Specify @var{getfunction} as the way to extract the value of this
@@ -258,10 +241,10 @@
 that really is stored in a Lisp variable.
 
 @item :initialize @var{function}
-@var{function} should be a function used to initialize the variable when
-the @code{defcustom} is evaluated.  It should take two arguments, the
-symbol and value.  Here are some predefined functions meant for use in
-this way:
+@var{function} should be a function used to initialize the variable
+when the @code{defcustom} is evaluated.  It should take two arguments,
+the option name (a symbol) and the value.  Here are some predefined
+functions meant for use in this way:
 
 @table @code
 @item custom-initialize-set
--- a/lispref/display.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/display.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -19,7 +19,6 @@
 * Progress::            Informing user about progress of a long operation.
 * Invisible Text::      Hiding part of the buffer text.
 * Selective Display::   Hiding part of the buffer text (the old way).
-* Overlay Arrow::       Display of an arrow to indicate position.
 * Temporary Displays::  Displays that go away automatically.
 * Overlays::            Use overlays to highlight parts of the buffer.
 * Width::               How wide a character or string is on the screen.
@@ -27,8 +26,6 @@
 * Faces::               A face defines a graphics style for text characters:
                           font, colors, etc.
 * Fringes::             Controlling window fringes.
-* Fringe Bitmaps::      Displaying bitmaps in the window fringes.
-* Customizing Bitmaps:: Specifying your own bitmaps to use in the fringes.
 * Scroll Bars::         Controlling vertical scroll bars.
 * Pointer Shape::       Controlling the mouse pointer shape.
 * Display Property::    Enabling special display features.
@@ -45,29 +42,30 @@
 @node Refresh Screen
 @section Refreshing the Screen
 
-The function @code{redraw-frame} redisplays the entire contents of a
-given frame (@pxref{Frames}).
+  The function @code{redraw-frame} clears and redisplays the entire
+contents of a given frame (@pxref{Frames}).  This is useful if the
+screen is corrupted.
 
 @c Emacs 19 feature
 @defun redraw-frame frame
 This function clears and redisplays frame @var{frame}.
 @end defun
 
-Even more powerful is @code{redraw-display}:
+  Even more powerful is @code{redraw-display}:
 
 @deffn Command redraw-display
 This function clears and redisplays all visible frames.
 @end deffn
 
-  This function forces certain windows to be redisplayed
-but does not clear them.
-
-@defun force-window-update object
+  This function calls for redisplay of certain windows, the next time
+redisplay is done, but does not clear them first.
+
+@defun force-window-update &optional object
 This function forces redisplay of some or all windows.  If
 @var{object} is a window, it forces redisplay of that window.  If
 @var{object} is a buffer or buffer name, it forces redisplay of all
-windows displaying that buffer.  If @var{object} is @code{nil}, it
-forces redisplay of all windows.
+windows displaying that buffer.  If @var{object} is @code{nil} (or
+omitted), it forces redisplay of all windows.
 @end defun
 
   Processing user input takes absolute priority over redisplay.  If you
@@ -130,8 +128,8 @@
 which is also called @dfn{continuing} the line.  (The display table can
 specify alternative indicators; see @ref{Display Tables}.)
 
-  On a windowed display, the @samp{$} and @samp{\} indicators are
-replaced with graphics bitmaps displayed in the window fringes
+  On a window system display, the @samp{$} and @samp{\} indicators are
+replaced with arrow images displayed in the window fringes
 (@pxref{Fringes}).
 
   Note that continuation is different from filling; continuation happens
@@ -164,9 +162,6 @@
   When horizontal scrolling (@pxref{Horizontal Scrolling}) is in use in
 a window, that forces truncation.
 
-  You can override the glyphs that indicate continuation or truncation
-using the display table; see @ref{Display Tables}.
-
   If your buffer contains @emph{very} long lines, and you use
 continuation to display them, just thinking about them can make Emacs
 redisplay slow.  The column computation and indentation functions also
@@ -189,14 +184,14 @@
 @cindex error display
 @cindex echo area
 
-The @dfn{echo area} is used for displaying messages made with the
-@code{message} primitive, and for echoing keystrokes.  It is not the
-same as the minibuffer, despite the fact that the minibuffer appears
-(when active) in the same place on the screen as the echo area.  The
-@cite{GNU Emacs Manual} specifies the rules for resolving conflicts
-between the echo area and the minibuffer for use of that screen space
-(@pxref{Minibuffer,, The Minibuffer, emacs, The GNU Emacs Manual}).
-Error messages appear in the echo area; see @ref{Errors}.
+The @dfn{echo area} is used for displaying error messages
+(@pxref{Errors}), for messages made with the @code{message} primitive,
+and for echoing keystrokes.  It is not the same as the minibuffer,
+despite the fact that the minibuffer appears (when active) in the same
+place on the screen as the echo area.  The @cite{GNU Emacs Manual}
+specifies the rules for resolving conflicts between the echo area and
+the minibuffer for use of that screen space (@pxref{Minibuffer,, The
+Minibuffer, emacs, The GNU Emacs Manual}).
 
 You can write output in the echo area by using the Lisp printing
 functions with @code{t} as the stream (@pxref{Output Functions}), or as
@@ -243,9 +238,15 @@
 @end example
 
 To automatically display a message in the echo area or in a pop-buffer,
-depending on its size, use @code{display-message-or-buffer}.
+depending on its size, use @code{display-message-or-buffer} (see below).
 @end defun
 
+@defopt max-mini-window-height
+This variable specifies the maximum height for resizing minibuffer
+windows.  If a float, it specifies a fraction of the height of the
+frame.  If an integer, it specifies a number of lines.
+@end defopt
+
 @tindex with-temp-message
 @defmac with-temp-message message &rest body
 This construct displays a message in the echo area temporarily, during
@@ -538,11 +539,11 @@
 @section Reporting Operation Progress
 @cindex progress reporting
 
-When an operation can take a while to finish, you should inform the
+  When an operation can take a while to finish, you should inform the
 user about the progress it makes.  This way the user can estimate
 remaining time and clearly see that Emacs is busy working, not hung.
 
-Functions listed in this section provide simple and efficient way of
+  Functions listed in this section provide simple and efficient way of
 reporting operation progress.  Here is a working example that does
 nothing useful:
 
@@ -557,15 +558,16 @@
 @end example
 
 @defun make-progress-reporter message min-value max-value &optional current-value min-change min-time
-This function creates a progress reporter---the object you will use as
-an argument for all other functions listed here.  The idea is to
-precompute as much data as possible to make progress reporting very
-fast.
-
-The @var{message} will be displayed in the echo area, followed by
-progress percentage.  @var{message} is treated as a simple string.  If
-you need it to depend on a filename, for instance, use @code{format}
-before calling this function.
+This function creates and returns a @dfn{progress reporter}---an
+object you will use as an argument for all other functions listed
+here.  The idea is to precompute as much data as possible to make
+progress reporting very fast.
+
+When this progress reporter is subsequently used, it will display
+@var{message} in the echo area, followed by progress percentage.
+@var{message} is treated as a simple string.  If you need it to depend
+on a filename, for instance, use @code{format} before calling this
+function.
 
 @var{min-value} and @var{max-value} arguments stand for starting and
 final states of your operation.  For instance, if you scan a buffer,
@@ -592,9 +594,10 @@
 
 @defun progress-reporter-update reporter value
 This function does the main work of reporting progress of your
-operation.  It print the message of @var{reporter} followed by
+operation.  It displays the message of @var{reporter}, followed by
 progress percentage determined by @var{value}.  If percentage is zero,
-then it is not printed at all.
+or close enough according to the @var{min-change} and @var{min-time}
+arguments, then it is omitted from the output.
 
 @var{reporter} must be the result of a call to
 @code{make-progress-reporter}.  @var{value} specifies the current
@@ -655,7 +658,9 @@
 You can make characters @dfn{invisible}, so that they do not appear on
 the screen, with the @code{invisible} property.  This can be either a
 text property (@pxref{Text Properties}) or a property of an overlay
-(@pxref{Overlays}).
+(@pxref{Overlays}).  Cursor motion also partly ignores these
+characters; if the command loop finds point within them, it moves
+point to the other side of them.
 
 In the simplest case, any non-@code{nil} @code{invisible} property makes
 a character invisible.  This is the default case---if you don't alter
@@ -784,10 +789,11 @@
   @dfn{Selective display} refers to a pair of related features for
 hiding certain lines on the screen.
 
-  The first variant, explicit selective display, is designed for use in
-a Lisp program: it controls which lines are hidden by altering the text.
-The invisible text feature (@pxref{Invisible Text}) has partially
-replaced this feature.
+  The first variant, explicit selective display, is designed for use
+in a Lisp program: it controls which lines are hidden by altering the
+text.  This kind of hiding in some ways resembles the effect of the
+@code{invisible} property (@pxref{Invisible Text}), but the two
+features are different and do not work the same way.
 
   In the second variant, the choice of lines to hide is made
 automatically based on indentation.  This variant is designed to be a
@@ -795,32 +801,32 @@
 
   The way you control explicit selective display is by replacing a
 newline (control-j) with a carriage return (control-m).  The text that
-was formerly a line following that newline is now invisible.  Strictly
-speaking, it is temporarily no longer a line at all, since only newlines
-can separate lines; it is now part of the previous line.
+was formerly a line following that newline is now hidden.  Strictly
+speaking, it is temporarily no longer a line at all, since only
+newlines can separate lines; it is now part of the previous line.
 
   Selective display does not directly affect editing commands.  For
-example, @kbd{C-f} (@code{forward-char}) moves point unhesitatingly into
-invisible text.  However, the replacement of newline characters with
-carriage return characters affects some editing commands.  For example,
-@code{next-line} skips invisible lines, since it searches only for
-newlines.  Modes that use selective display can also define commands
-that take account of the newlines, or that make parts of the text
-visible or invisible.
+example, @kbd{C-f} (@code{forward-char}) moves point unhesitatingly
+into hidden text.  However, the replacement of newline characters with
+carriage return characters affects some editing commands.  For
+example, @code{next-line} skips hidden lines, since it searches only
+for newlines.  Modes that use selective display can also define
+commands that take account of the newlines, or that control which
+parts of the text are hidden.
 
   When you write a selectively displayed buffer into a file, all the
 control-m's are output as newlines.  This means that when you next read
-in the file, it looks OK, with nothing invisible.  The selective display
+in the file, it looks OK, with nothing hidden.  The selective display
 effect is seen only within Emacs.
 
 @defvar selective-display
 This buffer-local variable enables selective display.  This means that
-lines, or portions of lines, may be made invisible.
+lines, or portions of lines, may be made hidden.
 
 @itemize @bullet
 @item
 If the value of @code{selective-display} is @code{t}, then the character
-control-m marks the start of invisible text; the control-m, and the rest
+control-m marks the start of hidden text; the control-m, and the rest
 of the line following it, are not displayed.  This is explicit selective
 display.
 
@@ -830,12 +836,12 @@
 displayed.
 @end itemize
 
-When some portion of a buffer is invisible, the vertical movement
+When some portion of a buffer is hidden, the vertical movement
 commands operate as if that portion did not exist, allowing a single
-@code{next-line} command to skip any number of invisible lines.
+@code{next-line} command to skip any number of hidden lines.
 However, character movement commands (such as @code{forward-char}) do
-not skip the invisible portion, and it is possible (if tricky) to insert
-or delete text in an invisible portion.
+not skip the hidden portion, and it is possible (if tricky) to insert
+or delete text in an hidden portion.
 
 In the examples below, we show the @emph{display appearance} of the
 buffer @code{foo}, which changes with the value of
@@ -873,7 +879,7 @@
 
 @defvar selective-display-ellipses
 If this buffer-local variable is non-@code{nil}, then Emacs displays
-@samp{@dots{}} at the end of a line that is followed by invisible text.
+@samp{@dots{}} at the end of a line that is followed by hidden text.
 This example is a continuation of the previous one.
 
 @example
@@ -894,42 +900,6 @@
 (@samp{@dots{}}).  @xref{Display Tables}.
 @end defvar
 
-@node Overlay Arrow
-@section The Overlay Arrow
-@cindex overlay arrow
-
-  The @dfn{overlay arrow} is useful for directing the user's attention
-to a particular line in a buffer.  For example, in the modes used for
-interface to debuggers, the overlay arrow indicates the line of code
-about to be executed.
-
-@defvar overlay-arrow-string
-This variable holds the string to display to call attention to a
-particular line, or @code{nil} if the arrow feature is not in use.
-On a graphical display the contents of the string are ignored; instead a
-glyph is displayed in the fringe area to the left of the display area.
-@end defvar
-
-@defvar overlay-arrow-position
-This variable holds a marker that indicates where to display the overlay
-arrow.  It should point at the beginning of a line.  On a non-graphical
-display the arrow text
-appears at the beginning of that line, overlaying any text that would
-otherwise appear.  Since the arrow is usually short, and the line
-usually begins with indentation, normally nothing significant is
-overwritten.
-
-The overlay string is displayed only in the buffer that this marker
-points into.  Thus, only one buffer can have an overlay arrow at any
-given time.
-@c !!! overlay-arrow-position: but the overlay string may remain in the display
-@c of some other buffer until an update is required.  This should be fixed
-@c now.  Is it?
-@end defvar
-
-  You can do a similar job by creating an overlay with a
-@code{before-string} property.  @xref{Overlay Properties}.
-
 @node Temporary Displays
 @section Temporary Displays
 
@@ -1092,28 +1062,152 @@
 inside the overlay or outside, and likewise for the end of the overlay.
 
 @menu
+* Managing Overlays::   Creating and moving overlays.
 * Overlay Properties::  How to read and set properties.
 			What properties do to the screen display.
-* Managing Overlays::   Creating and moving overlays.
 * Finding Overlays::    Searching for overlays.
 @end menu
 
+@node Managing Overlays
+@subsection Managing Overlays
+
+  This section describes the functions to create, delete and move
+overlays, and to examine their contents.  Overlay changes are not
+recorded in the buffer's undo list, since the overlays are not
+part of the buffer's contents.
+
+@defun overlayp object
+This function returns @code{t} if @var{object} is an overlay.
+@end defun
+
+@defun make-overlay start end &optional buffer front-advance rear-advance
+This function creates and returns an overlay that belongs to
+@var{buffer} and ranges from @var{start} to @var{end}.  Both @var{start}
+and @var{end} must specify buffer positions; they may be integers or
+markers.  If @var{buffer} is omitted, the overlay is created in the
+current buffer.
+
+The arguments @var{front-advance} and @var{rear-advance} specify the
+insertion type for the start of the overlay and for the end of the
+overlay, respectively.  @xref{Marker Insertion Types}.  If
+@var{front-advance} is non-@code{nil}, text inserted at the beginning
+of the overlay is excluded from the overlay.  If @var{read-advance} is
+non-@code{nil}, text inserted at the beginning of the overlay is
+included in the overlay.
+@end defun
+
+@defun overlay-start overlay
+This function returns the position at which @var{overlay} starts,
+as an integer.
+@end defun
+
+@defun overlay-end overlay
+This function returns the position at which @var{overlay} ends,
+as an integer.
+@end defun
+
+@defun overlay-buffer overlay
+This function returns the buffer that @var{overlay} belongs to.  It
+returns @code{nil} if @var{overlay} has been deleted.
+@end defun
+
+@defun delete-overlay overlay
+This function deletes @var{overlay}.  The overlay continues to exist as
+a Lisp object, and its property list is unchanged, but it ceases to be
+attached to the buffer it belonged to, and ceases to have any effect on
+display.
+
+A deleted overlay is not permanently disconnected.  You can give it a
+position in a buffer again by calling @code{move-overlay}.
+@end defun
+
+@defun move-overlay overlay start end &optional buffer
+This function moves @var{overlay} to @var{buffer}, and places its bounds
+at @var{start} and @var{end}.  Both arguments @var{start} and @var{end}
+must specify buffer positions; they may be integers or markers.
+
+If @var{buffer} is omitted, @var{overlay} stays in the same buffer it
+was already associated with; if @var{overlay} was deleted, it goes into
+the current buffer.
+
+The return value is @var{overlay}.
+
+This is the only valid way to change the endpoints of an overlay.  Do
+not try modifying the markers in the overlay by hand, as that fails to
+update other vital data structures and can cause some overlays to be
+``lost''.
+@end defun
+
+  Here are some examples:
+
+@example
+;; @r{Create an overlay.}
+(setq foo (make-overlay 1 10))
+     @result{} #<overlay from 1 to 10 in display.texi>
+(overlay-start foo)
+     @result{} 1
+(overlay-end foo)
+     @result{} 10
+(overlay-buffer foo)
+     @result{} #<buffer display.texi>
+;; @r{Give it a property we can check later.}
+(overlay-put foo 'happy t)
+     @result{} t
+;; @r{Verify the property is present.}
+(overlay-get foo 'happy)
+     @result{} t
+;; @r{Move the overlay.}
+(move-overlay foo 5 20)
+     @result{} #<overlay from 5 to 20 in display.texi>
+(overlay-start foo)
+     @result{} 5
+(overlay-end foo)
+     @result{} 20
+;; @r{Delete the overlay.}
+(delete-overlay foo)
+     @result{} nil
+;; @r{Verify it is deleted.}
+foo
+     @result{} #<overlay in no buffer>
+;; @r{A deleted overlay has no position.}
+(overlay-start foo)
+     @result{} nil
+(overlay-end foo)
+     @result{} nil
+(overlay-buffer foo)
+     @result{} nil
+;; @r{Undelete the overlay.}
+(move-overlay foo 1 20)
+     @result{} #<overlay from 1 to 20 in display.texi>
+;; @r{Verify the results.}
+(overlay-start foo)
+     @result{} 1
+(overlay-end foo)
+     @result{} 20
+(overlay-buffer foo)
+     @result{} #<buffer display.texi>
+;; @r{Moving and deleting the overlay does not change its properties.}
+(overlay-get foo 'happy)
+     @result{} t
+@end example
+
 @node Overlay Properties
 @subsection Overlay Properties
 
   Overlay properties are like text properties in that the properties that
 alter how a character is displayed can come from either source.  But in
-most respects they are different.  Text properties are considered a part
-of the text; overlays are specifically considered not to be part of the
-text.  Thus, copying text between various buffers and strings preserves
-text properties, but does not try to preserve overlays.  Changing a
-buffer's text properties marks the buffer as modified, while moving an
-overlay or changing its properties does not.  Unlike text property
-changes, overlay changes are not recorded in the buffer's undo list.
-@xref{Text Properties}, for comparison.
-
-  These functions are used for reading and writing the properties of an
-overlay:
+most respects they are different.  @xref{Text Properties}, for comparison.
+
+  Text properties are considered a part of the text; overlays and
+their properties are specifically considered not to be part of the
+text.  Thus, copying text between various buffers and strings
+preserves text properties, but does not try to preserve overlays.
+Changing a buffer's text properties marks the buffer as modified,
+while moving an overlay or changing its properties does not.  Unlike
+text property changes, overlay property changes are not recorded in
+the buffer's undo list.
+
+  These functions read and set the properties of an overlay:
 
 @defun overlay-get overlay prop
 This function returns the value of property @var{prop} recorded in
@@ -1301,127 +1395,6 @@
 property) rather than replacing it.
 @end table
 
-@node Managing Overlays
-@subsection Managing Overlays
-
-  This section describes the functions to create, delete and move
-overlays, and to examine their contents.
-
-@defun overlayp object
-This function returns @code{t} if @var{object} is an overlay.
-@end defun
-
-@defun make-overlay start end &optional buffer front-advance rear-advance
-This function creates and returns an overlay that belongs to
-@var{buffer} and ranges from @var{start} to @var{end}.  Both @var{start}
-and @var{end} must specify buffer positions; they may be integers or
-markers.  If @var{buffer} is omitted, the overlay is created in the
-current buffer.
-
-The arguments @var{front-advance} and @var{rear-advance} specify the
-insertion type for the start of the overlay and for the end of the
-overlay, respectively.  @xref{Marker Insertion Types}.  If
-@var{front-advance} is non-@code{nil}, text inserted at the beginning
-of the overlay is excluded from the overlay.  If @var{read-advance} is
-non-@code{nil}, text inserted at the beginning of the overlay is
-included in the overlay.
-@end defun
-
-@defun overlay-start overlay
-This function returns the position at which @var{overlay} starts,
-as an integer.
-@end defun
-
-@defun overlay-end overlay
-This function returns the position at which @var{overlay} ends,
-as an integer.
-@end defun
-
-@defun overlay-buffer overlay
-This function returns the buffer that @var{overlay} belongs to.  It
-returns @code{nil} if @var{overlay} has been deleted.
-@end defun
-
-@defun delete-overlay overlay
-This function deletes @var{overlay}.  The overlay continues to exist as
-a Lisp object, and its property list is unchanged, but it ceases to be
-attached to the buffer it belonged to, and ceases to have any effect on
-display.
-
-A deleted overlay is not permanently disconnected.  You can give it a
-position in a buffer again by calling @code{move-overlay}.
-@end defun
-
-@defun move-overlay overlay start end &optional buffer
-This function moves @var{overlay} to @var{buffer}, and places its bounds
-at @var{start} and @var{end}.  Both arguments @var{start} and @var{end}
-must specify buffer positions; they may be integers or markers.
-
-If @var{buffer} is omitted, @var{overlay} stays in the same buffer it
-was already associated with; if @var{overlay} was deleted, it goes into
-the current buffer.
-
-The return value is @var{overlay}.
-
-This is the only valid way to change the endpoints of an overlay.  Do
-not try modifying the markers in the overlay by hand, as that fails to
-update other vital data structures and can cause some overlays to be
-``lost''.
-@end defun
-
-  Here are some examples:
-
-@example
-;; @r{Create an overlay.}
-(setq foo (make-overlay 1 10))
-     @result{} #<overlay from 1 to 10 in display.texi>
-(overlay-start foo)
-     @result{} 1
-(overlay-end foo)
-     @result{} 10
-(overlay-buffer foo)
-     @result{} #<buffer display.texi>
-;; @r{Give it a property we can check later.}
-(overlay-put foo 'happy t)
-     @result{} t
-;; @r{Verify the property is present.}
-(overlay-get foo 'happy)
-     @result{} t
-;; @r{Move the overlay.}
-(move-overlay foo 5 20)
-     @result{} #<overlay from 5 to 20 in display.texi>
-(overlay-start foo)
-     @result{} 5
-(overlay-end foo)
-     @result{} 20
-;; @r{Delete the overlay.}
-(delete-overlay foo)
-     @result{} nil
-;; @r{Verify it is deleted.}
-foo
-     @result{} #<overlay in no buffer>
-;; @r{A deleted overlay has no position.}
-(overlay-start foo)
-     @result{} nil
-(overlay-end foo)
-     @result{} nil
-(overlay-buffer foo)
-     @result{} nil
-;; @r{Undelete the overlay.}
-(move-overlay foo 1 20)
-     @result{} #<overlay from 1 to 20 in display.texi>
-;; @r{Verify the results.}
-(overlay-start foo)
-     @result{} 1
-(overlay-end foo)
-     @result{} 20
-(overlay-buffer foo)
-     @result{} #<buffer display.texi>
-;; @r{Moving and deleting the overlay does not change its properties.}
-(overlay-get foo 'happy)
-     @result{} t
-@end example
-
 @node Finding Overlays
 @subsection Searching for Overlays
 
@@ -1457,12 +1430,14 @@
 
 @defun next-overlay-change pos
 This function returns the buffer position of the next beginning or end
-of an overlay, after @var{pos}.
+of an overlay, after @var{pos}.  If there is none, it returns
+@code{(point-max)}.
 @end defun
 
 @defun previous-overlay-change pos
 This function returns the buffer position of the previous beginning or
-end of an overlay, before @var{pos}.
+end of an overlay, before @var{pos}.  If there is none, it returns
+@code{(point-min)}.
 @end defun
 
   Here's an easy way to use @code{next-overlay-change} to search for the
@@ -1496,7 +1471,7 @@
 if it were displayed in the current buffer and the selected window.
 @end defun
 
-@defun truncate-string-to-width string width &optional start-column padding
+@defun truncate-string-to-width string width &optional start-column padding ellipsis
 This function returns the part of @var{string} that fits within
 @var{width} columns, as a new string.
 
@@ -1519,6 +1494,13 @@
 the beginning of the result if one multi-column character in
 @var{string} extends across the column @var{start-column}.
 
+If @var{ellipsis} is non-@code{nil}, it should be a string which will
+replace the end of @var{str} (including any padding) if it extends
+beyond @var{end-column}, unless the display width of @var{str} is
+equal to or less than the display width of @var{ellipsis}.  If
+@var{ellipsis} is non-@code{nil} and not a string, it stands for
+@code{"..."}.
+
 @example
 (truncate-string-to-width "\tab\t" 12 4)
      @result{} "ab"
@@ -2286,8 +2268,10 @@
 default for all text.  (In Emacs 19 and 20, the @code{default}
 face is used only when no other face is specified.)
 
-For a mode line or header line, the face @code{modeline} or
-@code{header-line} is used just before @code{default}.
+@item
+For a mode line or header line, the face @code{mode-line} or
+@code{mode-line-inactive}, or @code{header-line}, is merged in just
+before @code{default}.
 
 @item
 With text properties.  A character can have a @code{face} property; if
@@ -2313,20 +2297,16 @@
 
   If these various sources together specify more than one face for a
 particular character, Emacs merges the attributes of the various faces
-specified.  The attributes of the faces of special glyphs come first;
-then comes the face for region highlighting, if appropriate;
-then come attributes of faces from overlays, followed by those from text
-properties, and last the default face.
+specified.  For each attribute, Emacs tries first the face of any
+special glyph; then the face for region highlighting, if appropriate;
+then the faces specified by overlays, followed by those specified by
+text properties, then the @code{mode-line} or
+@code{mode-line-inactive} or @code{header-line} face (if in a mode
+line or a header line), and last the @code{default} face.
 
   When multiple overlays cover one character, an overlay with higher
 priority overrides those with lower priority.  @xref{Overlays}.
 
-  In Emacs 20, if an attribute such as the font or a color is not
-specified in any of the above ways, the frame's own font or color is
-used.  In newer Emacs versions, this cannot happen, because the
-@code{default} face specifies all attributes---in fact, the frame's own
-font and colors are synonymous with those of the default face.
-
 @node Font Selection
 @subsection Font Selection
 
@@ -2469,7 +2449,7 @@
 @end defun
 
 @defun copy-face old-face new-name &optional frame new-frame
-This function defines the face @var{new-name} as a copy of the existing
+This function defines a face named @var{new-name} as a copy of the existing
 face named @var{old-face}.  It creates the face @var{new-name} if that
 doesn't already exist.
 
@@ -2758,15 +2738,25 @@
 
   The @dfn{fringes} of a window are thin vertical strips down the
 sides that are used for displaying bitmaps that indicate truncation,
-continuation, horizontal scrolling, and the overlay arrow.  The
-fringes normally appear between the display margins and the window
-text, but you can put them outside the display margins for a specific
-buffer by setting @code{fringes-outside-margins} buffer-locally to a
-non-@code{nil} value.
+continuation, horizontal scrolling, and the overlay arrow.
+
+@menu
+* Fringe Size/Pos::     Specifying where to put the window fringes.
+* Fringe Bitmaps::      Displaying bitmaps in the window fringes.
+* Customizing Bitmaps:: Specifying your own bitmaps to use in the fringes.
+* Overlay Arrow::       Display of an arrow to indicate position.
+@end menu
+
+@node Fringe Size/Pos
+@subsection Fringe Size and Position
+
+  Here's how to control the position and width of the window fringes.
 
 @defvar fringes-outside-margins
-If the value is non-@code{nil}, the frames appear outside
-the display margins.
+If the value is non-@code{nil}, the frames appear outside the display
+margins.  The fringes normally appear between the display margins and
+the window text.  It works to set @code{fringes-outside-margins}
+buffer-locally.  @xref{Display Margins}.
 @end defvar
 
 @defvar left-fringe-width
@@ -2799,7 +2789,7 @@
 This function returns information about the fringes of a window
 @var{window}.  If @var{window} is omitted or @code{nil}, the selected
 window is used.  The value has the form @code{(@var{left-width}
-@var{right-width} @var{frames-outside-margins})}.
+@var{right-width} @var{outside-margins})}.
 @end defun
 
 @defvar overflow-newline-into-fringe
@@ -2810,7 +2800,7 @@
 @end defvar
 
 @node Fringe Bitmaps
-@section Fringe Bitmaps
+@subsection Fringe Bitmaps
 @cindex fringe bitmaps
 @cindex bitmaps, fringe
 
@@ -2870,7 +2860,7 @@
 @end defun
 
 @node Customizing Bitmaps
-@section Customizing Fringe Bitmaps
+@subsection Customizing Fringe Bitmaps
 
 @defun define-fringe-bitmap bitmap bits &optional height width align
 This function defines the symbol @var{bitmap} as a new fringe bitmap,
@@ -2921,6 +2911,61 @@
 specify only the foreground color.
 @end defun
 
+@node Overlay Arrow
+@subsection The Overlay Arrow
+@cindex overlay arrow
+
+  The @dfn{overlay arrow} is useful for directing the user's attention
+to a particular line in a buffer.  For example, in the modes used for
+interface to debuggers, the overlay arrow indicates the line of code
+about to be executed.  This feature has nothing to do with
+@dfn{overlays} (@pxref{Overlays}).
+
+@defvar overlay-arrow-string
+This variable holds the string to display to call attention to a
+particular line, or @code{nil} if the arrow feature is not in use.
+On a graphical display the contents of the string are ignored; instead a
+glyph is displayed in the fringe area to the left of the display area.
+@end defvar
+
+@defvar overlay-arrow-position
+This variable holds a marker that indicates where to display the overlay
+arrow.  It should point at the beginning of a line.  On a non-graphical
+display the arrow text
+appears at the beginning of that line, overlaying any text that would
+otherwise appear.  Since the arrow is usually short, and the line
+usually begins with indentation, normally nothing significant is
+overwritten.
+
+The overlay string is displayed only in the buffer that this marker
+points into.  Thus, only one buffer can have an overlay arrow at any
+given time.
+@c !!! overlay-arrow-position: but the overlay string may remain in the display
+@c of some other buffer until an update is required.  This should be fixed
+@c now.  Is it?
+@end defvar
+
+  You can do a similar job by creating an overlay with a
+@code{before-string} property.  @xref{Overlay Properties}.
+
+  You can define multiple overlay arrows via the variable
+@code{overlay-arrow-variable-list}.
+
+@defvar overlay-arrow-variable-list
+This variable's value is a list of varibles, each of which specifies
+the position of an overlay arrow.  The variable
+@code{overlay-arrow-position} has its normal meaning because it is on
+this list.
+@end defvar
+
+Each variable on this list can have properties
+@code{overlay-arrow-string} and @code{overlay-arrow-bitmap} that
+specify an overlay arrow string (for text-only terminals) or fringe
+bitmap (for graphical terminals) to display at the corresponding
+overlay arrow position.  If either property is not set, the default
+(@code{overlay-arrow-string} or @code{overlay-arrow-fringe-bitmap}) is
+used.
+
 @node Scroll Bars
 @section Scroll Bars
 
@@ -3029,8 +3074,6 @@
                           up or down on the page; adjusting the width
                           of spaces within text.
 * Display Margins::     Displaying text or images to the side of the main text.
-* Conditional Display::  Making any of the above features conditional
-                          depending on some Lisp expression.
 @end menu
 
 @node Specified Space
@@ -3093,7 +3136,7 @@
 
   Don't use both @code{:height} and @code{:relative-height} together.
 
-  The @code{:height} and @code{:align-to} properties are supported on
+  The @code{:width} and @code{:align-to} properties are supported on
 non-graphic terminals, but the other space properties in this section
 are not.
 
@@ -3156,10 +3199,11 @@
 to the left edge of the text area.  For example, @samp{:align-to 0} in a
 header-line aligns with the first text column in the text area.
 
-  A value of the form @code{(@var{num} . @var{expr})} stands
-multiplying the values of @var{num} and @var{expr}.  For example,
+  A value of the form @code{(@var{num} . @var{expr})} stands for the
+product of the values of @var{num} and @var{expr}.  For example,
 @code{(2 . in)} specifies a width of 2 inches, while @code{(0.5 .
-@var{image})} specifies half the width (or height) of the specified image.
+@var{image})} specifies half the width (or height) of the specified
+image.
 
   The form @code{(+ @var{expr} ...)} adds up the value of the
 expressions.  The form @code{(- @var{expr} ...)} negates or subtracts
@@ -3173,9 +3217,9 @@
 
 @table @code
 @item (image . @var{image-props})
-This is in fact an image descriptor (@pxref{Images}).  When used as a
-display specification, it means to display the image instead of the text
-that has the display specification.
+This display specification is an image descriptor (@pxref{Images}).
+When used as a display specification, it means to display the image
+instead of the text that has the display specification.
 
 @item (slice @var{x} @var{y} @var{width} @var{height})
 This specification together with @code{image} specifies a @dfn{slice}
@@ -3246,6 +3290,17 @@
 faces used for the text.
 @end table
 
+  You can make any display specification conditional.  To do that,
+package it in another list of the form @code{(when @var{condition} .
+@var{spec})}.  Then the specification @var{spec} applies only when
+@var{condition} evaluates to a non-@code{nil} value.  During the
+evaluation, @code{object} is bound to the string or buffer having the
+conditional @code{display} property.  @code{position} and
+@code{buffer-position} are bound to the position within @code{object}
+and the buffer position where the @code{display} property was found,
+respectively.  Both positions can be different when @code{object} is a
+string.
+
 @node Display Margins
 @subsection Displaying in the Margins
 @cindex display margins
@@ -3308,21 +3363,6 @@
 If @var{window} is @code{nil}, the selected window is used.
 @end defun
 
-@node Conditional Display
-@subsection Conditional Display Specifications
-@cindex conditional display specifications
-
-  You can make any display specification conditional.  To do that,
-package it in another list of the form @code{(when @var{condition} .
-@var{spec})}.  Then the specification @var{spec} applies only when
-@var{condition} evaluates to a non-@code{nil} value.  During the
-evaluation, @code{object} is bound to the string or buffer having the
-conditional @code{display} property.  @code{position} and
-@code{buffer-position} are bound to the position within @code{object}
-and the buffer position where the @code{display} property was found,
-respectively.  Both positions can be different when @code{object} is a
-string.
-
 @node Images
 @section Images
 @cindex images in buffers
@@ -3333,16 +3373,16 @@
 
   Emacs can display a number of different image formats; some of them
 are supported only if particular support libraries are installed on
-your machine.  In some environments, Emacs allows loading image
+your machine.  In some environments, Emacs can load image
 libraries on demand; if so, the variable @code{image-library-alist}
 can be used to modify the set of known names for these dynamic
 libraries (though it is not possible to add new image formats).
 
-  The supported image formats include XBM, XPM (needing the
-libraries @code{libXpm} version 3.4k and @code{libz}), GIF (needing
-@code{libungif} 4.1.0), Postscript, PBM, JPEG (needing the
-@code{libjpeg} library version v6a), TIFF (needing @code{libtiff} v3.4),
-and PNG (needing @code{libpng} 1.0.2).
+  The supported image formats include XBM, XPM (this requires the
+libraries @code{libXpm} version 3.4k and @code{libz}), GIF (requiring
+@code{libungif} 4.1.0), Postscript, PBM, JPEG (requiring the
+@code{libjpeg} library version v6a), TIFF (requiring @code{libtiff}
+v3.4), and PNG (requiring @code{libpng} 1.0.2).
 
   You specify one of these formats with an image type symbol.  The image
 type symbols are @code{xbm}, @code{xpm}, @code{gif}, @code{postscript},
@@ -3423,12 +3463,12 @@
 
 @table @code
 @item :file @var{file}
-The @code{:file} property specifies to load the image from file
+The @code{:file} property says to load the image from file
 @var{file}.  If @var{file} is not an absolute file name, it is expanded
 in @code{data-directory}.
 
 @item :data @var{data}
-The @code{:data} property specifies the actual contents of the image.
+The @code{:data} property says the actual contents of the image.
 Each image must use either @code{:data} or @code{:file}, but not both.
 For most image types, the value of the @code{:data} property should be a
 string containing the image data; we recommend using a unibyte string.
@@ -3687,12 +3727,7 @@
 @subsection GIF Images
 @cindex GIF
 
-  For GIF images, specify image type @code{gif}.  Because of the patents
-in the US covering the LZW algorithm, the continued use of GIF format is
-a problem for the whole Internet; to end this problem, it is a good idea
-for everyone, even outside the US, to stop using GIFs right away
-(@uref{http://www.burnallgifs.org/}).  But if you still want to use
-them, Emacs can display them.
+  For GIF images, specify image type @code{gif}.
 
 @table @code
 @item :index @var{index}
@@ -3871,8 +3906,9 @@
 This function inserts @var{image} in the current buffer at point.  The
 value @var{image} should be an image descriptor; it could be a value
 returned by @code{create-image}, or the value of a symbol defined with
-@code{defimage}.  The argument @var{string} specifies the text to put in
-the buffer to hold the image.
+@code{defimage}.  The argument @var{string} specifies the text to put
+in the buffer to hold the image.  If it is omitted or @code{nil},
+@code{insert-image} uses @code{" "} by default.
 
 The argument @var{area} specifies whether to put the image in a margin.
 If it is @code{left-margin}, the image appears in the left margin;
@@ -3983,16 +4019,16 @@
 buttons in Emacs buffers, such as might be used for help hyper-links,
 etc.  Emacs uses buttons for the hyper-links in help text and the like.
 
-A button is essentially a set of properties attached (via text
-properties or overlays) to a region of text in an Emacs buffer, which
-are called its button properties.  @xref{Button Properties}.
-
-One of the these properties (@code{action}) is a function, which will
+  A button is essentially a set of properties attached (via text
+properties or overlays) to a region of text in an Emacs buffer.  These
+properties are called @dfn{button properties}.
+
+  One of the these properties (@code{action}) is a function, which will
 be called when the user invokes it using the keyboard or the mouse.
 The invoked function may then examine the button and use its other
 properties as desired.
 
-In some ways the Emacs button package duplicates functionality offered
+  In some ways the Emacs button package duplicates functionality offered
 by the widget package (@pxref{Top, , Introduction, widget, The Emacs
 Widget Library}), but the button package has the advantage that it is
 much faster, much smaller, and much simpler to use (for elisp
@@ -4008,7 +4044,6 @@
 * Making Buttons::         Adding buttons to Emacs buffers.
 * Manipulating Buttons::   Getting and setting properties of buttons.
 * Button Buffer Commands:: Buffer-wide commands and bindings for buttons.
-* Manipulating Button Types::
 @end menu
 
 @node Button Properties
@@ -4017,13 +4052,10 @@
 
   Buttons have an associated list of properties defining their
 appearance and behavior, and other arbitrary properties may be used
-for application specific purposes.
-
-Some properties that have special meaning to the button package
-include:
+for application specific purposes.  Some properties that have special
+meaning to the button package include:
 
 @table @code
-
 @item action
 @kindex action @r{(button property)}
 The function to call when the user invokes the button, which is passed
@@ -4078,7 +4110,7 @@
 standard button functions do).
 @end table
 
-There are other properties defined for the regions of text in a
+  There are other properties defined for the regions of text in a
 button, but these are not generally interesting for typical uses.
 
 @node Button Types
@@ -4106,9 +4138,9 @@
 reflected in its subtypes.
 @end defun
 
-Using @code{define-button-type} to define default properties for
+  Using @code{define-button-type} to define default properties for
 buttons is not necessary---buttons without any specified type use the
-built-in button-type @code{button}---but it is is encouraged, since
+built-in button-type @code{button}---but it is encouraged, since
 doing so usually makes the resulting code clearer and more efficient.
 
 @node Making Buttons
@@ -4116,19 +4148,19 @@
 @cindex making buttons
 
   Buttons are associated with a region of text, using an overlay or
-text-properties to hold button-specific information, all of which are
+text properties to hold button-specific information, all of which are
 initialized from the button's type (which defaults to the built-in
 button type @code{button}).  Like all Emacs text, the appearance of
 the button is governed by the @code{face} property; by default (via
 the @code{face} property inherited from the @code{button} button-type)
 this is a simple underline, like a typical web-page link.
 
-For convenience, there are two sorts of button-creation functions,
+  For convenience, there are two sorts of button-creation functions,
 those that add button properties to an existing region of a buffer,
 called @code{make-...button}, and those also insert the button text,
 called @code{insert-...button}.
 
-The button-creation functions all take the @code{&rest} argument
+  The button-creation functions all take the @code{&rest} argument
 @var{properties}, which should be a sequence of @var{property value}
 pairs, specifying properties to add to the button; see @ref{Button
 Properties}.  In addition, the keyword argument @code{:type} may be
@@ -4137,40 +4169,41 @@
 during creation will be inherited from the button's type (if the type
 defines such a property).
 
-The following functions add a button using an overlay
+  The following functions add a button using an overlay
 (@pxref{Overlays}) to hold the button properties:
 
 @defun make-button beg end &rest properties
 @tindex make-button
-Make a button from @var{beg} to @var{end} in the current buffer.
+This makes a button from @var{beg} to @var{end} in the
+current buffer, and returns it.
 @end defun
 
 @defun insert-button label &rest properties
 @tindex insert-button
-Insert a button with the label @var{label}.
+This insert a button with the label @var{label} at point,
+and returns it.
 @end defun
 
-The following functions are similar, but use Emacs text-properties
+  The following functions are similar, but use Emacs text properties
 (@pxref{Text Properties}) to hold the button properties, making the
 button actually part of the text instead of being a property of the
-buffer (using text-properties is usually faster than using overlays,
-so this may be preferable when creating large numbers of buttons):
+buffer.  Buttons using text properties do not create markers into the
+buffer, which is important for speed when you use extremely large
+numbers of buttons.  Both functions return the position of the start
+of the new button:
 
 @defun make-text-button beg end &rest properties
 @tindex make-text-button
-Make a button from @var{beg} to @var{end} in the current buffer, using
-text-properties.
+This makes a button from @var{beg} to @var{end} in the current buffer, using
+text properties.
 @end defun
 
 @defun insert-text-button label &rest properties
 @tindex insert-text-button
-Insert a button with the label @var{label}, using text-properties.
+This inserts a button with the label @var{label} at point, using text
+properties.
 @end defun
 
-Buttons using text-properties retain no markers into the buffer are
-retained, which is important for speed in cases where there are
-extremely large numbers of buttons.
-
 @node Manipulating Buttons
 @subsection Manipulating Buttons
 @cindex manipulating buttons
@@ -4234,6 +4267,21 @@
 Return the button at position @var{pos} in the current buffer, or @code{nil}.
 @end defun
 
+@defun button-type-put type prop val
+@tindex button-type-put
+Set the button-type @var{type}'s @var{prop} property to @var{val}.
+@end defun
+
+@defun button-type-get type prop
+@tindex button-type-get
+Get the property of button-type @var{type} named @var{prop}.
+@end defun
+
+@defun button-type-subtype-p type supertype
+@tindex button-type-subtype-p
+Return @code{t} if button-type @var{type} is a subtype of @var{supertype}.
+@end defun
+
 @node Button Buffer Commands
 @subsection Button Buffer Commands
 @cindex button buffer commands
@@ -4251,8 +4299,9 @@
 parent keymap for its keymap.
 
 If the button has a non-@code{nil} @code{follow-link} property, and
-@var{mouse-1-click-follows-link} is set, a @key{Mouse-1} click will
-also activate the @code{push-button} command.
+@var{mouse-1-click-follows-link} is set, a quick @key{Mouse-1} click
+will also activate the @code{push-button} command.
+@xref{Links and Mouse-1}.
 
 @deffn Command push-button &optional pos use-mouse-action
 @tindex push-button
@@ -4304,25 +4353,6 @@
 @var{pos} in the search, instead of starting at the next button.
 @end defun
 
-@node Manipulating Button Types
-@subsection Manipulating Button Types
-@cindex manipulating button types
-
-@defun button-type-put type prop val
-@tindex button-type-put
-Set the button-type @var{type}'s @var{prop} property to @var{val}.
-@end defun
-
-@defun button-type-get type prop
-@tindex button-type-get
-Get the property of button-type @var{type} named @var{prop}.
-@end defun
-
-@defun button-type-subtype-p type supertype
-@tindex button-type-subtype-p
-Return @code{t} if button-type @var{type} is a subtype of @var{supertype}.
-@end defun
-
 @node Blinking
 @section Blinking Parentheses
 @cindex parenthesis matching
@@ -4396,14 +4426,10 @@
 @end defopt
 
 @defopt mode-line-inverse-video
-This variable controls the use of inverse video for mode lines and menu
-bars.  If it is non-@code{nil}, then these lines are displayed in
-inverse video.  Otherwise, these lines are displayed normally, just like
-other text.  The default is @code{t}.
-
-For window frames, this feature actually applies the face named
-@code{mode-line}; that face is normally set up as the inverse of the
-default face, unless you change it.
+This variable controls the use of inverse video for mode lines and
+menu bars.  If it is non-@code{nil}, then these lines are displayed in
+the face @code{mode-line}.  Otherwise, these lines are displayed
+normally, just like other text.  The default is @code{t}.
 @end defopt
 
 @node Usual Display
@@ -4587,22 +4613,26 @@
 @table @asis
 @item 0
 The glyph for the end of a truncated screen line (the default for this
-is @samp{$}).  @xref{Glyphs}.  Newer Emacs versions, on some platforms,
-display arrows to indicate truncation---the display table has no effect
-in these situations.
+is @samp{$}).  @xref{Glyphs}.  On graphical terminals, Emacs uses
+arrows in the fringes to indicate truncation, so the display table has
+no effect.
+
 @item 1
 The glyph for the end of a continued line (the default is @samp{\}).
-Newer Emacs versions, on some platforms, display curved arrows to
-indicate continuation---the display table has no effect in these
-situations.
+On graphical terminals, Emacs uses curved arrows in the fringes to
+indicate continuation, so the display table has no effect.
+
 @item 2
 The glyph for indicating a character displayed as an octal character
 code (the default is @samp{\}).
+
 @item 3
 The glyph for indicating a control character (the default is @samp{^}).
+
 @item 4
 A vector of glyphs for indicating the presence of invisible lines (the
 default is @samp{...}).  @xref{Selective Display}.
+
 @item 5
 The glyph used to draw the border between side-by-side windows (the
 default is @samp{|}).  @xref{Splitting Windows}.  This takes effect only
@@ -4662,9 +4692,10 @@
 table if any.  The display table chosen is called the @dfn{active}
 display table.
 
-@defun window-display-table window
+@defun window-display-table &optional window
 This function returns @var{window}'s display table, or @code{nil}
-if @var{window} does not have an assigned display table.
+if @var{window} does not have an assigned display table.  The default
+for @var{window} is the selected window.
 @end defun
 
 @defun set-window-display-table window table
--- a/lispref/edebug.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/edebug.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -99,7 +99,7 @@
 the Lisp code you are debugging.  This is referred to as the @dfn{source
 code buffer}, and it is temporarily read-only.
 
-  An arrow at the left margin indicates the line where the function is
+  An arrow in the left fringe indicates the line where the function is
 executing.  Point initially shows where within the line the function is
 executing, but this ceases to be true if you move point yourself.
 
@@ -158,16 +158,15 @@
 
 @kindex C-M-x
 @findex eval-defun (Edebug)
-  Once you have loaded Edebug, the command @kbd{C-M-x}
-(@code{eval-defun}) is redefined so that when invoked with a prefix
-argument on a definition, it instruments the definition before
-evaluating it.  (The source code itself is not modified.)  If the
-variable @code{edebug-all-defs} is non-@code{nil}, that inverts the
-meaning of the prefix argument: in this case, @kbd{C-M-x} instruments the
-definition @emph{unless} it has a prefix argument.  The default value of
-@code{edebug-all-defs} is @code{nil}.  The command @kbd{M-x
-edebug-all-defs} toggles the value of the variable
-@code{edebug-all-defs}.
+  When you invoke command @kbd{C-M-x} (@code{eval-defun}) with a
+prefix argument on a function definition, it instruments the
+definition before evaluating it.  (This does not modify the source
+code itself.)  If the variable @code{edebug-all-defs} is
+non-@code{nil}, that inverts the meaning of the prefix argument: in
+this case, @kbd{C-M-x} instruments the definition @emph{unless} it has
+a prefix argument.  The default value of @code{edebug-all-defs} is
+@code{nil}.  The command @kbd{M-x edebug-all-defs} toggles the value
+of the variable @code{edebug-all-defs}.
 
 @findex eval-region @r{(Edebug)}
 @findex eval-current-buffer @r{(Edebug)}
@@ -302,11 +301,12 @@
 inside Edebug.  This is usually an advantage.  See also the
 @code{edebug-continue-kbd-macro} option (@pxref{Edebug Options}).
 
-When you enter a new Edebug level, the initial execution mode comes from
-the value of the variable @code{edebug-initial-mode}.  By default, this
-specifies step mode.  Note that you may reenter the same Edebug level
-several times if, for example, an instrumented function is called
-several times from one command.
+When you enter a new Edebug level, the initial execution mode comes
+from the value of the variable @code{edebug-initial-mode}.
+(@xref{Edebug Options}.)  By default, this specifies step mode.  Note
+that you may reenter the same Edebug level several times if, for
+example, an instrumented function is called several times from one
+command.
 
 @defopt edebug-sit-for-seconds
 This option specifies how many seconds to wait between execution steps
@@ -1074,7 +1074,7 @@
 
   Therefore, you must define an Edebug specification for each macro
 that Edebug will encounter, to explain the format of calls to that
-macro.  To do this, add an @code{edebug} declaration to the macro
+macro.  To do this, add a @code{debug} declaration to the macro
 definition.  Here is a simple example that shows the specification for
 the @code{for} example macro (@pxref{Argument Evaluation}).
 
@@ -1095,10 +1095,9 @@
 
   You can also define an edebug specification for a macro separately
 from the macro definition with @code{def-edebug-spec}.  Adding
-@code{edebug} declarations is preferred, and more convenient, for
-macro definitions in Lisp, but @code{def-edebug-spec} makes it
-possible to define Edebug specifications for special forms implemented
-in C.
+@code{debug} declarations is preferred, and more convenient, for macro
+definitions in Lisp, but @code{def-edebug-spec} makes it possible to
+define Edebug specifications for special forms implemented in C.
 
 @deffn Macro def-edebug-spec macro specification
 Specify which expressions of a call to macro @var{macro} are forms to be
--- a/lispref/internals.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/internals.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -477,28 +477,22 @@
   (args)
      Lisp_Object args;
 @{
-  register Lisp_Object val;
-  Lisp_Object args_left;
+  register Lisp_Object val = Qnil;
   struct gcpro gcpro1;
 @end group
 
 @group
-  if (NILP (args))
-    return Qnil;
-
-  args_left = args;
-  GCPRO1 (args_left);
+  GCPRO1 (args);
 @end group
 
 @group
-  do
+  while (CONSP (args))
     @{
-      val = Feval (Fcar (args_left));
+      val = Feval (XCAR (args));
       if (!NILP (val))
-        break;
-      args_left = Fcdr (args_left);
+	break;
+      args = XCDR (args);
     @}
-  while (!NILP (args_left));
 @end group
 
 @group
@@ -549,7 +543,7 @@
 @code{MANY}, indicating an unlimited number of evaluated arguments (the
 equivalent of @code{&rest}).  Both @code{UNEVALLED} and @code{MANY} are
 macros.  If @var{max} is a number, it may not be less than @var{min} and
-it may not be greater than seven.
+it may not be greater than eight.
 
 @item interactive
 This is an interactive specification, a string such as might be used as
--- a/lispref/nonascii.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/lispref/nonascii.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -95,9 +95,10 @@
 
 @defun position-bytes position
 @tindex position-bytes
-Return the byte-position corresponding to buffer position @var{position}
-in the current buffer.  If @var{position} is out of range, the value
-is @code{nil}.
+Return the byte-position corresponding to buffer position
+@var{position} in the current buffer.  This is 1 at the start of the
+buffer, and counts upward in bytes.  If @var{position} is out of
+range, the value is @code{nil}.
 @end defun
 
 @defun byte-to-position byte-position
@@ -359,6 +360,11 @@
 special purposes within Emacs.
 @end defun
 
+@deffn Command list-charset-chars charset
+This command displays a list of characters in the character set
+@var{charset}.
+@end deffn
+
 @node Chars and Bytes
 @section Characters and Bytes
 @cindex bytes and characters
@@ -474,6 +480,13 @@
 coding systems (@pxref{Coding Systems}) are capable of representing all
 of the text in question.
 
+@defun charset-after &optional pos
+This function return the charset of a character in the current buffer
+at position @var{pos}.  If @var{pos} is omitted or @code{nil}, it
+defauls to the current value of point.  If @var{pos} is out of range,
+the value is @code{nil}.
+@end defun
+
 @defun find-charset-region beg end &optional translation
 This function returns a list of the character sets that appear in the
 current buffer between positions @var{beg} and @var{end}.
@@ -673,7 +686,7 @@
 uses one to encode the buffer contents.
 
   You can specify the coding system to use either explicitly
-(@pxref{Specifying Coding Systems}), or implicitly using the defaulting
+(@pxref{Specifying Coding Systems}), or implicitly using a default
 mechanism (@pxref{Default Coding Systems}).  But these methods may not
 completely specify what to do.  For example, they may choose a coding
 system such as @code{undefined} which leaves the character code
--- a/lwlib/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/lwlib/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,8 @@
+2005-03-12  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* xlwmenuP.h:
+	* xlwmenu.h: Add missing copyright and license notice.
+
 2004-12-27  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
 	* xlwmenu.c (xlwMenuActionsList): Install MenuGadgetEscape as an
@@ -19,11 +24,11 @@
 
 2004-08-30  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
-	* lwlib.h (_widget_value): Added lname and lkey.
+	* lwlib.h (_widget_value): Add lname and lkey.
 
 2004-01-12  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
-	* xlwmenuP.h (_XlwMenu_part): Added top_depth.
+	* xlwmenuP.h (_XlwMenu_part): Add top_depth.
 
 	* xlwmenu.h: Removed declaration of pop_up_menu
 
@@ -56,8 +61,8 @@
 
 	* lwlib-Xlw.c: Include lisp.h, not ../src/lisp.h.
 	(lw_lucid_widget_p): Remove unused `mw'.
-	(xlw_update_one_widget, xlw_pop_instance) [PROTOTYPES]: Provide
-	ISO C arglists.
+	(xlw_update_one_widget, xlw_pop_instance) [PROTOTYPES]:
+	Provide ISO C arglists.
 
 2003-04-30  Lute Kamstra  <lute@gnu.org>
 
@@ -84,8 +89,7 @@
 2002-11-20  Dave Love  <fx@gnu.org>
 
 	* lwlib.c: Remove obsolete USE_OLIT code.
-	[PROTOTYPES]: Provide ISO C arglists for functions with Boolean
-	args.
+	[PROTOTYPES]: Provide ISO C arglists for functions with Boolean args.
 	(lwlib_memset): Declare length arg as size_t.
 	(malloc_widget_value): Cast arg of lwlib_memset.
 
@@ -248,7 +252,7 @@
 
 	* lwlib-Xm.c (make_menu_in_widget): Add an XmNpopdownCallback
 	instead of an XmNunmapCallback.
-	(xm_unmap_callback): Removed.
+	(xm_unmap_callback): Remove.
 
 	* lwlib-Xm.c (make_menubar): Take out code in #if 0.
 
--- a/lwlib/xlwmenu.h	Wed Mar 16 16:03:44 2005 +0000
+++ b/lwlib/xlwmenu.h	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,23 @@
+/* Interface of a lightweight menubar widget.
+   Copyright (C) 2000, 2002, 2004  Free Software Foundation, Inc.
+
+This file is part of the Lucid Widget Library.
+
+The Lucid Widget Library is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+The Lucid Widget Library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Emacs; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
 #ifndef _XlwMenu_h
 #define _XlwMenu_h
 
--- a/lwlib/xlwmenuP.h	Wed Mar 16 16:03:44 2005 +0000
+++ b/lwlib/xlwmenuP.h	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,23 @@
+/* Internals of a lightweight menubar widget.
+   Copyright (C) 1999, 2000, 2002, 2004  Free Software Foundation, Inc.
+
+This file is part of the Lucid Widget Library.
+
+The Lucid Widget Library is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+The Lucid Widget Library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Emacs; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
 #ifndef _XlwMenuP_h
 #define _XlwMenuP_h
 
--- a/man/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/man/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,17 @@
+2005-03-14  Nick Roberts  <nickrob@snap.net.nz>
+
+	* building.texi (Commands of GUD): Move paragraph on setting
+	breakpoints with mouse to the GDB Graphical Interface node.
+
+2005-03-07  Richard M. Stallman  <rms@gnu.org>
+
+	* url.texi: Fix usage of "e.g.".
+	(HTTP language/coding): Explain the rules for these strings.
+
+	* misc.texi (Single Shell, Shell Options): Fix previous change.
+
+	* building.texi (Debugger Operation): Update GUD tooltip enable info.
+
 2005-03-06  Richard M. Stallman  <rms@gnu.org>
 
 	* building.texi (Starting GUD): Don't explain text vs graphical
--- a/man/building.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/man/building.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -414,11 +414,13 @@
 
 @cindex tooltips with GUD
 @vindex tooltip-gud-modes
+@vindex tooltip-gud-tips-p
   The Tooltip facility (@pxref{Tooltips}) provides support for GUD@.
-You activate this feature by customizing the @code{tooltip} group.
-Then you can display a variable's value in a tooltip simply by
-pointing at it with the mouse.  This operates in the GUD buffer and in
-source buffers with major modes in the list @code{tooltip-gud-modes}.
+You activate this feature by setting the variable
+@code{tooltip-gud-tips-p} to @code{t}.  Then you can display a
+variable's value in a tooltip simply by pointing at it with the mouse.
+This operates in the GUD buffer and in source buffers with major modes
+in the list @code{tooltip-gud-modes}.
 
 @node Commands of GUD
 @subsection Commands of GUD
@@ -568,14 +570,6 @@
 details.
 @end table
 
-With the GDB Graphical Interface, you can click @kbd{Mouse-1} on a
-line of the source buffer, in the fringe or display margin, to set a
-breakpoint there.  If a breakpoint already exists on that line, this
-action will remove it (@code{gdb-mouse-set-clear-breakpoint}). Where
-Emacs uses the margin to display breakpoints, it is also possible to
-enable or disable them when you click @kbd{Mouse-3} there
-(@code{gdb-mouse-toggle--breakpoint}).
-
   These commands interpret a numeric argument as a repeat count, when
 that makes sense.
 
@@ -656,7 +650,14 @@
 interface where you view and control the program's data using Emacs
 windows.  You can still interact with GDB through the GUD buffer, but
 the point of this mode is that you can do it through menus and clicks,
-without needing to know GDB commands.
+without needing to know GDB commands. For example, you can click
+@kbd{Mouse-1} on a line of the source buffer, in the fringe or display
+margin, to set a breakpoint there.  If a breakpoint already exists on
+that line, this action will remove it
+(@code{gdb-mouse-set-clear-breakpoint}). Where Emacs uses the margin
+to display breakpoints, it is also possible to enable or disable them
+when you click @kbd{Mouse-3} there
+(@code{gdb-mouse-toggle--breakpoint}).
 
 @vindex gud-gdb-command-name
 @findex gdba
--- a/man/misc.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/man/misc.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -391,7 +391,7 @@
 
   One use for @kbd{M-|} is to run @code{gpg} to see what keys are in
 the buffer.  For instance, if the buffer contains a GPG key, type
-@kbd{C-x h M-| uudecode @key{RET}} to feed the entire buffer contents
+@kbd{C-x h M-| gpg @key{RET}} to feed the entire buffer contents
 to the @code{gpg} program.  That program will ignore everything except
 the encoded keys, and will output a list of the keys it contains.
 
@@ -958,7 +958,7 @@
 
 @vindex comint-prompt-read-only
   If you set @code{comint-prompt-read-only}, the prompts in the Comint
-buffer a read-only.
+buffer are read-only.
 
 @vindex comint-input-ignoredups
   The variable @code{comint-input-ignoredups} controls whether successive
--- a/man/url.texi	Wed Mar 16 16:03:44 2005 +0000
+++ b/man/url.texi	Wed Mar 16 16:06:15 2005 +0000
@@ -109,7 +109,7 @@
 the possible exception of @code{telnet}, it is rare for ports to be
 specified, and it is possible using a non-standard port may have
 undesired consequences if a different service is listening on that
-port (e.g.@: an HTTP URL specifying the SMTP port can cause mail to be
+port (e.g., an HTTP URL specifying the SMTP port can cause mail to be
 sent).@c , but @xref{Other Variables, url-bad-port-list}.
 The meaning of
 the @var{path} component depends on the service.
@@ -142,7 +142,7 @@
 @noindent where
 @table @var
 @item type
-is the type of the URL scheme, e.g.@: @code{http}
+is the type of the URL scheme, e.g., @code{http}
 @item user
 is the username associated with it, or @code{nil};
 @item password
@@ -182,7 +182,7 @@
 @findex url-set-attributes
 @findex url-set-full
 These attributes have accessors named @code{url-@var{part}}, where
-@var{part} is the name of one of the elements above, e.g.@:
+@var{part} is the name of one of the elements above, e.g.,
 @code{url-host}.  Similarly, there are setters of the form
 @code{url-set-@var{part}}.
 
@@ -317,7 +317,12 @@
 @subsection Language and Encoding Preferences
 
 HTTP allows clients to express preferences for the language and
-encoding of documents which servers may honour.
+encoding of documents which servers may honour.  For each of these
+variables, the value is a string; it can specify a single choice, or
+it can be a comma-separated list in descending order of preference.
+Each element can be followed by @samp{;q=@var{priority}} to specify
+its preference level; e.g., for @code{url-mime-language-string},
+@w{@code{"de, en-gb;q=0.8, en;q=0.7"}}.
 
 @defopt url-mime-charset-string
 @cindex character sets
@@ -325,23 +330,22 @@
 This variable specifies a preference for character sets when documents
 can be served in more than one encoding.
 
-HTTP allows specifying a list of MIME charsets which indicate your
-preferred character set encodings, e.g.@: Latin-9 or Big5, and these
-can be weighted.  This list is generated automatically from the list
-of defined coding systems which have associated MIME types.  These are
-sorted by coding priority.  @xref{Recognize Coding, , Recognizing
-Coding Systems, emacs, The GNU Emacs Manual}.
+HTTP allows specifying a series of MIME charsets which indicate your
+preferred character set encodings, e.g., Latin-9 or Big5, and these
+can be weighted.  The default series is generated automatically from
+the associated MIME types of all defined coding systems, sorted by the
+coding system priority specified in Emacs.  @xref{Recognize Coding, ,
+Recognizing Coding Systems, emacs, The GNU Emacs Manual}.
 @end defopt
 
 @defopt url-mime-language-string
 @cindex language preferences
 A string specifying the preferred language when servers can serve
-files in several languages.  Use RFC 1766 abbreviations, e.g.@:
-@samp{en} for English, @samp{de} for German.  It can be a
-comma-separated list in descending order of preference.  The ordering
-can be made explicit using `q' factors defined by HTTP, e.g.@:
-@w{@samp{de, en-gb;q=0.8, en;q=0.7}}.  It can be @samp{*} to get the
-first available language (as opposed to the default).
+files in several languages.  Use RFC 1766 abbreviations, e.g.,
+@samp{en} for English, @samp{de} for German.
+
+The string can be @code{"*"} to get the first available language (as
+opposed to the default).
 @end defopt
 
 @node HTTP URL Options
--- a/src/ChangeLog	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/ChangeLog	Wed Mar 16 16:06:15 2005 +0000
@@ -1,3 +1,64 @@
+2005-03-15  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* macterm.c (keycode_to_xkeysym_table): Change mapping so that it
+	coincide with that in Apple X11 except `clear', `enter' on
+	laptops, and fn + `enter' on laptops.
+
+2005-03-12  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* xmenu.c (ENCODE_MENU_STRING): Explicitly use string_make_unibyte.
+	(list_of_panes, list_of_items, Fx_popup_menu): Use XCAR/XCDR.
+	(digest_single_submenu, xmenu_show): Use ENCODE_MENU_STRING.
+
+	* xfns.c (xic_defaut_fontset): New constant.
+	(xic_create_fontsetname): New function.
+	Extracted from create_frame_xic.  Try to generate a slightly
+	better fontset.
+	(xic_create_xfontset): Use it.
+	(create_frame_xic): Simplify.
+
+2005-03-11  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* fileio.c (Fmake_symbolic_link): Fix last change.
+
+2005-03-11  Richard M. Stallman  <rms@gnu.org>
+
+	* fileio.c (Frename_file, Fadd_name_to_file)
+	(Fmake_symbolic_link): If NEWNAME or LINKNAME is a directory,
+	expand the basename of FILE relative to it.
+
+2005-03-11  Kenichi Handa  <handa@m17n.org>
+
+	* fileio.c (Finsert_file_contents): Call Fcheck_coding_system
+	before calling setup_coding_system so that autoloading of a coding
+	system work.
+
+2005-03-10  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
+
+	* xfns.c (hourglass_started): New function.
+
+	* dispextern.h: Declare hourglass_started.
+
+	* keyboard.c (Fexecute_extended_command): Restart hourglass
+	after call to Fcompleting_read if already started.
+
+	* gtkutil.c (xg_update_scrollbar_pos): Call x_sync so that the
+	GTK main loop is entered in xterm.c, thus doing the redraw.
+
+2005-03-10  Kim F. Storm  <storm@cua.dk>
+
+	* xdisp.c (pos_visible_p): Fix X value in last line of buffer.
+
+2005-03-08  Kenichi Handa  <handa@m17n.org>
+
+	* frame.c (x_set_font): Call set_default_ascii_font if an
+	available font is found.
+
+	* fontset.c (set_default_ascii_font): New function.
+	(syms_of_fontset): Don't set FONTSET_ASCII (Vdefault_fontset) here.
+
+	* fontset.h (set_default_ascii_font): Extern it.
+
 2005-03-07  Kim F. Storm  <storm@cua.dk>
 
 	* xdisp.c (CLEAR_IMAGE_CACHE_COUNT): New const.
@@ -55,13 +116,11 @@
 	* emacs.c (main): Change `#ifdef HAVE_CARBON' to `#if
 	defined (MAC_OSX) && defined (HAVE_CARBON)'.
 
-	* image.c [!MAC_OSX && TARGET_API_MAC_CARBON]: Include
-	QuickTime.h.
+	* image.c [!MAC_OSX && TARGET_API_MAC_CARBON]: Include QuickTime.h.
 
 	* mac.c [!MAC_OSX && HAVE_CARBON]: Include Carbon.h.
 	[!MAC_OSX] (select) [TARGET_API_MAC_CARBON]: Use ReceiveNextEvent.
-	(posix_pathname_to_fsspec, fsspec_to_posix_pathname): New
-	functions.
+	(posix_pathname_to_fsspec, fsspec_to_posix_pathname): New functions.
 	(mac_clear_font_name_table): Move extern to macterm.h.
 
 	* macfns.c (install_window_handler): Move extern to macterm.h.
@@ -69,16 +128,15 @@
 	valid.  Don't check !NILP (dir) because it is already checked with
 	CHECK_STRING.
 	(Fx_file_dialog) [!MAC_OSX]: Use FSSpec instead of FSRef for
-	specifying the default location and obtaining the selected
-	filename.
+	specifying the default location and obtaining the selected filename.
 
 	* macgui.h [!MAC_OSX && HAVE_CARBON]: Include Carbon.h.
 
 	* macmenu.c [TARGET_API_MAC_CARBON]: Don't include headers that
 	are included via Carbon.h.
 
-	* macterm.c [TARGET_API_MAC_CARBON && !MAC_OSX]: Define
-	USE_CARBON_EVENTS to 1.
+	* macterm.c [TARGET_API_MAC_CARBON && !MAC_OSX]:
+	Define USE_CARBON_EVENTS to 1.
 	(qd) [__MRC__ && TARGET_API_MAC_CARBON]: Don't declare.
 	(x_free_frame_resources): Call remove_window_handler for
 	non-tooltip windows.
@@ -91,12 +149,12 @@
 	(install_window_handler) [TARGET_API_MAC_CARBON]: Create UPPs for
 	drag-and-drop handler functions and register them.
 	(remove_window_handler): New function.
-	(do_ae_open_documents, mac_do_receive_drag) [!MAC_OSX]: Use
-	fsspec_to_posix_pathname.
+	(do_ae_open_documents, mac_do_receive_drag) [!MAC_OSX]:
+	Use fsspec_to_posix_pathname.
 	(main): Change #if !TARGET_API_MAC_CARBON to #ifdef MAC_OS8.
 	(XTread_socket) [!MAC_OSX]: Don't pass keyboard events to TSM.
-	[MAC_OS8] (make_mac_terminal_frame) [TARGET_API_MAC_CARBON]: Set
-	default cursors.
+	[MAC_OS8] (make_mac_terminal_frame) [TARGET_API_MAC_CARBON]:
+	Set default cursors.
 	(mac_initialize) [USE_CARBON_EVENTS && !MAC_OSX] : Don't call
 	init_service_handler or init_quit_char_handler.
 	(mac_initialize) [!MAC_OSX]: Don't call MakeMeTheFrontProcess.
--- a/src/coding.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/coding.c	Wed Mar 16 16:06:15 2005 +0000
@@ -7819,7 +7819,10 @@
 On detecting a coding system, Emacs tries code detection algorithms
 associated with each coding-category one by one in this order.  When
 one algorithm agrees with a byte sequence of source text, the coding
-system bound to the corresponding coding-category is selected.  */);
+system bound to the corresponding coding-category is selected.
+
+When you modify this variable, `update-coding-systems-internal' must
+be called.  */);
   {
     int i;
 
--- a/src/dispextern.h	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/dispextern.h	Wed Mar 16 16:06:15 2005 +0000
@@ -2808,6 +2808,7 @@
 EXFUN (Fx_hide_tip, 0);
 extern void start_hourglass P_ ((void));
 extern void cancel_hourglass P_ ((void));
+extern int hourglass_started P_ ((void));
 extern int display_hourglass_p;
 
 /* Returns the background color of IMG, calculating one heuristically if
--- a/src/fileio.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/fileio.c	Wed Mar 16 16:06:15 2005 +0000
@@ -1,6 +1,6 @@
 /* File IO for GNU Emacs.
    Copyright (C) 1985, 1986, 1987, 1988, 1993, 1994, 1995, 1996, 1997, 1998,
-     1999, 2000, 2001, 2003, 2004  Free Software Foundation, Inc.
+     1999, 2000, 2001, 2003, 2004, 2005  Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -2693,7 +2693,11 @@
   CHECK_STRING (file);
   CHECK_STRING (newname);
   file = Fexpand_file_name (file, Qnil);
-  newname = Fexpand_file_name (newname, Qnil);
+
+  if (!NILP (Ffile_directory_p (newname)))
+    newname = Fexpand_file_name (Ffile_name_nondirectory (file), newname);
+  else
+    newname = Fexpand_file_name (newname, Qnil);
 
   /* If the file name has special constructs in it,
      call the corresponding file handler.  */
@@ -2776,7 +2780,11 @@
   CHECK_STRING (file);
   CHECK_STRING (newname);
   file = Fexpand_file_name (file, Qnil);
-  newname = Fexpand_file_name (newname, Qnil);
+
+  if (!NILP (Ffile_directory_p (newname)))
+    newname = Fexpand_file_name (Ffile_name_nondirectory (file), newname);
+  else
+    newname = Fexpand_file_name (newname, Qnil);
 
   /* If the file name has special constructs in it,
      call the corresponding file handler.  */
@@ -2843,7 +2851,11 @@
      we want to permit links to relative file names.  */
   if (SREF (filename, 0) == '~')
     filename = Fexpand_file_name (filename, Qnil);
-  linkname = Fexpand_file_name (linkname, Qnil);
+
+  if (!NILP (Ffile_directory_p (linkname)))
+    linkname = Fexpand_file_name (Ffile_name_nondirectory (filename), linkname);
+  else
+    linkname = Fexpand_file_name (linkname, Qnil);
 
   /* If the file name has special constructs in it,
      call the corresponding file handler.  */
@@ -4505,12 +4517,12 @@
 	     this way, we can run Lisp program safely before decoding
 	     the inserted text.  */
 	  Lisp_Object unwind_data;
-	      int count = SPECPDL_INDEX ();
+	  int count = SPECPDL_INDEX ();
 
 	  unwind_data = Fcons (current_buffer->enable_multibyte_characters,
 			       Fcons (current_buffer->undo_list,
 				      Fcurrent_buffer ()));
-	      current_buffer->enable_multibyte_characters = Qnil;
+	  current_buffer->enable_multibyte_characters = Qnil;
 	  current_buffer->undo_list = Qt;
 	  record_unwind_protect (decide_coding_unwind, unwind_data);
 
@@ -4532,7 +4544,6 @@
 	      if (CONSP (coding_systems))
 		val = XCAR (coding_systems);
 	    }
-
 	  unbind_to (count, Qnil);
 	  inserted = Z_BYTE - BEG_BYTE;
 	}
@@ -4543,7 +4554,7 @@
 	 on some system.  */
       {
 	struct coding_system temp_coding;
-	setup_coding_system (val, &temp_coding);
+	setup_coding_system (Fcheck_coding_system (val), &temp_coding);
 	bcopy (&temp_coding, &coding, sizeof coding);
       }
       /* Ensure we set Vlast_coding_system_used.  */
--- a/src/fontset.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/fontset.c	Wed Mar 16 16:06:15 2005 +0000
@@ -765,6 +765,23 @@
 #pragma optimize("", on)
 #endif
 
+/* Set the ASCII font of the default fontset to FONTNAME if that is
+   not yet set.  */
+void
+set_default_ascii_font (fontname)
+     Lisp_Object fontname;
+{
+  if (! CONSP (FONTSET_ASCII (Vdefault_fontset)))
+    {
+      int id = fs_query_fontset (fontname, 2);
+
+      if (id >= 0)
+	fontname = XCDR (FONTSET_ASCII (FONTSET_FROM_ID (id)));
+      FONTSET_ASCII (Vdefault_fontset)
+	= Fcons (make_number (0), fontname);
+    }
+}
+
 
 /* Cache data used by fontset_pattern_regexp.  The car part is a
    pattern string containing at least one wild card, the cdr part is
@@ -1628,19 +1645,6 @@
   FONTSET_ID (Vdefault_fontset) = make_number (0);
   FONTSET_NAME (Vdefault_fontset)
     = build_string ("-*-*-*-*-*-*-*-*-*-*-*-*-fontset-default");
-#if defined (MAC_OS)
-  FONTSET_ASCII (Vdefault_fontset)
-    = Fcons (make_number (0),
-	     build_string ("-apple-monaco-medium-r-*--*-120-*-*-*-*-mac-roman"));
-#elif defined (WINDOWSNT)
-  FONTSET_ASCII (Vdefault_fontset)
-    = Fcons (make_number (0),
-	     build_string ("-*-courier new-normal-r-*-*-*-100-*-*-*-*-iso8859-1"));
-#else
-  FONTSET_ASCII (Vdefault_fontset)
-    = Fcons (make_number (0),
-	     build_string ("-adobe-courier-medium-r-*-*-*-120-*-*-*-*-iso8859-1"));
-#endif
   AREF (Vfontset_table, 0) = Vdefault_fontset;
   next_fontset_id = 1;
 
--- a/src/fontset.h	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/fontset.h	Wed Mar 16 16:06:15 2005 +0000
@@ -194,6 +194,7 @@
 extern int face_suitable_for_char_p P_ ((struct face *, int));
 extern int face_for_char P_ ((FRAME_PTR, struct face *, int));
 extern int make_fontset_for_ascii_face P_ ((FRAME_PTR, int));
+extern void set_default_ascii_font P_ ((Lisp_Object));
 extern struct font_info *fs_load_font P_ ((struct frame *, int, char *, int,
 					   struct face *));
 extern int fs_query_fontset P_ ((Lisp_Object, int));
--- a/src/frame.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/frame.c	Wed Mar 16 16:06:15 2005 +0000
@@ -3321,6 +3321,7 @@
     error ("The characters of the given font have varying widths");
   else if (STRINGP (result))
     {
+      set_default_ascii_font (result);
       if (STRINGP (fontset_name))
 	{
 	  /* Fontset names are built from ASCII font names, so the
--- a/src/gtkutil.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/gtkutil.c	Wed Mar 16 16:06:15 2005 +0000
@@ -2999,9 +2999,14 @@
       GtkWidget *wparent = gtk_widget_get_parent (wscroll);
 
       /* Move and resize to new values.  */
+      gtk_fixed_move (GTK_FIXED (wfixed), wparent, left, top);
       gtk_widget_set_size_request (wscroll, width, height);
-      gtk_fixed_move (GTK_FIXED (wfixed), wparent, left, top);
-
+      gtk_widget_queue_draw (wparent);
+      gdk_window_process_all_updates ();
+      /* GTK does not redraw until the main loop is entered again, but
+         if there are no X events pending we will not enter it.  So we sync
+         here to get some events.  */
+      x_sync (f);
       SET_FRAME_GARBAGED (f);
       cancel_mouse_face (f);
     }
--- a/src/keyboard.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/keyboard.c	Wed Mar 16 16:06:15 2005 +0000
@@ -1335,6 +1335,11 @@
     cancel_hourglass ();
 #endif
 
+  /* Unblock input if we enter with input blocked.  This may happen if
+     redisplay traps e.g. during tool-bar update with input blocked.  */
+  while (INPUT_BLOCKED_P)
+    UNBLOCK_INPUT;
+
   return Fthrow (Qtop_level, Qnil);
 }
 
@@ -9780,6 +9785,15 @@
   Lisp_Object saved_keys, saved_last_point_position_buffer;
   Lisp_Object bindings, value;
   struct gcpro gcpro1, gcpro2, gcpro3;
+#ifdef HAVE_X_WINDOWS
+  /* The call to Fcompleting_read wil start and cancel the hourglass,
+     but if the hourglass was already scheduled, this means that no
+     hourglass will be shown for the actual M-x command itself.
+     So we restart it if it is already scheduled.  Note that checking
+     hourglass_shown_p is not enough,  normally the hourglass is not shown,
+     just scheduled to be shown.  */
+  int hstarted = hourglass_started ();
+#endif
 
   saved_keys = Fvector (this_command_key_count,
 			XVECTOR (this_command_keys)->contents);
@@ -9811,6 +9825,10 @@
 			       Qt, Qnil, Qextended_command_history, Qnil,
 			       Qnil);
 
+#ifdef HAVE_X_WINDOWS
+  if (hstarted) start_hourglass ();
+#endif
+
   if (STRINGP (function) && SCHARS (function) == 0)
     error ("No command name given");
 
--- a/src/macterm.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/macterm.c	Wed Mar 16 16:06:15 2005 +0000
@@ -8451,19 +8451,23 @@
 #endif
 
 /* Table for translating Mac keycode to X keysym values.  Contributed
-   by Sudhir Shenoy.  */
+   by Sudhir Shenoy.
+   Mapping for special keys is now identical to that in Apple X11
+   except `clear' (-> <clear>) on the KeyPad, `enter' (-> <kp-enter>)
+   on the right of the Cmd key on laptops, and fn + `enter' (->
+   <linefeed>). */
 static unsigned char keycode_to_xkeysym_table[] = {
   /*0x00*/ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
   /*0x10*/ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
   /*0x20*/ 0, 0, 0, 0, 0x0d /*return*/, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 
   /*0x30*/ 0x09 /*tab*/, 0 /*0x0020 space*/, 0, 0x08 /*backspace*/,
-  /*0x34*/ 0, 0x1b /*escape*/, 0, 0,
+  /*0x34*/ 0x8d /*enter on laptops*/, 0x1b /*escape*/, 0, 0,
   /*0x38*/ 0, 0, 0, 0,
   /*0x3C*/ 0, 0, 0, 0,
 
   /*0x40*/ 0, 0xae /*kp-.*/, 0, 0xaa /*kp-**/,
-  /*0x44*/ 0, 0xab /*kp-+*/, 0, 0x7f /*kp-clear*/,
+  /*0x44*/ 0, 0xab /*kp-+*/, 0, 0x0b /*clear*/,
   /*0x48*/ 0, 0, 0, 0xaf /*kp-/*/,
   /*0x4C*/ 0x8d /*kp-enter*/, 0, 0xad /*kp--*/, 0,
 
@@ -8475,11 +8479,11 @@
   /*0x60*/ 0xc2 /*f5*/, 0xc3 /*f6*/, 0xc4 /*f7*/, 0xc0 /*f3*/,
   /*0x64*/ 0xc5 /*f8*/, 0xc6 /*f9*/, 0, 0xc8 /*f11*/,
   /*0x68*/ 0, 0xca /*f13*/, 0, 0xcb /*f14*/,
-  /*0x6C*/ 0, 0xc7 /*f10*/, 0, 0xc9 /*f12*/,
-
-  /*0x70*/ 0, 0xcc /*f15*/, 0x9e /*insert (or 0x6a==help)*/, 0x95 /*home*/,
-  /*0x74*/ 0x9a /*pgup*/, 0x9f /*delete*/, 0xc1 /*f4*/, 0x9c /*end*/,
-  /*0x78*/ 0xbf /*f2*/, 0x9b /*pgdown*/, 0xbe /*f1*/, 0x51 /*left*/,
+  /*0x6C*/ 0, 0xc7 /*f10*/, 0x0a /*fn+enter on laptops*/, 0xc9 /*f12*/,
+
+  /*0x70*/ 0, 0xcc /*f15*/, 0x6a /*help*/, 0x50 /*home*/,
+  /*0x74*/ 0x55 /*pgup*/, 0xff /*delete*/, 0xc1 /*f4*/, 0x57 /*end*/,
+  /*0x78*/ 0xbf /*f2*/, 0x56 /*pgdown*/, 0xbe /*f1*/, 0x51 /*left*/,
   /*0x7C*/ 0x53 /*right*/, 0x54 /*down*/, 0x52 /*up*/, 0
 };
 
--- a/src/xdisp.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/xdisp.c	Wed Mar 16 16:06:15 2005 +0000
@@ -1294,6 +1294,7 @@
   /* Note that we may overshoot because of invisible text.  */
   if (IT_CHARPOS (it) >= charpos)
     {
+      int top_x = it.current_x;
       int top_y = it.current_y;
       int bottom_y = (last_height = 0, line_bottom_y (&it));
       int window_top_y = WINDOW_HEADER_LINE_HEIGHT (w);
@@ -1302,15 +1303,12 @@
 	visible_p = bottom_y > window_top_y;
       else if (top_y < it.last_visible_y)
 	  visible_p = 1;
-      if (visible_p && x)
-	{
-	  *x = it.current_x;
+      if (visible_p)
+	{
+	  *x = top_x;
 	  *y = max (top_y + max (0, it.max_ascent - it.ascent), window_top_y);
-	  if (rtop)
-	    {
-	      *rtop = max (0, window_top_y - top_y);
-	      *rbot = max (0, bottom_y - it.last_visible_y);
-	    }
+	  *rtop = max (0, window_top_y - top_y);
+	  *rbot = max (0, bottom_y - it.last_visible_y);
 	}
     }
   else
@@ -1323,18 +1321,12 @@
       if (charpos < IT_CHARPOS (it))
 	{
 	  visible_p = 1;
-	  if (x)
-	    {
-	      move_it_to (&it2, charpos, -1, -1, -1, MOVE_TO_POS);
-	      *x = it2.current_x;
-	      *y = it2.current_y + it2.max_ascent - it2.ascent;
-	      if (rtop)
-		{
-		  *rtop = max (0, -it2.current_y);
-		  *rbot = max (0, ((it2.current_y + it2.max_ascent + it2.max_descent)
-				   - it.last_visible_y));
-		}
-	    }
+	  move_it_to (&it2, charpos, -1, -1, -1, MOVE_TO_POS);
+	  *x = it2.current_x;
+	  *y = it2.current_y + it2.max_ascent - it2.ascent;
+	  *rtop = max (0, -it2.current_y);
+	  *rbot = max (0, ((it2.current_y + it2.max_ascent + it2.max_descent)
+			   - it.last_visible_y));
 	}
     }
 
--- a/src/xfns.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/xfns.c	Wed Mar 16 16:06:15 2005 +0000
@@ -1969,6 +1969,88 @@
 
 /* Create an X fontset on frame F with base font name BASE_FONTNAME.  */
 
+char xic_defaut_fontset[] = "-*-*-*-r-normal--14-*-*-*-*-*-*-*";
+
+char *
+xic_create_fontsetname (base_fontname)
+     char *base_fontname;
+{
+  /* Make a fontset name from the base font name.  */
+  if (xic_defaut_fontset == base_fontname)
+    /* There is no base font name, use the default.  */
+    return base_fontname;
+  else
+    {
+      /* Make a fontset name from the base font name.
+	 The font set will be made of the following elements:
+	 - the base font.
+	 - the base font where the charset spec is replaced by -*-*.
+	 - the same but with the family also replaced with -*-*-.  */
+      char *p = base_fontname;
+      char *fontsetname;
+      int i;
+	
+      for (i = 0; *p; p++)
+	if (*p == '-') i++;
+      if (i != 14)
+	{ /* As the font name doesn't conform to XLFD, we can't
+	     modify it to generalize it to allcs and allfamilies.
+	     Use the specified font plus the default.  */
+	  int len = strlen (base_fontname) + strlen (xic_defaut_fontset) + 2;
+	  fontsetname = xmalloc (len);
+	  bzero (fontsetname, len);
+	  strcpy (fontsetname, base_fontname);
+	  strcat (fontsetname, ",");
+	  strcat (fontsetname, xic_defaut_fontset);
+	}
+      else
+	{
+	  int len;
+	  char *p1 = NULL;
+	  char *font_allcs = NULL;
+	  char *font_allfamilies = NULL;
+	  char *allcs = "*-*-*-*-*-*-*";
+	  char *allfamilies = "-*-*-";
+	  
+	  for (i = 0, p = base_fontname; i < 8; p++)
+	    {
+	      if (*p == '-')
+		{
+		  i++;
+		  if (i == 3)
+		    p1 = p + 1;
+		}
+	    }
+	  /* Build the font spec that matches all charsets.  */
+	  len = p - base_fontname + strlen (allcs) + 1;
+	  font_allcs = (char *) alloca (len);
+	  bzero (font_allcs, len);
+	  bcopy (base_fontname, font_allcs, p - base_fontname);
+	  strcat (font_allcs, allcs);
+
+	  /* Build the font spec that matches all families.  */
+	  len = p - p1 + strlen (allcs) + strlen (allfamilies) + 1;
+	  font_allfamilies = (char *) alloca (len);
+	  bzero (font_allfamilies, len);
+	  strcpy (font_allfamilies, allfamilies);
+	  bcopy (p1, font_allfamilies + (strlen (allfamilies)), p - p1);
+	  strcat (font_allfamilies, allcs);
+
+	  /* Build the actual font set name.  */
+	  len = strlen (base_fontname) + strlen (font_allcs)
+	    + strlen (font_allfamilies) + 3;
+	  fontsetname = xmalloc (len);
+	  bzero (fontsetname, len);
+	  strcpy (fontsetname, base_fontname);
+	  strcat (fontsetname, ",");
+	  strcat (fontsetname, font_allcs);
+	  strcat (fontsetname, ",");
+	  strcat (fontsetname, font_allfamilies);
+	}
+      return fontsetname;
+    }
+}
+
 static XFontSet
 xic_create_xfontset (f, base_fontname)
      struct frame *f;
@@ -1980,6 +2062,9 @@
   char *def_string;
   Lisp_Object rest, frame;
 
+  if (!base_fontname)
+    base_fontname = xic_defaut_fontset;
+
   /* See if there is another frame already using same fontset.  */
   FOR_EACH_FRAME (rest, frame)
     {
@@ -1996,12 +2081,16 @@
 
   if (!xfs)
     {
+      char *fontsetname = xic_create_fontsetname (base_fontname);
+
       /* New fontset.  */
       xfs = XCreateFontSet (FRAME_X_DISPLAY (f),
-                            base_fontname, &missing_list,
+                            fontsetname, &missing_list,
                             &missing_count, &def_string);
       if (missing_list)
         XFreeStringList (missing_list);
+      if (fontsetname != base_fontname)
+	xfree (fontsetname);
     }
 
   if (FRAME_XIC_BASE_FONTNAME (f))
@@ -2083,6 +2172,11 @@
   if (FRAME_XIC (f))
     return;
 
+  /* Create X fontset. */
+  xfs = xic_create_xfontset
+    (f, (FRAME_FONTSET (f) < 0) ? NULL
+        : (char *) SDATA (fontset_ascii (FRAME_FONTSET (f))));
+
   xim = FRAME_X_XIM (f);
   if (xim)
     {
@@ -2090,52 +2184,9 @@
       XPoint spot;
       XVaNestedList preedit_attr;
       XVaNestedList status_attr;
-      char *base_fontname;
-      int fontset;
 
       s_area.x = 0; s_area.y = 0; s_area.width = 1; s_area.height = 1;
       spot.x = 0; spot.y = 1;
-      /* Create X fontset. */
-      fontset = FRAME_FONTSET (f);
-      if (fontset < 0)
-	base_fontname = "-*-*-*-r-normal--14-*-*-*-*-*-*-*";
-      else
-	{
-	  /* Determine the base fontname from the ASCII font name of
-	     FONTSET.  */
-	  char *ascii_font = (char *) SDATA (fontset_ascii (fontset));
-	  char *p = ascii_font;
-	  int i;
-
-	  for (i = 0; *p; p++)
-	    if (*p == '-') i++;
-	  if (i != 14)
-	    /* As the font name doesn't conform to XLFD, we can't
-	       modify it to get a suitable base fontname for the
-	       frame.  */
-	    base_fontname = "-*-*-*-r-normal--14-*-*-*-*-*-*-*";
-	  else
-	    {
-	      int len = strlen (ascii_font) + 1;
-	      char *p1 = NULL;
-
-	      for (i = 0, p = ascii_font; i < 8; p++)
-		{
-		  if (*p == '-')
-		    {
-		      i++;
-		      if (i == 3)
-			p1 = p + 1;
-		    }
-		}
-	      base_fontname = (char *) alloca (len);
-	      bzero (base_fontname, len);
-	      strcpy (base_fontname, "-*-*-");
-	      bcopy (p1, base_fontname + 5, p - p1);
-	      strcat (base_fontname, "*-*-*-*-*-*-*");
-	    }
-	}
-      xfs = xic_create_xfontset (f, base_fontname);
 
       /* Determine XIC style.  */
       if (xic_style == 0)
@@ -4310,6 +4361,14 @@
 static void show_hourglass P_ ((struct atimer *));
 static void hide_hourglass P_ ((void));
 
+/* Return non-zero if houglass timer has been started or hourglass is shown.  */
+
+int
+hourglass_started ()
+{
+  return hourglass_shown_p || hourglass_atimer != NULL;
+}
+
 
 /* Cancel a currently active hourglass timer, and start a new one.  */
 
--- a/src/xmenu.c	Wed Mar 16 16:03:44 2005 +0000
+++ b/src/xmenu.c	Wed Mar 16 16:06:15 2005 +0000
@@ -1,6 +1,6 @@
 /* X Communication module for terminals which understand the X protocol.
-   Copyright (C) 1986, 1988, 1993, 1994, 1996, 1999, 2000, 2001, 2003, 2004
-   Free Software Foundation, Inc.
+   Copyright (C) 1986, 1988, 1993, 1994, 1996, 1999, 2000, 2001, 2003, 2004,
+   2005  Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -138,12 +138,7 @@
 /* gtk just uses utf-8.  */
 # define ENCODE_MENU_STRING(str) ENCODE_UTF_8 (str)
 #else
-/* I'm not convinced ENCODE_SYSTEM is defined correctly, or maybe
-   something else should be used here.  Except under MS-Windows it
-   just converts to unibyte, but encoding with `locale-coding-system'
-   seems better -- X may actually display the result correctly, and
-   it's not necessarily equivalent to the unibyte text.  -- fx  */
-# define ENCODE_MENU_STRING(str) ENCODE_SYSTEM (str)
+# define ENCODE_MENU_STRING(str) string_make_unibyte (str)
 #endif
 
 static void push_menu_item P_ ((Lisp_Object, Lisp_Object, Lisp_Object,
@@ -645,10 +640,10 @@
 
   init_menu_items ();
 
-  for (tail = menu; !NILP (tail); tail = Fcdr (tail))
+  for (tail = menu; CONSP (tail); tail = XCDR (tail))
     {
       Lisp_Object elt, pane_name, pane_data;
-      elt = Fcar (tail);
+      elt = XCAR (tail);
       pane_name = Fcar (elt);
       CHECK_STRING (pane_name);
       push_menu_pane (ENCODE_MENU_STRING (pane_name), Qnil);
@@ -668,22 +663,22 @@
 {
   Lisp_Object tail, item, item1;
 
-  for (tail = pane; !NILP (tail); tail = Fcdr (tail))
+  for (tail = pane; CONSP (tail); tail = XCDR (tail))
     {
-      item = Fcar (tail);
+      item = XCAR (tail);
       if (STRINGP (item))
 	push_menu_item (ENCODE_MENU_STRING (item), Qnil, Qnil, Qt,
 			Qnil, Qnil, Qnil, Qnil);
-      else if (NILP (item))
-	push_left_right_boundary ();
-      else
+      else if (CONSP (item))
 	{
-	  CHECK_CONS (item);
-	  item1 = Fcar (item);
+	  item1 = XCAR (item);
 	  CHECK_STRING (item1);
-	  push_menu_item (ENCODE_MENU_STRING (item1), Qt, Fcdr (item),
+	  push_menu_item (ENCODE_MENU_STRING (item1), Qt, XCDR (item),
 			  Qt, Qnil, Qnil, Qnil, Qnil);
 	}
+      else
+	push_left_right_boundary ();
+
     }
 }
 
@@ -802,8 +797,8 @@
 	  if (CONSP (tem))
 	    {
 	      window = Fcar (Fcdr (position));
-	      x = Fcar (tem);
-	      y = Fcar (Fcdr (tem));
+	      x = XCAR (tem);
+	      y = Fcar (XCDR (tem));
 	    }
 	  else
 	    {
@@ -931,11 +926,11 @@
 
       /* The first keymap that has a prompt string
 	 supplies the menu title.  */
-      for (tem = menu, i = 0; CONSP (tem); tem = Fcdr (tem))
+      for (tem = menu, i = 0; CONSP (tem); tem = XCDR (tem))
 	{
 	  Lisp_Object prompt;
 
-	  maps[i++] = keymap = get_keymap (Fcar (tem), 1, 0);
+	  maps[i++] = keymap = get_keymap (XCAR (tem), 1, 0);
 
 	  prompt = Fkeymap_prompt (keymap);
 	  if (NILP (title) && !NILP (prompt))
@@ -1750,7 +1745,7 @@
 #ifndef HAVE_MULTILINGUAL_MENU
 	  if (STRINGP (pane_name) && STRING_MULTIBYTE (pane_name))
 	    {
-	      pane_name = ENCODE_SYSTEM (pane_name);
+	      pane_name = ENCODE_MENU_STRING (pane_name);
 	      AREF (menu_items, i + MENU_ITEMS_PANE_NAME) = pane_name;
 	    }
 #endif
@@ -2695,7 +2690,7 @@
 #ifndef HAVE_MULTILINGUAL_MENU
 	  if (STRINGP (pane_name) && STRING_MULTIBYTE (pane_name))
 	    {
-	      pane_name = ENCODE_SYSTEM (pane_name);
+	      pane_name = ENCODE_MENU_STRING (pane_name);
 	      AREF (menu_items, i + MENU_ITEMS_PANE_NAME) = pane_name;
 	    }
 #endif