How to initialize a screen to a given size How to use an image as your background How to move the turtle to a given (x, y) position without drawing a line on the screen How to draw a circle, how to draw a square (we covered some of this in class) How to draw filled-in shapes with begin_fill() How to clear the screen after drawing In Python, the center of the screen is at (0, 0) by default. Your program should do the following: Draw a square with a length of 80. The center of your square should be at (0, 0). Use any color you want; in the example screen captures here, I’m using blue. Draw an inscribed circle in the square that was drawn in step 1. Use a different color for your circle. I used magenta but pick any color you like – other than what you used for your square. Due to the way Turtle draws lines and circles, you’ll likely need to experiment with your starting coordinates for your circle draw. Prompt the user for a new (x, y) coordinate for the square, and a new (x, y) coordinate for the circle. “Move” the shapes to their new positions by erasing the original square and circle, and drawing them in the location specified by the user. The redrawn shapes should be solid-filled with the color of your choice (the shapes’ center-points are specified by the information input by the user). Define any functions you need to make this all work. The “app window” is screen capture I saved to a png file, so your drawings might be a pixel or two shifted. That’s okay as long as the placement and movement seem reasonable from the (0, 0) origin you start at. You can assume the user gives you “good data”: values all within the Turtle coordinate system between 200 and -200. Notes: Consider the given .png image of the application window is 970x635 pixels, and that should be the starting size of your Turtle screen. If you don’t remember your geometry, an inscribed circle looks like this, and the diameter is equal to the length of the square’s side. Tips: It’s very difficult to test graphics-related functions without explicit test tools (screen-grabbers, functional test tools, etc.), so your most important job is to ensure your turtle movement and drawing is as consistent as possible. Of note, when you move the turtle, it has a directional heading (N/S/E/W). Take care to set the heading consistently to ensure repeatable drawing of the shapes. You can trust the user to give you good information, and to stay within the ±200 (the default bounds of the drawing canvas coordinates)
How to initialize a screen to a given size How to use an image as your background How to move the turtle to a given (x, y) position without drawing a line on the screen How to draw a circle, how to draw a square (we covered some of this in class) How to draw filled-in shapes with begin_fill() How to clear the screen after drawing In Python, the center of the screen is at (0, 0) by default. Your program should do the following: Draw a square with a length of 80. The center of your square should be at (0, 0). Use any color you want; in the example screen captures here, I’m using blue. Draw an inscribed circle in the square that was drawn in step 1. Use a different color for your circle. I used magenta but pick any color you like – other than what you used for your square. Due to the way Turtle draws lines and circles, you’ll likely need to experiment with your starting coordinates for your circle draw. Prompt the user for a new (x, y) coordinate for the square, and a new (x, y) coordinate for the circle. “Move” the shapes to their new positions by erasing the original square and circle, and drawing them in the location specified by the user. The redrawn shapes should be solid-filled with the color of your choice (the shapes’ center-points are specified by the information input by the user). Define any functions you need to make this all work. The “app window” is screen capture I saved to a png file, so your drawings might be a pixel or two shifted. That’s okay as long as the placement and movement seem reasonable from the (0, 0) origin you start at. You can assume the user gives you “good data”: values all within the Turtle coordinate system between 200 and -200. Notes: Consider the given .png image of the application window is 970x635 pixels, and that should be the starting size of your Turtle screen. If you don’t remember your geometry, an inscribed circle looks like this, and the diameter is equal to the length of the square’s side. Tips: It’s very difficult to test graphics-related functions without explicit test tools (screen-grabbers, functional test tools, etc.), so your most important job is to ensure your turtle movement and drawing is as consistent as possible. Of note, when you move the turtle, it has a directional heading (N/S/E/W). Take care to set the heading consistently to ensure repeatable drawing of the shapes. You can trust the user to give you good information, and to stay within the ±200 (the default bounds of the drawing canvas coordinates)
Programming with Microsoft Visual Basic 2017
8th Edition
ISBN:9781337102124
Author:Diane Zak
Publisher:Diane Zak
Chapter13: Web Site Applications
Section: Chapter Questions
Problem 5E
Related questions
Question
- How to initialize a screen to a given size
- How to use an image as your background
- How to move the turtle to a given (x, y) position without drawing a line on the screen
- How to draw a circle, how to draw a square (we covered some of this in class)
- How to draw filled-in shapes with begin_fill()
- How to clear the screen after drawing
In Python, the center of the screen is at (0, 0) by default.
Your program should do the following:
- Draw a square with a length of 80. The center of your square should be at (0, 0). Use any color you want; in the example screen captures here, I’m using blue.
- Draw an inscribed circle in the square that was drawn in step 1. Use a different color for your circle. I used magenta but pick any color you like – other than what you used for your square. Due to the way Turtle draws lines and circles, you’ll likely need to experiment with your starting coordinates for your circle draw.
- Prompt the user for a new (x, y) coordinate for the square, and a new (x, y) coordinate for the circle.
- “Move” the shapes to their new positions by erasing the original square and circle, and drawing them in the location specified by the user. The redrawn shapes should be solid-filled with the color of your choice (the shapes’ center-points are specified by the information input by the user).
Define any functions you need to make this all work. The “app window” is screen capture I saved to a png file, so your drawings might be a pixel or two shifted. That’s okay as long as the placement and movement seem reasonable from the (0, 0) origin you start at.
You can assume the user gives you “good data”: values all within the Turtle coordinate system between 200 and -200.
Notes:
- Consider the given .png image of the application window is 970x635 pixels, and that should be the starting size of your Turtle screen.
- If you don’t remember your geometry, an inscribed circle looks like this, and the diameter is equal to the length of the square’s side.
Tips:
- It’s very difficult to test graphics-related functions without explicit test tools (screen-grabbers, functional test tools, etc.), so your most important job is to ensure your turtle movement and drawing is as consistent as possible. Of note, when you move the turtle, it has a directional heading (N/S/E/W). Take care to set the heading consistently to ensure repeatable drawing of the shapes.
- You can trust the user to give you good information, and to stay within the ±200 (the default bounds of the drawing canvas coordinates)
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 2 steps
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
Computer Science
ISBN:
9780357392676
Author:
FREUND, Steven
Publisher:
CENGAGE L
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage