GNU bug report logs -
#25374
align command can't use align-region-separate interactively
Previous Next
Reported by: John Wiegley <jwiegley <at> gmail.com>
Date: Fri, 6 Jan 2017 07:25:02 UTC
Severity: minor
Tags: moreinfo, wontfix
Found in version 25.1.91
Done: Glenn Morris <rgm <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 25374 in the body.
You can then email your comments to 25374 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#25374
; Package
emacs
.
(Fri, 06 Jan 2017 07:25:03 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
John Wiegley <jwiegley <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Fri, 06 Jan 2017 07:25:03 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From: Le Wang <l26wang <at> gmail.com>
It doesn't look right to me that auto region selection is not
accessible interactively. The interactive "r" form is quite broken,
so you may want to fix it in other interactive forms as well. Unless
there is a good reason you left it this way?
diff -u -b -B c\:/emacs/emacs-23.3/lisp/align.el
c\:/Users/Le/cygwin_home/tmp/align_region_patch.el
--- c:/emacs/emacs-23.3/lisp/align.el 2011-01-08 12:45:14.000000000 +0800
+++ c:/Users/Le/cygwin_home/tmp/align_region_patch.el 2011-08-28
00:39:51.336490900 +0800
@@ -857,11 +857,11 @@
;;;###autoload
(defun align (beg end &optional separate rules exclude-rules)
"Attempt to align a region based on a set of alignment rules.
-BEG and END mark the region. If BEG and END are specifically set to
-nil (this can only be done programmatically), the beginning and end of
-the current alignment section will be calculated based on the location
-of point, and the value of `align-region-separate' (or possibly each
-rule's `separate' attribute).
+BEG and END mark the region. If no region is active, the
+beginning and end of the current alignment section will be
+calculated based on the location of point, and the value of
+`align-region-separate' (or possibly each rule's `separate'
+attribute).
If SEPARATE is non-nil, it overrides the value of
`align-region-separate' for all rules, except those that have their
@@ -871,7 +871,9 @@
default rule lists defined in `align-rules-list' and
`align-exclude-rules-list'. See `align-rules-list' for more details
on the format of these lists."
- (interactive "r")
+ (interactive (if (use-region-p)
+ (list (region-beginning) (region-end))
+ (list nil nil)))
(let ((separator
(or separate
(if (and (symbolp align-region-separate)
--
John Wiegley GPG fingerprint = 4710 CF98 AF9B 327B B80F
http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#25374
; Package
emacs
.
(Fri, 06 Jan 2017 08:03:02 GMT)
Full text and
rfc822 format available.
Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):
> From: John Wiegley <jwiegley <at> gmail.com>
> Date: Sun, 28 Aug 2011 00:51:56 +0800 (5 years, 18 weeks, 6 days ago)
>
> From: Le Wang <l26wang <at> gmail.com>
>
> It doesn't look right to me that auto region selection is not
> accessible interactively. The interactive "r" form is quite broken,
> so you may want to fix it in other interactive forms as well. Unless
> there is a good reason you left it this way?
Sorry, I don't think I understand this part. Please elaborate what is
broken in the interactive "r" form.
> - (interactive "r")
> + (interactive (if (use-region-p)
> + (list (region-beginning) (region-end))
> + (list nil nil)))
This is not an equivalent change: the previous code would use the
region even if it was not active (i.e. transient-mark-mode is off),
the new code will think there's no region in that case.
Changed bug title to 'align command can't use align-region-separate interactively' from '25.1.91; bug'
Request was from
npostavs <at> users.sourceforge.net
to
control <at> debbugs.gnu.org
.
(Fri, 06 Jan 2017 13:42:01 GMT)
Full text and
rfc822 format available.
Added tag(s) moreinfo.
Request was from
npostavs <at> users.sourceforge.net
to
control <at> debbugs.gnu.org
.
(Fri, 06 Jan 2017 13:42:01 GMT)
Full text and
rfc822 format available.
Added tag(s) wontfix.
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> debbugs.gnu.org
.
(Tue, 08 Jan 2019 19:47:02 GMT)
Full text and
rfc822 format available.
bug closed, send any further explanations to
25374 <at> debbugs.gnu.org and John Wiegley <jwiegley <at> gmail.com>
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> debbugs.gnu.org
.
(Tue, 08 Jan 2019 19:47:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Wed, 06 Feb 2019 12:24:15 GMT)
Full text and
rfc822 format available.
This bug report was last modified 5 years and 52 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.