import axi
BOUNDS = (0,0,11.75,8.25)
# Set this variable to true when you wish to draw with the plotter.
draw = False
def main():
turtle = axi.Turtle()
turtle.pu()
turtle.goto(5,0)
turtle.pd()
turtle.goto(0,0)
turtle.goto(3,2)
turtle.goto(0,4)
turtle.goto(5,4)
turtle.pu()
turtle.home()
# Scale letter to fit A4-sized paper
drawing = turtle.drawing.rotate_and_scale_to_fit(11.75, 8.25, step=90, padding=0.25)
# Render drawing
im = drawing.render()
# Create an image file of the drawing
im.write_to_png('LetterM.png')
# Draw with the plotter if relevant
if draw:
axi.draw(drawing)
if __name__ == '__main__':
main()