ó
öŔ\c           @   s0  d  Z  d d l Z d d l m Z d d l m Z d d l m Z m	 Z
 d d l m Z d d l m Z d d l m Z d d	 l m Z d d
 l m Z e ră d d l m Z m Z m Z m Z d d l m Z d d l m  Z  n  d e f d     YZ i  g  d  Z d   Z! d   Z" d   Z# d   Z$ d S(   să   
    sphinx.ext.mathbase
    ~~~~~~~~~~~~~~~~~~~

    Set up math support in source files and LaTeX/text output.

    :copyright: Copyright 2007-2019 by the Sphinx team, see AUTHORS.
    :license: BSD, see LICENSE for details.
i˙˙˙˙N(   t   nodes(   t	   math_role(   t   matht
   math_block(   t   math_reference(   t   RemovedInSphinx30Warning(   t   MathDirective(   t
   MathDomain(   t   MathReferenceRole(   t   Anyt   Callablet   Listt   Tuple(   t   Writer(   t   SphinxR   c           B   s   e  Z d    Z RS(   c         C   s)   t  j d t d d t t |   j   S(   NsP   sphinx.ext.mathbase.MathDirective is moved to sphinx.directives.patches package.t
   stackleveli   (   t   warningst   warnR   t   superR   t   run(   t   self(    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyR       s    	(   t   __name__t
   __module__R   (    (    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyR      s   c         C   s2   t  j d t d d t |  | | | | | |  S(   Nsi   sphinx.ext.mathbase.math_role() is deprecated. Please use docutils.parsers.rst.roles.math_role() instead.R   i   (   R   R   R   t   math_role_base(   t   rolet   rawtextt   textt   linenot   inlinert   optionst   content(    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyR   '   s    	c         C   s3   t  j d t d d d d l m } | |  |  S(   NsT   sphinx.ext.mathbase.get_node_equation_number() is moved to sphinx.util.math package.R   i   i˙˙˙˙(   t   get_node_equation_number(   R   R   R   t   sphinx.util.mathR   (   t   writert   nodeR   (    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyR   .   s    	c         C   s6   t  j d t d d d d l m } | |  | |  S(   NsL   sphinx.ext.mathbase.wrap_displaymath() is moved to sphinx.util.math package.R   i   i˙˙˙˙(   t   wrap_displaymath(   R   R   R   R    R#   (   R   t   labelt	   numberingR#   (    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyR#   7   s    	c         C   sl   d d l  m } t j d t d d x? | |   D]1 } t | t j  r3 t | j t j	  r3 t
 Sq3 Wt S(   s0   Determine whether the node is in a section titlei˙˙˙˙(   t   traverse_parents$   is_in_section_title() is deprecated.R   i   (   t   sphinx.util.nodesR&   R   R   R   t
   isinstanceR    t   titlet   parentt   sectiont   Truet   False(   R"   R&   t   ancestor(    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyt   is_in_section_title@   s    	c         C   s-   t  j d t d d |  j d | |  d  S(   NsL   setup_math() is deprecated. Please use app.add_html_math_renderer() instead.R   i   t   unknown(   R   R   R   t   add_html_math_renderer(   t   appt   htmlinlinevisitorst   htmldisplayvisitors(    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyt
   setup_mathO   s    	(%   t   __doc__R   t   docutilsR    t   docutils.parsers.rst.rolesR   R   t   sphinx.addnodesR   R   t   displaymatht   sphinx.builders.latex.nodesR   t   eqreft   sphinx.deprecationR   t   sphinx.directives.patchesR   t   MathDirectiveBaset   sphinx.domains.mathR   R   t
   EqXRefRoleR-   t   typingR	   R
   R   R   t   docutils.writers.html4css1R   t   sphinx.applicationR   R   R#   R/   R5   (    (    (    s2   lib/python2.7/site-packages/sphinx/ext/mathbase.pyt   <module>
   s&   "					