Skip to content

Commit

Permalink
[1.4.x] Added a bugfix in docutils 0.11 -- docs will now build properly.
Browse files Browse the repository at this point in the history
Backport of a3a59a3 from master
  • Loading branch information
timgraham committed Jul 31, 2013
1 parent ed6ec47 commit 8af0b1a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions docs/_ext/djangodocs.py
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -105,9 +105,15 @@ class DjangoHTMLTranslator(SmartyPantsHTMLTranslator):


# Don't use border=1, which docutils does by default. # Don't use border=1, which docutils does by default.
def visit_table(self, node): def visit_table(self, node):
self.context.append(self.compact_p)
self.compact_p = True
self._table_row_index = 0 # Needed by Sphinx self._table_row_index = 0 # Needed by Sphinx
self.body.append(self.starttag(node, 'table', CLASS='docutils')) 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? # <big>? Really?
def visit_desc_parameterlist(self, node): def visit_desc_parameterlist(self, node):
self.body.append('(') self.body.append('(')
Expand Down

0 comments on commit 8af0b1a

Please sign in to comment.