]> git.eshelyaron.com Git - emacs.git/commitdiff
*** empty log message ***
authorRichard M. Stallman <rms@gnu.org>
Wed, 6 Feb 2002 15:44:48 +0000 (15:44 +0000)
committerRichard M. Stallman <rms@gnu.org>
Wed, 6 Feb 2002 15:44:48 +0000 (15:44 +0000)
etc/NEWS
leim/ChangeLog
lisp/ChangeLog
src/ChangeLog

index da01bf3177e6c7b07abac8843aae0afd4c891d33..8720e7941dbc8b710ab4bb8c776dd8ed05c63b8c 100644 (file)
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -416,6 +416,63 @@ SQL buffer.
 \f
 * Lisp Changes in Emacs 21.3
 
+** Atomic change groups.
+
+To perform some changes in the current buffer "atomically" so that
+they either all succeed or are all undone, use `atomic-change-group'
+around the code that makes changes.  For instance:
+
+  (atomic-change-group
+    (insert foo)
+    (delete-region x y))
+
+If an error (or other nonlocal exit) occurs inside the body of
+`atomic-change-group', it unmakes all the changes in that buffer that
+were during the execution of the body.  The change group has no effect
+on any other buffers--any such changes remain.
+
+If you need something more sophisticated, you can directly call the
+lower-level functions that `atomic-change-group' uses.  Here is how.
+
+To set up a change group for one buffer, call `prepare-change-group'.
+Specify the buffer as argument; it defaults to the current buffer.
+This function returns a "handle" for the change group.  You must save
+the handle to activate the change group and then finish it.
+
+Before you change the buffer again, you must activate the change
+group.  Pass the handle to `activate-change-group' afterward to
+do this.
+
+After you make the changes, you must finish the change group.  You can
+either accept the changes or cancel them all.  Call
+`accept-change-group' to accept the changes in the group as final;
+call `cancel-change-group' to undo them all.
+
+You should use `unwind-protect' to make sure the group is always
+finished.  The call to `activate-change-group' should be inside the
+`unwind-protect', in case the user types C-g just after it runs.
+(This is one reason why `prepare-change-group' and
+`activate-change-group' are separate functions.)  Once you finish the
+group, don't use the handle again--don't try to finish the same group
+twice.
+
+To make a multibuffer change group, call `prepare-change-group' once
+for each buffer you want to cover, then use `nconc' to combine the
+returned values, like this:
+
+  (nconc (prepare-change-group buffer-1)
+         (prepare-change-group buffer-2))
+
+You can then activate the multibuffer change group with a single call
+to `activate-change-group', and finish it with a single call to
+`accept-change-group' or `cancel-change-group'.
+
+Nested use of several change groups for the same buffer works as you
+would expect.  Non-nested use of change groups for the same buffer
+will lead to undesirable results, so don't let it happen; the first
+change group you start for any given buffer should be the last one
+finished.
+
 ** New function substring-no-properties.
 
 +++
index f076df2a431a077050d1fe8b0ec62f25b9dee282..fbfd8b0dd6110076dfa240619c14e4dbe3fe287e 100644 (file)
@@ -1,3 +1,8 @@
+2002-02-06  Richard M. Stallman  <rms@gnu.org>
+
+       * quail/latin-pre.el (french-prefix): ", " => "," and "~ " => "~".
+       Don't define "~," at all.
+
 2002-01-29  Pavel Jan\e,Bm\e(Bk  <Pavel@Janik.cz>
 
        * quail/latin-pre.el (latin-2-prefix): Add \e,BL\e(B and \e,Bl\e(B.
index 7767771579912018bd4a2f52dbb011ac7eea2eb8..92bfde23736454006688ded94b3d07cb904c24d1 100644 (file)
@@ -1,3 +1,58 @@
+2002-02-06  Richard M. Stallman  <rms@gnu.org>
+
+       * mail/mailabbrev.el: Require sendmail only at compile time.
+       (mail-mode-header-syntax-table): Var deleted.
+       (mail-abbrev-syntax-table): Init to nil, will compute when needed.
+       (sendmail-pre-abbrev-expand-hook): Only temporarily change
+       local-abbrev-table and the syntax table.
+       Compute mail-abbrev-syntax-table if that has not been done.
+
+       * progmodes/compile.el (grep-compute-defaults): Definition moved up.
+
+       * emacs-lisp/debug.el (debugger-frame-offset): Var deleted.
+       (debugger-frame-number): Figure out the offset directly.
+       (debugger-setup-buffer): Don't use debugger-frame-offset.
+       (debugger-frame, debugger-frame-clear): Likewise.
+       (debugger-jump): Don't alter debugger-frame-offset.
+
+       * emacs-lisp/checkdoc.el (checkdoc-this-string-valid-engine):
+       Replace foo-p as var name with foo-flag, not foo-p-flag.
+
+       * hilit-chg.el (highlight-changes-active-string): Default to +Chg.
+       (highlight-changes-passive-string): Default to -Chg.
+       (highlight-changes-global-modes): Doc fix.
+
+       * dired.el (dired-get-filename): Add /: when appropriate
+       to avoid taking a local name as remote.
+
+       * files.el (file-name-non-special): Add special handling for
+       file-name-sans-versions, file-name-completion, and
+       file-name-all-completions.
+
+       * isearch.el (isearch-update): Don't update display in kbd macro.
+       (isearch-lazy-highlight-new-loop): Do nothing in kbd macro.
+
+       * subr.el (force-mode-line-update): Doc fix.
+
+       * subr.el (atomic-change-group, prepare-change-group) 
+       (activate-change-group, accept-change-group, cancel-change-group):
+       New functions.
+
+       * simple.el (undo-get-state, undo-revert-to-state): Fns deleted.
+       (transpose-subr-1): Use atomic-change-group.
+
+       * subr.el (add-minor-mode): Include the mode's lighter string
+       in the minor mode menu item name.
+
+       * mail/rmail.el (rmail-toggle-header): Avoid possibly slow call to
+       rmail-count-screen-lines starting from (point-min).
+
+       * startup.el (use-fancy-splash-screens-p): Need 19 lines,
+       beyond the image height, to use the fancy splash screen.
+
+       * textmodes/text-mode.el (text-mode-hook-identify): Function deleted.
+       (text-mode): Set text-mode-variant here.
+
 2002-02-06  Eli Zaretskii  <eliz@is.elta.co.il>
 
        * play/pong.el (pong-height): Don't use height that exceeds the
index b4d25314b575a94027f715f9df92eba3c06c5d49..6e78f8f976817a2ac73a6db2da6ffb94b786c8f7 100644 (file)
@@ -1,3 +1,7 @@
+2002-02-06  Richard M. Stallman  <rms@gnu.org>
+
+       * filelock.c (S_ISLNK): Define if not defined.
+
 2002-02-03  Richard M. Stallman  <rms@gnu.org>
 
        * fileio.c (Fdo_auto_save): Improve "auto save disabled" msg.