加载中...

Python

  1. Home
  2. Computing & Technology
  3. Python

An Introduction to Programming wxPython

By Al Lukaszewski, About.com

2 of 6

Import wxPython

After the bang line, the first step in our simple program is to import the wx module, the main module in the wxPython package. It contains an array of functionality for working with the graphic interface.

import wx

In this guide, we will be using but two classes from the wx library: App and Frame. To get a feel for how many others there are, type the following in a Python shell session:

>>> import wx
>>> dir(wx)

The output will likely scroll off the screen. However, this gives you some idea of the richness of functionality built into the wxPython package.

Explore Python

More from About.com

New Year, New You

Take action today to accomplish your biggest goals with these motivating ideas.

Best Moves in a Bad Economy

Stay on top in this tough economy with our smart, easy-to-follow financial tips.

Python

  1. Home
  2. Computing & Technology
  3. Python

©2009 About.com, a part of The New York Times Company.

All rights reserved.