beloved Emacs in favor of Eclipse for Java coding. I don't
really regret this. Eclipse's many features offering specialized
support for Java (things like Organize Imports, Generate
Getters and Setters, all the refactoring commands, etc.) make
this a no-brainer. Yet I still find myself occasionally dropping
back into Emacs for these indispensable features:
- Defining macros on the fly with M-(, M-) for repetitive changes.
- M-X sort-lines. If I'm working on some kind of list like a list of JAR files in a classpath where the order doesn't really matter, I like to have them in alphabetical order. Eclipse doesn't really give you any way to do this.
- Dired (file manager)
- Split-window (C-X 2), split-window-horizontally (C-X 3).
- All the downcase/upcase/capitalize commands.
- Case-smart search and replace. I'm constantly repeating the same search and replace 2 or 3 times in Eclipse because Eclipse can't figure out that if I want to change 'string1' to 'string2', then I probably also want to change 'String1' to 'String2'. Emacs just quietly Does The Right Thing.
- Comment-dwim (M-;) Inserts end of line comments, aligned at a preconfigured column or just at the end of the line if the line is already longer than that column. If a comment is already present, aligns the comment to the appropriate column and places the cursor at the beginning of the comment. Does multiple lines if a region is selected. Works the same way in Java, Perl, C, etc. using the appropriate syntax for the language. Great for adding a short comment to every element of a list neatly aligned in the same column. DWIM stands for 'do what I mean'.
- Indenting and filling that works for comments.
- Ironically, Emacs' compact and lightweight memory footprint, by comparison.
No comments:
Post a Comment