From c42bf6a803829f7e6c042831f6e576e0c7137afd Mon Sep 17 00:00:00 2001 From: Guillaume Ayoub Date: Fri, 29 Jan 2016 02:20:04 +0100 Subject: [PATCH] Fix table row height when its height is not auto --- weasyprint/layout/tables.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/weasyprint/layout/tables.py b/weasyprint/layout/tables.py index 15bbc9fdb..af89797b9 100644 --- a/weasyprint/layout/tables.py +++ b/weasyprint/layout/tables.py @@ -164,14 +164,15 @@ def group_layout(group, position_y, max_position_y, ending_cells_by_row[cell.rowspan - 1].append(cell) ending_cells = ending_cells_by_row.pop(0) if ending_cells: # in this row - row_bottom_y = max( - cell.position_y + cell.border_height() - for cell in ending_cells) if row.height == 'auto': + row_bottom_y = max( + cell.position_y + cell.border_height() + for cell in ending_cells) row.height = row_bottom_y - row.position_y else: row.height = max(row.height, max( row_cell.height for row_cell in ending_cells)) + row_bottom_y = cell.position_y + row.height else: row_bottom_y = row.position_y row.height = 0