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

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

RE: Auto-indentation


From: Ludwig, Mark
Subject: RE: Auto-indentation
Date: Sat, 21 Apr 2012 22:38:17 +0000

> From: Richard H Lee
> Sent: Saturday, April 21, 2012 8:52 AM
> To: help-gnu-emacs@gnu.org
> Subject: Re: Auto-indentation
> 
> On 21/04/12 13:58, Richard H Lee wrote:
> > c-offsets-alist to nil
> 
> I still had problems.
> 
> c-syntactic-indentation did the trick

If this is all you need to do, great.  To fit existing code I maintain, I found 
I needed to extensively customize c-offsets-list, but also others such as 
c-basic-offset and c-comment-only-line-offset; the easiest way to do it all 
together is to create your own "style" and add it using c-add-style.

(I did this so I can impress my colleagues by positioning point in front of the 
opening brace of an entire C function or Java method and press C-M-q.)

Cheers,
Mark




reply via email to

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