turtle.TPen

class turtle.TPen(resizemode='noresize')[source]

Drawing part of the RawTurtle. Implements drawing properties.

Methods

__format__ default object formatter
__init__([resizemode])
__new__((S, ...)
__reduce__ helper for pickle
__reduce_ex__ helper for pickle
__sizeof__(() -> int) size of object in memory, in bytes
__subclasshook__ Abstract classes can override this to customize issubclass().
_color(args) dummy method - to be overwritten by child class
_colorstr(args) dummy method - to be overwritten by child class
_newLine([usePos]) dummy method - to be overwritten by child class
_reset([pencolor, fillcolor])
_update([count, forced]) dummy method - to be overwritten by child class
color(*args) Return or set the pencolor and fillcolor.
down() Pull the pen down – drawing when moving.
fillcolor(*args) Return or set the fillcolor.
hideturtle() Makes the turtle invisible.
ht() Makes the turtle invisible.
isdown() Return True if pen is down, False if it’s up.
isvisible() Return True if the Turtle is shown, False if it’s hidden.
pd() Pull the pen down – drawing when moving.
pen([pen]) Return or set the pen’s attributes.
pencolor(*args) Return or set the pencolor.
pendown() Pull the pen down – drawing when moving.
pensize([width]) Set or return the line thickness.
penup() Pull the pen up – no drawing when moving.
pu() Pull the pen up – no drawing when moving.
resizemode([rmode]) Set resizemode to one of the values: “auto”, “user”, “noresize”.
showturtle() Makes the turtle visible.
speed([speed]) Return or set the turtle’s speed.
st() Makes the turtle visible.
up() Pull the pen up – no drawing when moving.
width([width]) Set or return the line thickness.