Chapter 16
Creating Graphical User Interfaces

Most of the programs in previous chapters are not interactive. Once launched, they run to completion without giving us a chance to steer them or provide new input. The few that do communicate with us do so through the kind of text-only command-line user interface, or CLUI, that would have already been considered old-fashioned in the early 1980s.

As you already know, most modern programs interact with users via a graphical user interface, or GUI, which is made up of windows, menus, buttons, and so on. In this chapter, we will show you how to build simple GUIs using a Python module called tkinter. Along the way, we will introduce a different way of structuring programs called event-driven programming. A traditionally structured program usually has control over what happens when, but an event-driven program must be able to respond to input at unpredictable moments.

tkinter is one of several toolkits you can use to build GUIs in Python. It is the only one that comes with a standard Python installation.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.188.119.81