16#ifndef QGSLAYERTREEMAPCANVASBRIDGE_H
17#define QGSLAYERTREEMAPCANVASBRIDGE_H
71 sipCpp->setOverviewCanvas( a0 );
88 Q_INVOKABLE
void setCanvasLayers();
99 void nodeVisibilityChanged();
100 void nodeCustomPropertyChanged(
QgsLayerTreeNode *node,
const QString &key );
101 void layersAdded(
const QList<QgsMapLayer *> &layers );
105 void setCanvasLayers(
QgsLayerTreeNode *node, QList<QgsMapLayer *> &canvasLayers, QList<QgsMapLayer *> &overviewLayers, QList<QgsMapLayer *> &allLayers );
107 void deferredSetCanvasLayers();
113 bool mPendingCanvasUpdate =
false;
115 bool mAutoSetupOnFirstLayer =
true;
117 bool mHasLayersLoaded;
118 bool mHasValidLayersLoaded =
false;
Represents a coordinate reference system (CRS).
Layer tree group node serves as a container for layers and further groups.
QgsMapCanvas * mapCanvas() const
QgsLayerTree * rootGroup() const
void setAutoSetupOnFirstLayer(bool enabled)
if enabled, will automatically set full canvas extent and destination CRS + map units when first laye...
Q_INVOKABLE void setCanvasLayers()
force update of canvas layers from the layer tree. Normally this should not be needed to be called.
void canvasLayersChanged(const QList< QgsMapLayer * > &layers)
Emitted when the set of layers (or order of layers) visible in the canvas changes.
QgsMapOverviewCanvas * overviewCanvas() const
Returns associated overview canvas (may be nullptr).
bool autoSetupOnFirstLayer() const
void setOverviewCanvas(QgsMapOverviewCanvas *overviewCanvas)
Associates overview canvas with the bridge, so the overview will be updated whenever main canvas is u...
QgsLayerTreeMapCanvasBridge(QgsLayerTree *root, QgsMapCanvas *canvas, QObject *parent SIP_TRANSFERTHIS=nullptr)
Constructor: does not take ownership of the layer tree nor canvas.
Base class for nodes in a layer tree.
Namespace with helper functions for layer tree operations.
Map canvas is a class for displaying all GIS data types on a canvas.
Base class for all map layer types.
A widget that displays an overview map.