How to use the rich.box.MINIMAL_DOUBLE_HEAD function in rich

To help you get started, we’ve selected a few rich examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github efenka / mtv_dl / mtv_dl.py View on Github external
return str(obj)

    headers = headers if isinstance(headers, list) else [
        'hash',
        'channel',
        'title',
        'topic',
        'size',
        'start',
        'duration',
        'age',
        'region',
        'downloaded']

    # noinspection PyTypeChecker
    table = Table(box=box.MINIMAL_DOUBLE_HEAD)
    for h in headers:
        table.add_column(h)
    for row in shows:
        table.add_row(*[_escape_cell(t, row.get(t)) for t in headers])
    console.print(table)