help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: hanging paragraph within lisp comments


From: Stefan Monnier
Subject: Re: hanging paragraph within lisp comments
Date: Wed, 11 Feb 2004 20:17:10 GMT
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

> Anybody has code to reformat this:

> ;; (1) Defines most of Emacs's file- and directory-handling
> ;; functions, including basic file visiting, backup generation,
> ;; link handling, ITS-id version control, load- and write-hook
> ;; handling, and the like.

> into this:

> ;; (1) Defines most of Emacs's file- and directory-handling
> ;;     functions, including basic file visiting, backup generation,
> ;;     link handling, ITS-id version control, load- and write-hook
> ;;     handling, and the like.

No, I don't.  But I have something close (as a patch to fill.el).
It can wrap

 ;; (1) foo bar baz

to

 ;; (1) foo bar
 ;;     baz

during auto-fill and will preserve the indentation-in-comment during
fill-paragraph.  But it will preserve the original indentation of the second
line (just as the current fill.el always does) so it will not do exactly
what you asked for.

All of the above is "modulo bugs and misfeatures" as always: filling is
tricky business where an important part is to make sure you recognize
paragraph boundaries correctly.


        Stefan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]