diff options
| author | Richard M. Stallman | 2007-12-25 23:00:07 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2007-12-25 23:00:07 +0000 |
| commit | c60d543d8bb6468ba0b652d9923acd17d2087233 (patch) | |
| tree | 7613bb0db5fa69c86e413bb57748b58ee0e4dbd9 | |
| parent | ddb74107ac1650f160ffed5dd52b9c6359f65573 (diff) | |
| download | emacs-c60d543d8bb6468ba0b652d9923acd17d2087233.tar.gz emacs-c60d543d8bb6468ba0b652d9923acd17d2087233.zip | |
(allout-region-active-p): Renamed from my-region-active-p. Use `use-region-p'.
(allout-write-file-hook-handler): Simplify code.
| -rw-r--r-- | etc/NEWS | 7 | ||||
| -rw-r--r-- | lisp/ChangeLog | 28 | ||||
| -rw-r--r-- | lisp/allout.el | 22 |
3 files changed, 45 insertions, 12 deletions
| @@ -450,9 +450,14 @@ variable as having been made within Custom. | |||
| 450 | ** `frame-inherited-parameters' lets new frames inherit parameters from | 450 | ** `frame-inherited-parameters' lets new frames inherit parameters from |
| 451 | the selected frame. | 451 | the selected frame. |
| 452 | 452 | ||
| 453 | ** Commands should use `region-active-p' to test whether there is | 453 | ** Commands should use `use-region-p' to test whether there is |
| 454 | an active region that they should operate on. | 454 | an active region that they should operate on. |
| 455 | 455 | ||
| 456 | ** `region-active-p' returns non-nil when Transient Mark mode | ||
| 457 | is enabled and there is an active region. This is NOT the best function | ||
| 458 | to use to test whether a command should operate on the region instead | ||
| 459 | of the usual behavior -- for that, use `use-region-p'. | ||
| 460 | |||
| 456 | ** New keymap `input-decode-map' overrides like key-translation-map, but | 461 | ** New keymap `input-decode-map' overrides like key-translation-map, but |
| 457 | applies before function-key-map. Also it is terminal-local contrary to | 462 | applies before function-key-map. Also it is terminal-local contrary to |
| 458 | key-translation-map. Terminal-specific key-sequences are generally added to | 463 | key-translation-map. Terminal-specific key-sequences are generally added to |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index af3dc434448..f4533083e2c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -11,11 +11,39 @@ | |||
| 11 | 11 | ||
| 12 | 2007-12-25 Richard Stallman <rms@gnu.org> | 12 | 2007-12-25 Richard Stallman <rms@gnu.org> |
| 13 | 13 | ||
| 14 | * allout.el (allout-region-active-p): Renamed from my-region-active-p. | ||
| 15 | Use `use-region-p'. | ||
| 16 | (allout-write-file-hook-handler): Simplify code. | ||
| 17 | |||
| 18 | * ps-print.el (ps-mark-active-p): Function deleted. | ||
| 19 | (ps-print-preprint-region): Use (mark) for the error check. | ||
| 20 | |||
| 21 | * tooltip.el (tooltip-region-active-p): Use `use-region-p'. | ||
| 22 | |||
| 23 | * winner.el (winner-active-region): Use `mark-active' if it's defined. | ||
| 24 | |||
| 25 | * progmodes/ada-mode.el (ada-region-selected): Use `use-region-p'. | ||
| 26 | |||
| 27 | * textmodes/org.el (org-region-active-p): Use `use-region-p'. | ||
| 28 | |||
| 29 | * progmodes/idlwave.el (idlwave-region-active-p): Use `use-region-p'. | ||
| 30 | |||
| 31 | * textmodes/reftex.el (reftex-region-active-p): Use `use-region-p'. | ||
| 32 | |||
| 33 | * progmodes/cc-defs.el (c-region-is-active-p): | ||
| 34 | Use `mark-active' if it's defined. | ||
| 35 | |||
| 36 | * progmodes/cc-cmds.el (c-indent-line-or-region): | ||
| 37 | Pass prefix arg to `c-indent-command'. Use `use-region-p'. | ||
| 38 | |||
| 14 | * simple.el (select-active-regions): New option. | 39 | * simple.el (select-active-regions): New option. |
| 15 | (set-mark): Obey it. | 40 | (set-mark): Obey it. |
| 16 | (yank-pop-change-selection): New option. | 41 | (yank-pop-change-selection): New option. |
| 17 | (current-kill): Obey it. | 42 | (current-kill): Obey it. |
| 18 | 43 | ||
| 44 | * simple.el (use-region-p): Renamed from `region-active-p'. | ||
| 45 | (region-active-p): New function. | ||
| 46 | |||
| 19 | 2007-12-25 David Golden <david.delaharpe.golden@gmail.com> (tiny change) | 47 | 2007-12-25 David Golden <david.delaharpe.golden@gmail.com> (tiny change) |
| 20 | 48 | ||
| 21 | * term/x-win.el (x-select-enable-primary): New option. | 49 | * term/x-win.el (x-select-enable-primary): New option. |
diff --git a/lisp/allout.el b/lisp/allout.el index 8878c56735f..12c1b3941c3 100644 --- a/lisp/allout.el +++ b/lisp/allout.el | |||
| @@ -1501,11 +1501,11 @@ See `allout-encryption-ciphertext-rejection-regexps' for rejection reasons.") | |||
| 1501 | (condition-case failure | 1501 | (condition-case failure |
| 1502 | (setq allout-after-save-decrypt | 1502 | (setq allout-after-save-decrypt |
| 1503 | (allout-encrypt-decrypted except-mark)) | 1503 | (allout-encrypt-decrypted except-mark)) |
| 1504 | (error (progn | 1504 | (message "allout-write-file-hook-handler suppressing error %s" |
| 1505 | (message | 1505 | failure) |
| 1506 | "allout-write-file-hook-handler suppressing error %s" | 1506 | (sit-for 2) |
| 1507 | failure) | 1507 | (error "allout-write-file-hook-handler suppressing error %s" |
| 1508 | (sit-for 2)))))) | 1508 | failure)))) |
| 1509 | )) | 1509 | )) |
| 1510 | nil) | 1510 | nil) |
| 1511 | ;;;_ > allout-auto-save-hook-handler () | 1511 | ;;;_ > allout-auto-save-hook-handler () |
| @@ -5457,11 +5457,11 @@ header and body. The elements of that list are: | |||
| 5457 | (cdr format))))))) | 5457 | (cdr format))))))) |
| 5458 | ;; Put the list with first at front, to last at back: | 5458 | ;; Put the list with first at front, to last at back: |
| 5459 | (nreverse result)))) | 5459 | (nreverse result)))) |
| 5460 | ;;;_ > my-region-active-p () | 5460 | ;;;_ > allout-region-active-p () |
| 5461 | (defmacro my-region-active-p () | 5461 | (defmacro allout-region-active-p () |
| 5462 | (if (fboundp 'region-active-p) | 5462 | (if (fboundp 'use-region-p) |
| 5463 | '(region-active-p) | 5463 | '(use-region-p) |
| 5464 | 'mark-active)) | 5464 | '(region-active-p))) |
| 5465 | ;;;_ > allout-process-exposed (&optional func from to frombuf | 5465 | ;;;_ > allout-process-exposed (&optional func from to frombuf |
| 5466 | ;;; tobuf format) | 5466 | ;;; tobuf format) |
| 5467 | (defun allout-process-exposed (&optional func from to frombuf tobuf | 5467 | (defun allout-process-exposed (&optional func from to frombuf tobuf |
| @@ -5494,7 +5494,7 @@ Defaults: | |||
| 5494 | ; defaulting if necessary: | 5494 | ; defaulting if necessary: |
| 5495 | (if (not func) (setq func 'allout-insert-listified)) | 5495 | (if (not func) (setq func 'allout-insert-listified)) |
| 5496 | (if (not (and from to)) | 5496 | (if (not (and from to)) |
| 5497 | (if (my-region-active-p) | 5497 | (if (allout-region-active-p) |
| 5498 | (setq from (region-beginning) to (region-end)) | 5498 | (setq from (region-beginning) to (region-end)) |
| 5499 | (setq from (point-min) to (point-max)))) | 5499 | (setq from (point-min) to (point-max)))) |
| 5500 | (if frombuf | 5500 | (if frombuf |