GNU bug report logs -
#25773
25.2; movement w/ prefix args in rectangle-mark-mode
Previous Next
Reported by: charles <at> aurox.ch (Charles A. Roelli)
Date: Fri, 17 Feb 2017 13:56:01 UTC
Severity: normal
Found in version 25.2
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 25773 in the body.
You can then email your comments to 25773 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#25773
; Package
emacs
.
(Fri, 17 Feb 2017 13:56:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
charles <at> aurox.ch (Charles A. Roelli)
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Fri, 17 Feb 2017 13:56:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From emacs -Q:
- C-u 2 C-p
- C-x SPC
- C-u C-f
Emacs hangs before point can move, and you can exit the hang with enough
C-g's. C-f works fine without a prefix arg, however.
In GNU Emacs 25.2.1 (x86_64-apple-darwin10.8.0, NS appkit-1038.36 Version 10.6.8 (Build 10K549))
of 2017-02-07 built on gray
Windowing system distributor 'Apple', version 10.3.1038
Configured using:
'configure --with-modules'
Configured features:
JPEG RSVG NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS MODULES
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#25773
; Package
emacs
.
(Fri, 17 Feb 2017 15:01:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 25773 <at> debbugs.gnu.org (full text, mbox):
> From: charles <at> aurox.ch (Charles A. Roelli)
> Date: Fri, 17 Feb 2017 14:55:32 +0100
>
> >From emacs -Q:
>
> - C-u 2 C-p
> - C-x SPC
> - C-u C-f
>
> Emacs hangs before point can move, and you can exit the hang with enough
> C-g's. C-f works fine without a prefix arg, however.
(It also works with a prefix arg, as long as the arg is 1.)
Does the patch below give good results? (I myself am not much of a
rectangle-mode user.)
Thanks.
diff --git a/lisp/rect.el b/lisp/rect.el
index a4fa282..a85101f 100644
--- a/lisp/rect.el
+++ b/lisp/rect.el
@@ -639,7 +639,8 @@ rectangle--*-char
;; rectangles" and not "visual rectangles", so in the presence of
;; bidirectional text things won't work well anyway.
(if (< n 0) (rectangle--*-char other-cmd (- n))
- (let ((col (rectangle--point-col (point))))
+ (let ((col (rectangle--point-col (point)))
+ (step 1))
(while (> n 0)
(let* ((bol (line-beginning-position))
(eol (line-end-position))
@@ -647,7 +648,7 @@ rectangle--*-char
(nextcol
(condition-case nil
(save-excursion
- (funcall cmd 1)
+ (funcall cmd step)
(cond
((> bol (point)) (- curcol 1))
((< eol (point)) (+ col (1+ n)))
@@ -666,7 +667,8 @@ rectangle--*-char
(t ;; (> nextcol curcol)
(if (<= diff n)
(progn (cl-decf n diff) (setq col nextcol))
- (setq col (if (< col nextcol) (+ col n) (- col n)) n 0))))))
+ (setq col (if (< col nextcol) (+ col n) (- col n)) n 0))))
+ (setq step (1+ step))))
;; FIXME: This rectangle--col-pos's move-to-column is wasted!
(rectangle--col-pos col 'point))))
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#25773
; Package
emacs
.
(Fri, 17 Feb 2017 16:41:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 25773 <at> debbugs.gnu.org (full text, mbox):
The patch fixes the problem. Thank you.
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Sat, 18 Feb 2017 09:34:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
charles <at> aurox.ch (Charles A. Roelli)
:
bug acknowledged by developer.
(Sat, 18 Feb 2017 09:34:01 GMT)
Full text and
rfc822 format available.
Message #16 received at 25773-done <at> debbugs.gnu.org (full text, mbox):
> From: charles <at> aurox.ch (Charles A. Roelli)
> Cc: 25773 <at> debbugs.gnu.org
> Date: Fri, 17 Feb 2017 17:39:55 +0100
>
> The patch fixes the problem. Thank you.
Thanks, pushed to the master branch.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 18 Mar 2017 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 8 years and 156 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.