It n this part of the book, we will explore the essential widgets that make up the core of the wxPython toolkit. These basics will be a critical part of any wxPython program you write. For each element, we'll show you the most important parts of the API for dealing with that element, as well as sample code and tips on how to use the element in actual programs.
Chapter 7, "Working with the basic controls," starts us off with the basic widget set. We'll cover text labels, text entry, buttons, and numerical and list choice widgets. We'll show you how to use each element, how to customize its look to match your application, and how to respond to user interaction. In chapter 8, "Putting widgets in frames," we'll move up the container hierarchy and talk about frames. We'll show you how to add widgets into a frame, and describe the available frame styles. We'll also cover the frame lifecycle from creation to destruction. In chapter 9, "Giving users choices with dialogs," we'll focus on dialogs, starting with the ways in which dialog containers differ from frames. We'll also show the range of predefined dialogs available in wxPython, as well as shortcuts for using them easily.
The focus of chapter 10, "Creating and using wxPython menus," is on menus. We'll discuss how to create menu items, which can be attached to menus, which can be placed on a menu bar. We'll also cover toggle menus, pop-up menus, and various ways to customize your menu display. In chapter 11, "Placing widgets with sizers," we demystify the art of the sizer. Sizers are used to simplify widget layout inside wxPython frames and dialogs. We'll cover the six kinds of predefined sizers, show you how they behave, and give some hints on when they are best used. Finally, in chapter 12, "Manipulating basic graphical images," we discuss the raw basics of drawing to the screen via a device context. This section lists the primitive drawing methods that you can use to draw your own widgets, or to support user drawing, or just for decoration.
Was this article helpful?