[PyKDE] Beginner Questions (coming from KJSEmbed)
Phil Thompson
phil at riverbankcomputing.co.uk
Wed Sep 15 17:58:50 BST 2004
On Wednesday 15 September 2004 5:34 pm, Hihn, Jason wrote:
> I've been trying to use KJSEmbed (the qt/kde/javascript engine) but I am
> having maturity problems with it. I understand that PyQt is more mature?
The first release was November 1998 for Qt v1.41.
> I am hoping someone can answer these basic questions:
>
> 1) Does it have an embeddable interpreter? Can we create an interpreter
> object in a C++ program, give it the code wither as string or a
> filename, and have it execute, and retrieve values of objects from the
> interpreter when the script is done?
Yes. This is a function of Python rather than PyQt.
> 2) Is it MSVC 6 or 7 compatible? Can it be compiled and linked in to an
> existing MFC program?
Yes.
> 3) What are the size/execution speed costs, if known?
The bindings are very thin. The main PyQt module is a 3M DLL on Windows. Costs
have never been measured because AFAIK they have never been an issue.
> 4) How are custom bindings to custom binary controls handled? (This is
> the biggest problem with KJSEmbed for me ATM) While we could script it,
> it's just too slow. I'd like an easy way to extend the interpreter to
> use a binary control.
You generate your own extension module using SIP. Alternatively, ActiveX
support is planned for the version after next.
> 5) Are there any glaring omissions in this technology?
Not that I'm aware of. You can do 99% of what you can do in C++ in Python -
but with fewer lines of code and much less programmer time.
> 6) Aside from the above, how does it compare and rank with KJSEmbed?
Can't comment on that.
Phil
More information about the PyQt
mailing list