Class: QgsLayoutItemMapAtlasClippingSettings¶
Contains settings relating to clipping a layout map by the current atlas feature.
Added in version 3.16.
Class Hierarchy¶
Base classes¶
Methods
Returns   | 
|
Returns the feature clipping type to apply when clipping to the current atlas feature.  | 
|
Returns   | 
|
Returns the list of map layers to clip to the atlas feature.  | 
|
Sets the setting's state from a DOM document, where element is the DOM node corresponding to a 'LayoutMap' tag.  | 
|
Returns   | 
|
Sets whether the map content should be clipped to the current atlas feature.  | 
|
Sets the feature clipping type to apply when clipping to the current atlas feature.  | 
|
Sets whether labels should only be placed inside the atlas feature geometry.  | 
|
Sets the list of map layers to clip to the atlas feature.  | 
|
Sets whether clipping should be restricted to a subset of layers.  | 
|
Stores settings in a DOM element, where element is the DOM element corresponding to a 'LayoutMap' tag.  | 
Signals
Emitted when the atlas clipping settings are changed.  | 
- class qgis.core.QgsLayoutItemMapAtlasClippingSettings[source]¶
 Bases:
QObject- __init__(map: QgsLayoutItemMap | None = None)
 Constructor for QgsLayoutItemMapAtlasClippingSettings, with the specified
mapparent.- Parameters:
 map (Optional[QgsLayoutItemMap] = None)
- enabled(self) bool[source]¶
 Returns
Trueif the map content should be clipped to the current atlas feature.See also
- Return type:
 bool
- featureClippingType(self) QgsMapClippingRegion.FeatureClippingType[source]¶
 Returns the feature clipping type to apply when clipping to the current atlas feature.
See also
- Return type:
 
- forceLabelsInsideFeature(self) bool[source]¶
 Returns
Trueif labels should only be placed inside the atlas feature geometry.See also
- Return type:
 bool
- layersToClip(self) List[QgsMapLayer]¶
 Returns the list of map layers to clip to the atlas feature.
Note
This setting is only used if
restrictToLayers()isTrue.See also
See also
- Return type:
 List[QgsMapLayer]
- readXml(self, element: QDomElement, doc: QDomDocument, context: QgsReadWriteContext) bool[source]¶
 Sets the setting’s state from a DOM document, where
elementis the DOM node corresponding to a ‘LayoutMap’ tag.See also
- Parameters:
 element (QDomElement)
doc (QDomDocument)
context (QgsReadWriteContext)
- Return type:
 bool
- restrictToLayers(self) bool[source]¶
 Returns
Trueif clipping should be restricted to a subset of layers.See also
See also
- Return type:
 bool
- setEnabled(self, enabled: bool)[source]¶
 Sets whether the map content should be clipped to the current atlas feature.
See also
- Parameters:
 enabled (bool)
- setFeatureClippingType(self, type: QgsMapClippingRegion.FeatureClippingType)[source]¶
 Sets the feature clipping
typeto apply when clipping to the current atlas feature.See also
- Parameters:
 
- setForceLabelsInsideFeature(self, forceInside: bool)[source]¶
 Sets whether labels should only be placed inside the atlas feature geometry.
See also
- Parameters:
 forceInside (bool)
- setLayersToClip(self, layers: Iterable[QgsMapLayer])[source]¶
 Sets the list of map
layersto clip to the atlas feature.Note
This setting is only used if
restrictToLayers()isTrue.See also
See also
- Parameters:
 layers (Iterable[QgsMapLayer])
- setRestrictToLayers(self, enabled: bool)[source]¶
 Sets whether clipping should be restricted to a subset of layers.
See also
See also
- Parameters:
 enabled (bool)
- writeXml(self, element: QDomElement, document: QDomDocument, context: QgsReadWriteContext) bool[source]¶
 Stores settings in a DOM element, where
elementis the DOM element corresponding to a ‘LayoutMap’ tag.See also
- Parameters:
 element (QDomElement)
document (QDomDocument)
context (QgsReadWriteContext)
- Return type:
 bool