File: qgsprocessingguiregistry.sip.in

package info (click to toggle)
qgis 3.40.10%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,183,672 kB
  • sloc: cpp: 1,595,771; python: 372,544; xml: 23,474; sh: 3,761; perl: 3,664; ansic: 2,257; sql: 2,137; yacc: 1,068; lex: 577; javascript: 540; lisp: 411; makefile: 161
file content (167 lines) | stat: -rw-r--r-- 6,538 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/gui/processing/qgsprocessingguiregistry.h                        *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/





class QgsProcessingGuiRegistry
{
%Docstring(signature="appended")
The :py:class:`QgsProcessingGuiRegistry` is a home for widgets for
processing configuration widgets.

:py:class:`QgsProcessingGuiRegistry` is not usually directly created,
but rather accessed through :py:func:`QgsGui.processingGuiRegistry()`.

.. versionadded:: 3.2
%End

%TypeHeaderCode
#include "qgsprocessingguiregistry.h"
%End
  public:
    QgsProcessingGuiRegistry();
%Docstring
Constructor. Should never be called manually, is already created by
:py:class:`QgsGui`.
%End
    ~QgsProcessingGuiRegistry();

    void addAlgorithmConfigurationWidgetFactory( QgsProcessingAlgorithmConfigurationWidgetFactory *factory /Transfer/ );
%Docstring
Add a new configuration widget factory for customized algorithm
configuration widgets. Ownership is taken.

.. versionadded:: 3.2
%End

    void removeAlgorithmConfigurationWidgetFactory( QgsProcessingAlgorithmConfigurationWidgetFactory *factory );
%Docstring
Remove a configuration widget factory for customized algorithm
configuration widgets.

.. versionadded:: 3.2
%End

    QgsProcessingAlgorithmConfigurationWidget *algorithmConfigurationWidget( const QgsProcessingAlgorithm *algorithm ) const;
%Docstring
Gets the configuration widget for an ``algorithm``. This widget will be
shown next to parameter widgets. Most algorithms do not have a
configuration widget and in this case, ``None`` will be returned.

.. versionadded:: 3.2
%End

    bool addParameterWidgetFactory( QgsProcessingParameterWidgetFactoryInterface *factory /Transfer/ );
%Docstring
Adds a parameter widget ``factory`` to the registry, allowing widget
creation for parameters of the matching type via
:py:func:`~QgsProcessingGuiRegistry.createParameterWidgetWrapper` and
:py:func:`~QgsProcessingGuiRegistry.createModelerParameterWidget`.

Ownership of ``factory`` is transferred to the registry.

Returns ``True`` if the factory was successfully added, or ``False`` if
the factory could not be added. Each factory must return a unique value
for
:py:func:`QgsProcessingParameterWidgetFactoryInterface.parameterType()`,
and attempting to add a new factory with a duplicate type will result in
failure.

.. seealso:: :py:func:`removeParameterWidgetFactory`

.. seealso:: :py:func:`createParameterWidgetWrapper`

.. seealso:: :py:func:`createModelerParameterWidget`

.. versionadded:: 3.4
%End

    void removeParameterWidgetFactory( QgsProcessingParameterWidgetFactoryInterface *factory );
%Docstring
Removes a parameter widget ``factory`` from the registry. The factory
will be deleted.

.. seealso:: :py:func:`addParameterWidgetFactory`

.. versionadded:: 3.4
%End

    QgsAbstractProcessingParameterWidgetWrapper *createParameterWidgetWrapper( const QgsProcessingParameterDefinition *parameter, QgsProcessingGui::WidgetType type ) /Factory/;
%Docstring
Creates a new parameter widget wrapper for the given ``parameter``. The
``type`` argument dictates the type of dialog the wrapper should be
created for. The caller takes ownership of the returned wrapper.

If no factory is registered which handles the given ``parameter``,
``None`` will be returned.

.. seealso:: :py:func:`createModelerParameterWidget`

.. seealso:: :py:func:`addParameterWidgetFactory`

.. versionadded:: 3.4
%End

    QgsProcessingModelerParameterWidget *createModelerParameterWidget( QgsProcessingModelAlgorithm *model, const QString &childId, const QgsProcessingParameterDefinition *parameter, QgsProcessingContext &context ) /Factory/;
%Docstring
Creates a new modeler parameter widget for the given ``parameter``. This
widget allows configuration of the parameter's value when used inside a
Processing ``model``.

The ID of the child algorithm within the model must be specified via the
``childId`` argument. This value corresponds to the
:py:func:`QgsProcessingModelChildAlgorithm.childId()` string, which
uniquely identifies which child algorithm the parameter is associated
with inside the given ``model``.

The caller takes ownership of the returned widget. If no factory is
registered which handles the given ``parameter``, ``None`` will be
returned.

.. seealso:: :py:func:`createParameterWidgetWrapper`

.. seealso:: :py:func:`addParameterWidgetFactory`

.. versionadded:: 3.4
%End

    QgsProcessingAbstractParameterDefinitionWidget *createParameterDefinitionWidget( const QString &type, QgsProcessingContext &context, const QgsProcessingParameterWidgetContext &widgetContext, const QgsProcessingParameterDefinition *definition = 0, const QgsProcessingAlgorithm *algorithm = 0 ) /Factory/;
%Docstring
Creates a new parameter definition widget allowing for configuration of
an instance of a specific parameter ``type``.

The ``context`` argument must specify a Processing context, which will
be used by the widget to evaluate existing ``definition`` properties
such as default values. Similarly, the ``widgetContext`` argument
specifies the wider GUI context in which the widget will be used.

The optional ``definition`` argument may specify an existing parameter
definition which will be reflected in the initial state of the returned
widget. If ``definition`` is ``None``, then the returned widget will use
default settings instead.

Additionally, the optional ``algorithm`` parameter may be used to
specify the algorithm or model associated with the parameter.

If ``None`` is returned for a particular parameter ``type``, it
indicates that the parameter type cannot be configured via GUI.

.. versionadded:: 3.10
%End

};

/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/gui/processing/qgsprocessingguiregistry.h                        *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/