1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
AsciiTable at = new AsciiTable();
at.addRule();
AT_Row row1 = at.addRow("first", "information");
at.addRule();
AT_Row row2 = at.addRow("second", "info");
at.addRule();
at.getRenderer().setCWC(new CWC_LongestWord());
System.out.println(at.render());
at.setPaddingLeftRight(1);
System.out.println(at.render());
at.setPaddingLeftRight(0);
row1.getCells().get(0).getContext().setPaddingLeftRight(2);
row1.getCells().get(1).getContext().setPaddingLeftRight(3);
row2.getCells().get(0).getContext().setPaddingLeftRight(3);
row2.getCells().get(1).getContext().setPaddingLeftRight(4);
System.out.println(at.render()); |