Lines Matching defs:columns
8 * Output text in multiple columns
15 /** @var string border between columns */
115 * @param array $columns
119 protected function calculateColLengths($columns)
123 $fixed = (count($columns) - 1) * $border; // borders are used already
126 // first pass for format check and fixed columns
127 foreach ($columns as $idx => $col) {
128 // handle fixed columns
153 foreach ($columns as $idx => $col) {
161 $columns[$idx] = $real;
172 $columns[$idx] += ($remain); // add to last column
174 $columns[$fluid] = $remain;
177 return $columns;
181 * Displays text in multiple word wrapped columns
183 * @param int[] $columns list of column widths (in characters, percent or '*')
189 public function format($columns, $texts, $colors = array())
191 $columns = $this->calculateColLengths($columns);
196 foreach ($columns as $col => $width) {
205 $last = count($columns) - 1;
208 foreach ($columns as $col => $width) {