Skip to content

Commit d9fc225

Browse files
latex tables: Fix rendering for grid filled merged vertical cells (#14024)
Co-authored-by: Jean-François B. <2589111+jfbu@users.noreply.github.com>
1 parent b062fa9 commit d9fc225

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

CHANGES.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ Features added
2020
Bugs fixed
2121
----------
2222

23+
* LaTeX: Fix rendering for grid filled merged vertical cell
24+
(PR #14024).
25+
Patch by Tim Nordell
2326
* #14189: autodoc: Fix duplicate ``:no-index-entry:`` for modules.
2427
Patch by Adam Turner
2528
* #13713: Fix compatibility with MyST-Parser.

sphinx/writers/latex.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1298,9 +1298,10 @@ def visit_row(self, node: Element) -> None:
12981298
# insert suitable strut for equalizing row heights in given multirow
12991299
self.body.append(r'\sphinxtablestrut{%d}' % cell.cell_id)
13001300
else: # use \multicolumn for wide multirow cell
1301+
left_colsep = _colsep if cell.col == 0 else ''
13011302
self.body.append(
13021303
r'\multicolumn{%d}{%sl%s}{\sphinxtablestrut{%d}}'
1303-
% (cell.width, _colsep, _colsep, cell.cell_id)
1304+
% (cell.width, left_colsep, _colsep, cell.cell_id)
13041305
)
13051306

13061307
def depart_row(self, node: Element) -> None:

0 commit comments

Comments
 (0)