tabled 0.20.0

An easy to use library for pretty print tables of Rust `struct`s and `enum`s.
Documentation
1
2
3
4
5
6
7
8
9
use crate::grid::config::SpannedConfig;

pub(crate) fn get_table_total_width(list: &[usize], cfg: &SpannedConfig) -> usize {
    let margin = cfg.get_margin();
    list.iter().sum::<usize>()
        + cfg.count_vertical(list.len())
        + margin.left.size
        + margin.right.size
}