[Kde-bindings] Re: Review Request: Add konsole support to PyKDE4

Shaheed Haque srhaque at theiet.org
Tue May 3 22:24:18 UTC 2011


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/101269/
-----------------------------------------------------------

(Updated May 3, 2011, 10:24 p.m.)


Review request for KDE Bindings.


Changes
-------

Implemented something like the previously mentioned alternative design. I didn't find a way to use static methods, but the C++ KTerminal class is now much smaller, and the resulting example code is much more vanilla "KDE code".


Summary
-------

In order to deal with the need for qobject_cast in the usage model for KTerminalInterface{,V2}, I created a C++ class KTerminal and built on top of that. Feeedback on whether this is a reasonable approach or not, and if it is, how best to get it documented in the right places is welcome (e.g. maybe it should be added to kdelibs/interfaces/terminal).

Other than that, I've tried to mirror the way ktexteditor is handled within PyKDE4.

I'm also consiering an alternative design which would wrap the qobject_cast<TerminalInterfaceV2*> in a static method wrapped in Python (if I can figure out how to do that). This would result in a considerable slimming down of non-standard code compared to the current approach (I think).


Diffs (updated)
-----

  CMakeLists.txt 54373d3 
  examples/kpartsExamples/konsolepart.py PRE-CREATION 
  sip/kterminal/kterminal.sip PRE-CREATION 
  sip/kterminal/kterminalmod.sip PRE-CREATION 
  sip/kterminal/terminal_interface.sip PRE-CREATION 
  sip/kterminal/terminal_interface_v2.sip PRE-CREATION 

Diff: http://git.reviewboard.kde.org/r/101269/diff


Testing
-------

A simple test program in Python can create a KTerminal instance (i.e. a konsole).


Thanks,

Shaheed

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-bindings/attachments/20110503/a5d5cc54/attachment.html>


More information about the Kde-bindings mailing list