[partially solved] Re: [PyQt] KProcess setUsePty not there...

Giovanni Bajo rasky at develer.com
Sun Apr 13 17:47:25 BST 2008

On Sat, 2008-04-12 at 19:53 +0200, Wilbert Berendsen wrote:

> A remaining question, as I can't ask the users of my LilyKDE module to 
> recompile PyKDE: does setUsePty work in mainstream distributions like Ubuntu?

I don't know the answer, but the workaround is a tiny C++ module
(wrapped with SIP) which exposes a single function which calls setUsePty
on the object you pass it, and then monkey-patch KProcess:

void MySetUsePty(KProcess *proc, KProcess::Communication c, bool b)
   proc->setUsePty(c, b);
import useptyfix
KProcess.setUsePty = useptyfix.MySetUsePty

Giovanni Bajo
Develer S.r.l.

More information about the PyQt mailing list