File: qgscoordinatereferencesystemregistry.sip.in

package info (click to toggle)
qgis 3.40.11%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,183,800 kB
  • sloc: cpp: 1,595,841; python: 372,637; 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: 154
file content (274 lines) | stat: -rw-r--r-- 7,078 bytes parent folder | download | duplicates (14)
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
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/core/proj/qgscoordinatereferencesystemregistry.h                 *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/







class QgsCoordinateReferenceSystemRegistry : QObject
{
%Docstring(signature="appended")
A registry for known coordinate reference system (CRS) definitions,
including any user-defined CRSes.

:py:class:`QgsCoordinateReferenceSystemRegistry` is not usually directly
created, but rather accessed through
:py:func:`QgsApplication.coordinateReferenceSystemRegistry()`.

.. versionadded:: 3.18
%End

%TypeHeaderCode
#include "qgscoordinatereferencesystemregistry.h"
%End
  public:

    explicit QgsCoordinateReferenceSystemRegistry( QObject *parent = 0 );
%Docstring
Constructor for QgsCoordinateReferenceSystemRegistry, with the specified
``parent`` object.
%End

    ~QgsCoordinateReferenceSystemRegistry();

    class UserCrsDetails
{
%Docstring(signature="appended")
Contains details of a custom (user defined) CRS.

.. versionadded:: 3.18
%End

%TypeHeaderCode
#include "qgscoordinatereferencesystemregistry.h"
%End
      public:

        long id;

        QString name;

        QString proj;

        QString wkt;

        QgsCoordinateReferenceSystem crs;
    };

    QList< QgsCoordinateReferenceSystemRegistry::UserCrsDetails > userCrsList() const;
%Docstring
Returns a list containing the details of all registered custom
(user-defined) CRSes.
%End

    long addUserCrs( const QgsCoordinateReferenceSystem &crs, const QString &name, Qgis::CrsDefinitionFormat nativeFormat = Qgis::CrsDefinitionFormat::Wkt );
%Docstring
Adds a new ``crs`` definition as a custom ("USER") CRS.

Returns the new CRS
:py:func:`~QgsCoordinateReferenceSystemRegistry.srsid`, or -1 if the CRS
could not be saved.

The ``nativeFormat`` argument specifies the format to use when saving
the CRS definition. FormatWkt is recommended as it is a lossless format.

.. warning::

   Not all CRS definitions can be represented as a Proj string, so
   take care when using the FormatProj option.

.. seealso:: :py:func:`updateUserCrs`

.. seealso:: :py:func:`userCrsAdded`
%End

    bool updateUserCrs( long id, const QgsCoordinateReferenceSystem &crs, const QString &name, Qgis::CrsDefinitionFormat nativeFormat = Qgis::CrsDefinitionFormat::Wkt );
%Docstring
Updates the definition of the existing user CRS with matching ``id``.

The ``crs`` argument specifies a CRS with the desired new definition.

Returns ``False`` if the new CRS definition could not be saved.

The ``nativeFormat`` argument specifies the format to use when saving
the CRS definition. FormatWkt is recommended as it is a lossless format.

.. warning::

   Not all CRS definitions can be represented as a Proj string, so
   take care when using the FormatProj option.

.. seealso:: :py:func:`addUserCrs`

.. seealso:: :py:func:`userCrsChanged`
%End

    bool removeUserCrs( long id );
%Docstring
Removes the existing user CRS with matching ``id``.

Returns ``False`` if the CRS could not be removed.

.. seealso:: :py:func:`userCrsRemoved`
%End

    QMap< QString, QgsProjOperation > projOperations() const;
%Docstring
Returns a map of all valid PROJ operations.

The map keys correspond to PROJ operation IDs.

.. versionadded:: 3.20
%End

    QList< QgsCelestialBody > celestialBodies() const;
%Docstring
Returns a list of all known celestial bodies.

.. warning::

   This method requires PROJ 8.1 or later

:raises QgsNotSupportedException: on QGIS builds based on PROJ 8.0 or
                                  earlier.

.. versionadded:: 3.20
%End

    QSet< QString > authorities() const;
%Docstring
Returns a list of all known authorities.

.. note::

   authority names will always be returned in lower case

.. versionadded:: 3.34
%End


    QList< QgsCoordinateReferenceSystem > recentCrs();
%Docstring
Returns a list of recently used CRS.

.. versionadded:: 3.36
%End

    void pushRecent( const QgsCoordinateReferenceSystem &crs );
%Docstring
Pushes a recently used CRS to the top of the recent CRS list.

.. seealso:: :py:func:`recentCrsPushed`

.. versionadded:: 3.16
%End

    void removeRecent( const QgsCoordinateReferenceSystem &crs );
%Docstring
Removes a CRS from the list of recently used CRS.

.. seealso:: :py:func:`recentCrsRemoved`

.. versionadded:: 3.36
%End

    void clearRecent();
%Docstring
Cleans the list of recently used CRS.

.. seealso:: :py:func:`recentCrsCleared`

.. versionadded:: 3.36
%End

  signals:

    void userCrsChanged( const QString &id );
%Docstring
Emitted whenever an existing user CRS definition is changed.

The ``id`` argument specifies the ID of the user CRS which has been
changed.

Objects which store :py:class:`QgsCoordinateReferenceSystem` members
should connect to this signal and update any stored CRS definitions to
ensure that they always use the current definition of any user defined
CRSes.

.. seealso:: :py:func:`crsDefinitionsChanged`

.. seealso:: :py:func:`userCrsAdded`
%End

    void userCrsAdded( const QString &id );
%Docstring
Emitted whenever a new user CRS definition is added.

The ``id`` argument specifies the ID of the user CRS which has been
changed.

.. seealso:: :py:func:`userCrsChanged`

.. seealso:: :py:func:`crsDefinitionsChanged`
%End

    void userCrsRemoved( long id );
%Docstring
Emitted when the user CRS with matching ``id`` is removed from the
database.

.. seealso:: :py:func:`removeUserCrs`
%End

    void crsDefinitionsChanged();
%Docstring
Emitted whenever an operation has caused any of the known CRS
definitions (including user-defined CRS) to change.
%End

    void recentCrsPushed( const QgsCoordinateReferenceSystem &crs );
%Docstring
Emitted when a recently used CRS has been pushed to the top of the
recent CRS list.

.. seealso:: :py:func:`pushRecent`

.. versionadded:: 3.36
%End

    void recentCrsRemoved( const QgsCoordinateReferenceSystem &crs );
%Docstring
Emitted when a recently used CRS has been removed from the recent CRS
list.

.. seealso:: :py:func:`removeRecent`

.. versionadded:: 3.36
%End

    void recentCrsCleared();
%Docstring
Emitted when the list of recently used CRS has been cleared.

.. seealso:: :py:func:`clearRecent`

.. versionadded:: 3.36
%End

};


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