Commit 45b89e6a authored by Miguel Angel Reina Ortega's avatar Miguel Angel Reina Ortega
Browse files

Fix when checking generated table rows

parent ea9475eb
Loading
Loading
Loading
Loading
+11 −2
Original line number Diff line number Diff line
@@ -532,6 +532,10 @@ def parseGridTableWithSpans(gridTable:str) -> tuple[GridTableRowList, GridTableR
					forwardRowspan[cellIndex] -= 1
			if forwardRowspan[cellIndex] == 0 and cell.rowspan > 1:
				forwardRowspan[cellIndex] = cell.rowspan -1
				colspan=1
				while cell.colspan > colspan:
					forwardRowspan[cellIndex + colspan] = cell.rowspan - 1
					colspan += 1

		if not sum == numberOfColumns:
			raise ValueError('Grid table not converted properly')
@@ -551,6 +555,11 @@ def parseGridTableWithSpans(gridTable:str) -> tuple[GridTableRowList, GridTableR
					forwardRowspan[cellIndex] -= 1
			if forwardRowspan[cellIndex] == 0 and cell.rowspan > 1:
				forwardRowspan[cellIndex] = cell.rowspan - 1
				colspan=1
				while cell.colspan > colspan:
					forwardRowspan[cellIndex + colspan] = cell.rowspan - 1
					colspan += 1
					
		if not sum == numberOfColumns:
			raise ValueError('Grid table not converted properly')