Building GUI applications

We can differentiate between applications which merely work with graphics and applications which are deeply interactive. In the first case, we might have a command-line application which creates or modifies image files. In the second case, we'll define an application which responds to input events. These interactive applications create an event loop which accepts mouse clicks, screen gestures, keyboard characters, and other events, and responds to those events. In some respects, the only unique feature of a GUI program is the wide variety of events it responds to.

The tkinter module is an interface between Python and the Tk user interface widget toolkit. This module helps us build richly interactive applications. When ...

Get Python Essentials now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.