[IPython-dev] Ace versus CodeMirror

Brian Granger ellisonbg at gmail.com
Mon Jan 23 13:46:05 EST 2012

On Sun, Jan 22, 2012 at 2:39 PM, Fernando Perez <fperez.net at gmail.com> wrote:
> On Sun, Jan 22, 2012 at 1:56 PM, Brian Granger <ellisonbg at gmail.com> wrote:
>> 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?
>> Please check out the Ace capabilty in master and let us know what you think...
> There are some limitations of CM that make it really painful for
> editing longer cells:
> - inability to rigidly indent/dedent whole blocks.  This is a killer
> for refactoring just about anything.

Based on some of the responses we have gotten, I think we are
configuring the notebook so that this doesn't work.  I will play
around with the config to see if I can get this to work.

> - no indentation support (not even soft-tabs) inside docstrings.
> Typing eight spaces at the beginning of each line in a method
> docstring is ridiculously annoying.  I just type them in emacs and
> paste them back in.

Yes, this is likely a problem with the python mode.  It is very likely
it can be fixed.

> - no search and replace: also killer for refactoring.
> These are the big ones for me, so I'm +1 on including Ace.

There is a search and replace demo for CM here:


Fernando, if we can fix these things, are you open to using CodeMirror
always?  Would you still want the ability to do the full-window-like
editing mode?

> There's also the fact that in teaching/workshops, we often struggle
> with the question of 'what editor should I use along with ipython'.
> Once Ace is available, we can simply tell people to use it for editing
> also their python scripts, all within the ipython workflow.  This may
> not be the long-term solution they want if they become full-time
> users, but when you only have a day or two to teach a group some
> basics, having ipython provide them a complete solution out of the box
> would be great, I think.

> Cheers,
> f

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger at calpoly.edu and ellisonbg at gmail.com

More information about the IPython-dev mailing list