How to Test GUI Apps for many Python X GUI toolkits

Mark Summerfield list at
Sun Jun 3 09:55:39 CEST 2012


There are many options for writing desktop GUI applications with
Python and I'd like to explore some of them. However, to do this I
need to be able to test various Python 3.x X GUI toolkit y.z

With PyQt4 this is easy. (Example given at the end.)

I'd like to be able to do the same with other Python GUI toolkits.

- For PyGObject (PyGtk's successor) it seems that you have to do a
local build of Gtk+ and the PyGObject. I've tried and failed on this.
(And even if I'd succeeded, I don't see how to do this for local

- I haven't tried this for wxPython (& anyway they don't seem to have
a Python 3 version).

- I've also failed to do this for Tcl/Tk (as per my posting "Use a
locally built Tk for Python?". It is easy to build local versions of
Tcl/Tk using --prefix; but I don't see how to make the Python build
process use a locally built Tcl/Tk.

- I haven't tried this for PySide.

Has anyone else succeeded for any of these? Surely they must have;
otherwise how could they test their PyGObject/wxPython/Tkinter

I'd appreciate suggestions/links.


Example: build two Python 3.2s one with Qt 4.7 and one with Qt 4.8:

- Build local pythons, e.g.,
  ./configure --prefix=/home/me/opt/py32qt47
  ./configure --prefix=/home/me/opt/py32qt48
- Build local Qts, e.g.,
  ./configure --prefix=/home/me/opt/qt47
  ./configure --prefix=/home/me/opt/qt48
- Build PyQts specifying which Python & Qt to use, e.g.,
  /home/me/opt/py32qt47/bin/python3 --qmake=/home/me/opt/
  /home/me/opt/py32qt48/bin/python3 --qmake=/home/me/opt/

This makes it easy to test PyQt GUI applications. And, of course, if a
user reports a problem with some other combination, it is easy (if
time consuming) to create a matching combination to test.

More information about the Python-list mailing list