Easy Draw Module
  • About the Project
  • Student Developed Art
  • 🐍Python
    • Setup and Install
    • Starter Template
    • Example Code
    • Style Guide
    • Module Reference
      • The Drawing Canvas
      • Colors
      • Drawing Shapes
      • Text and Images
      • Property Getting and Setting
      • Object Methods
      • Event Handling
      • Saving Your Drawing
    • Power Users
    • Issues and Features Coming Soon...
  • Python Curriculum
    • Unit 1: Drawing Basics
    • Unit 2: Drawing Algorithms
    • Unit 3: Functions and Events
  • ☕Java
  • Coming Soon...
  • Java Curriculum
    • Unit 1: Using Easy Draw Objects
    • Unit 2: If Statements and Drawings
    • Unit 3: Iteration and Drawings
    • Unit 4: Methods and Classes to Abstract Drawings
    • Tabs
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Python

Starter Template

PreviousSetup and InstallNextExample Code

Last updated 4 years ago

Was this helpful?

To open the Easy Draw screen, all you need is three lines of code. It is that easy!

# Learn how to use Easy Draw!
# https://easy-draw.joemazzone.net/python/module-reference

import easy_draw           # Import the module to use it

easy_draw.load_canvas()    # Always start your program with this

# --- Your main program below here ---



# --- Your main program ends here ---

easy_draw.end()            # Always end your program with this

The following will open when you run the above program:

Features of the Easy Draw screen:

1. Grid on and off

To help learners visualize the coordinate system, a grid can be turned on and off.

2. Coordinates

To help learners position shapes on the drawing canvas, as you move your mouse around the canvas the bottom-right corner of the screen showcases the x, y coordinates of your mouse.

3. Color Picker

To help learners identify color values to use in their code, they can launch a color picker from the Easy Draw window.

Note: The color picker is native to the operating system and will look different on different systems.

4. Save the Canvas Drawing

You can save your drawing as a PNG file by clicking the "Save Canvas" button. Just be sure to provide the image with a file name. The image will save in your project's current working directory (most likely the same folder as your code).

🐍