| 14 | |
| 15 | |
| 16 | class Block(Turtle): |
| 17 | |
| 18 | def __init__(self, size): |
| 19 | self.size = size |
| 20 | Turtle.__init__(self, shape="square", visible=False) |
| 21 | self.pu() |
| 22 | self.shapesize(size * 1.5, 1.5, 2) # square-->rectangle |
| 23 | self.fillcolor("black") |
| 24 | self.st() |
| 25 | |
| 26 | def glow(self): |
| 27 | self.fillcolor("red") |
| 28 | |
| 29 | def unglow(self): |
| 30 | self.fillcolor("black") |
| 31 | |
| 32 | def __repr__(self): |
| 33 | return "Block size: {0}".format(self.size) |
| 34 | |
| 35 | |
| 36 | class Shelf(list): |
no outgoing calls
no test coverage detected
searching dependent graphs…