Hi,
I've started to use shiboken to bind my cpp lib to python and I have a couple 
of questions related to the namespaces.
So from what I've seen if a use a namespace in .xml file definition, shiboken 
will create a class with the same name and it will use this class as namespace.
But, there is a way to bind a function ro a class that in my cpp code is in a 
namespace to a global function or class without namespace in python?

for example in my cpp code

namespace Foo
{
    void initFoo();
}

in shiboken the only way I found to export this function is this:
.xml file

<?xml version="1.0" encoding="utf-8"?>
<typesystem package="MyPkg">
  <namespace-type name="Foo">
    <function signature="initFoo()"/>
  </namespace-type>
</typesystem>

if I try something like this it doens't work:
<typesystem package="MyPkg">
<function signature="initFoo()"/>
</typesystem>

or 

<typesystem package="MyPkg">
<function signature="Foo::initFoo()" rename="initFoo"/>
</typesystem>


anyone know if there is a solution to this problem?

Thank you
Alan


                                          
_______________________________________________
PySide mailing list
PySide@qt-project.org
http://lists.qt-project.org/mailman/listinfo/pyside

Reply via email to