Invoking super().Draw in GridCellRenderer

Hello Robin and all. Happy holidays!

I have a fairly technical question. In summary: Is it possible to invoke super().Draw in a custom GridCellRenderer?

Longer discussion:

From: we remark that Draw is pure virtual but has a default implementation that prepares the display context.

I was thinking of invoking super().Draw(...) as part of my own renderer’s Draw method but this does not work raising an exception to the effect that Draw is virtual.

I was looking at to see if there was something obvious (to me) that I could change. To that effect I looked at the SIP docs at and I noticed we can use virtualCatcherCode to provide a default python implementation, and remark that you use it in some parts of the code, but I do not think this was what we want in this case, is it?.

What do you think? Is there something we can do to allow invoking the default implementation of Draw in a custom GridCellRenderer?

Evidently this is not a big thing as one can just reimplement the default implementation in python trivially.

Thank you. Best regards,


In C++ a pure virtual with an implementation is not a common thing. (Personally I would call it an oxymoron…) Since SIP can’t tell if there is an implementation or not, it has to assume that the pure virtual really is a pure virtual with no implementation.

I can easily override this in the etg/, and so far it seems to be working okay. Once I ensure that compilers on the other platforms are still happy then I’ll commit the change.

Thank you, Robin. I look forward to see what the solution looks like and learn something.

With the ETG framework used for converting from Doxygen XML to SIP code it is simply a matter of turning off the pure virtual flag for that method.

1 Like