def colors(self): """Get the css color list""" def color(tupl): """Make a color css""" return ".color-{0} {{\n" " stroke: {1};\n" " fill: {1};\n" "}}\n".format(*tupl) return "\n".join(map(color, enumerate(cycle_fill(self._colors, 16))))
def get_colors(self, prefix): """Get the css color list""" def color(tupl): """Make a color css""" return (('%s.color-{0} {{\n' ' stroke: {1};\n' ' fill: {1};\n' '}}\n') % prefix).format(*tupl) return '\n'.join(map(color, enumerate(cycle_fill(self.colors, 16))))
def colors(self): """Get the css color list""" def color(tupl): """Make a color css""" return ('.color-{0} {{\n' ' stroke: {1};\n' ' fill: {1};\n' '}}\n'.format(*tupl)) return '\n'.join(map(color, enumerate(cycle_fill(self._colors, 16))))
def get_colors(self, prefix): """Get the css color list""" def color(tupl): """Make a color css""" return (( '%s.color-{0}, %s.color-{0} a:visited {{\n' ' stroke: {1};\n' ' fill: {1};\n' '}}\n') % (prefix, prefix)).format(*tupl) return '\n'.join(map(color, enumerate(cycle_fill(self.colors, 16))))
def colors(self): """Get the css color list""" def color(tupl): """Make a color css""" return ( '.color-{0} {{\n' ' stroke: {1};\n' ' fill: {1};\n' '}}\n'.format(*tupl)) return '\n'.join(map(color, enumerate(cycle_fill(self._colors, 16))))
def get_colors(self, prefix, len_): """Get the css color list""" def color(tupl): """Make a color css""" return (( '%s.color-{0}, %s.color-{0} a:visited {{\n' ' stroke: {1};\n' ' fill: {1};\n' '}}\n') % (prefix, prefix)).format(*tupl) if len(self.colors) < len_: colors = cycle_fill(self.colors, len_) else: colors = self.colors[:len_] return '\n'.join(map(color, enumerate(colors)))