[dot] FOSDEM 2005: Python Bindings Interview
Dot Stories
stories at kdenews.org
Sat Feb 19 03:02:11 CET 2005
URL: http://dot.kde.org/1108778399/
From: Jonathan Riddell <>
Dept: something-completely-different
Date: Saturday 19/Feb/2005, @02:59
FOSDEM 2005: Python Bindings Interview
======================================
Simon Edwards [http://www.simonzone.com/] will be talking about KDE
application development using Python in the FOSDEM KDE Developer's Room
[http://www.fosdem.org/2005/index/dev_room_kde]. In the interview below
he talks about the advantages of Python, how it compares to other
languages and whether KDE should be rewritten in Python.
Please introduce yourself and your role in KDE
I started using KDE as a user and application developer when KDE
1.0 came out. Since then I've developed a Linux firewall utility called
Guarddog, and beginning with KDE 3.3 I've been maintaining a copy of the
Qt/KDE Python bindings in KDE CVS kdebindings module. I've also got a
KDE/Python project or two on the go and am involved with KDE-NL.
How does Python compare to C++ or other high level languages for
KDE development?
I think it's an excellent language for developing KDE applications.
In my opinion it is a better language choice than C++ for most
applications. Python is a mature language with the features you need to
be able to develop fast and effectively. It has the usual features that
you expect to see in a high level language, classes/OOP, exceptions,
garbage collection, and so on and so on. But the feature I like the most
is that it works the way you expect it to. There are very few hidden
catches, and the language is small and simple enough that it will fit in
your head. All together this makes development a lot faster and a lot
more enjoyable.
Why do you think that so few KDE applications have been written
with Python, given the maturity of the bindings?
Getting a working set of bindings compiled and installed has
traditionally meant downloading and building 3 different pieces of
software and making sure that you've picked a set of versions that are
mutually compatible and compatible with your version of KDE/Qt. This has
acted as a deterrent to anyone wanting to write and distribute Python
software that users can easily install and use. And since there are few
KDE Python programs, distributors have had little incentive to package
and distribute the bindings. Catch-22.
Now, that is KDE applications, Qt based applications are a
different story. Phil Thompson tells me that hundreds of commercial
licenses have been sold for the Qt part of the bindings. The next
commercial Qt application you see could very well have Python under the
hood.
Do you hope that one day Python may be the native language for KDE
or Qt?
I'd certainly like to see the day when higher level languages are
regulary used for KDE development. Interest in languages other than C++
certainly seems to be increasing inside the KDE project. So I don't
think we will have to wait long before that day comes. After all much of
the computer industry has always moved to higher level languages where
possible. Look at the use of Java in business, or even, dare I say,
Visual Basic. There is probably more high level code being written these
days than C and C++.
Would it be realistic to write the whole of KDE in Python?
Well, you've got the technical problem of how would other languages
interface with KDE objects written in Python, and the fact that some
parts of KDE are speed critical, think GUI drawing and rendering.
However, I think there are large tracts of KDE that could be written
using Python. The KDE Control Centre is a good example. There is really
no reason why the whole thing couldn't be done using Python.
How do you see the Python bindings fitting in with other
technologies like Korundum, KJSEmbed and Kommander?
I see Python as an alternative to C++ for application development.
Kommander is directed more towards the rapid development of GUI front
ends to shell programs. KJSEmbed strikes me as being better suited for
scripting and macros inside a host program, than for application
development. I have my doubts about the suitability of Javascript for
large programs. Mind you, the Mozilla people have been doing this for
quite some time now. Anyway, there are lots of places that can use
different programming tools. There is room for everyone.
Lastly, some thanks need to go out to Phil Thompson and Jim
Bublitz. The people who did the hard work of creating the Python
bindings in the first place. Thanks guys!
More information about the dot-stories
mailing list