[pygtk] PyGTK GUI for a C program?
John Pye
john at curioussymbols.com
Thu Oct 16 14:17:52 WST 2008
Hi Jeff
You should not overlook the option of using SWIG. It is very powerful
and works well even with unmodified C and C++ header files. SWIG doesn't
only work with Python, which is nice advantage.
We use SWIG with the ASCEND project, to wrap our solver 'engine'; the
GUI is implemented in Python with PyGTK.
http://ascend.cheme.cmu.edu/
Coding a GTK GUI in PyGTK is much more convienient than in C - much less
verbose. I think that using PyGTK helps to keep a clean division between
GUI code and 'library' or 'engine' code.
Cheers
JP
Jeff Bullard wrote:
> I decided to scrap the python and go with the C interface to GTK.
> Learning PyGTK first certainly made it easier. I'm still struggling
> with a few things but I think the code will be cleaner this way.
> Good thing is that I can use the same glade xml file that I used with
> PyGTK.
>
> Pyrex looks convenient but I frequently modify the C code. That would
> require translating to Pyrex every time I make changes.
More information about the pygtk
mailing list