diff options
author | pierresy <pierre-henri.symoneaux@alcatel-lucent.com> | 2015-06-01 20:21:06 +0200 |
---|---|---|
committer | pierresy <pierre-henri.symoneaux@alcatel-lucent.com> | 2015-06-01 20:24:41 +0200 |
commit | 974c6b83b510eee56a3484aeb2798d401b5b35d9 (patch) | |
tree | 370a79e446632f0a20627f956ee6757aff28b04c /examples | |
parent | d61fd0e84055da1ed3ae31e9d6890ec4881274a7 (diff) |
Removed titles from tables since they can be set in row 0.
Also, this simplifies a lot macros implementations
Diffstat (limited to 'examples')
-rw-r--r-- | examples/basic.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/basic.rs b/examples/basic.rs index 7cefeb8..db4ba9f 100644 --- a/examples/basic.rs +++ b/examples/basic.rs @@ -22,7 +22,8 @@ use tabprint::cell::Cell; +---------+------+---------+
*/
fn main() {
- let mut table = Table::new(row!["ABC", "DEFG", "HIJKLMN"]);
+ let mut table = Table::new();
+ table.add_row(row!["ABC", "DEFG", "HIJKLMN"]);
table.add_row(row!["foobar", "bar", "foo"]);
table.add_row(Row::new(vec![
Cell::new(&"foobar2".to_string()),
|