aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/doc/developer/feature-motivation.rst
diff options
context:
space:
mode:
Diffstat (limited to 'sources/pyside6/doc/developer/feature-motivation.rst')
-rw-r--r--sources/pyside6/doc/developer/feature-motivation.rst24
1 files changed, 12 insertions, 12 deletions
diff --git a/sources/pyside6/doc/developer/feature-motivation.rst b/sources/pyside6/doc/developer/feature-motivation.rst
index 33bcf1651..1509ea724 100644
--- a/sources/pyside6/doc/developer/feature-motivation.rst
+++ b/sources/pyside6/doc/developer/feature-motivation.rst
@@ -84,12 +84,11 @@ all methods of all classes used in this module are changing their name.
The algorithm to change names is this:
- * if the name has less than 3 chars, or
- * if two upper chars are adjacent, or
- * if the name starts with ``gl`` (which marks OpenGL),
- * the name is returned unchanged. Otherwise
-
- * a single upper char ``C`` is replaced by ``_c``
+* if the name has less than 3 chars, or
+* if two upper chars are adjacent, or
+* if the name starts with ``gl`` (which marks OpenGL),
+* the name is returned unchanged. Otherwise
+* a single upper char ``C`` is replaced by ``_c``
The true_property feature
@@ -231,8 +230,9 @@ Example:
.. code-block:: python
>>> from PySide6 import *
+ >>> from PySide6.support.signature import get_signature
>>> import pprint
- >>> pprint.pprint(QtCore.QTimer.singleShot.__signature__)
+ >>> pprint.pprint(get_signature(QtCore.QTimer.singleShot))
[<Signature (arg__1: int, arg__2: Callable) -> None>,
<Signature (msec: int, receiver: PySide6.QtCore.QObject, member: bytes) -> None>,
<Signature (msec: int, timerType: PySide6.QtCore.Qt.TimerType,
@@ -284,7 +284,11 @@ a ``QtCore.pyi`` file next to ``QtCore.abi3.so`` or ``QtCore.pyd`` on Windows.
When using ``__feature__`` often with common IDEs, you may want to provide
a feature-aware version of ``.pyi`` files to get a correct display. The simplest
-way to change them all in-place is the command
+way to change them all in-place is the command:
+
+.. code-block:: bash
+
+ pyside6-genpyi all --feature snake_case true_property
Using __feature__ with UIC files
@@ -295,9 +299,5 @@ are _not_ converted, intentionally. Mixing them with feature selections in other
Python modules should always work, because switching will happen as needed, selected
by the currently active module. (Please report to us if this fails for an example)
-.. code-block:: python
-
- pyside6-genpyi all --feature snake_case true_property
-
.. _`Import-Hooks`: https://docs.python.org/3/reference/import.html#import-hooks