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

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

Re: 'smart' indentation


From: Kai Großjohann
Subject: Re: 'smart' indentation
Date: Mon, 10 Mar 2003 15:01:28 +0100
User-agent: Gnus/5.090016 (Oort Gnus v0.16) Emacs/21.3.50 (gnu/linux)

Michael Powe <michael@trollope.org> writes:

> i would like to have 'smart' indentation, à la some editors i use like
> textpad.

Compared with Emacs standards, that indentation is rather dumb...

> if i indent a line, then when i press enter at the end of the line,
> i want point to go to the indented position on the following line.

On the new line, invoke M-x indent-relative RET.  I like to use that
in text mode a lot, so I do (define-key text-mode-map (kbd "RET")
'indent-relative) in my ~/.emacs file.


Usually, Emacs does syntax-driven indentation.  This means that it
groks the syntax of your programming language and then uses the right
indentation level.
-- 
A preposition is not a good thing to end a sentence with.


reply via email to

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