From: Tomas V.V.Cox Date: Fri, 7 Jun 2002 14:48:01 +0000 (+0000) Subject: more wrapping cases X-Git-Tag: php5_5_0~142 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8f21117efb08c073561332fc26c0ac7d22ef1e06;p=php more wrapping cases --- diff --git a/pear/PEAR/Frontend/CLI.php b/pear/PEAR/Frontend/CLI.php index 0c352e45ae..e9c4cc9eab 100644 --- a/pear/PEAR/Frontend/CLI.php +++ b/pear/PEAR/Frontend/CLI.php @@ -409,13 +409,21 @@ class PEAR_Frontend_CLI extends PEAR array("Description", $data['description']), ), ); - default: + default: { if (is_array($data)) { $this->_startTable($data); - $opts = array(0 => array('wrap' => 25), - 1 => array('wrap' => 55) - ); + $count = count($data['data'][0]); + if ($count == 2) { + $opts = array(0 => array('wrap' => 25), + 1 => array('wrap' => 55) + ); + } else { + $opts = array(0 => array('wrap' => 20), + 1 => array('wrap' => 20), + 2 => array('wrap' => 40) + ); + } if (isset($data['headline']) && is_array($data['headline'])) { $this->_tableRow($data['headline'], array('bold' => true), @@ -428,6 +436,7 @@ class PEAR_Frontend_CLI extends PEAR } else { $this->_displayLine($data); } + } } }