[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/speedrect c47e5e4e7b 43/90: move commands: use rectangl
From: |
ELPA Syncer |
Subject: |
[elpa] externals/speedrect c47e5e4e7b 43/90: move commands: use rectangle-right/next-line |
Date: |
Fri, 6 Dec 2024 18:59:13 -0500 (EST) |
branch: externals/speedrect
commit c47e5e4e7bb398dba5d245a1b396f234c0d724da
Author: JD Smith <93749+jdtsmith@users.noreply.github.com>
Commit: JD Smith <93749+jdtsmith@users.noreply.github.com>
move commands: use rectangle-right/next-line
---
speedrect.el | 19 +++++++------------
1 file changed, 7 insertions(+), 12 deletions(-)
diff --git a/speedrect.el b/speedrect.el
index 3227b1d267..555d85e96a 100644
--- a/speedrect.el
+++ b/speedrect.el
@@ -80,13 +80,11 @@ rect and exit `rectangle-mark-mode'."
Note that point and mark will not move beyond the end of text on their lines."
(interactive "P")
(let ((p (point))
- (pcol (current-column))
- (columns (or columns 1))
- (mcol (progn (goto-char (mark)) (current-column))))
- (move-to-column (max 0 (+ mcol columns)))
+ (columns (or columns 1)))
+ (rectangle-right-char columns)
(set-mark (point))
(goto-char p)
- (move-to-column (max 0 (+ pcol columns)))))
+ (rectangle-right-char columns)))
(defun speedrect-shift-right-fast (columns)
"Shift the current speedrect left by COLUMNS (default 5)."
@@ -107,15 +105,12 @@ Note that point and mark will not move beyond the end of
text on their lines."
"Shift rectangle down by LINES."
(interactive "P")
(let ((p (point))
- (pcol (current-column))
- (lines (or lines 1))
- (mcol (progn (goto-char (mark)) (current-column))))
- (forward-line lines)
- (move-to-column mcol)
+ (lines (or lines 1)))
+ (goto-char (mark))
+ (rectangle-next-line lines)
(set-mark (point))
(goto-char p)
- (forward-line lines)
- (move-to-column pcol)))
+ (rectangle-next-line lines)))
(defun speedrect-shift-down-fast (lines)
"Shift the current speedrect down by LINES (default 5)."
- [elpa] externals/speedrect 94d6c643cb 51/90: README: improve calc section, (continued)
- [elpa] externals/speedrect 94d6c643cb 51/90: README: improve calc section, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 3120746026 56/90: Update README.md, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect e37d89acc6 63/90: wrap-command: ensure buffer is restored on re-running command, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 94c125f60f 68/90: fill-text: use height of rect as line count limit, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 5da3d70805 74/90: delete-rest: save rectangle after command, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 16e79924ed 82/90: Prepare for ELPA, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 2782b03be2 38/90: Update README.md, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 7390122e49 75/90: calc-grab: improve with calc-top, avoid brackets/truncation, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 4b79f0109d 88/90: README: document new `speedrect-mode' config, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 43a89af9f7 52/90: allow rectangle-mark-mode-hook to operate on continue, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect c47e5e4e7b 43/90: move commands: use rectangle-right/next-line,
ELPA Syncer <=
- [elpa] externals/speedrect 6363a7ba6d 47/90: yank-rectangle-dwim: exchange point and mark before yank if needed, ELPA Syncer, 2024/12/06
- [elpa] externals/speedrect 9be7569c70 70/90: shift-right: use rectangle point-mark exchange for line ends, ELPA Syncer, 2024/12/06