In emacs, it is possible to start a file off with a line this:
/* -*- mode: java; c-basic-offset: 4; indent-tabs-mode: nil -*- */
This instructs emacs to use 4 spaces for indentation. I like the idea of storing this coding style meta-information directly and explicitly in the source code. Are there any options for doing this in other IDEs? Does eclipse in particular have the ability to configure itself from a line in the emacs format or something equivalent?
As far as I know: no, Eclipse Formatter won't configure itself when reading emacs instructions in the code.
This is why you can find Emacs plugins like this one for Ganymede allowing you to quickly open a file on Emacs from Eclipse!
(source: chaosnet.org)