Lines Matching refs:cstr
1116 def _color(self, cstr):1117 if not cstr.startswith("#"):1118 return cstr1119 if len(cstr) == 7:1120 cl = [int(cstr[i:i+2], 16) for i in (1, 3, 5)]1121 elif len(cstr) == 4:1122 cl = [16*int(cstr[h], 16) for h in cstr[1:]]1124 raise TurtleGraphicsError("bad colorstring: %s" % cstr)