(format-lines lens parts)
Format a sequence of summary parts into columns. lens is a sequence of
lengths to use for parts. There are two sequences of lengths if we are
not displaying defaults. There are three sequences of lengths if we
are showing defaults.
Source
(defn ^{:added "0.3.0"} format-lines
"Format a sequence of summary parts into columns. lens is a sequence of
lengths to use for parts. There are two sequences of lengths if we are
not displaying defaults. There are three sequences of lengths if we
are showing defaults."
[lens parts]
(let [fmt (case (count lens)
2 "~{ ~vA ~vA~}"
3 "~{ ~vA ~vA ~vA~}")]
(map #(s/trimr (pp/cl-format nil fmt (interleave lens %))) parts)))