Skip to content
Permalink
Browse files
Better wording for setLayers documentation
  • Loading branch information
elpaso committed Jun 8, 2021
1 parent 6657f8b commit 5c597641ef477a391b73741cb89b95d898517850
Showing with 9 additions and 6 deletions.
  1. +5 −3 python/core/auto_generated/layout/qgslayoutitemmap.sip.in
  2. +4 −3 src/core/layout/qgslayoutitemmap.h
@@ -508,15 +508,17 @@ be used instead.

void setLayers( const QList<QgsMapLayer *> &layers );
%Docstring
Sets the stored ``layers`` set. If empty, the current project layers or the
layer specified in the map theme (if the follow visibility preset flag is set)
will be used instead.
Sets the stored ``layers`` set. If empty, the current project layers will be used.
If the map item is set to follow a map theme (via :py:func:`~QgsLayoutItemMap.followVisibilityPreset` and :py:func:`~QgsLayoutItemMap.followVisibilityPresetName` ),
then this method will have no effect and the layers rendered in the map will always follow the map theme.

.. seealso:: :py:func:`layers`

.. seealso:: :py:func:`keepLayerSet`

.. seealso:: :py:func:`followVisibilityPreset`

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

bool keepLayerStyles() const;
@@ -513,12 +513,13 @@ class CORE_EXPORT QgsLayoutItemMap : public QgsLayoutItem, public QgsTemporalRan
QList<QgsMapLayer *> layers() const;

/**
* Sets the stored \a layers set. If empty, the current project layers or the
* layer specified in the map theme (if the follow visibility preset flag is set)
* will be used instead.
* Sets the stored \a layers set. If empty, the current project layers will be used.
* If the map item is set to follow a map theme (via followVisibilityPreset() and followVisibilityPresetName() ),
* then this method will have no effect and the layers rendered in the map will always follow the map theme.
* \see layers()
* \see keepLayerSet()
* \see followVisibilityPreset()
* \see followVisibilityPresetName()
*/
void setLayers( const QList<QgsMapLayer *> &layers );

0 comments on commit 5c59764

Please sign in to comment.