mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Merge pull request #4990 from tk0miya/refactor_math4
Refactor math implemenation
This commit is contained in:
commit
fc5f5e3b86
@ -193,6 +193,9 @@ class production(nodes.Part, nodes.Inline, nodes.FixedTextElement):
|
||||
class math(nodes.math):
|
||||
"""Node for inline equations.
|
||||
|
||||
.. warning:: This node is provided to keep compatibility only.
|
||||
It will be removed in nearly future. Don't use this from your extension.
|
||||
|
||||
.. deprecated:: 1.8
|
||||
Use ``docutils.nodes.math`` instead.
|
||||
"""
|
||||
@ -211,6 +214,9 @@ class math(nodes.math):
|
||||
class math_block(nodes.math_block):
|
||||
"""Node for block level equations.
|
||||
|
||||
.. warning:: This node is provided to keep compatibility only.
|
||||
It will be removed in nearly future. Don't use this from your extension.
|
||||
|
||||
.. deprecated:: 1.8
|
||||
"""
|
||||
|
||||
@ -227,6 +233,9 @@ class math_block(nodes.math_block):
|
||||
class displaymath(math_block):
|
||||
"""Node for block level equations.
|
||||
|
||||
.. warning:: This node is provided to keep compatibility only.
|
||||
It will be removed in nearly future. Don't use this from your extension.
|
||||
|
||||
.. deprecated:: 1.8
|
||||
"""
|
||||
|
||||
|
@ -130,8 +130,6 @@ class MathDirective(SphinxDirective):
|
||||
nowrap='nowrap' in self.options)
|
||||
ret = [node]
|
||||
set_source_info(self, node)
|
||||
if hasattr(self, 'src'):
|
||||
node.source = self.src
|
||||
self.add_target(ret)
|
||||
return ret
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user