Python GUI Programming with Tkinter –SECOND EDITION!

It’s official, friends — The second edition of my book, Python GUI Programming with Tkinter, is officially available for purchase on Amazon!

Python GUI Programming with Tkinter, Second Edition!

This new edition has been my primary focus since last February, and it’s a lot more than just a dust-off of the text and a new cover. Here’s a rundown of the improvements we’ve made since the first edition:

  • Obviously, we updated the code for Python 3.9 and the latest versions of other libraries (Postgres, Matplotlib, cx_Freeze, etc). Many things that had to be worked around in the first edition are fixed now, so all that’s been updated.
  • The learning curve is completely re-tooled. The first edition jumped straight into OOP usage, which I found caused a lot of beginners to struggle. This version starts out with more procedural Tkinter code for the first few chapters. There is an entire new chapter that specifically covers classes and OOP, and goes through various practical ways you can use classes with a Tkinter application.
  • There is a stronger emphasis and consistency in MVC design throughout the book.
  • The networking section now covers SFTP instead of FTP, for a more modern take on file transfers.
  • We cover more Tkinter widgets, and lots of new things the first edition didn’t cover.
  • Overall the text is fleshed out and more readable; the book is about 50% longer than the original edition!

It’s hard to put into words how much work went into this revision; I had a GREAT editing team this time around and technical feedback from author and coder Alejandro Rodas de Paz (author of Tkinter GUI Application Development Cookbook) who really kept me on my toes!

For my Youtube audience, I hope to get a video together soon to tell you all about it!

5 Thoughts on “Python GUI Programming with Tkinter –SECOND EDITION!

  1. Tobias says:

    hi alan,

    your videos are very informative and i have already learned a lot. i would like to buy your pyqt5 book. however, I wanted to ask whether you are planning a revision here as well. should i wait to buy it?

    greetings from germany


    1. Alan says:

      Hi Tobias! I have no firm plans at the moment for a second edition of the PyQt5 book, though I have talked with Packt about it. We were holding off to complete this project and let PyQt6 mature a bit, so if a second edition happens it’s probably a year away, at the least.

  2. Ryohei Matsumoto says:

    Hi Alan,

    I bought your new book, and it is really helpful. Thank you!

    However, I still have one problem unsolved. I am coding for an app, which has a canvas showing and updating live image from a web-cam. To update the image, I use threading.Thread(). It causes flickering video. I am sure that the tkinter recommends after() instead of threading(), but I need to manage the task with threading() to keep the mainloop unused. Could you please suggest me any idea to realize video stream without blinking by using threading()?



    1. Alan says:

      Hi Ryohei,

      Thanks for buying the book!

      So, after() is not the same as threading; it defers a task by putting it in the Tkinter event queue, but it still runs the task in the main thread. If your updating process is very fast (a few milliseconds) it might be acceptable to simplify your code using after() instead of threads, but the app will be frozen while it runs.

      As to why you’re getting flickering with threads, it’s hard to say without seeing your code. How quickly are you trying to update the canvas?

      1. Ryohei Matsumoto says:

        Hi Alan,

        Thank you for your quick reply,

        The canvas is updated at about 30 fps. I use the original image from web-cam (full HD) to be displayed on the canvas. Should I drop the image quality to make the task less heavy?


Leave a Reply

Your email address will not be published.