diff options
author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2020-09-29 07:35:34 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2020-09-29 07:35:34 +0200 |
commit | 3bbcb7b0e6e0342569aa155d695bca46a7459eb0 (patch) | |
tree | e3675d77f409db4ecbc4f92cdfdbfa62763cb2d4 /sources/pyside2 | |
parent | 9881b68c4c7bc1715cd266c41c63a3a918d83b07 (diff) | |
parent | 50247e7d4a67e892a85dff7472f889bac97c91c7 (diff) |
Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: Ie6da3938b82f5ebe96dd12bd65a3ccc4180d2fba
Diffstat (limited to 'sources/pyside2')
-rw-r--r-- | sources/pyside2/PySide2/QtQml/pysideqmlregistertype.cpp | 4 | ||||
-rw-r--r-- | sources/pyside2/doc/deployment-briefcase.rst | 4 | ||||
-rw-r--r-- | sources/pyside2/doc/deployment.rst | 2 | ||||
-rw-r--r-- | sources/pyside2/doc/faq.rst | 4 | ||||
-rw-r--r-- | sources/pyside2/doc/gettingstarted.rst | 3 | ||||
-rw-r--r-- | sources/pyside2/doc/index.rst | 4 | ||||
-rw-r--r-- | sources/pyside2/doc/tutorials/portingguide/chapter3/chapter3.rst | 2 | ||||
-rw-r--r-- | sources/pyside2/doc/tutorials/qmlsqlintegration/qmlsqlintegration.rst | 14 | ||||
-rw-r--r-- | sources/pyside2/libpyside/pysideclassinfo.cpp | 2 | ||||
-rw-r--r-- | sources/pyside2/libpyside/pysidemetafunction.cpp | 2 | ||||
-rw-r--r-- | sources/pyside2/libpyside/pysideproperty.cpp | 2 | ||||
-rw-r--r-- | sources/pyside2/libpyside/pysidesignal.cpp | 6 | ||||
-rw-r--r-- | sources/pyside2/libpyside/pysideslot.cpp | 2 |
13 files changed, 28 insertions, 23 deletions
diff --git a/sources/pyside2/PySide2/QtQml/pysideqmlregistertype.cpp b/sources/pyside2/PySide2/QtQml/pysideqmlregistertype.cpp index a933876e4..fd470cd71 100644 --- a/sources/pyside2/PySide2/QtQml/pysideqmlregistertype.cpp +++ b/sources/pyside2/PySide2/QtQml/pysideqmlregistertype.cpp @@ -626,7 +626,7 @@ static const char *VolatileBool_SignatureStrings[] = { void PySide::initQmlSupport(PyObject *module) { // Export QmlListProperty type - if (SbkSpecial_Type_Ready(module, PropertyListTypeF(), PropertyList_SignatureStrings) < 0) { + if (InitSignatureStrings(PropertyListTypeF(), PropertyList_SignatureStrings) < 0) { PyErr_Print(); qWarning() << "Error initializing PropertyList type."; return; @@ -639,7 +639,7 @@ void PySide::initQmlSupport(PyObject *module) PyModule_AddObject(module, PepType_GetNameStr(PropertyListTypeF()), reinterpret_cast<PyObject *>(PropertyListTypeF())); - if (SbkSpecial_Type_Ready(module, QtQml_VolatileBoolTypeF(), VolatileBool_SignatureStrings) < 0) { + if (InitSignatureStrings(QtQml_VolatileBoolTypeF(), VolatileBool_SignatureStrings) < 0) { PyErr_Print(); qWarning() << "Error initializing VolatileBool type."; return; diff --git a/sources/pyside2/doc/deployment-briefcase.rst b/sources/pyside2/doc/deployment-briefcase.rst index fec5e0d56..a5179a279 100644 --- a/sources/pyside2/doc/deployment-briefcase.rst +++ b/sources/pyside2/doc/deployment-briefcase.rst @@ -160,7 +160,7 @@ It creates a subdirectory each for the different platforms. This step takes longer as it adds the packages listed in `requires` sections in the `pyproject.toml` file. Build the application ---------------- +--------------------- :: briefcase build @@ -175,7 +175,7 @@ You'll get:: Run the application ------------ +------------------- :: briefcase run diff --git a/sources/pyside2/doc/deployment.rst b/sources/pyside2/doc/deployment.rst index 414a468ed..3d6aa218e 100644 --- a/sources/pyside2/doc/deployment.rst +++ b/sources/pyside2/doc/deployment.rst @@ -101,7 +101,7 @@ these tools don't offer a mechanism to update your application packages. To create update packages, use the `PyUpdater <https://www.pyupdater.org/>`_, which is a tool built around PyInstaller. -The `fbs <https://build-system.fman.io>`_ tool offers a nice UI for the user to install the +The `fbs`_ tool offers a nice UI for the user to install the application step-by-step. .. note:: diff --git a/sources/pyside2/doc/faq.rst b/sources/pyside2/doc/faq.rst index f1aa3ebcc..b7e9816c8 100644 --- a/sources/pyside2/doc/faq.rst +++ b/sources/pyside2/doc/faq.rst @@ -1,3 +1,7 @@ +.. _faq: + +:orphan: + Frequently Asked Questions ========================== diff --git a/sources/pyside2/doc/gettingstarted.rst b/sources/pyside2/doc/gettingstarted.rst index b8d6f9e45..197657493 100644 --- a/sources/pyside2/doc/gettingstarted.rst +++ b/sources/pyside2/doc/gettingstarted.rst @@ -7,10 +7,9 @@ with ``pip`` you need to run:: pip install pyside2 for more details, refer to our `Quick Start`_ guide. Additionally, you can -check the `FAQ`_ related to the project. +check the :ref:`FAQ <faq>` related to the project. .. _Quick Start: quickstart.html -.. _FAQ: faq.html General Requirements -------------------- diff --git a/sources/pyside2/doc/index.rst b/sources/pyside2/doc/index.rst index 289a653f3..ed5aeb6b4 100644 --- a/sources/pyside2/doc/index.rst +++ b/sources/pyside2/doc/index.rst @@ -5,13 +5,13 @@ **Qt for Python** offers the official Python bindings for `Qt`_ (`PySide2`_), so that you can use Qt5 APIs in your Python applications, and a binding generator tool - (`Shiboken2 <shiboken2/index.html>`_) which can be used to expose C++ projects into Python. + (`Shiboken2 <shiboken2/index.html>`__) which can be used to expose C++ projects into Python. .. ifconfig:: output_format == 'qthelp' **Qt for Python** offers the official Python bindings for `Qt`_ (`PySide2`_), so that you can use Qt5 APIs in your Python applications, and a binding generator tool - (`Shiboken2 <../shiboken2/index.html>`_) which can be used to expose C++ projects into Python. + (`Shiboken2 <../shiboken2/index.html>`__) which can be used to expose C++ projects into Python. |project| is available under the LGPLv3/GPLv3 and the Qt commercial license. diff --git a/sources/pyside2/doc/tutorials/portingguide/chapter3/chapter3.rst b/sources/pyside2/doc/tutorials/portingguide/chapter3/chapter3.rst index 71b254811..6d7db9ef5 100644 --- a/sources/pyside2/doc/tutorials/portingguide/chapter3/chapter3.rst +++ b/sources/pyside2/doc/tutorials/portingguide/chapter3/chapter3.rst @@ -34,7 +34,7 @@ C++ version .. literalinclude:: bookwindow.cpp :language: c++ :linenos: - :lines: 47-115 + :lines: 57-140 Python version --------------- diff --git a/sources/pyside2/doc/tutorials/qmlsqlintegration/qmlsqlintegration.rst b/sources/pyside2/doc/tutorials/qmlsqlintegration/qmlsqlintegration.rst index c26d154ac..f675f7899 100644 --- a/sources/pyside2/doc/tutorials/qmlsqlintegration/qmlsqlintegration.rst +++ b/sources/pyside2/doc/tutorials/qmlsqlintegration/qmlsqlintegration.rst @@ -99,9 +99,10 @@ There are three properties that are almost always set when using ApplicationWind Once we've set these, we have a properly sized, empty window ready to be filled with content. There are two ways of laying out items in QML: `Item Positioners`_ and `Qt Quick Layouts`_. -* Item positioners (`Row`_, `Column`_, and so on) are useful for situations where the size of items + +- Item positioners (`Row`_, `Column`_, and so on) are useful for situations where the size of items is known or fixed, and all that is required is to neatly position them in a certain formation. -* The layouts in Qt Quick Layouts can both position and resize items, making them well suited for +- The layouts in Qt Quick Layouts can both position and resize items, making them well suited for resizable user interfaces. Below, we use `ColumnLayout`_ to vertically lay out a `ListView`_ and a `Pane`_. @@ -205,14 +206,15 @@ if it doesn't already exist. A few interesting things happen in the ``main`` function: -* Declaring a :ref:`QGuiApplication`. + +- Declaring a :ref:`QGuiApplication`. You should use a :ref:`QGuiApplication` instead of :ref:`QApplication` because we're not using the **QtWidgets** module. -* Connecting to the database, -* Declaring a :ref:`QQmlApplicationEngine`. +- Connecting to the database, +- Declaring a :ref:`QQmlApplicationEngine`. This allows you to access the QML context property to connect Python and QML from the conversation model we built on ``sqlDialog.py``. -* Loading the ``.qml`` file that defines the UI. +- Loading the ``.qml`` file that defines the UI. Finally, the Qt application runs, and your program starts. diff --git a/sources/pyside2/libpyside/pysideclassinfo.cpp b/sources/pyside2/libpyside/pysideclassinfo.cpp index 375a31b57..aa47f97c1 100644 --- a/sources/pyside2/libpyside/pysideclassinfo.cpp +++ b/sources/pyside2/libpyside/pysideclassinfo.cpp @@ -184,7 +184,7 @@ static const char *ClassInfo_SignatureStrings[] = { void init(PyObject *module) { - if (SbkSpecial_Type_Ready(module, PySideClassInfoTypeF(), ClassInfo_SignatureStrings) < 0) + if (InitSignatureStrings(PySideClassInfoTypeF(), ClassInfo_SignatureStrings) < 0) return; Py_INCREF(PySideClassInfoTypeF()); diff --git a/sources/pyside2/libpyside/pysidemetafunction.cpp b/sources/pyside2/libpyside/pysidemetafunction.cpp index 0326e0f11..0b7799af1 100644 --- a/sources/pyside2/libpyside/pysidemetafunction.cpp +++ b/sources/pyside2/libpyside/pysidemetafunction.cpp @@ -107,7 +107,7 @@ static const char *MetaFunction_SignatureStrings[] = { void init(PyObject *module) { - if (SbkSpecial_Type_Ready(module, PySideMetaFunctionTypeF(), MetaFunction_SignatureStrings) < 0) + if (InitSignatureStrings(PySideMetaFunctionTypeF(), MetaFunction_SignatureStrings) < 0) return; Py_INCREF(PySideMetaFunctionTypeF()); diff --git a/sources/pyside2/libpyside/pysideproperty.cpp b/sources/pyside2/libpyside/pysideproperty.cpp index c902afc0c..79464541d 100644 --- a/sources/pyside2/libpyside/pysideproperty.cpp +++ b/sources/pyside2/libpyside/pysideproperty.cpp @@ -357,7 +357,7 @@ static const char *Property_SignatureStrings[] = { void init(PyObject *module) { - if (SbkSpecial_Type_Ready(module, PySidePropertyTypeF(), Property_SignatureStrings) < 0) + if (InitSignatureStrings(PySidePropertyTypeF(), Property_SignatureStrings) < 0) return; Py_INCREF(PySidePropertyTypeF()); diff --git a/sources/pyside2/libpyside/pysidesignal.cpp b/sources/pyside2/libpyside/pysidesignal.cpp index 1a9e5e115..f3fb4e06d 100644 --- a/sources/pyside2/libpyside/pysidesignal.cpp +++ b/sources/pyside2/libpyside/pysidesignal.cpp @@ -635,17 +635,17 @@ static const char *SignalInstance_SignatureStrings[] = { void init(PyObject *module) { - if (SbkSpecial_Type_Ready(module, PySideMetaSignalTypeF(), MetaSignal_SignatureStrings) < 0) + if (InitSignatureStrings(PySideMetaSignalTypeF(), MetaSignal_SignatureStrings) < 0) return; Py_INCREF(PySideMetaSignalTypeF()); PyModule_AddObject(module, "MetaSignal", reinterpret_cast<PyObject *>(PySideMetaSignalTypeF())); - if (SbkSpecial_Type_Ready(module, PySideSignalTypeF(), Signal_SignatureStrings) < 0) + if (InitSignatureStrings(PySideSignalTypeF(), Signal_SignatureStrings) < 0) return; Py_INCREF(PySideSignalTypeF()); PyModule_AddObject(module, "Signal", reinterpret_cast<PyObject *>(PySideSignalTypeF())); - if (SbkSpecial_Type_Ready(module, PySideSignalInstanceTypeF(), SignalInstance_SignatureStrings) < 0) + if (InitSignatureStrings(PySideSignalInstanceTypeF(), SignalInstance_SignatureStrings) < 0) return; Py_INCREF(PySideSignalInstanceTypeF()); PyModule_AddObject(module, "SignalInstance", reinterpret_cast<PyObject *>(PySideSignalInstanceTypeF())); diff --git a/sources/pyside2/libpyside/pysideslot.cpp b/sources/pyside2/libpyside/pysideslot.cpp index 7bfd1719a..1ec24ab21 100644 --- a/sources/pyside2/libpyside/pysideslot.cpp +++ b/sources/pyside2/libpyside/pysideslot.cpp @@ -188,7 +188,7 @@ static const char *Slot_SignatureStrings[] = { void init(PyObject *module) { - if (SbkSpecial_Type_Ready(module, PySideSlotTypeF(), Slot_SignatureStrings) < 0) + if (InitSignatureStrings(PySideSlotTypeF(), Slot_SignatureStrings) < 0) return; Py_INCREF(PySideSlotTypeF()); |