aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/plugins/customwidget.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Rename PySide2 to PySide6Friedemann Kleint2020-11-021-138/+0
| | | | | | | | Adapt CMake files, build scripts, tests and examples. Task-number: PYSIDE-904 Change-Id: I845f7b006e9ad274fed5444ec4c1f9dbe176ff88 Reviewed-by: Christian Tismer <tismer@stackless.com>
* Brush up the code related to custom widgets in the QUiLoader moduleFriedemann Kleint2020-07-211-38/+28
| | | | | | | | | | | | | | | - Modernize, use override, nullptr - Fix include conventions - Remove *Private structs. They don't make sense in a static plugin. - Add some explanatory comments - Add missing initializations of members - Most importantly: add error handling to PyCustomWidget::createWidget(), which so far would swallow all errors encountered when executing the Widget's __init__ function. Change-Id: I100a4239013f959c8fb0b0adc0d3a99f73bd4bff Reviewed-by: Christian Tismer <tismer@stackless.com>
* Cleanup pointer whitespace everywhereChristian Tismer2019-06-241-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Among other files to fix, basewrapper.(cpp|h) was full of uncommon pointer whitespace. After fixing that, I could not resist and fixed also libshiboken, generators, and after acceptance also PySide. Most of the time, this regex worked fine (\w\w+)([*&]+)[ ]*(?![&*]*[/=]) replaced with \1 \2 but everything was checked by hand. I did not touch the shiboken tests which are quite hairy. It turned out that inserting a space between a variable and asterisk causes a crash of shiboken, if the same line contains "CONVERTTOCPP". This was temporarily fixed by adding another space after it. Example.. sources/pyside2/PySide2/glue/qtcore.cpp line 977 QByteArray * cppSelf = %CONVERTTOCPP[QByteArray *](obj); //XXX /|\ omitting this space crashes shiboken! cppgenerator.cpp was special, since it was modified to _generate_ correct pointer whitespace. This caused a few testcases to fail, which had to be adjusted, again. This was difficult since some internal names must end on "*" and generated code normally not. Removing the last errors involved binary search on path sets... Apply C++ 11 fixits to the changed code, where applicable. Done-with: Friedemann.Kleint@qt.io Task-number: PYSIDE-1037 Change-Id: I4ac070f52c5efb296c05d581c9d46e6f397a6c81 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Pep 384 Final Cut: Remove PepTypeChristian Tismer2018-07-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | While trying to document the Limited API Project, it suddenly struck me: We can make the patch much much simpler and implement it without the necessity to have an extra PepType! Now I am happy to continue the documentation, because it is now no more improvable. This version will last as long as the layout of PyTypeObject does not change substantially. When that happens, then we need to rewrite stuff with the according PyType_GetSlot() access functions. These access functions will until then be complete enough so that we can live without the tricks like inventing a reduced PyTypeObject as was done in the current implementation. Task-number: PYSIDE-560 Change-Id: I49849cc377baa6794a5b53292691e21d6e2853ab Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* PEP 384-squash: Implement PEP 384Christian Tismer2018-05-301-1/+1
| | | | | | | | | | This is the condensed checkin of 18 commits which created the implementation of PEP 384. Task-number: PYSIDE-560 Change-Id: I834c659af4c2b55b268f8e8dc4cfa53f02502409 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Change license from all the filesCristian Maureira-Fredes2018-05-031-1/+1
| | | | | | | | | | | | | | | | | Removing the word 'project' from all the headers, and changing the PySide reference from the examples to Qt for Python: The following line was used inside the source/ and build_scripts/ directory: for i in $(grep -r "the Qt for Python project" * |grep -v "pyside2-tools" | awk '{print $1}' | sed 's/:.*//g');do sed -i 's/the\ Qt\ for\ Python\ project/Qt\ for\ Python/g' $i;done and the following line was used inside the examples/ directory: for i in $(grep -r "of the PySide" * |grep -v "pyside2-tools" | awk '{print $1}' | sed 's/:.*//g');do sed -i 's/of\ the\ PySide/of\ the\ Qt\ for\ Python/g' $i;done Change-Id: Ic480714686ad62ac4d81c670f87f1c2033d4ffa1 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Rename PySide references to Qt for PythonCristian Maureira-Fredes2018-04-271-1/+1
| | | | | | | | | When referring to the project one should use "Qt for Python" and for the module "PySide2" Change-Id: I36497df245c9f6dd60d6e160e2fc805e48cefcae Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* move everying into sources/pyside2 (5.9 edition)Oswald Buddenhagen2017-05-221-0/+148
in preparation for a subtree merge. this should not be necessary to do in a separate commit, but git is a tad stupid about following history correctly without it.