Useful New Features in 24.413 Oct 2014, by Artur Malabarba.
New in 24.4 post series
Following yesterday's list of the Sweetest New Features in 24.4, today I go through the ones that strike me as most useful, either to me or to the Emacs environment itself. This is the part where I had to cut the most. Emacs 24.4 exhibits a downpour of usability improvements, and it almost feels unjust to not list them all. Nonetheless, I've narrowed them down to 8.
C-x C-e), and
C-jin Lisp Interaction mode) can take a zero prefix argument. This disables truncation of lists in the output, equivalent to setting
(eval-expression-)print-levelto nil. Additionally, it causes integers to be printed in other formats (octal, hexadecimal, and character).
Fantastic! The default behaviour of truncating lists proves frustrating
every so often. My solution had been to set
print-length to nil, but
that's also not ideal as you don't always want to see everything either.
Being able to quickly toggle between the two is just perfect.
electric-indent-modeis now enabled by default.
focus-out-hook. These are normal hooks run when an Emacs frame gains or loses input focus.
Uniquify is enabled by default
This doesn't really affect me, as smart-mode-line has its own way of uniquifying names, but it's a huge improvement over the old numbering system.
letf is now just an alias for cl-letf.
I shouldn't have to tell you why this is a big deal.
New Dired minor mode
This used to be a very popular third party extension for dired. It's always nice to see good ideas getting promoted to built-in.
More packages look for ~/.emacs.d/<foo> additionally to ~/.<foo>.
I won't list each of the affected files here, suffice to say that they
add up to 17 and include some very popular packages, such as
ido. You could always do this yourself by configuring a score of
different variables, but it's nice to see Emacs taking initiative
against home clutter.
define-alternativescan be used to define generic commands.
I had to write up some code to see what this was about and it
certainly piqued my interest.
define-alternatives is a command which
defines a function with several possible implementations. The user is
then asked to choose the implementation he prefers upon invoking the command
for the first time.
For instance, say I'm writing up a major-mode for the Julia language. I want to offer a compilation command, but I don't known whether the user will prefer synchronous or asynchronous compilation. So I use define alternatives.
The first time the user invokes M-x
julia-mode-compile, they will be asked to choose an implementation.