02 December 2010

Best text editor: Aquamacs

Programmers are very passionate about which text editor they use. There are many lists of the top 10 text editors available for Windows, OSX and Linux.

During my PhD, I had to become very familiar with coding and scripting. I need my text editor to be able to perform complex, multi-line regular expression searches. And as a student, preferably, the text editor would be available for free.

I discovered Notepad ++, which I fell in love with. It was very easy to use, and made me feel very comfortable. But, I soon discovered that Notepad ++ was not very good at multi-line regular expressions. This was a deal breaker. I started looking for a solution. Unable to find one, a colleague nudged me towards XEmacs. It took some getting used to (and configuring), but once it was set up, I could use it to get my work done (although I wouldn't say that I enjoyed using it).

When I started working as a Research Officer, I was handed a MacBook Pro and needed to find a suitable OSX editor. After some detective work, I came across Smultron, which I immediately liked nearly as much as Notepad ++.  I created a Praat syntax highlighting scheme for Smultron, but when I read that it was no longer being developed or supported, it made me think twice about relying on a no longer supported application. I decided to keep looking.

And then, it happened. I came across Aquamacs. Aquamacs takes everything you hate about Emacs and fixes it, making everything you love about Emacs multiply tenfold. You just download and install it and it just works, without losing any of the awesome power of Emacs. It is hands down the best text editor I have ever used, and reason enough to sell your Windows machine and purchase a MacBook. It is that good.

4 comments:

Jacopo Prendin said...

You're right! I didn't like very much Emacs, but Aquamacs it's the best text-editor on Macintosh platform. I really would to know why Emacs' developers don't launch cua-mode at start :P

yandros said...

We don't enable cua-mode by default because it changes some things about the way Emacs works that are considerably older than the CUA. Once these things are ``built in to your fingers'', as we sometimes say, it's very jarring to have them change.

David Reitter does an excellent job with Aquamacs, and has joined the GNU Emacs development effort, so we can expect to see Emacs' new goodness incorporated into Aquamacs very quickly, and even some of Aquamacs' goodness work their way back into GNU Emacs -- but CUA by default may be a step too far. It does come up whenever we discuss a new major version, though. We'll see.

Nicholas Lee said...

The way I do multi-line editing in Notepad++ is by replacing all the new line characters with a keyword, reducing the document to a single line. When I'm done, I put the line breaks back in.

Mark Antoniou said...

Nicholas, that is probably the best way to get around the limitations of Notepad++ for simple expressions. It becomes a bit more problematic when the newline is part of the pattern that you are looking for, e.g.,

Search for: one two

as opposed to

Search for: one
two

Many people won't be bothered by this limitation, and that's fine. But for power users, converting newlines to strings and back again is both time consuming and messy, and ultimately unnecessary given that there are more powerful text editors available, and for free no less. Imagine having to check through 100,000 lines of code to see if all of your newlines are back where they should be. As the great Chris Rock once said, "You can drive with your feet if you want to, but that doesn't make it a good idea."