[Top][All Lists]

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

Re: auto-fill mode in java-mode

From: Alan Mackenzie
Subject: Re: auto-fill mode in java-mode
Date: Mon, 13 Oct 2003 09:10:53 +0000
User-agent: tin/1.4.5-20010409 ("One More Nightmare") (UNIX) (Linux/2.0.35 (i686))

Adam Hardy <> wrote on Sun, 12 Oct 2003 00:07:00
> I'm trying to get my java-mode to wrap lines at 75 cols and I've not
> got it working.

What do you mean by "lines"?  In the CC Modes, only comments get
auto-filled by default.  Are your comment lines getting auto-filled?  Do
you also want code lines to get auto-filled?

If you want lines of code to get filled too, set the user option
c-ignore-auto-fill.  For example, in your mode hook add something like

(setq c-ignore-auto-fill '(cpp))

which will fill everything but preprocessor lines (do such exist in
Java?).  c-ignore-auto-fill is fully documented on the page "Text Filling
and Line Breaking" in the CC Mode info pages.

I'm not sure how useful the auto-filling is in lines other than comment

[ .... ]

> Thanks for any help.

Best of luck!  Come back again if the above doesn't help.

> Adam

> -- 
> GNU Emacs 21.3.1 on Linux 2.4.20 RH9

Alan Mackenzie (Munich, Germany)
Email: aacm@muuc.dee; to decode, wherever there is a repeated letter
(like "aa"), remove half of them (leaving, say, "a").

reply via email to

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