[Top][All Lists]

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

Re: auto-fill mode in java-mode

From: Adam Hardy
Subject: Re: auto-fill mode in java-mode
Date: Sat, 18 Oct 2003 19:15:41 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20030925

On 10/17/2003 04:49 PM Stefan Monnier wrote:
If you think about it, auto-fill with reindentation would be complicated -
The Java code could be filled, then reindented, causing it to spill over
the right margin, requiring re-filling, then reindentation, .....  It
would probably end up looking like an Outlook-Express Usenet posting.  :-(

It's not that bad: you only re-indent the second line, so there is no
circularity and things end just fine.  If it doesn't work, it's only
because nobody coded it up or because there's a bug.

The indentation works if you want the line to rewrap to the point where the line above starts, but in java that's rarely the case.

As someone in the thread said earlier, auto-filling java code is a pretty unusual thing to want to do.

Although it is true that auto-fill will break and wrap my line of java, and not indent the new line to where it should be, this is in fact a minor issue since I mostly want to choose where in the original line the line-break should go, manually, but auto-fill automatically takes the previous white space.

I realise now that my issue here is that it would actually be preferable to have emacs just stop taking input beyond line 72 - and beep instead. Or perhaps color the text red, because I can imagine situations where I can't break the line.

Is anything like that possible?

Actually is 72 the standard email line length? As I said earlier, my requirement is to have all the code easily emailable without being rewrapped by the email software.


GNU Emacs 21.3.1 on Linux 2.4.20 RH9

reply via email to

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