QGIS API Documentation
3.0.2-Girona (307d082)
|
Stores information relating to the current reporting context for a layout. More...
#include <qgslayoutreportcontext.h>
Signals | |
void | changed () |
Emitted certain settings in the context is changed, e.g. More... | |
void | layerChanged (QgsVectorLayer *layer) |
Emitted when the context's layer is changed. More... | |
Public Member Functions | |
QgsLayoutReportContext (QgsLayout *layout) | |
Constructor for QgsLayoutReportContext. More... | |
QgsGeometry | currentGeometry (const QgsCoordinateReferenceSystem &crs=QgsCoordinateReferenceSystem()) const |
Returns the current feature() geometry in the given crs. More... | |
QgsFeature | feature () const |
Returns the current feature for evaluating the layout. More... | |
QgsVectorLayer * | layer () const |
Returns the vector layer associated with the layout's context. More... | |
QVector< qreal > | predefinedScales () const |
Returns the current list of predefined scales for use with the layout. More... | |
void | setFeature (const QgsFeature &feature) |
Sets the current feature for evaluating the layout. More... | |
void | setLayer (QgsVectorLayer *layer) |
Sets the vector layer associated with the layout's context. More... | |
void | setPredefinedScales (const QVector< qreal > &scales) |
Sets the list of predefined scales to use with the layout. More... | |
Friends | |
class | QgsLayoutExporter |
class | TestQgsLayout |
Stores information relating to the current reporting context for a layout.
Definition at line 30 of file qgslayoutreportcontext.h.
QgsLayoutReportContext::QgsLayoutReportContext | ( | QgsLayout * | layout | ) |
Constructor for QgsLayoutReportContext.
Definition at line 21 of file qgslayoutreportcontext.cpp.
|
signal |
Emitted certain settings in the context is changed, e.g.
by setting a new feature or vector layer for the context.
QgsGeometry QgsLayoutReportContext::currentGeometry | ( | const QgsCoordinateReferenceSystem & | crs = QgsCoordinateReferenceSystem() | ) | const |
|
inline |
Returns the current feature for evaluating the layout.
This feature may be used for altering an item's content and appearance for a report or atlas layout.
Definition at line 60 of file qgslayoutreportcontext.h.
QgsVectorLayer * QgsLayoutReportContext::layer | ( | ) | const |
Returns the vector layer associated with the layout's context.
Definition at line 65 of file qgslayoutreportcontext.cpp.
|
signal |
Emitted when the context's layer is changed.
|
inline |
Returns the current list of predefined scales for use with the layout.
Definition at line 99 of file qgslayoutreportcontext.h.
void QgsLayoutReportContext::setFeature | ( | const QgsFeature & | feature | ) |
Sets the current feature for evaluating the layout.
This feature may be used for altering an item's content and appearance for a report or atlas layout.
Emits the changed() signal.
Definition at line 26 of file qgslayoutreportcontext.cpp.
void QgsLayoutReportContext::setLayer | ( | QgsVectorLayer * | layer | ) |
Sets the vector layer associated with the layout's context.
Emits the changed() signal.
Definition at line 70 of file qgslayoutreportcontext.cpp.
void QgsLayoutReportContext::setPredefinedScales | ( | const QVector< qreal > & | scales | ) |
Sets the list of predefined scales to use with the layout.
This is used for maps which are set to the predefined atlas scaling mode.
Definition at line 77 of file qgslayoutreportcontext.cpp.
|
friend |
Definition at line 127 of file qgslayoutreportcontext.h.
|
friend |
Definition at line 128 of file qgslayoutreportcontext.h.