Beispiel #1
0
from color import Color

print (Color.__doc__())

#______TRUE VERBOSE______________________
red = Color(255, 256, 512)
green = Color(256, 255, 0)
blue = Color(0, 0, 511)

yellow = red.add(green)
cyan = green.add(blue)
magenta = blue.add(red)

white = red.add(green).add(blue)

print red
print green
print blue
print yellow
print cyan
print magenta
print white

#______FALSE VERBOSE_____________________
black = white.sub(red).sub(green).sub(blue)
print black

darkgray = Color(10, 10, 10)
lightgray = darkgray.mult(22.5)
random = Color(12.3, 31.2, 23.1)