unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET
@ 2021-02-04 14:43 Tomas Nordin
  2021-02-04 15:35 ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Tomas Nordin @ 2021-02-04 14:43 UTC (permalink / raw)
  To: 46296

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))





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET
  2021-02-04 14:43 bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET Tomas Nordin
@ 2021-02-04 15:35 ` Eli Zaretskii
  2021-02-05 10:00   ` Lars Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2021-02-04 15:35 UTC (permalink / raw)
  To: Tomas Nordin; +Cc: 46296

> From: Tomas Nordin <tomasn@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.





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET
  2021-02-04 15:35 ` Eli Zaretskii
@ 2021-02-05 10:00   ` Lars Ingebrigtsen
  2021-02-05 18:45     ` Tomas Nordin
  0 siblings, 1 reply; 5+ messages in thread
From: Lars Ingebrigtsen @ 2021-02-05 10:00 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Tomas Nordin, 46296

Eli Zaretskii <eliz@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





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET
  2021-02-05 10:00   ` Lars Ingebrigtsen
@ 2021-02-05 18:45     ` Tomas Nordin
  2021-02-06 10:47       ` Lars Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Tomas Nordin @ 2021-02-05 18:45 UTC (permalink / raw)
  To: Lars Ingebrigtsen, Eli Zaretskii; +Cc: 46296

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Eli Zaretskii <eliz@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





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET
  2021-02-05 18:45     ` Tomas Nordin
@ 2021-02-06 10:47       ` Lars Ingebrigtsen
  0 siblings, 0 replies; 5+ messages in thread
From: Lars Ingebrigtsen @ 2021-02-06 10:47 UTC (permalink / raw)
  To: Tomas Nordin; +Cc: 46296

Tomas Nordin <tomasn@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





^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-02-06 10:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-04 14:43 bug#46296: 28.0.50; indent-rigidly inserts newline when exiting with RET Tomas Nordin
2021-02-04 15:35 ` Eli Zaretskii
2021-02-05 10:00   ` Lars Ingebrigtsen
2021-02-05 18:45     ` Tomas Nordin
2021-02-06 10:47       ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).