Add a new module#
New modules can be added for many reasons, the most important one is when Qt enables or includes a new one for a new release.
Adding the bindings, and documentation are the essentials to include new modules, but adding tests and examples is ideal.
Find the correct name (look at the include path of Qt).
Add the module to the
Add it to
Add it to
Copy an existing module to
CMakeList.txt(using for example Qt Creator’s case-preserving replace function).
Make sure the dependencies are correct.
Find the exported public classes, add them to the
typesystem.xmlfile, checking whether they are
object-type. Add their enums and flags.
Add the wrapper files to
Create a test dir under
sources/pyside6/testswith an empty
Try to build with the module added to the
Watch out for shiboken warnings in the log.
Be aware that
ninjamixes stdout and stderr, so, the first warning is typically hidden behind a progress message.
A convenient way of doing this is using
qt-creator/scripts/shiboken2tasks.pyfrom the Qt Creator repository converting them to a
.tasksfile which can be loaded into Qt Creator’s issue pane.
Link errors may manifest when
generate_pyiimports the module trying to create signatures. They indicate a missing source file entry or a bug in the module itself.
For the build to succeed, the module must follow the Qt convention
#include <QtModule/header.h> since module include paths
are not passed in PySide.
Add entry to
Add a .qdocconf.in file in
Add module description