[IPython-dev] Ace versus CodeMirror

Jason Grout jason-sage at creativetrax.com
Mon Jan 23 07:33:46 EST 2012

On 1/22/12 3:56 PM, Brian Granger wrote:
> Hi,
> Recently, we added the ability for users to edit a single cell in the
> notebook using the Ace editor.  I think Fernando and I have been under
> the impression that Ace was a more featureful editor that power users
> would want for serious dev work in the notebook.  Here is my take on
> this:
> * Ace has better support for keyboard bindings (emacs/vim), although a
> recent version of CodeMirror has improved this situation.
> * Ace has more keyboard actions out of the box, such as indentation of blocks.

If I highlight a block and press tab or shift-tab in 
http://codemirror.net/mode/python/index.html, it indents/dedents the 
entire block.  Is that what you mean?

> * Fernando and others have remarked that CodeMirror was not quite as
> nice as Ace.  I have this vague sense, but it is difficult to say
> exactly what is better.
> * Hmm...
> Some questions:
> * Is Ace really that much better that it is worth us shipping/using it?
> * Do people like the ability to edit a single cell in a
> more-full-window capacity?

See http://codemirror.net/demo/fullscreen.html for an example of this 
with CodeMirror.  At least, I think that's what you're talking about.

As for search and replace, see this: http://codemirror.net/demo/search.html

Also, CodeMirror technically can actually apply a rst mode 
(http://codemirror.net/mode/rst/index.html) just inside of docstrings, 
though I don't know if the mode overlay is written yet.  That would be 
cool, though.  I looked into writing it a long time ago, but haven't yet 
and likely won't have time in the near future.



More information about the IPython-dev mailing list