[PyKDE] SIP: undocumented API for enums
Phil Thompson
phil at riverbankcomputing.co.uk
Tue Mar 21 20:56:22 GMT 2006
On Tuesday 21 March 2006 6:56 pm, Giovanni Bajo wrote:
> Phil Thompson <phil at riverbankcomputing.co.uk> wrote:
> >> I found out there is an undocumented "sipConvertFromNamedEnum". Should
> >> it be documented? Maybe there are other undocumented functions as well.
> >
> > There are lots of undocumented functions. They are undocumented because
>
> they
>
> > are not intended to be used - unless you can show why you need them.
>
> It was the only way I could find to wrap a function like this one:
>
> enum Foo { A, B, C };
> Foo* getFoos(int *size); //*size is the length of the returned array
>
> so that it returns a python list of instances of Foo. Is there another way?
sipBuildResult()
However I notice that I've used it myself in handwritten code in PyQt4, so
I'll document it.
Phil
More information about the PyQt
mailing list