Print table on Linux or Windows terminal
pip install ttytable
Warning: Only the following is supported
- Xshell: Default theme
- MobaXterm: All
- Vmware: All
Other tools have not been tested yet
from ttytable.table import Use
c = Use(['Name', 'Age', 'Country'])
c.add_row(['Oliven', '20', 'China'])
c.add_row(['Bob', '29', 'American'])
c.echo()
You can customize it.
c.top_left = '1' # ↖
c.top_up = '2' # ↑
c.top_right = '3' # ↗
c.left = '4' # ←
c.center = '5' # ·
c.right = '6' # →
c.bottom_left = '7' # ↙
c.bottom_down = '8' # ↓
c.bottom_right = '9' # ↘
c.vertical = 'o' # |
c.across = 'x' # -
c.echo()