protected function colorize($color, $bold = 0)
    {
        if (!isset(self::$colors[$color])) {
            throw new Exception("Unknown color '$color'.");
        }

        $code = self::$colors[$color];
        $this->content .= "\033[{$bold};{$code}m";
    }