[PyKDE] Getting control over the Tab key

Konrad Hinsen hinsen at cnrs-orleans.fr
Thu Oct 24 10:25:00 BST 2002


Phil Thompson <phil at river-bank.demon.co.uk> writes:

> That's because you aren't keeping a reference to the FilterObject
> instance so it gets garbage collected immediately.

I admit that the ownership details in PyQt still surprise me
occasionally. How can installEventFilter() possibly work without
keeping a reference on the object that is passed to it? What does it
keep, if not a reference? If it kept just the address without
increasing the Python reference counter, then my code should crash.

Konrad.




More information about the PyQt mailing list