PyDocs

Nav

Graphical user interfaces with Tk

Shape.addcomponent

turtle

method of Shape
  • Shape.addcomponent(poly, fill, outline=None)
Add a component to a shape of type “compound”. poly is a polygon, a tuple of pairs of numbers. fill is the color the polygon is filled with and outline is the color of its outline. If outline is not given, fill is used for it as well.
1 Example
>>> poly = ((0,0), (10,-5), (0,10), (-10,-5))
>>> s = Shape("compound")
>>> s.addcomponent(poly, "red", "blue")
>>> # ... add more components and then use register_shape()
from the Python docs
See Also
No see-alsos for turtle/Shape.addcomponent
0 Notes
No notes for Shape.addcomponent