You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be pretty cool to see a way to make a format with a macro!
Something Like
let format = table_format!(// This could be the title format// C would signify that the cell goes hereTitle->{
+===+===+
| C | C |
+===+===+
},// The Other FormatsRow-> {
+---+---+
| CC |
+---+---+
});// Then to make a table out of itletmut table = table!(format,["Hello World!","This is a cool format tool"]);
table.set_titles(row!["Cool Title","Part 2"]);
table.print_tty(true);
Which would result in
+==============+============================+
| Cool Title | Part 2 |
+==============+============================+
| Hello World! | This is a cool format tool |
+--------------+----------------------------+
I'm not remotely familiar with how macro writing would work, but would this be possible, I'm happy to work through it, if interested.
The text was updated successfully, but these errors were encountered:
It would be pretty cool to see a way to make a format with a macro!
Something Like
Which would result in
I'm not remotely familiar with how macro writing would work, but would this be possible, I'm happy to work through it, if interested.
The text was updated successfully, but these errors were encountered: