I would like rainbow parens for editing Clojure in Emacs and since VI does this I assume that in Emacs it should be something like M-x butterfly or something :)
相关问题
- Symbol's function definition is void: declare-
- Better Sequence Duplicate Remover
- How can I set the SVN password with Emacs 23.1 bui
- Emacs shell: save commit message
- Installation of Leiningen 2.X in Mac OS X
相关文章
- ess-rdired: I get this error “no ESS process is as
- Emacs/xterm color annoyance on Linux
- Factor Clojure code setting many different fields
- Does learning one Lisp help in learning the other?
- Pipe less to Emacs
- Capturing the output of “diff” with org-babel
- Better way to nest if-let in clojure
- emacs terminal mode: how to copy and paste efficie
This is an old question now, but I recently wrote RainbowDelimiters mode for this. It's a 'rainbow parens'-type mode which colors all parens, brackets and braces, made with Clojure programming in mind.
It highlights the whole buffer, not just the parens surrounding point.
The most important thing is that it's FAST - all the other rainbow paren modes I've tried slow down editing (especially scrolling) quite a lot. I put significant effort into profiling and optimizing it so doesn't have any noticeable impact on scrolling/editing speed.
You can find info about it at the EmacsWiki page, and the mode itself is at rainbow-delimiters.el.
Here's a mode for that which I have used in the past briefly. Here's another one which I haven't tried.
I'm using
highlight-parentheses-mode
from the script mquander mentioned. It doesn't provide much of a rainbow effect out of the box, but it is customisable:I believe I've lifted the actual colours from Vimclojure. Note that Vimclojure highlights all parentheses in the file, whereas with
highlight-parentheses-mode
only the parens which actually contain the point will be highlighted (and only a limited number of levels). I happen to find this behaviour useful, but it is perhaps a bit lacking in the prettiness area in comparison with the Vimclojure way.I now notice I've never gotten 'round to fixing those outer paren colours actually... Maybe I will now that you've reminded me about it.