# Path: moult/compat.py
# PY3 = sys.version_info[0] == 3


import sys
from .compat import PY3, str_
HEY = ColorCombo(FG_RED)
YAY = ColorCombo(FG_GREEN)
MEH = ColorCombo(FG_YELLOW)
GOOD = ColorCombo(FG_BLUE)
NEAT = ColorCombo(FG_CYAN)
SHHH = ColorCombo(FG_MAGENTA)
NOOO = ColorCombo(FG_WHITE, BG_RED, bright=True)
MAN = ColorCombo(FG_BLACK, BG_YELLOW, bright=True)


class ColorTextRun(object):
    '''String imposter that supports multiple color strings, mostly so len()
    reports the actual text's length
    '''
    def __init__(self, *items):
        self.items = list(items)

    def __len__(self):
        return sum(map(len, self.items))

    def __unicode__(self):
        return str_(''.join(map(str_, self.items)))

    def __str__(self):
        if PY3:
            return self.__unicode__()
        return self.__unicode__().encode('utf8')

    def __repr__(self):
        r = '<ColorTextRun {}>'.format([repr(x) for x in self.items])

# Path: moult/compat.py
# PY3 = sys.version_info[0] == 3


# Path: moult/color.py
import sys
from .compat import PY3, str_

HEY = ColorCombo(FG_RED)
YAY = ColorCombo(FG_GREEN)
MEH = ColorCombo(FG_YELLOW)
GOOD = ColorCombo(FG_BLUE)
NEAT = ColorCombo(FG_CYAN)
SHHH = ColorCombo(FG_MAGENTA)
NOOO = ColorCombo(FG_WHITE, BG_RED, bright=True)
MAN = ColorCombo(FG_BLACK, BG_YELLOW, bright=True)


class ColorTextRun(object):
    '''String imposter that supports multiple color strings, mostly so len()
    reports the actual text's length
    '''
    def __init__(self, *items):
        self.items = list(items)

    def __len__(self):
        return sum(map(len, self.items))

    def __unicode__(self):
        return str_(''.join(map(str_, self.items)))

    def __str__(self):
        if PY3:
            return self.__unicode__()
        return self.__unicode__().encode('utf8')

    def __repr__(self):
        r = '<ColorTextRun {}>'.format([repr(x) for x in self.items])

        if PY3: