Fun with Canvas

Canvas is undoubtedly one of the most versatile widgets of Tkinter. Given that it provides direct control over the drawing of each individual pixel, combine it with some maths and it can be used to create all sorts of neat visualizations. While the possibilities are endless, we will explore how to implement some of the important mathematical ideas in this chapter.

The key objectives for this chapter are:

  • Learning to animate with the Tkinter canvas
  • Understanding the usage of polar and Cartesian coordinates on the canvas
  • Implementing ordinary differential equations
  • Modeling simulations given a list of formulas
  • Modeling 3D graphics and studying some common transformation matrices used in 3D animation

Note that many of the code ...

Get Tkinter GUI Application Development Blueprints - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.