]> code.delx.au - gnu-emacs/commitdiff
Doc updates for default values of some -function vars no longer being nil
authorGlenn Morris <rgm@gnu.org>
Fri, 4 Apr 2014 01:49:28 +0000 (21:49 -0400)
committerGlenn Morris <rgm@gnu.org>
Fri, 4 Apr 2014 01:49:28 +0000 (21:49 -0400)
* doc/emacs/files.texi (Backup Names):
* doc/emacs/arevert-xtra.texi (Supporting additional buffers):
* doc/lispref/backups.texi (Making Backups, Reverting):
Update for default values of some -function vars no longer being nil.

* etc/NEWS: Related edits.

doc/emacs/ChangeLog
doc/emacs/arevert-xtra.texi
doc/emacs/files.texi
doc/lispref/ChangeLog
doc/lispref/backups.texi
etc/NEWS

index 34679b8ba1d83c1b12f67e787d3a8cee41ee1cb4..bd593f49db3ab5f1a836ce00df69d017e60929fe 100644 (file)
@@ -1,3 +1,9 @@
+2014-04-04  Glenn Morris  <rgm@gnu.org>
+
+       * files.texi (Backup Names):
+       * arevert-xtra.texi (Supporting additional buffers):
+       Update for default values of some -function vars no longer being nil.
+
 2014-03-16  Dmitry Gutov  <dgutov@yandex.ru>
 
        * programs.texi (Matching): Update the missed spot.  (Bug#17008)
index a13f59b69bdbf3a527941caf919ce225dd4af8d9..0f05d1db0e1aeeefbfc636cdecee45c5702a3eec 100644 (file)
@@ -103,11 +103,11 @@ arguments to list only some of the files.  @file{*Find*} and
 This section is intended for Elisp programmers who would like to add
 support for auto-reverting new types of buffers.
 
-To support auto-reverting the buffer must first of all have a
+To support auto-reverting the buffer must first of all have a suitable
 @code{revert-buffer-function}.  @xref{Definition of
 revert-buffer-function,, Reverting, elisp, the Emacs Lisp Reference Manual}.
 
-In addition, it @emph{must} have a @code{buffer-stale-function}.
+In addition, it must have a @code{buffer-stale-function}.
 
 @c FIXME only defvar in all of doc/emacs!
 @defvar buffer-stale-function
@@ -149,7 +149,7 @@ also be useful if the function is consulted for purposes other than
 auto-reverting.
 @end defvar
 
-Once the buffer has a @code{revert-buffer-function} and a
+Once the buffer has a suitable @code{revert-buffer-function} and
 @code{buffer-stale-function}, several problems usually remain.
 
 The buffer will only auto-revert if it is marked unmodified.  Hence,
index 3b9aefa332be84a65d371f484851675887145ef3..9310c44f1e676c9dd5f147b5038a83cf8ff8e1e3 100644 (file)
@@ -594,8 +594,8 @@ directory.  Emacs creates the directory, if necessary, to make the
 backup.
 
 @vindex make-backup-file-name-function
-  If you define the variable @code{make-backup-file-name-function} to
-a suitable Lisp function, that overrides the usual way Emacs
+  If you set the variable @code{make-backup-file-name-function} to
+a suitable Lisp function, you can override the usual way Emacs
 constructs backup file names.
 
 @node Backup Deletion
index bf3c6f170eaadff42ea707900659cc757c351672..456c2cbdc121515e969b96b94c6acfbb7a7fef53 100644 (file)
@@ -1,3 +1,8 @@
+2014-04-04  Glenn Morris  <rgm@gnu.org>
+
+       * backups.texi (Making Backups, Reverting):
+       Update for default values of some -function vars no longer being nil.
+
 2014-03-25  Eli Zaretskii  <eliz@gnu.org>
 
        * files.texi (Kinds of Files): Improve documentation of
index 83ffb2f95e478d54c5fb52549d38ea5d1ee729d6..9fa97fc13007080e0fbb3fc3623e98a3d28a7b5a 100644 (file)
@@ -90,8 +90,7 @@ save disk space.  (You would put this code in your init file.)
 @smallexample
 @group
 (add-hook 'rmail-mode-hook
-          (lambda ()
-            (set (make-local-variable 'make-backup-files) nil)))
+          (lambda () (setq-local make-backup-files nil)))
 @end group
 @end smallexample
 @end defopt
@@ -150,13 +149,12 @@ ignored.
 @end defopt
 
 @defopt make-backup-file-name-function
-This variable's value is a function to use for making backups instead
-of the default @code{make-backup-file-name}.  A value of @code{nil}
-gives the default @code{make-backup-file-name} behavior.
+This variable's value is a function to use for making backup file names.
+The function @code{make-backup-file-name} calls it.
 @xref{Backup Names,, Naming Backup Files}.
 
 This could be buffer-local to do something special for specific
-files.  If you define it, you may need to change
+files.  If you change it, you may need to change
 @code{backup-file-name-p} and @code{file-name-sans-versions} too.
 @end defopt
 
@@ -727,25 +725,24 @@ buffer-local bindings for these variables:
 @defvar revert-buffer-function
 @anchor{Definition of revert-buffer-function}
 The value of this variable is the function to use to revert this
-buffer.  If non-@code{nil}, it should be a function with two optional
+buffer.  It should be a function with two optional
 arguments to do the work of reverting.  The two optional arguments,
 @var{ignore-auto} and @var{noconfirm}, are the arguments that
-@code{revert-buffer} received.  If the value is @code{nil}, reverting
-works the usual way.
+@code{revert-buffer} received.
 
 Modes such as Dired mode, in which the text being edited does not
 consist of a file's contents but can be regenerated in some other
-fashion, can give this variable a buffer-local value that is a function to
-regenerate the contents.
+fashion, can give this variable a buffer-local value that is a special
+function to regenerate the contents.
 @end defvar
 
 @defvar revert-buffer-insert-file-contents-function
-The value of this variable, if non-@code{nil}, specifies the function to use to
+The value of this variable specifies the function to use to
 insert the updated contents when reverting this buffer.  The function
 receives two arguments: first the file name to use; second, @code{t} if
 the user has asked to read the auto-save file.
 
-The reason for a mode to set this variable instead of
+The reason for a mode to change this variable instead of
 @code{revert-buffer-function} is to avoid duplicating or replacing the
 rest of what @code{revert-buffer} does: asking for confirmation,
 clearing the undo list, deciding the proper major mode, and running the
@@ -753,21 +750,21 @@ hooks listed below.
 @end defvar
 
 @defvar before-revert-hook
-This normal hook is run by @code{revert-buffer} before
-inserting the modified contents---but only if
-@code{revert-buffer-function} is @code{nil}.
+This normal hook is run by the default @code{revert-buffer-function}
+before inserting the modified contents.  A custom @code{revert-buffer-function}
+may or may not run this hook.
 @end defvar
 
 @defvar after-revert-hook
-This normal hook is run by @code{revert-buffer} after inserting
-the modified contents---but only if @code{revert-buffer-function} is
-@code{nil}.
+This normal hook is run by the default @code{revert-buffer-function}
+after inserting the modified contents.  A custom @code{revert-buffer-function}
+may or may not run this hook.
 @end defvar
 
 @c FIXME?  Move this section from arevert-xtra to here?
 @defvar buffer-stale-function
-The value of this variable, if non-@code{nil}, specifies a function
-to call to check whether a non-file buffer needs reverting
+The value of this variable specifies a function to call to check
+whether a non-file buffer needs reverting
 @iftex
 (@pxref{Supporting additional buffers,,, emacs-xtra,  Specialized Emacs Features}).
 @end iftex
index ea62be87bfb3e167311c127f7e8ed231c7c4e23d..c3998934b5e9f5b889570e62295812cce6411a6b 100644 (file)
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -159,6 +159,7 @@ You can change the default by customizing `blink-cursor-blinks'.
 ** In keymaps where SPC scrolls forward, S-SPC now scrolls backward.
 This affects View mode, etc.
 
++++
 ** The default value of `make-backup-file-name-function' is no longer nil.
 Instead it defaults to a function that does what the nil value used to.
 
@@ -1400,6 +1401,7 @@ argument, with the same interpretation as the returned value of
 
 ** Revert and Autorevert changes
 
+FIXME buffer-stale-function no longer just for non-file buffers?
 *** The default values of `buffer-stale-function', `revert-buffer-function',
 and `revert-buffer-insert-file-contents-function' are no longer nil.
 Instead they default to functions that do what the nil value used to.