Last active
February 24, 2019 19:51
-
-
Save bashbaugh/efeb8dca816d47c0bbe8ebb3fa531455 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function draw_background() | |
| { | |
| // First we erase everything on the canvas: | |
| canvas.clearRect(0, 0, canvas_element.width, canvas_element.height); | |
| // And then we change the color of our "paintbrush": | |
| canvas.fillStyle = "#1EBA00"; | |
| // And then we draw a colored rectangle that covers the entire canvas: | |
| canvas.fillRect(0, 0, canvas_element.width, canvas_element.height); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment