summaryrefslogtreecommitdiff
path: root/docs/_ext/djangodocs.py
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2013-07-31 09:24:29 -0400
committerTim Graham <timograham@gmail.com>2013-07-31 09:24:29 -0400
commita3a59a3197d4e03c5c016edc581bfc5f25668bca (patch)
tree22910463f5faa75d0f8348d8d284e2b77ca26f20 /docs/_ext/djangodocs.py
parente888a9b30dd9d62a930b9244d1b5531bb17544b4 (diff)
downloaddjango-a3a59a3197d4e03c5c016edc581bfc5f25668bca.tar.gz
Added a bugfix in docutils 0.11 -- docs will now build properly.
Diffstat (limited to 'docs/_ext/djangodocs.py')
-rw-r--r--docs/_ext/djangodocs.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/docs/_ext/djangodocs.py b/docs/_ext/djangodocs.py
index 833232a0c3..e7e316f58b 100644
--- a/docs/_ext/djangodocs.py
+++ b/docs/_ext/djangodocs.py
@@ -92,9 +92,15 @@ class DjangoHTMLTranslator(SmartyPantsHTMLTranslator):
# Don't use border=1, which docutils does by default.
def visit_table(self, node):
+ self.context.append(self.compact_p)
+ self.compact_p = True
self._table_row_index = 0 # Needed by Sphinx
self.body.append(self.starttag(node, 'table', CLASS='docutils'))
+ def depart_table(self, node):
+ self.compact_p = self.context.pop()
+ self.body.append('</table>\n')
+
# <big>? Really?
def visit_desc_parameterlist(self, node):
self.body.append('(')