[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/multiple-cursors 9938aca 028/434: Save er/history for each
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/multiple-cursors 9938aca 028/434: Save er/history for each cursor, to be able to contract. |
Date: |
Sat, 7 Aug 2021 09:19:48 -0400 (EDT) |
branch: elpa/multiple-cursors
commit 9938acaf7136dc85a8c9b5d6b6f85a2ee35cc4c2
Author: Magnar Sveen <magnars@gmail.com>
Commit: Magnar Sveen <magnars@gmail.com>
Save er/history for each cursor, to be able to contract.
---
multiple-cursors.el | 6 +++++-
todo.org | 12 +++++++++---
2 files changed, 14 insertions(+), 4 deletions(-)
diff --git a/multiple-cursors.el b/multiple-cursors.el
index 7148f6b..6cad9e0 100644
--- a/multiple-cursors.el
+++ b/multiple-cursors.el
@@ -119,6 +119,7 @@ Also makes a copy of the kill-ring to be used by this
cursor."
(overlay-put overlay 'mark-ring mark-ring)
(overlay-put overlay 'mark-active mark-active)
(overlay-put overlay 'mark (set-marker (make-marker) (mark)))
+ (overlay-put overlay 'er/history er/history)
(when (use-region-p)
(overlay-put overlay 'region-overlay
(mc/make-region-overlay-between-point-and-mark)))
@@ -133,6 +134,7 @@ cursor with updated info."
(let ((current-kill-ring kill-ring)
(current-mark-ring mark-ring)
(current-mark-active mark-active)
+ (current-er/history er/history)
(annoying-arrows-mode nil))
(save-excursion
(mapc #'(lambda (o)
@@ -143,6 +145,7 @@ cursor with updated info."
(set-marker (overlay-get o 'mark) nil)
(setq mark-ring (overlay-get o 'mark-ring))
(setq mark-active (overlay-get o 'mark-active))
+ (setq er/history (overlay-get o 'er/history))
(delete-region-overlay o)
(delete-overlay o)
(ignore-errors
@@ -152,7 +155,8 @@ cursor with updated info."
(overlays-in (point-min) (point-max))))
(setq kill-ring current-kill-ring)
(setq mark-ring current-mark-ring)
- (setq mark-active current-mark-active)))
+ (setq mark-active current-mark-active)
+ (setq er/history current-er/history)))
(defun delete-region-overlay (o)
(ignore-errors
diff --git a/todo.org b/todo.org
index 86b2b8e..c8f4ef4 100644
--- a/todo.org
+++ b/todo.org
@@ -1,10 +1,16 @@
-* TODO: [2/8]
+* TODO: [3/9]
** DONE (set-marker MARKER nil) for performance
** DONE C-g deactivates regions first, before disabling multiple-cursors
-** TODO remove mark-multiple integration
+** DONE more state to save per cursor: er/history
** TODO refactor
an object with all the current state, used for both overlays and current
** TODO add tests
-** TODO more state to save per cursor: er/history
** TODO collapse cursors at same point
** TODO unknown command: (t)ry all or (i)gnore -> (did that work ok? (k)eep
doing that or (d)on't)
+** TODO separate mark-multiple and multiple-cursors
+ mark-multiple goes back to being the util? or just dies?
+ given the problem with extract-var and undo, may just kill mark-multiple.
+ problem with that is: C-g when doing rename-tag shouldn't go to
multiple-cursors.
+
+** TODO there's something going wrong with last-command/this-command?
+ expand-region works nicely, even collapse when we save er/history, but last
collapse puts all cursors in same spot
- [nongnu] elpa/multiple-cursors b28e8f9 023/434: Update test to fix missing step definition., (continued)
- [nongnu] elpa/multiple-cursors b28e8f9 023/434: Update test to fix missing step definition., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors a682c15 027/434: Disable regions first with C-g, then multiple-cursors., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 13668a9 001/434: initial commit, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors c18aa84 002/434: Separate kill-ring for each cursor., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 0d40ea1 003/434: Updated readme., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 18f7f1a 010/434: More white-listed commands for multiple cursors., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors cf82088 014/434: Add backward-list to white-list., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 26d0e52 015/434: Add more commands to white-list., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 5e64246 025/434: Move todo to own file., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors e0ffd9c 026/434: Disable marker when done with it, for performance reasons., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 9938aca 028/434: Save er/history for each cursor, to be able to contract.,
ELPA Syncer <=
- [nongnu] elpa/multiple-cursors dfe8a2d 029/434: Slight optimisation, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 6c0e16e 033/434: More things to do., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 07a4411 036/434: More things to do., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 75581da 037/434: Fix bug with expand-region dependency., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 8d49171 039/434: Update todo, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 80fdb6f 007/434: Hook multiple-cursors into mark-multiple, first step:, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 9182897 046/434: Add message about delete-char vs delete-forward-char, ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors c34e4df 064/434: Don't grow cursor overlays., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors 382616a 020/434: Don't get annoyed so easily at multiple cursors., ELPA Syncer, 2021/08/07
- [nongnu] elpa/multiple-cursors b99d54a 047/434: Fix error message., ELPA Syncer, 2021/08/07