project_report/project_report_latex.py
def create_horizontal_table(container, rows):
        """ Meant to be used for only two columns where the header is the first column"""
        # Convert cell containing lists into multilines cells
        converted_rows = []
        for row in rows:
            converted_row = []
            for cell in row:
                if isinstance(cell, list):
                    converted_row.append('\n'.join(cell))
                else:
                    converted_row.append(cell)
            converted_rows.append(converted_row)

        column_def = r'>{\bfseries}lX[l]'
        with container.create(Tabu(column_def, row_height=1.6)) as data_table:
            for r in converted_rows:
                data_table.add_row(r)
 Meant to be used for only two columns where the header is the first column
Meant to be used for only two columns where the header is the first column
Meant to be used for only two columns where the header is the first column
def create_horizontal_table(container, rows):
        converted_rows = []
        for row in rows:
            converted_row = []
            for cell in row:
                if isinstance(cell, list):
                    converted_row.append('\n'.join(cell))
                else:
                    converted_row.append(cell)
            converted_rows.append(converted_row)
        column_def = r'>{\bfseries}lX[l]'
        with container.create(Tabu(column_def, row_height=1.6)) as data_table:
            for r in converted_rows:
                data_table.add_row(r)
def create_horizontal_table ( container , rows ) : converted_rows = [ ] for row in rows : converted_row = [ ] for cell in row : if isinstance ( cell , list ) : converted_row . append ( '\n' . join ( cell ) ) else : converted_row . append ( cell ) converted_rows . append ( converted_row ) column_def = r'>{\bfseries}lX[l]' with container . create ( Tabu ( column_def , row_height = 1.6 ) ) as data_table : for r in converted_rows : data_table . add_row ( r )
Meant to be used for only two columns where the header is the first column
Meant to be used for only two columns where the header is the first column
""" Meant to be used for only two columns where the header is the first column""" # Convert cell containing lists into multilines cells
container
rows