Challenging python coders: Who can create a gnucash-like GUI in python in a few weeks?
Christian Stimming
stimming at tuhh.de
Mon Jan 10 05:24:55 EST 2011
Dear all,
We've been discussing various future directions for gnucash, including
a switch to a different programming language for the GUI code [1]. GUI
coding in C sucks. Because of this, I've experimented with C++/Qt and
was able to write up a usable gnucash-like register window GUI in 2-3
weeks which already includes features that are unavailable in
"conventional gnucash" [2]. I chose C++/Qt because I'm very familiar
and productive with that platform.
However, a scripting language might be even more suitable for writing
the GUI code of a project like gnucash. The language Python is a
particularly good candidate here because gnucash already has python
wrappers for most of its underlying data type and storage code,
thankfully provided by Mike Evans and others. See
src/optional/python-bindings/ and the doxygen output [3] and the
example scripts in python-bindings/example_scripts/, in particular
scripts like simple_book.py: Loading an existing file, modifying some
of the data, and writing again, all in 12 lines.
Here's my challenge to coders who *are* familiar with GUI coding in
python (because I'm not): Who of you is able to write up some python
code that creates a gnucash-like GUI, using the existing python
wrappers to re-use the data store of normal gnucash, but your python
code is at least a thousand times more elegant than the previous code?
And you won't need more than 1-2 weeks to achieve something where we
can view our data files and enter new transactions, will you? I was
able to do this in C++/Qt in four weeks; are you able to do it in
python in two?
If your results are convincing, I will join. I am extremely curious to
see how python can drive the GUI of a large application like gnucash.
I experimented in one direction; now I want to learn about other
possible directions. In case the results turn out unconvincing - well,
you cannot loose more than a little bit of time and we will all have
learnt something about the potentials and limitations here. But if you
achieve something convincing, you will of course gain unlimited
bragging rights that python "is the language of choice for
discriminating hackers..." [4]
And now, let the coding begin!
Best Regards,
Christian
[1]
http://lists.gnucash.org/pipermail/gnucash-devel/2010-December/030516.html and
thread
[2] http://wiki.gnucash.org/wiki/Cutecash
[3] http://svn.gnucash.org/docs/HEAD/python_bindings_page.html
[4] http://en.wikipedia.org/wiki/ICFP_Programming_Contest#Prizes
More information about the gnucash-devel
mailing list