@@ -440,7 +440,7 @@ Joins another vector layer to this layer
440
440
%Docstring
441
441
Removes a vector layer join
442
442
443
- :return: true if join was found and successfully removed
443
+ :return: ``True`` if join was found and successfully removed
444
444
%End
445
445
446
446
QgsVectorLayerJoinBuffer *joinBuffer();
@@ -460,7 +460,7 @@ Sets the list of dependencies.
460
460
461
461
:param layers: set of :py:class:`QgsMapLayerDependency`. Only user-defined dependencies will be added
462
462
463
- :return: false if a dependency cycle has been detected
463
+ :return: ``False`` if a dependency cycle has been detected
464
464
465
465
.. versionadded:: 3.0
466
466
%End
@@ -678,7 +678,7 @@ Returns the bounding box of the selected features. If there is no selection, Qgs
678
678
%Docstring
679
679
Returns whether the layer contains labels which are enabled and should be drawn.
680
680
681
- :return: true if layer contains enabled labels
681
+ :return: ``True`` if layer contains enabled labels
682
682
683
683
.. seealso:: :py:func:`setLabelsEnabled`
684
684
@@ -691,7 +691,7 @@ Sets whether labels should be ``enabled`` for the layer.
691
691
692
692
.. note::
693
693
694
- Labels will only be rendered if labelsEnabled() is true and a labeling
694
+ Labels will only be rendered if labelsEnabled() is ``True`` and a labeling
695
695
object is returned by labeling().
696
696
697
697
.. seealso:: :py:func:`labelsEnabled`
@@ -703,7 +703,7 @@ Sets whether labels should be ``enabled`` for the layer.
703
703
%Docstring
704
704
Returns whether the layer contains diagrams which are enabled and should be drawn.
705
705
706
- :return: true if layer contains enabled diagrams
706
+ :return: ``True`` if layer contains enabled diagrams
707
707
708
708
.. versionadded:: 2.9
709
709
%End
@@ -818,7 +818,7 @@ Delete a style from the database
818
818
819
819
:param styleId: the provider's layer_styles table id of the style to delete
820
820
821
- :return: - true in case of success
821
+ :return: - ``True`` in case of success
822
822
- msgError: reference to string that will be updated with any error messages
823
823
824
824
.. versionadded:: 3.0
@@ -830,29 +830,29 @@ Delete a style from the database
830
830
Load a named style from file/local db/datasource db
831
831
832
832
:param theURI: the URI of the style or the URI of the layer
833
- :param resultFlag: will be set to true if a named style is correctly loaded
834
- :param loadFromLocalDb: if true forces to load from local db instead of datasource one
833
+ :param resultFlag: will be set to ``True`` if a named style is correctly loaded
834
+ :param loadFromLocalDb: if ``True`` forces to load from local db instead of datasource one
835
835
:param categories: the style categories to be loaded.
836
836
%End
837
837
838
838
virtual QString loadNamedStyle( const QString &theURI, bool &resultFlag /Out/,
839
839
QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories ) ${SIP_FINAL};
840
840
%Docstring
841
- Calls loadNamedStyle( theURI, resultFlag, false );
841
+ Calls loadNamedStyle( theURI, resultFlag, ``False`` );
842
842
Retained for backward compatibility
843
843
%End
844
844
845
845
bool loadAuxiliaryLayer( const QgsAuxiliaryStorage &storage, const QString &key = QString() );
846
846
%Docstring
847
847
Loads the auxiliary layer for this vector layer. If there's no
848
- corresponding table in the database, then nothing happens and false is
848
+ corresponding table in the database, then nothing happens and ``False`` is
849
849
returned. The key is optional because if this layer has been read from
850
850
a XML document, then the key read in this document is used by default.
851
851
852
852
:param storage: The auxiliary storage where to look for the table
853
853
:param key: The key to use for joining.
854
854
855
- :return: true if the auxiliary layer is well loaded, false otherwise
855
+ :return: ``True`` if the auxiliary layer is well loaded, ``False`` otherwise
856
856
857
857
858
858
.. versionadded:: 3.0
@@ -886,7 +886,7 @@ Read the symbology for the current layer from the Dom node supplied.
886
886
:param context: reading context (used for transform from relative to absolute paths)
887
887
:param categories: the style categories to be read
888
888
889
- :return: true in case of success.
889
+ :return: ``True`` in case of success.
890
890
%End
891
891
892
892
virtual bool readStyle( const QDomNode &node, QString &errorMessage,
@@ -899,7 +899,7 @@ Read the style for the current layer from the Dom node supplied.
899
899
:param context: reading context (used for transform from relative to absolute paths)
900
900
:param categories: the style categories to be read
901
901
902
- :return: true in case of success.
902
+ :return: ``True`` in case of success.
903
903
%End
904
904
905
905
virtual bool writeSymbology( QDomNode &node, QDomDocument &doc, QString &errorMessage,
@@ -913,7 +913,7 @@ Write the symbology for the layer into the docment provided.
913
913
:param context: writing context (used for transform from absolute to relative paths)
914
914
:param categories: the style categories to be written
915
915
916
- :return: true in case of success.
916
+ :return: ``True`` in case of success.
917
917
%End
918
918
919
919
virtual bool writeStyle( QDomNode &node, QDomDocument &doc, QString &errorMessage,
@@ -927,7 +927,7 @@ Write just the style information for the layer into the document
927
927
:param context: writing context (used for transform from absolute to relative paths)
928
928
:param categories: the style categories to be written
929
929
930
- :return: true in case of success.
930
+ :return: ``True`` in case of success.
931
931
%End
932
932
933
933
bool writeSld( QDomNode &node, QDomDocument &doc, QString &errorMessage, const QgsStringMap &props = QgsStringMap() ) const;
@@ -939,7 +939,7 @@ Writes the symbology of the layer into the document provided in SLD 1.1 format
939
939
:param errorMessage: reference to string that will be updated with any error messages
940
940
:param props: a open ended set of properties that can drive/inform the SLD encoding
941
941
942
- :return: true in case of success
942
+ :return: ``True`` in case of success
943
943
%End
944
944
945
945
virtual bool readSld( const QDomNode &node, QString &errorMessage ) ${SIP_FINAL};
@@ -976,7 +976,7 @@ if the geometry type of the new data source matches the current geometry type of
976
976
:param dataSource: new layer data source
977
977
:param baseName: base name of the layer
978
978
:param provider: provider string
979
- :param loadDefaultStyleFlag: set to true to reset the layer's style to the default for the
979
+ :param loadDefaultStyleFlag: set to ``True`` to reset the layer's style to the default for the
980
980
data source
981
981
982
982
.. versionadded:: 2.10
@@ -994,7 +994,7 @@ if the geometry type of the new data source matches the current geometry type of
994
994
:param baseName: base name of the layer
995
995
:param provider: provider string
996
996
:param options: provider options
997
- :param loadDefaultStyleFlag: set to true to reset the layer's style to the default for the
997
+ :param loadDefaultStyleFlag: set to ``True`` to reset the layer's style to the default for the
998
998
data source
999
999
1000
1000
.. seealso:: :py:func:`dataSourceChanged`
@@ -1029,7 +1029,7 @@ Set the string (typically sql) used to define a subset of the layer
1029
1029
or other definition string specific to the underlying dataprovider
1030
1030
and data store.
1031
1031
1032
- :return: true , when setting the subset string was successful, false otherwise
1032
+ :return: ``True`` , when setting the subset string was successful, ``False`` otherwise
1033
1033
%End
1034
1034
1035
1035
virtual QString subsetString() const;
@@ -1085,10 +1085,10 @@ Updates an existing ``feature`` in the layer, replacing the attributes and geome
1085
1085
with matching QgsFeature.id() with the attributes and geometry from ``feature``.
1086
1086
Changes are not immediately committed to the layer.
1087
1087
1088
- If ``skipDefaultValue`` is set to true , default field values will not
1088
+ If ``skipDefaultValue`` is set to ``True`` , default field values will not
1089
1089
be updated. This can be used to override default field value expressions.
1090
1090
1091
- Returns true if the feature's attribute was successfully changed.
1091
+ Returns ``True`` if the feature's attribute was successfully changed.
1092
1092
1093
1093
.. note::
1094
1094
@@ -1195,7 +1195,7 @@ Deletes a vertex from a feature.
1195
1195
%Docstring
1196
1196
Deletes the selected features
1197
1197
1198
- :return: true in case of success and false otherwise
1198
+ :return: ``True`` in case of success and ``False`` otherwise
1199
1199
%End
1200
1200
1201
1201
QgsGeometry::OperationResult addRing( const QVector<QgsPointXY> &ring, QgsFeatureId *featureId = 0 );
@@ -1336,7 +1336,7 @@ Translates feature by dx, dy
1336
1336
Splits parts cut by the given line
1337
1337
1338
1338
:param splitLine: line that splits the layer features
1339
- :param topologicalEditing: true if topological editing is enabled
1339
+ :param topologicalEditing: ``True`` if topological editing is enabled
1340
1340
1341
1341
:return: QgsGeometry.OperationResult
1342
1342
- Success
@@ -1360,7 +1360,7 @@ Splits parts cut by the given line
1360
1360
Splits features cut by the given line
1361
1361
1362
1362
:param splitLine: line that splits the layer features
1363
- :param topologicalEditing: true if topological editing is enabled
1363
+ :param topologicalEditing: ``True`` if topological editing is enabled
1364
1364
1365
1365
:return: QgsGeometry.OperationResult
1366
1366
- Success
@@ -1425,7 +1425,7 @@ Access to labeling configuration. May be null if labeling is not used.
1425
1425
1426
1426
.. note::
1427
1427
1428
- Labels will only be rendered if labelsEnabled() returns true .
1428
+ Labels will only be rendered if labelsEnabled() returns ``True`` .
1429
1429
1430
1430
.. seealso:: :py:func:`labelsEnabled`
1431
1431
@@ -1442,24 +1442,24 @@ Set labeling configuration. Takes ownership of the object.
1442
1442
virtual bool isEditable() const ${SIP_FINAL};
1443
1443
1444
1444
%Docstring
1445
- Returns true if the provider is in editing mode
1445
+ Returns ``True`` if the provider is in editing mode
1446
1446
%End
1447
1447
1448
1448
virtual bool isSpatial() const ${SIP_FINAL};
1449
1449
1450
1450
%Docstring
1451
- Returns true if this is a geometry layer and false in case of NoGeometry (table only) or UnknownGeometry
1451
+ Returns ``True`` if this is a geometry layer and ``False`` in case of NoGeometry (table only) or UnknownGeometry
1452
1452
%End
1453
1453
1454
1454
virtual bool isModified() const;
1455
1455
%Docstring
1456
- Returns true if the provider has been modified since the last commit
1456
+ Returns ``True`` if the provider has been modified since the last commit
1457
1457
%End
1458
1458
1459
1459
bool isAuxiliaryField( int index, int &srcIndex ) const;
1460
1460
%Docstring
1461
- Returns true if the field comes from the auxiliary layer,
1462
- false otherwise.
1461
+ Returns ``True`` if the field comes from the auxiliary layer,
1462
+ ``False`` otherwise.
1463
1463
1464
1464
.. versionadded:: 3.0
1465
1465
%End
@@ -1515,7 +1515,7 @@ If you need only the count of committed features call this method on this layer'
1515
1515
%Docstring
1516
1516
Make layer read-only (editing disabled) or not
1517
1517
1518
- :return: false if the layer is in editing yet
1518
+ :return: ``False`` if the layer is in editing yet
1519
1519
%End
1520
1520
1521
1521
bool changeGeometry( QgsFeatureId fid, QgsGeometry &geometry, bool skipDefaultValue = false );
@@ -1524,10 +1524,10 @@ Changes a feature's ``geometry`` within the layer's edit buffer
1524
1524
(but does not immediately commit the changes). The ``fid`` argument
1525
1525
specifies the ID of the feature to be changed.
1526
1526
1527
- If ``skipDefaultValue`` is set to true , default field values will not
1527
+ If ``skipDefaultValue`` is set to ``True`` , default field values will not
1528
1528
be updated. This can be used to override default field value expressions.
1529
1529
1530
- Returns true if the feature's geometry was successfully changed.
1530
+ Returns ``True`` if the feature's geometry was successfully changed.
1531
1531
1532
1532
.. note::
1533
1533
@@ -1561,10 +1561,10 @@ QVariant is used (the default behavior), then the feature's current value will b
1561
1561
retrieved and used. Note that this involves a feature request to the underlying data provider,
1562
1562
so it is more efficient to explicitly pass an ``oldValue`` if it is already available.
1563
1563
1564
- If ``skipDefaultValues`` is set to true , default field values will not
1564
+ If ``skipDefaultValues`` is set to ``True`` , default field values will not
1565
1565
be updated. This can be used to override default field value expressions.
1566
1566
1567
- Returns true if the feature's attribute was successfully changed.
1567
+ Returns ``True`` if the feature's attribute was successfully changed.
1568
1568
1569
1569
.. note::
1570
1570
@@ -1598,11 +1598,11 @@ automatically retrieved and used. Note that this involves a feature
1598
1598
request to the underlying data provider, so it is more efficient to
1599
1599
explicitly pass an oldValue if it is already available.
1600
1600
1601
- If ``skipDefaultValues`` is set to true , default field values will not
1601
+ If ``skipDefaultValues`` is set to ``True`` , default field values will not
1602
1602
be updated. This can be used to override default field value
1603
1603
expressions.
1604
1604
1605
- Returns true if feature's attributes was successfully changed.
1605
+ Returns ``True`` if feature's attributes was successfully changed.
1606
1606
1607
1607
.. note::
1608
1608
@@ -1629,7 +1629,7 @@ Returns true if feature's attributes was successfully changed.
1629
1629
bool addAttribute( const QgsField &field );
1630
1630
%Docstring
1631
1631
Add an attribute field (but does not commit it)
1632
- returns true if the field was added
1632
+ returns ``True`` if the field was added
1633
1633
1634
1634
.. note::
1635
1635
@@ -1726,7 +1726,7 @@ Deletes a list of attribute fields (but does not commit it)
1726
1726
1727
1727
:param attrs: the indices of the attributes to delete
1728
1728
1729
- :return: true if at least one attribute has been deleted
1729
+ :return: ``True`` if at least one attribute has been deleted
1730
1730
%End
1731
1731
1732
1732
virtual bool addFeatures( QgsFeatureList &features, QgsFeatureSink::Flags flags = 0 ) ${SIP_FINAL};
@@ -1750,7 +1750,7 @@ Deletes a set of features from the layer (but does not commit it)
1750
1750
1751
1751
:param fids: The feature ids to delete
1752
1752
1753
- :return: false if the layer is not in edit mode or does not support deleting
1753
+ :return: ``False`` if the layer is not in edit mode or does not support deleting
1754
1754
in case of an active transaction depends on the provider implementation
1755
1755
1756
1756
.. note::
@@ -1766,7 +1766,7 @@ Deletes a set of features from the layer (but does not commit it)
1766
1766
Attempts to commit to the underlying data provider any buffered changes made since the
1767
1767
last to call to startEditing().
1768
1768
1769
- Returns the result of the attempt. If a commit fails (i.e. false is returned), the
1769
+ Returns the result of the attempt. If a commit fails (i.e. ``False`` is returned), the
1770
1770
in-memory changes are left untouched and are not discarded. This allows editing to
1771
1771
continue if the commit failed on e.g. a disallowed value in a Postgres
1772
1772
database - the user can re-edit and try again.
@@ -1797,7 +1797,7 @@ to commit changes to the layer.
1797
1797
%Docstring
1798
1798
Stops a current editing operation and discards any uncommitted edits.
1799
1799
1800
- If ``deleteBuffer`` is true the editing buffer will be completely deleted (the default
1800
+ If ``deleteBuffer`` is ``True`` the editing buffer will be completely deleted (the default
1801
1801
behavior).
1802
1802
1803
1803
.. seealso:: :py:func:`startEditing`
@@ -2088,7 +2088,7 @@ Calculates an aggregated value from the layer's features.
2088
2088
:param fieldOrExpression: source field or expression to use as basis for aggregated values.
2089
2089
:param parameters: parameters controlling aggregate calculation
2090
2090
:param context: expression context for expressions and filters
2091
- :param ok: if specified, will be set to true if aggregate calculation was successful
2091
+ :param ok: if specified, will be set to ``True`` if aggregate calculation was successful
2092
2092
2093
2093
:return: calculated aggregate value
2094
2094
@@ -2232,8 +2232,8 @@ to determine it.
2232
2232
2233
2233
bool readExtentFromXml() const;
2234
2234
%Docstring
2235
- Returns true if the extent is read from the XML document when data
2236
- source has no metadata, false if it's the data provider which determines
2235
+ Returns ``True`` if the extent is read from the XML document when data
2236
+ source has no metadata, ``False`` if it's the data provider which determines
2237
2237
it.
2238
2238
2239
2239
.. versionadded:: 3.0
@@ -2305,7 +2305,7 @@ Clear selection
2305
2305
Update the extents for the layer. This is necessary if features are
2306
2306
added/deleted or the layer has been subsetted.
2307
2307
2308
- :param force: true to update layer extent even if it's read from xml by default, false otherwise
2308
+ :param force: ``True`` to update layer extent even if it's read from xml by default, ``False`` otherwise
2309
2309
%End
2310
2310
2311
2311
bool startEditing();
@@ -2316,7 +2316,7 @@ This starts an edit session on this layer. Changes made in this edit session wil
2316
2316
be made persistent until commitChanges() is called, and can be reverted by calling
2317
2317
rollBack().
2318
2318
2319
- Returns true if the layer was successfully made editable, or false if the operation
2319
+ Returns ``True`` if the layer was successfully made editable, or ``False`` if the operation
2320
2320
failed (e.g. due to an underlying read-only data source, or lack of edit support
2321
2321
by the backend data provider).
2322
2322
@@ -2333,7 +2333,7 @@ Emitted when selection was changed
2333
2333
2334
2334
:param selected: Newly selected feature ids
2335
2335
:param deselected: Ids of all features which have previously been selected but are not any more
2336
- :param clearAndSelect: In case this is set to true , the old selection was dismissed and the new selection corresponds to selected
2336
+ :param clearAndSelect: In case this is set to ``True`` , the old selection was dismissed and the new selection corresponds to selected
2337
2337
%End
2338
2338
2339
2339
void layerModified();
0 commit comments