Bozhidar Batsov over at Emacs Redux has another post up in his series on features of the upcoming Emacs 24.4. This time, he writes about Emacs Auto-indentation. The feature was added in Emacs 24.1 but in version 24.4 it’s enabled by default and there are, apparently, some additional improvements.
As Batsov remarks, sometimes electric-indent-mode
doesn’t play nicely with some other (usually third party) packages. Happily, Emacs 24.4 now has electric-indent-local-mode
, which allows you to turn off electric-indent-mode for individual buffers. Thus, all one need do is
(add-hook 'some-package (lambda () (electric-indent-local-mode -1)))
for each some-package
that has problems with electric-indent-mode
. It’s a nice feature to be able to disable a global mode for individual buffers.
I’m really enjoying Batsov’s posts on the new features and look forward reading more.
Update: Dmitry Gutov has a great follow on post that explores electric-indent-mode in Emacs 24.4 a bit further.