Absolutely true.  M-q works nicely.  But my fingers are slim and shapely;
they don't really need the extra exercise.  {I can always use vi, if I need
a good finger work out.} ;)

 Paul is also absolutely right that cc-mode controls comment indenting, I
must have actually read that auto-fill-mode stuff about cc-mode.

Any how, I found the source of my problem. As explained here
http://cc-mode.sourceforge.net/filladapt.php , it turns out that filladapt
needed a patch applied,  and 'c-setup-filladapt had to be called.
Everything worked perfectly after that.

I also have this keybinding in my jde mode hook

  (define-key c-mode-base-map [(return)] '(lambda ()
                                            (interactive)
                                            (c-indent-command)
                                            (c-context-line-break)
                                            ))

Now 'return' actually starts a new line of comment when you're in a block
comment.  Woo hoo!

If anyone is interested in similar auto-fill-mode setup for comments for all
other languages, I strongly urge you to check out tmmofl at
http://www.cs.man.ac.uk/~phillord/applications/emacs/emacs-packages.html .

Thanks for all your help.

regards,
-lw


""Daniel Hegyi"" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Have you tried Filladapt?
>
> http://www.wonderworks.com/download/filladapt.el
>
> It is very cool for doing M-q on javadoc comments: it doesn't break the
> comment structure.
>
> Regards,
> Daniel
>
>
> >From: Paul Kinnucan <[EMAIL PROTECTED]>
> >To: "Le Wang" <[EMAIL PROTECTED]>
> >CC: [EMAIL PROTECTED]
> >Subject: auto-fill mode really works?
> >Date: Mon, 17 Dec 2001 23:20:34 -0500
> >
> >Le Wang writes:
> >  > Hi,
> >  >
> >  > I know JDE is supposed to work nicely with auto-fill mode now, but
I'm
> >not
> >  > seeing this with XEmacs 21.4.5.  I'm using the latest libraries and
JDE
> >  > 2.2.9beta7.  Everything freshly installed.  I'm using Solaris 8, and
> >  > Cygwin+XP.
> >  >
> >  > When I turn on auto-fill, it's true that my code does not wrap as I
> >type.
> >  > But I can't get comments (/** or /*) to fill properly either (i.e.
with
> >" *
> >  > " at the beginning of each line).  The first filled line will usually
> >be
> >  > auto-filled properly, but the subsequent lines won't; and sometimes
the
> >text
> >  > is not even lined up.
> >  >
> >  > Is this feature actually working nicely for anyone?
> >  >
> >
> >I've never gotten "autofill" (autoindentation?) to work properly on
> >comments. Since cc-mode handles indentation of Java source files,
> >include jde-mode, which extends but does not modify cc-mode, I have
> >assumed that the problem is with cc-mode. You could easily verify this
> >by temporarily commenting out the JDE in your .emacs file, loading a
> >Java file, and trying to indent a comment block. If Emacs indents the
> >comments correctly, then the problem is with cc-mode and you
> >should send a bug report to the Emacs maintainers, using
> >the Help->Send Bug Report command. If not, send a bug report to me
> >and I will try to reproduce and debug the problem.
> >
> >- Paul
> >
>
>
>
>
> _________________________________________________________________
> Join the world's largest e-mail service with MSN Hotmail.
> http://www.hotmail.com
>


Reply via email to