GNU bug report logs - #46296
28.0.50; indent-rigidly inserts newline when exiting with RET

Previous Next

Package: emacs;

Reported by: Tomas Nordin <tomasn <at> posteo.net>

Date: Thu, 4 Feb 2021 14:45:01 UTC

Severity: normal

Tags: fixed

Found in version 28.0.50

Fixed in versions 28.1, 27.2

Done: Lars Ingebrigtsen <larsi <at> gnus.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 46296 in the body.
You can then email your comments to 46296 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#46296; Package emacs. (Thu, 04 Feb 2021 14:45:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Tomas Nordin <tomasn <at> posteo.net>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 04 Feb 2021 14:45:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Tomas Nordin <tomasn <at> posteo.net>
To: bug-gnu-emacs <at> gnu.org
Subject: 28.0.50; indent-rigidly inserts newline when exiting with RET
Date: Thu, 04 Feb 2021 15:43:23 +0100
emacs -Q /tmp/indent.me

Insert the following

wording1
wording2

Move point to beginning of wording1, C-SPC, move to end of wording2. Say
C-x TAB, hit <right> two times or something, RET. A newline is
inserted. The doc of 'indent-rigidly' gives me the impression that any
key other than <left> and friends should just exit the mode.

Seems like a bug to me but I am not sure.

Best regards
--
Tomas

In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.5, cairo version 1.16.0)
 of 2021-01-10 built on fliptop
Repository revision: 7252082bda459d9b18e7c148832fe17a1e485aaa
Repository branch: tomnor
Windowing system distributor 'The X.Org Foundation', version 11.0.12004000
System Description: Debian GNU/Linux 10 (buster)

Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF
ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS PDUMPER LCMS2

Important settings:
  value of $LC_TIME: sv_SE.UTF-8
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Nroff

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml easymenu mml-sec epa derived epg epg-config gnus-util rmail
rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json map text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
nroff-mode iso-transl tooltip eldoc electric uniquify ediff-hook
vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd
tool-bar dnd fontset image regexp-opt fringe tabulated-list replace
newcomment text-mode elisp-mode lisp-mode prog-mode register page
tab-bar menu-bar rfn-eshadow isearch timer select scroll-bar mouse
jit-lock font-lock syntax facemenu font-core term/tty-colors frame
minibuffer cl-generic cham georgian utf-8-lang misc-lang vietnamese
tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek
romanian slovak czech european ethiopic indian cyrillic chinese
composite charscript charprop case-table epa-hook jka-cmpr-hook help
simple abbrev obarray cl-preloaded nadvice button loaddefs faces
cus-face macroexp files window text-properties overlay sha1 md5 base64
format env code-pages mule custom widget hashtable-print-readable
backquote threads dbusbind inotify lcms2 dynamic-setting
system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit
x multi-tty make-network-process emacs)

Memory information:
((conses 16 51428 9167)
 (symbols 48 6839 1)
 (strings 32 18567 1707)
 (string-bytes 1 610042)
 (vectors 16 11526)
 (vector-slots 8 164596 8739)
 (floats 8 21 51)
 (intervals 56 191 0)
 (buffers 984 11))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#46296; Package emacs. (Thu, 04 Feb 2021 15:36:02 GMT) Full text and rfc822 format available.

Message #8 received at 46296 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Tomas Nordin <tomasn <at> posteo.net>
Cc: 46296 <at> debbugs.gnu.org
Subject: Re: bug#46296: 28.0.50;
 indent-rigidly inserts newline when exiting with RET
Date: Thu, 04 Feb 2021 17:35:00 +0200
> From: Tomas Nordin <tomasn <at> posteo.net>
> Date: Thu, 04 Feb 2021 15:43:23 +0100
> 
> emacs -Q /tmp/indent.me
> 
> Insert the following
> 
> wording1
> wording2
> 
> Move point to beginning of wording1, C-SPC, move to end of wording2. Say
> C-x TAB, hit <right> two times or something, RET. A newline is
> inserted. The doc of 'indent-rigidly' gives me the impression that any
> key other than <left> and friends should just exit the mode.
> 
> Seems like a bug to me but I am not sure.

I think it's a documentation bug.  The manual says:

  Typing any other key disables the transient mode, and resumes normal
  editing.                                          ^^^^^^^^^^^^^^^^^^
  ^^^^^^^

So I think this means that any other character terminates the mode and
is acted upon.  We can clarify this in the docs.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#46296; Package emacs. (Fri, 05 Feb 2021 10:01:02 GMT) Full text and rfc822 format available.

Message #11 received at 46296 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: Tomas Nordin <tomasn <at> posteo.net>, 46296 <at> debbugs.gnu.org
Subject: Re: bug#46296: 28.0.50; indent-rigidly inserts newline when exiting
 with RET
Date: Fri, 05 Feb 2021 11:00:36 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

> I think it's a documentation bug.  The manual says:
>
>   Typing any other key disables the transient mode, and resumes normal
>   editing.                                          ^^^^^^^^^^^^^^^^^^
>   ^^^^^^^
>
> So I think this means that any other character terminates the mode and
> is acted upon.  We can clarify this in the docs.

Yup.  I've now pushed a slight clarification to Emacs 27.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) fixed. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Fri, 05 Feb 2021 10:01:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 28.1, send any further explanations to 46296 <at> debbugs.gnu.org and Tomas Nordin <tomasn <at> posteo.net> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Fri, 05 Feb 2021 10:01:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 27.2, send any further explanations to 46296 <at> debbugs.gnu.org and Tomas Nordin <tomasn <at> posteo.net> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Fri, 05 Feb 2021 10:02:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#46296; Package emacs. (Fri, 05 Feb 2021 18:46:02 GMT) Full text and rfc822 format available.

Message #20 received at 46296 <at> debbugs.gnu.org (full text, mbox):

From: Tomas Nordin <tomasn <at> posteo.net>
To: Lars Ingebrigtsen <larsi <at> gnus.org>, Eli Zaretskii <eliz <at> gnu.org>
Cc: 46296 <at> debbugs.gnu.org
Subject: Re: bug#46296: 28.0.50; indent-rigidly inserts newline when exiting
 with RET
Date: Fri, 05 Feb 2021 19:45:45 +0100
Lars Ingebrigtsen <larsi <at> gnus.org> writes:

> Eli Zaretskii <eliz <at> gnu.org> writes:
>
>> I think it's a documentation bug.  The manual says:
>>
>>   Typing any other key disables the transient mode, and resumes normal
>>   editing.                                          ^^^^^^^^^^^^^^^^^^
>>   ^^^^^^^
>>
>> So I think this means that any other character terminates the mode and
>> is acted upon.  We can clarify this in the docs.
>
> Yup.  I've now pushed a slight clarification to Emacs 27.

Cool, I saw it. But the function doc string was not touched? Maybe
that's often the first look-up for docs one does.

So this was a documentation bug. Is it only me who thinks a behavior
more like string-rectangle is expected with indent-rigidly? I think it
is a little surprising when a newline is inserted at exit.

--
Tomas




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#46296; Package emacs. (Sat, 06 Feb 2021 10:49:01 GMT) Full text and rfc822 format available.

Message #23 received at 46296 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Tomas Nordin <tomasn <at> posteo.net>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 46296 <at> debbugs.gnu.org
Subject: Re: bug#46296: 28.0.50; indent-rigidly inserts newline when exiting
 with RET
Date: Sat, 06 Feb 2021 11:47:59 +0100
Tomas Nordin <tomasn <at> posteo.net> writes:

> Cool, I saw it. But the function doc string was not touched? Maybe
> that's often the first look-up for docs one does.

OK, I've now added this to the doc string, too.

> So this was a documentation bug. Is it only me who thinks a behavior
> more like string-rectangle is expected with indent-rigidly? I think it
> is a little surprising when a newline is inserted at exit.

You can use other (non-inserting) keys to exit the mode.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 06 Mar 2021 12:24:09 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 43 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.