Installing pygtk in Python2.3 under Windows, the version is always a problem, tried several times of experiment success,
Python2.3.3pygtk-2.2.0.win32-py2.3.exe (or Pygtk-2.2.0-1.win32-py2.3.exe) gtk-runtime-environment-2.2.4.exe (or gtk-runtime -ENVIRONMENT-2.2.4.2.EXE)
If you install the above, if you still have other GTK things on the machine, it is difficult to guarantee the version, gtk-runtime-environment-2.2.4.exe is installed, put the C: / Program Files / Common files / GTK / 2.0 / lib (specific installation path) is added to PATH, this is its dynamic connection library.
Pygtk-2.2.0.win32-py2.3.exe here: http://www.pcpm.ucl.ac.be/~gusti n / win32_ports / binaries / pygtk-2.2.0.win32-py2.3. EXE
Pygtk-2.2.0-1.win32-py2.3.exe here: http://www.pcpm.ucl.ac.be/~gus tin / win32_ports / binaries / pygtk-2.2.0-1.win32- Py2.3.exe
GTK-Runtime-Environment-2.2.4.exe here: http://www.org.lcs.mit.edu/6.893/files/gtk -runtime-environment-2.2.4.exe is also available on SourceForge.net : Http://sourceforge.net/projects/gtk-win/
Tool recommendation: Glade2 http://gladewin32.sourceforge.net/
Test code
CODE:
import gtkdef hello_cb (button): print "Hello World" window.destroy () window = gtk.Window (gtk.WINDOW_TOPLEVEL) # create a top level windowwindow.connect ( "destroy", gtk.mainquit) # quit the event loop on destructionwindow.set_border_width (10) # set padding round child widgetbutton = gtk.Button ( "Hello World") button.connect ( "clicked", hello_cb) # call hello_cb when clickedwindow.add (button) # add button to windowbutton.show ( # Show buttonwindow.show () gtk.main ()