IPython Documentation

Table Of Contents

Previous topic

Module: nbconvert.filters.datatypefilter

Next topic

Module: nbconvert.filters.latex

This Page

Warning

This documentation is for an old version of IPython. You can find docs for newer versions here.

Module: nbconvert.filters.highlight

Module containing filter functions that allow code to be highlighted from within Jinja templates.

2 Functions

IPython.nbconvert.filters.highlight.highlight2html(source, language='ipython')

Return a syntax-highlighted version of the input source as html output.

Parameters:

source : str

Source code to highlight the syntax of.

language : str

Language to highlight the syntax of.

IPython.nbconvert.filters.highlight.highlight2latex(source, language='ipython')

Return a syntax-highlighted version of the input source as latex output.

Parameters:

source : str

Source code to highlight the syntax of.

language : str

Language to highlight the syntax of.