How to use the termplotlib.figure.Figure function in termplotlib

To help you get started, we’ve selected a few termplotlib 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 nschloe / termplotlib / termplotlib / subplot.py View on Github external
else:
                self._column_widths = [
                    (width - self._num_borders * border_width) // layout[1]
                    for _ in range(layout[1])
                ]
                for k in range((width - self._num_borders * border_width) % layout[1]):
                    self._column_widths[k] += 1
        else:
            assert (
                width is None
            ), "At most one of `width` and `column_widths` can be specified."
            assert len(column_widths) == layout[1]
            self._column_widths = column_widths

        self._subfigures = [
            [Figure(self._column_widths[j], padding=padding) for j in range(layout[1])]
            for _ in range(layout[0])
        ]
        return
github nschloe / termplotlib / termplotlib / figure.py View on Github external
def figure(*args, **kwargs):
    return Figure(*args, **kwargs)