Method: ObjectTable::Printing.calc_column_widths
- Defined in:
- lib/object_table/printing.rb
.calc_column_widths(rows, padding) ⇒ Object
40 41 42 43 |
# File 'lib/object_table/printing.rb', line 40 def self.calc_column_widths(rows, padding) columns = rows.transpose columns.map{|col| col.flatten.map(&:length).max + padding} end |