[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/multiple-cursors 038c9a7 161/434: Added stop as a possible
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/multiple-cursors 038c9a7 161/434: Added stop as a possible value for mc/cycle-looping-behaviour. |
Date: |
Sat, 7 Aug 2021 09:20:17 -0400 (EDT) |
branch: elpa/multiple-cursors
commit 038c9a7f03116f016a129981cdaa4094d89bedd8
Author: Marco Baringer <mb@bese.it>
Commit: Marco Baringer <mb@bese.it>
Added stop as a possible value for mc/cycle-looping-behaviour.
Simply disables looping (no warning either).
---
mc-cycle-cursors.el | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/mc-cycle-cursors.el b/mc-cycle-cursors.el
index 9dea266..3fe44bd 100644
--- a/mc-cycle-cursors.el
+++ b/mc-cycle-cursors.el
@@ -58,13 +58,15 @@
"What to do if asked to cycle beyond the last cursor or before the first
cursor."
:type '(radio (const :tag "Loop around to beginning/end of document."
continue)
(const :tag "Warn and then loop around." warn)
- (const :tag "Signal an error." error)))
+ (const :tag "Signal an error." error)
+ (const :tag "Don't loop." stop)))
(defun mc/handle-loop-condition (error-message)
(ecase mc/cycle-looping-behaviour
(error (error error-message))
(warn (message error-message))
- (continue nil)))
+ (continue 'continue)
+ (stop 'stop)))
(defun mc/first-cursor-after (point)
"Very similar to mc/furthest-cursor-before-point, but ignores (mark) and
(point)."
@@ -84,9 +86,10 @@
(cursors-in-order (sort* cursors-before-point '> :key
'mc/cursor-end)))
(first cursors-in-order)))
-(defun mc/cycle (next-cursor fallback-cursor loop-message)
+(defun* mc/cycle (next-cursor fallback-cursor loop-message)
(when (null next-cursor)
- (mc/handle-loop-condition loop-message)
+ (when (eql 'stop (mc/handle-loop-condition loop-message))
+ (return-from mc/cycle nil))
(setf next-cursor fallback-cursor))
(mc/create-fake-cursor-at-point)
(mc/pop-state-from-overlay next-cursor)
- [nongnu] elpa/multiple-cursors c3c4544 083/434: Place the file definition with the save definition., (continued)
- [nongnu] elpa/multiple-cursors c3c4544 083/434: Place the file definition with the save definition., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 39e4eb2 091/434: Added mc-version of mark-more-like-this-extended, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors b72e016 098/434: Don't require mark-multiple., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 294d574 093/434: Update README, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors b607794 110/434: Add config for travis-ci, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 32213d4 115/434: Make sure we run the right version of Emacs in travis., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 6e61e3d 114/434: Fix travis badge, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 719fe40 119/434: Integrate with rect.el instead of consolidating/splitting on kill-ring, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 5fcc69c 139/434: Skip keyboard macros, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 3f20fc1 154/434: When no region is active mc/mark-next-like-this and mc/mark-previous-like-this should create a cursor one like up (or down)., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 038c9a7 161/434: Added stop as a possible value for mc/cycle-looping-behaviour.,
ELPA Syncer <=
- [nongnu] elpa/multiple-cursors e4adefc 158/434: Fix issues with mc/cycle-(backward|forward) where the cycling was dependent on not having an active mark., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 1cdd730 221/434: Automatically select word/symbol, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 72ba43a 225/434: add .nosearch to directory with bundled libraries, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 6a5969e 202/434: Adding support for using mc/edit-lines without transient mark mode., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 980a880 223/434: Merge pull request #63 from tkf/select-thing-at-point, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors dce6c00 174/434: Add mc/cursor-specific-vars to handle vars that need to be tracked per cursor., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 0a081a7 184/434: Move mc/maybe-multiple-cursors-mode to core., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 9a376a6 201/434: Add note about yank-rectangle, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors e7605bb 194/434: Merge pull request #42 from purcell/cleanup, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors d24ddc5 217/434: Default ECUKES_EMACS to $EMACS, ELPA Syncer, 2021/08/07