mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
merge with stable
This commit is contained in:
commit
fa3db9e209
@ -2,7 +2,7 @@
|
||||
* doctools.js
|
||||
* ~~~~~~~~~~~
|
||||
*
|
||||
* Sphinx JavaScript utilties for all documentation.
|
||||
* Sphinx JavaScript utilities for all documentation.
|
||||
*
|
||||
* :copyright: Copyright 2007-2011 by the Sphinx team, see AUTHORS.
|
||||
* :license: BSD, see LICENSE for details.
|
||||
|
@ -744,13 +744,13 @@ class LaTeXTranslator(nodes.NodeVisitor):
|
||||
if self.table.col > 0:
|
||||
self.body.append(' & ')
|
||||
self.table.col += 1
|
||||
self.context.append('')
|
||||
context = ''
|
||||
if 'morerows' in node:
|
||||
self.body.append(' \multirow{')
|
||||
self.previous_spanning_row = 1
|
||||
self.body.append(str(node.get('morerows') + 1))
|
||||
self.body.append('}{*}{')
|
||||
self.context.append('}')
|
||||
context += '}'
|
||||
self.remember_multirow[self.table.col] = node.get('morerows') + 1
|
||||
if 'morecols' in node:
|
||||
self.body.append(' \multicolumn{')
|
||||
@ -759,13 +759,14 @@ class LaTeXTranslator(nodes.NodeVisitor):
|
||||
self.body.append('}{|l|}{')
|
||||
else:
|
||||
self.body.append('}{l|}{')
|
||||
self.context.append('}')
|
||||
context += '}'
|
||||
if isinstance(node.parent.parent, nodes.thead):
|
||||
self.body.append('\\textbf{')
|
||||
self.context.append('}')
|
||||
context += '}'
|
||||
if self.remember_multirow.get(self.table.col + 1, 0) > 1:
|
||||
self.remember_multirow[self.table.col + 1] -= 1
|
||||
self.context.append(' & ')
|
||||
context += ' & '
|
||||
self.context.append(context)
|
||||
def depart_entry(self, node):
|
||||
self.body.append(self.context.pop()) # header
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user