Symfony\Component\Console\Descriptor\TextDescriptor::getColumnWidth PHP Method

getColumnWidth() private method

private getColumnWidth ( array $commands ) : integer
$commands array
return integer
    private function getColumnWidth(array $commands)
    {
        $widths = array();
        foreach ($commands as $command) {
            $widths[] = strlen($command->getName());
            foreach ($command->getAliases() as $alias) {
                $widths[] = strlen($alias);
            }
        }
        return max($widths) + 2;
    }