
    b                     6    d Z ddlmZ ddlmZ  G d de      Zy)zWModule that allows latex output notebooks to be conditioned before
they are converted.
    )Unicode   )Preprocessorc                   J    e Zd ZdZ edd      j                  d      Zd Zy)	LatexPreprocessorzPreprocessor for latex destined documents.

    Mainly populates the ``latex`` key in the resources dict,
    adding definitions for pygments highlight styles.
    defaultz!Name of the pygments style to use)helpT)configc                     ddl m} |j                  di        |d   j                  d || j                        j	                                |d   j                  d| j                         ||fS )aB  Preprocessing to apply on each notebook.

        Parameters
        ----------
        nb : NotebookNode
            Notebook being converted
        resources : dictionary
            Additional resources used in the conversion process.  Allows
            preprocessors to pass variables into the Jinja engine.
        r   )LatexFormatterlatexpygments_definitions)stylepygments_style_name)pygments.formattersr   
setdefaultr   get_style_defs)selfnb	resourcesr   s       ?/usr/lib/python3/dist-packages/nbconvert/preprocessors/latex.py
preprocesszLatexPreprocessor.preprocess#   sg     	7Wb)'%%"N$D$S$S$U	
 	'%%&;TZZH9}    N)__name__
__module____qualname____doc__r   tagr   r    r   r   r   r      s*     I$GHLLTXLYEr   r   N)r   	traitletsr   baser   r   r   r   r   <module>r"      s       r   