summaryrefslogtreecommitdiff
path: root/docutils/writers/html4css1
diff options
context:
space:
mode:
authormilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2011-06-29 16:24:09 +0000
committermilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2011-06-29 16:24:09 +0000
commit88b257eec30b5e84c133191c1feeb3d6834f4e18 (patch)
tree32446a15af8b79dd2f6b1234864f3dbe0cfe3b5c /docutils/writers/html4css1
parent6990ec17e04c6948a744cb4e35d6e78f5ccfff4c (diff)
downloaddocutils-88b257eec30b5e84c133191c1feeb3d6834f4e18.tar.gz
math update
latex2e writer: set label if node has a name attribute html4css1 writer: do not wrap inline <math> functional test: adapt expected output to last changes git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk/docutils@7061 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'docutils/writers/html4css1')
-rw-r--r--docutils/writers/html4css1/__init__.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/docutils/writers/html4css1/__init__.py b/docutils/writers/html4css1/__init__.py
index 54376f5a8..81490d388 100644
--- a/docutils/writers/html4css1/__init__.py
+++ b/docutils/writers/html4css1/__init__.py
@@ -1136,7 +1136,7 @@ class HTMLTranslator(nodes.NodeVisitor):
#
# HTML container
tags = {# math_output: (block, inline, class-arguments)
- 'mathml': ('div', 'span', ''),
+ 'mathml': ('div', '', ''),
'html': ('div', 'span', 'formula'),
'mathjax': ('div', 'span', 'math'),
'latex': ('pre', 'tt', 'math'),
@@ -1183,11 +1183,13 @@ class HTMLTranslator(nodes.NodeVisitor):
self.depart_system_message(err_node)
raise nodes.SkipNode
# append to document body
- self.body.append(self.starttag(node, tag, CLASS=clsarg))
+ if tag:
+ self.body.append(self.starttag(node, tag, CLASS=clsarg))
self.body.append(math_code)
if math_env:
self.body.append('\n')
- self.body.append('</%s>\n' % tag)
+ if tag:
+ self.body.append('</%s>\n' % tag)
# Content already processed:
raise nodes.SkipNode