Michael Droettboom wrote:
> Secondly, the ipython console sessions aren't getting syntax highlighted 
> -- it would be nice if they did, particularly to indicate input vs. 
> output.  I'll volunteer to look into this -- I've done some pygments 
> customization work in the past and maybe it won't be too difficult.
>   
I just committed support for this on the trunk.  The usage is not 
automatic.  The reST code must specifically request it using the 
..sourcecode directive:

.. sourcecode:: ipython

    In [101]: ax.lines[0]
    Out[101]: <matplotlib.lines.Line2D instance at 0x19a95710>

    In [102]: line
    Out[102]: <matplotlib.lines.Line2D instance at 0x19a95710>

Making this automatic would have required monkey-patching Sphinx -- 
there doesn't seem to be an API to extend its algorithm to automatically 
select a syntax highlighter, as I suppose this requirement is somewhat 
obscure.

Cheers,
Mike

-- 
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to