![]() Registered Member ![]()
|
Hi all. I want to start programming something for KDE and I don't know where to start. My first goal is to extend an existing python software with a gtk interface adding a kde interface.
I thought to write this interface in pykde but I haven't found any useful documentation for pykde. So I'm wondering...can I write a pure KDE (C++) interface reusing the python core of the other app or I can just use pykde for writing it? Or it's better to rewrite even the core of the app in KDE (C++)? (I see that "pure" KDE is better documented) Thanks! |
![]() Registered Member ![]()
|
Here is the API reference: http://api.kde.org/pykde-4.5-api/modules.html
And since KDE is Qt-based the PyQt docs should tell you a lot: http://www.riverbankcomputing.com/stati ... t4ref.html http://www.riverbankcomputing.co.uk/sta ... asses.html The rest should be the same as either python or KDE/Qt. Is there anything else you need?
Man is the lowest-cost, 150-pound, nonlinear, all-purpose computer system which can be mass-produced by unskilled labor.
-NASA in 1965 |
![]() Registered Member ![]()
|
Thanks for the info. Another thing...I used Qt Creator for designing the inteface, I compiled it with pykdeuic4 and then I added the code by hand. But if I need to add something on the interface and I recompile it, it will destroy all my code right? So I can use Qt Creator just for designing the inteface the first time right?
|
![]() Registered Member ![]()
|
You should import the class from the file generated by pykdeuic4 and then make a subclass from it. Du the coding in the subclass, then you can run pykdeuic4 again without ruining your code.
As it says in the files generated by pykdeuic4: # WARNING! All changes to this file will be lost.
Best Regards / Med venlig hilsen
Thomas Olsen |
![]() Registered Member ![]()
|
Forgot to mention that the subclass must also be derived from QWidget (or a QWidget derived class).
For example:
Or whatever the file/class are called. Well this is one way to do it ![]()
Best Regards / Med venlig hilsen
Thomas Olsen |
![]() Registered Member ![]()
|
Registered users: Bing [Bot], Evergrowing, Google [Bot], rockscient