unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#3336: fill-individual-paragraphs recently created bug
@ 2009-05-20 11:40 Rory Mulvaney
  2009-05-20 18:38 ` Rory Mulvaney
  2011-09-17  5:46 ` Lars Magne Ingebrigtsen
  0 siblings, 2 replies; 9+ messages in thread
From: Rory Mulvaney @ 2009-05-20 11:40 UTC (permalink / raw)
  To: bug-gnu-emacs

Hello,

I use a system of indented note-taking where each separate note is a 
paragraph with a hanging indent of 1 space, and the whole paragraph is 
indented by some even number of spaces.  I frequently use indent-rigidly 
and fill-individual-paragraphs, in order to make the indentation right. 
When I recently upgraded to emacs22 this year, a bug was introduced in 
fill-individual-paragraphs, described here in a simple example:

In text fill mode with fill-column set at 78 (I think), repeat 12 blocks 
of 1234567890 like so, properly filled with a hanging indent of 1 space:

1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
  1234567890 1234567890 1234567890 1234567890 1234567890 1234567890

Then select the region given by that paragraph and call indent-rigidly 
with an argument of 4, to indent the whole thing, and then follow that up 
with an invocation of fill-individual-paragraphs, with that paragraph 
selected.  In my upgraded emacs, that improperly fills the paragraph.  If 
the simpler command fill-paragraph is used on the paragraph, it works 
correctly.  Obviously I don't want to call fill-paragraph a bunch of times 
when I want to fill many paragraphs at once, so this is a very annoying 
bug.  Fill-individual-paragraphs used to work correclty on the previous 
version of emacs (emacs21, I think) for Debian stable.

Thanks for any help with this,
Rory Mulvaney

some settings from report-emacs-bug:

In GNU Emacs 22.2.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
  of 2008-11-09 on raven, modified by Debian
Windowing system distributor `The X.Org Foundation', version 11.0.10402000
configured using `configure  '--build=i486-linux-gnu' 
'--host=i486-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' 
'--libexecdir=/usr/lib' '--localstatedir=/var/lib' 
'--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' 
'--enable-locallisppath=/etc/emacs22:/etc/emacs:/usr/local/share/emacs/22.2/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/22.2/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/22.2/leim' 
'--with-x=yes' '--with-x-toolkit=athena' '--with-toolkit-scroll-bars' 
'build_alias=i486-linux-gnu' 'host_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN 
-g -O2' 'LDFLAGS=-g' 'CPPFLAGS=''

Important settings:
   value of $LC_ALL: nil
   value of $LC_COLLATE: nil
   value of $LC_CTYPE: nil
   value of $LC_MESSAGES: nil
   value of $LC_MONETARY: nil
   value of $LC_NUMERIC: nil
   value of $LC_TIME: nil
   value of $LANG: C
   locale-coding-system: nil
   default-enable-multibyte-characters: t

Major mode: Text

Minor modes in effect:
   tooltip-mode: t
   mouse-wheel-mode: t
   menu-bar-mode: t
   file-name-shadow-mode: t
   global-font-lock-mode: t
   font-lock-mode: t
   unify-8859-on-encoding-mode: t
   utf-translate-cjk-mode: t
   auto-compression-mode: t
   column-number-mode: t
   line-number-mode: t
   transient-mark-mode: t








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

* bug#3336: fill-individual-paragraphs recently created bug
  2009-05-20 11:40 bug#3336: fill-individual-paragraphs recently created bug Rory Mulvaney
@ 2009-05-20 18:38 ` Rory Mulvaney
  2011-09-17  5:46 ` Lars Magne Ingebrigtsen
  1 sibling, 0 replies; 9+ messages in thread
From: Rory Mulvaney @ 2009-05-20 18:38 UTC (permalink / raw)
  To: 3336

Just checking on this bug I submitted about 6 hours ago, since I still 
don't see it appearing on the archive at 
http://lists.gnu.org/archive/html/bug-gnu-emacs/2009-05/index.html

Thanks,
Rory M.


On Wed, 20 May 2009, Rory Mulvaney wrote:

> Hello,
>
> I use a system of indented note-taking where each separate note is a 
> paragraph with a hanging indent of 1 space, and the whole paragraph is 
> indented by some even number of spaces.  I frequently use indent-rigidly and 
> fill-individual-paragraphs, in order to make the indentation right. When I 
> recently upgraded to emacs22 this year, a bug was introduced in 
> fill-individual-paragraphs, described here in a simple example:
>
> In text fill mode with fill-column set at 78 (I think), repeat 12 blocks of 
> 1234567890 like so, properly filled with a hanging indent of 1 space:
>
> 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
> 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
>
> Then select the region given by that paragraph and call indent-rigidly with 
> an argument of 4, to indent the whole thing, and then follow that up with an 
> invocation of fill-individual-paragraphs, with that paragraph selected.  In 
> my upgraded emacs, that improperly fills the paragraph.  If the simpler 
> command fill-paragraph is used on the paragraph, it works correctly. 
> Obviously I don't want to call fill-paragraph a bunch of times when I want to 
> fill many paragraphs at once, so this is a very annoying bug. 
> Fill-individual-paragraphs used to work correclty on the previous version of 
> emacs (emacs21, I think) for Debian stable.
>
> Thanks for any help with this,
> Rory Mulvaney
>
> some settings from report-emacs-bug:
>
> In GNU Emacs 22.2.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
> of 2008-11-09 on raven, modified by Debian
> Windowing system distributor `The X.Org Foundation', version 11.0.10402000
> configured using `configure  '--build=i486-linux-gnu' '--host=i486-linux-gnu' 
> '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' 
> '--localstatedir=/var/lib' '--infodir=/usr/share/info' 
> '--mandir=/usr/share/man' '--with-pop=yes' 
> '--enable-locallisppath=/etc/emacs22:/etc/emacs:/usr/local/share/emacs/22.2/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/22.2/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/22.2/leim' 
> '--with-x=yes' '--with-x-toolkit=athena' '--with-toolkit-scroll-bars' 
> 'build_alias=i486-linux-gnu' 'host_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN -g 
> -O2' 'LDFLAGS=-g' 'CPPFLAGS=''
>
> Important settings:
>  value of $LC_ALL: nil
>  value of $LC_COLLATE: nil
>  value of $LC_CTYPE: nil
>  value of $LC_MESSAGES: nil
>  value of $LC_MONETARY: nil
>  value of $LC_NUMERIC: nil
>  value of $LC_TIME: nil
>  value of $LANG: C
>  locale-coding-system: nil
>  default-enable-multibyte-characters: t
>
> Major mode: Text
>
> Minor modes in effect:
>  tooltip-mode: t
>  mouse-wheel-mode: t
>  menu-bar-mode: t
>  file-name-shadow-mode: t
>  global-font-lock-mode: t
>  font-lock-mode: t
>  unify-8859-on-encoding-mode: t
>  utf-translate-cjk-mode: t
>  auto-compression-mode: t
>  column-number-mode: t
>  line-number-mode: t
>  transient-mark-mode: t
>
>






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

* bug#3336: fill-individual-paragraphs recently created bug
  2009-05-20 11:40 bug#3336: fill-individual-paragraphs recently created bug Rory Mulvaney
  2009-05-20 18:38 ` Rory Mulvaney
@ 2011-09-17  5:46 ` Lars Magne Ingebrigtsen
  2011-09-22  4:37   ` Rory Mulvaney
  1 sibling, 1 reply; 9+ messages in thread
From: Lars Magne Ingebrigtsen @ 2011-09-17  5:46 UTC (permalink / raw)
  To: Rory Mulvaney; +Cc: 3336

Rory Mulvaney <rory1@umbc.edu> writes:

> In text fill mode with fill-column set at 78 (I think), repeat 12
> blocks of 1234567890 like so, properly filled with a hanging indent of
> 1 space:
>
> 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
>  1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
>
> Then select the region given by that paragraph and call indent-rigidly
> with an argument of 4, to indent the whole thing, and then follow that
> up with an invocation of fill-individual-paragraphs, with that
> paragraph selected.  In my upgraded emacs, that improperly fills the
> paragraph.  If the simpler command fill-paragraph is used on the
> paragraph, it works correctly.

So, you're saying that if you fill this:

     1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
      1234567890 1234567890 1234567890 1234567890 1234567890 1234567890

Then you get this:      

     1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
      1234567890 1234567890 1234567890 1234567890 1234567890
      1234567890

(Well, that's what I get when I follow your recipe.)

I don't think that's a bug, but perhaps I'm not seeing what you're
seeing?
      
-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/





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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-17  5:46 ` Lars Magne Ingebrigtsen
@ 2011-09-22  4:37   ` Rory Mulvaney
  2011-09-22  7:39     ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 9+ messages in thread
From: Rory Mulvaney @ 2011-09-22  4:37 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: 3336

On Sat, 17 Sep 2011, Lars Magne Ingebrigtsen wrote:

> Rory Mulvaney <rory1@umbc.edu> writes:
> 
> > In text fill mode with fill-column set at 78 (I think), repeat 12
> > blocks of 1234567890 like so, properly filled with a hanging indent of
> > 1 space:
> >
> > 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
> >  1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
> >
> > Then select the region given by that paragraph and call indent-rigidly
> > with an argument of 4, to indent the whole thing, and then follow that
> > up with an invocation of fill-individual-paragraphs, with that
> > paragraph selected.  In my upgraded emacs, that improperly fills the
> > paragraph.  If the simpler command fill-paragraph is used on the
> > paragraph, it works correctly.
> 
> So, you're saying that if you fill this:
> 
>      1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
>       1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
> 
> Then you get this:      
> 
>      1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
>       1234567890 1234567890 1234567890 1234567890 1234567890
>       1234567890
> 
> (Well, that's what I get when I follow your recipe.)
> 
> I don't think that's a bug, but perhaps I'm not seeing what you're
> seeing?

I think you just need to rigidly-indent it a little further before trying 
fill-individual-paragraphs.  First rigidly-indent it a little further 
(like 4 or 6 spaces), and then there is a difference between the action of 
fill-paragraph (works) and fill-individual-paragraphs (gives an odd 
result).

Thanks and regards,
Rory






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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-22  4:37   ` Rory Mulvaney
@ 2011-09-22  7:39     ` Lars Magne Ingebrigtsen
  2011-09-22 17:28       ` Glenn Morris
  2011-09-24  1:16       ` Rory Mulvaney
  0 siblings, 2 replies; 9+ messages in thread
From: Lars Magne Ingebrigtsen @ 2011-09-22  7:39 UTC (permalink / raw)
  To: Rory Mulvaney; +Cc: 3336

Rory Mulvaney <rory1@umbc.edu> writes:

> I think you just need to rigidly-indent it a little further before trying 
> fill-individual-paragraphs.  First rigidly-indent it a little further 
> (like 4 or 6 spaces), and then there is a difference between the action of 
> fill-paragraph (works) and fill-individual-paragraphs (gives an odd 
> result).

Can you give a precise test case that demonstrates this bug?

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





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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-22  7:39     ` Lars Magne Ingebrigtsen
@ 2011-09-22 17:28       ` Glenn Morris
  2011-09-24  1:16       ` Rory Mulvaney
  1 sibling, 0 replies; 9+ messages in thread
From: Glenn Morris @ 2011-09-22 17:28 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: Rory Mulvaney, 3336

[-- Attachment #1: Type: text/plain, Size: 288 bytes --]


Highlight all the text and call M-x fill-individual-paragraphs on the
attached file. It ends up looking like:

	1234567890 1234567890 1234567890 1234567890 1234567890
	1234567890
	 1234567890 1234567890 1234567890 1234567890 1234567890
	 1234567890

Last works in Emacs 21.4, it seems.


[-- Attachment #2: sample --]
[-- Type: text/plain, Size: 135 bytes --]

	1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
	 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890

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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-22  7:39     ` Lars Magne Ingebrigtsen
  2011-09-22 17:28       ` Glenn Morris
@ 2011-09-24  1:16       ` Rory Mulvaney
  2011-09-25 22:19         ` Lars Magne Ingebrigtsen
  1 sibling, 1 reply; 9+ messages in thread
From: Rory Mulvaney @ 2011-09-24  1:16 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: 3336

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1130 bytes --]

On Thu, 22 Sep 2011, Lars Magne Ingebrigtsen wrote:

> Rory Mulvaney <rory1@umbc.edu> writes:
> 
> > I think you just need to rigidly-indent it a little further before 
> > trying fill-individual-paragraphs.  First rigidly-indent it a little 
> > further (like 4 or 6 spaces), and then there is a difference between 
> > the action of fill-paragraph (works) and fill-individual-paragraphs 
> > (gives an odd result).
> 
> Can you give a precise test case that demonstrates this bug?
> 

Lars,

You are right that the way it was wrapped in my initial email (the wrap 
column for the email program is less than 78) that the initial text was 
not displaying correctly.  Actually if it is first filled with the 
fill-column set at 78, it appears as in the attached file text.txt 
(because there is still more room on the first line for a 7th block).

Then, if you rigidly indent it 4 spaces by selecting it followed by C-u 4 
M-x rigidly-indent, then fill it with fill-individual-paragraphs by 
selecting it and M-x fill-individual-paragraphs, it gives the weird 
result, in contrast to fill-paragraph.

I hope that clears it up,
Rory

[-- Attachment #2: Type: TEXT/PLAIN, Size: 135 bytes --]

1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
 1234567890 1234567890 1234567890 1234567890 1234567890

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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-24  1:16       ` Rory Mulvaney
@ 2011-09-25 22:19         ` Lars Magne Ingebrigtsen
  2016-01-24 16:19           ` Alan Third
  0 siblings, 1 reply; 9+ messages in thread
From: Lars Magne Ingebrigtsen @ 2011-09-25 22:19 UTC (permalink / raw)
  To: Rory Mulvaney; +Cc: 3336

Rory Mulvaney <rory1@umbc.edu> writes:

> Then, if you rigidly indent it 4 spaces by selecting it followed by C-u 4 
> M-x rigidly-indent, then fill it with fill-individual-paragraphs by 
> selecting it and M-x fill-individual-paragraphs, it gives the weird 
> result, in contrast to fill-paragraph.

Yeah, I'm able to reproduce this bug in Emacs 24 now.

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





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

* bug#3336: fill-individual-paragraphs recently created bug
  2011-09-25 22:19         ` Lars Magne Ingebrigtsen
@ 2016-01-24 16:19           ` Alan Third
  0 siblings, 0 replies; 9+ messages in thread
From: Alan Third @ 2016-01-24 16:19 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: Rory Mulvaney, 3336

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> Rory Mulvaney <rory1@umbc.edu> writes:
>
>> Then, if you rigidly indent it 4 spaces by selecting it followed by C-u 4 
>> M-x rigidly-indent, then fill it with fill-individual-paragraphs by 
>> selecting it and M-x fill-individual-paragraphs, it gives the weird 
>> result, in contrast to fill-paragraph.
>
> Yeah, I'm able to reproduce this bug in Emacs 24 now.

Using Emacs 25 I'm not sure if I can reproduce it.
fill-individual-paragraphs and fill-paragraph fill the paragraph(s)
differently, but they seem to me to be behaving as described in the
documentation.

fill-paragraph treats the two lines as a single paragraph.
fill-individual-paragraphs treats the lines as two different paragraphs,
as described in the docs.

-- 
Alan Third





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

end of thread, other threads:[~2016-01-24 16:19 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-20 11:40 bug#3336: fill-individual-paragraphs recently created bug Rory Mulvaney
2009-05-20 18:38 ` Rory Mulvaney
2011-09-17  5:46 ` Lars Magne Ingebrigtsen
2011-09-22  4:37   ` Rory Mulvaney
2011-09-22  7:39     ` Lars Magne Ingebrigtsen
2011-09-22 17:28       ` Glenn Morris
2011-09-24  1:16       ` Rory Mulvaney
2011-09-25 22:19         ` Lars Magne Ingebrigtsen
2016-01-24 16:19           ` Alan Third

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