QGIS API Documentation 3.41.0-Master (45a0abf3bec)
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
QgsMapSettings Class Reference

The QgsMapSettings class contains configuration for rendering of the map. More...

#include <qgsmapsettings.h>

Inheritance diagram for QgsMapSettings:
Inheritance graph
[legend]

Public Member Functions

 QgsMapSettings ()
 
void addClippingRegion (const QgsMapClippingRegion &region)
 Adds a new clipping region to the map settings.
 
void addRenderedFeatureHandler (QgsRenderedFeatureHandlerInterface *handler)
 Adds a rendered feature handler to use while rendering the map settings.
 
QColor backgroundColor () const
 Returns the background color of the map.
 
void clearCustomRenderingFlag (const QString &flag)
 Clears the specified custom rendering flag.
 
QList< QgsMapClippingRegionclippingRegions () const
 Returns the list of clipping regions to apply to the map.
 
QgsRectangle computeExtentForScale (const QgsPointXY &center, double scale) const
 Compute the extent such that its center is at the specified position (mapped to the destinatonCrs) and the zoom factor corresponds to the specified scale.
 
double computeScaleForExtent (const QgsRectangle &extent) const
 Compute the scale that corresponds to the specified extent.
 
long long currentFrame () const
 Returns the current frame number of the map, for maps which are part of an animation.
 
Q_DECL_DEPRECATED QString customRenderFlags () const
 Returns custom rendering flags.
 
QVariantMap customRenderingFlags () const
 Returns any custom rendering flags.
 
QgsCoordinateReferenceSystem destinationCrs () const
 Returns the destination coordinate reference system for the map render.
 
QSize deviceOutputSize () const
 Returns the device output size of the map render.
 
float devicePixelRatio () const
 Returns the device pixel ratio.
 
double dpiTarget () const
 Returns the target DPI (dots per inch) to be taken into consideration when rendering.
 
const QgsElevationShadingRendererelevationShadingRenderer () const
 Returns the shading renderer used to render shading on the entire map.
 
QString ellipsoid () const
 Returns ellipsoid's acronym.
 
const QgsExpressionContextexpressionContext () const
 Gets the expression context.
 
QgsRectangle extent () const
 Returns geographical coordinates of the rectangle that should be rendered.
 
double extentBuffer () const
 Returns the buffer in map units to use around the visible extent for rendering symbols whose corresponding geometries are outside the visible extent.
 
Qgis::MapSettingsFlags flags () const
 Returns combination of flags used for rendering.
 
double frameRate () const
 Returns the frame rate of the map (in frames per second), for maps which are part of an animation.
 
QgsRectangle fullExtent () const
 returns current extent of layer set
 
bool hasValidSettings () const
 Check whether the map settings are valid and can be used for rendering.
 
QList< QgsLabelBlockingRegionlabelBlockingRegions () const
 Returns the list of regions to avoid placing labels within.
 
QgsGeometry labelBoundaryGeometry () const
 Returns the label boundary geometry, which restricts where in the rendered map labels are permitted to be placed.
 
const QgsLabelingEngineSettingslabelingEngineSettings () const
 Returns the global configuration of the labeling engine.
 
QgsRectangle layerExtentToOutputExtent (const QgsMapLayer *layer, QgsRectangle extent) const
 transform bounding box from layer's CRS to output CRS
 
QStringList layerIds (bool expandGroupLayers=false) const
 Returns the list of layer IDs which will be rendered in the map.
 
template<typename T >
QVector< T > layers () const
 Returns a list of registered map layers with a specified layer type.
 
QList< QgsMapLayer * > layers (bool expandGroupLayers=false) const
 Returns the list of layers which will be rendered in the map.
 
QMap< QString, QString > layerStyleOverrides () const
 Returns the map of map layer style overrides (key: layer ID, value: style name) where a different style should be used instead of the current one.
 
QgsPoint layerToMapCoordinates (const QgsMapLayer *layer, const QgsPoint &point) const
 transform point coordinates from layer's CRS to output CRS
 
QgsPointXY layerToMapCoordinates (const QgsMapLayer *layer, QgsPointXY point) const
 transform point coordinates from layer's CRS to output CRS
 
QgsRectangle layerToMapCoordinates (const QgsMapLayer *layer, QgsRectangle rect) const
 transform rectangle from layer's CRS to output CRS
 
double layerToMapUnits (const QgsMapLayer *layer, const QgsRectangle &referenceExtent=QgsRectangle()) const
 Computes an estimated conversion factor between layer and map units, where layerUnits × layerToMapUnits = mapUnits
 
QgsCoordinateTransform layerTransform (const QgsMapLayer *layer) const
 Returns the coordinate transform from layer's CRS to destination CRS.
 
double magnificationFactor () const
 Returns the magnification factor.
 
QgsPoint mapToLayerCoordinates (const QgsMapLayer *layer, const QgsPoint &point) const
 transform point coordinates from output CRS to layer's CRS
 
QgsPointXY mapToLayerCoordinates (const QgsMapLayer *layer, QgsPointXY point) const
 transform point coordinates from output CRS to layer's CRS
 
QgsRectangle mapToLayerCoordinates (const QgsMapLayer *layer, QgsRectangle rect) const
 transform rectangle from output CRS to layer's CRS
 
const QgsMapToPixelmapToPixel () const
 
Qgis::DistanceUnit mapUnits () const
 Returns the units of the map's geographical coordinates - used for scale calculation.
 
double mapUnitsPerPixel () const
 Returns the distance in geographical coordinates that equals to one pixel in the map.
 
QgsMaskRenderSettingsmaskSettings ()
 Returns a reference to the mask render settings, which control how masks are drawn and behave during the map render.
 
const QgsMaskRenderSettingsmaskSettings () const
 Returns a reference to the mask render settings, which control how masks are drawn and behave during the map render.
 
double outputDpi () const
 Returns the DPI (dots per inch) used for conversion between real world units (e.g.
 
QgsRectangle outputExtentToLayerExtent (const QgsMapLayer *layer, QgsRectangle extent) const
 transform bounding box from output CRS to layer's CRS
 
QImage::Format outputImageFormat () const
 format of internal QImage, default QImage::Format_ARGB32_Premultiplied
 
QSize outputSize () const
 Returns the size of the resulting map image, in pixels.
 
const QgsPathResolverpathResolver () const
 Returns the path resolver for conversion between relative and absolute paths during rendering operations, e.g.
 
void readXml (QDomNode &node)
 Restore the map settings from a XML node.
 
QList< QgsRenderedFeatureHandlerInterface * > renderedFeatureHandlers () const
 Returns the list of rendered feature handlers to use while rendering the map settings.
 
Qgis::RendererUsage rendererUsage () const
 Returns the rendering usage.
 
double rotation () const
 Returns the rotation of the resulting map image, in degrees clockwise.
 
double scale () const
 Returns the calculated map scale.
 
double segmentationTolerance () const
 Gets the segmentation tolerance applied when rendering curved geometries.
 
QgsAbstractGeometry::SegmentationToleranceType segmentationToleranceType () const
 Gets segmentation tolerance type (maximum angle or maximum difference between curve and approximation)
 
QColor selectionColor () const
 Returns the color that is used for drawing of selected vector features.
 
void setBackgroundColor (const QColor &color)
 Sets the background color of the map.
 
void setClippingRegions (const QList< QgsMapClippingRegion > &regions)
 Sets the list of clipping regions to apply to the map.
 
void setCurrentFrame (long long frame)
 Sets the current frame of the map, for maps which are part of an animation.
 
Q_DECL_DEPRECATED void setCustomRenderFlags (const QString &customRenderFlags)
 Sets the custom rendering flags.
 
void setCustomRenderingFlag (const QString &flag, const QVariant &value)
 Sets a custom rendering flag.
 
void setDestinationCrs (const QgsCoordinateReferenceSystem &crs)
 Sets the destination crs (coordinate reference system) for the map render.
 
void setDevicePixelRatio (float dpr)
 Sets the device pixel ratio.
 
void setDpiTarget (double dpi)
 Sets the target dpi (dots per inch) to be taken into consideration when rendering.
 
void setElevationShadingRenderer (const QgsElevationShadingRenderer &renderer)
 Sets the shading renderer used to render shading on the entire map.
 
bool setEllipsoid (const QString &ellipsoid)
 Sets the ellipsoid by its acronym.
 
void setExpressionContext (const QgsExpressionContext &context)
 Sets the expression context.
 
void setExtent (const QgsRectangle &rect, bool magnified=true)
 Sets the coordinates of the rectangle which should be rendered.
 
void setExtentBuffer (double buffer)
 Sets the buffer in map units to use around the visible extent for rendering symbols whose corresponding geometries are outside the visible extent.
 
void setFlag (Qgis::MapSettingsFlag flag, bool on=true)
 Enable or disable a particular flag (other flags are not affected)
 
void setFlags (Qgis::MapSettingsFlags flags)
 Sets combination of flags that will be used for rendering.
 
void setFrameRate (double rate)
 Sets the frame rate of the map (in frames per second), for maps which are part of an animation.
 
void setLabelBlockingRegions (const QList< QgsLabelBlockingRegion > &regions)
 Sets a list of regions to avoid placing labels within.
 
void setLabelBoundaryGeometry (const QgsGeometry &boundary)
 Sets the label boundary geometry, which restricts where in the rendered map labels are permitted to be placed.
 
void setLabelingEngineSettings (const QgsLabelingEngineSettings &settings)
 Sets the global configuration of the labeling engine.
 
void setLayers (const QList< QgsMapLayer * > &layers)
 Sets the list of layers to render in the map.
 
void setLayerStyleOverrides (const QMap< QString, QString > &overrides)
 Sets the map of map layer style overrides (key: layer ID, value: style name) where a different style should be used instead of the current one.
 
void setMagnificationFactor (double factor, const QgsPointXY *center=nullptr)
 Set the magnification factor.
 
void setMaskSettings (const QgsMaskRenderSettings &settings)
 Sets the mask render settings, which control how masks are drawn and behave during the map render.
 
void setOutputDpi (double dpi)
 Sets the dpi (dots per inch) used for conversion between real world units (e.g.
 
void setOutputImageFormat (QImage::Format format)
 sets format of internal QImage
 
void setOutputSize (QSize size)
 Sets the size of the resulting map image, in pixels.
 
void setPathResolver (const QgsPathResolver &resolver)
 Sets the path resolver for conversion between relative and absolute paths during rendering operations, e.g.
 
void setRendererUsage (Qgis::RendererUsage rendererUsage)
 Sets the rendering usage.
 
void setRotation (double rotation)
 Sets the rotation of the resulting map image, in degrees clockwise.
 
void setSegmentationTolerance (double tolerance)
 Sets the segmentation tolerance applied when rendering curved geometries.
 
void setSegmentationToleranceType (QgsAbstractGeometry::SegmentationToleranceType type)
 Sets segmentation tolerance type (maximum angle or maximum difference between curve and approximation)
 
void setSelectionColor (const QColor &color)
 Sets the color that is used for drawing of selected vector features.
 
void setSimplifyMethod (const QgsVectorSimplifyMethod &method)
 Sets the simplification setting to use when rendering vector layers.
 
void setTextRenderFormat (Qgis::TextRenderFormat format)
 Sets the text render format, which dictates how text is rendered (e.g.
 
void setTransformContext (const QgsCoordinateTransformContext &context)
 Sets the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.
 
void setZRange (const QgsDoubleRange &range)
 Sets the range of z-values which will be visible in the map.
 
const QgsVectorSimplifyMethodsimplifyMethod () const
 Returns the simplification settings to use when rendering vector layers.
 
bool testFlag (Qgis::MapSettingsFlag flag) const
 Check whether a particular flag is enabled.
 
Qgis::TextRenderFormat textRenderFormat () const
 Returns the text render format, which dictates how text is rendered (e.g.
 
QgsCoordinateTransformContext transformContext () const
 Returns the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.
 
QgsRectangle visibleExtent () const
 Returns the actual extent derived from requested extent that takes output image size into account.
 
QPolygonF visiblePolygon () const
 Returns the visible area as a polygon (may be rotated)
 
QPolygonF visiblePolygonWithBuffer () const
 Returns the visible area as a polygon (may be rotated) with extent buffer included.
 
void writeXml (QDomNode &node, QDomDocument &doc)
 Writes the map settings to an XML node.
 
QgsDoubleRange zRange () const
 Returns the range of z-values which will be visible in the map.
 
- Public Member Functions inherited from QgsTemporalRangeObject
 QgsTemporalRangeObject (bool enabled=false)
 Constructor QgsTemporalRangeObject.
 
virtual ~QgsTemporalRangeObject ()=default
 
bool isTemporal () const
 Returns true if the object's temporal range is enabled, and the object will be filtered when rendering maps with a specific time range set.
 
void setIsTemporal (bool enabled)
 Sets whether the temporal range is enabled (i.e.
 
void setTemporalRange (const QgsDateTimeRange &range)
 Sets the temporal range for the object.
 
const QgsDateTimeRangetemporalRange () const
 Returns the datetime range for the object.
 

Protected Member Functions

void updateDerived ()
 

Protected Attributes

QColor mBackgroundColor
 
long long mCurrentFrame = -1
 
QString mCustomRenderFlags
 
QVariantMap mCustomRenderingFlags
 
QgsCoordinateReferenceSystem mDestCRS
 
float mDevicePixelRatio = 1.0
 
double mDpi = 96.0
 
double mDpiTarget = -1
 
QString mEllipsoid
 ellipsoid acronym (from table tbl_ellipsoids)
 
QgsExpressionContext mExpressionContext
 
QgsRectangle mExtent
 
double mExtentBuffer = 0.0
 
Qgis::MapSettingsFlags mFlags
 
double mFrameRate = -1
 
QImage::Format mImageFormat = QImage::Format_ARGB32_Premultiplied
 
QgsGeometry mLabelBoundaryGeometry
 
QgsLabelingEngineSettings mLabelingEngineSettings
 
QgsWeakMapLayerPointerList mLayers
 list of layers to be rendered (stored as weak pointers)
 
QMap< QString, QString > mLayerStyleOverrides
 
double mMagnificationFactor = 1.0
 
QgsMapToPixel mMapToPixel
 
double mMapUnitsPerPixel = 1
 
QgsMaskRenderSettings mMaskRenderSettings
 
QgsPathResolver mPathResolver
 
Qgis::RendererUsage mRendererUsage = Qgis::RendererUsage::Unknown
 
double mRotation = 0.0
 
double mScale = 1
 
QgsScaleCalculator mScaleCalculator
 
double mSegmentationTolerance
 
QgsAbstractGeometry::SegmentationToleranceType mSegmentationToleranceType = QgsAbstractGeometry::MaximumAngle
 
QColor mSelectionColor
 
QgsElevationShadingRenderer mShadingRenderer
 
QgsVectorSimplifyMethod mSimplifyMethod
 
QSize mSize
 
Qgis::TextRenderFormat mTextRenderFormat = Qgis::TextRenderFormat::AlwaysOutlines
 
QgsCoordinateTransformContext mTransformContext
 
bool mValid = false
 Whether the actual settings are valid (set in updateDerived())
 
QgsRectangle mVisibleExtent
 Extent with some additional white space that matches the output aspect ratio.
 

Detailed Description

The QgsMapSettings class contains configuration for rendering of the map.

The rendering itself is done by QgsMapRendererJob subclasses.

In order to set up QgsMapSettings instance, it is necessary to set at least few members: extent, output size and layers.

Some systems use high DPI scaling that is an alternative to the traditional DPI scaling. The operating system provides Qt with a scaling ratio and it scales window, event, and desktop geometry. The Cocoa platform plugin sets the scaling ratio as QWindow::devicePixelRatio(). To properly render the map on such systems, the map settings device pixel ratio shall be set accordingly.

Definition at line 90 of file qgsmapsettings.h.

Constructor & Destructor Documentation

◆ QgsMapSettings()

QgsMapSettings::QgsMapSettings ( )

Definition at line 34 of file qgsmapsettings.cpp.

Member Function Documentation

◆ addClippingRegion()

void QgsMapSettings::addClippingRegion ( const QgsMapClippingRegion region)

Adds a new clipping region to the map settings.

See also
clippingRegions()
setClippingRegions()
Since
QGIS 3.16

Definition at line 839 of file qgsmapsettings.cpp.

◆ addRenderedFeatureHandler()

void QgsMapSettings::addRenderedFeatureHandler ( QgsRenderedFeatureHandlerInterface handler)

Adds a rendered feature handler to use while rendering the map settings.

Ownership of handler is NOT transferred, and it is the caller's responsibility to ensure that the handler exists for the lifetime of the map render job.

See also
renderedFeatureHandlers()
Since
QGIS 3.10

Definition at line 859 of file qgsmapsettings.cpp.

◆ backgroundColor()

QColor QgsMapSettings::backgroundColor ( ) const
inline

Returns the background color of the map.

See also
setBackgroundColor()

Definition at line 392 of file qgsmapsettings.h.

◆ clearCustomRenderingFlag()

void QgsMapSettings::clearCustomRenderingFlag ( const QString &  flag)
inline

Clears the specified custom rendering flag.

Parameters
flagthe flag name
See also
setCustomRenderingFlag()
Since
QGIS 3.12

Definition at line 343 of file qgsmapsettings.h.

◆ clippingRegions()

QList< QgsMapClippingRegion > QgsMapSettings::clippingRegions ( ) const

Returns the list of clipping regions to apply to the map.

See also
addClippingRegion()
setClippingRegions()
Since
QGIS 3.16

Definition at line 849 of file qgsmapsettings.cpp.

◆ computeExtentForScale()

QgsRectangle QgsMapSettings::computeExtentForScale ( const QgsPointXY center,
double  scale 
) const

Compute the extent such that its center is at the specified position (mapped to the destinatonCrs) and the zoom factor corresponds to the specified scale.

Parameters
centerthe center, in map coordinates
scalethe desired zoom factor (the x part of 1:x)
Returns
an extent which can be passed to QgsMapCanvas::setExtent
See also
computeScaleForExtent()
Since
QGIS 3.22

Definition at line 505 of file qgsmapsettings.cpp.

◆ computeScaleForExtent()

double QgsMapSettings::computeScaleForExtent ( const QgsRectangle extent) const

Compute the scale that corresponds to the specified extent.

Parameters
extentthe extent, as passed to
See also
QgsMapCanvas::setExtent
Returns
the scale denominator
See also
computeExtentForScale()
Note
This function does not consider any map rotation
Since
QGIS 3.22

Definition at line 533 of file qgsmapsettings.cpp.

◆ currentFrame()

long long QgsMapSettings::currentFrame ( ) const

Returns the current frame number of the map, for maps which are part of an animation.

Returns -1 if the map is not associated with an animation.

See also
setCurrentFrame()
Since
QGIS 3.26

Definition at line 899 of file qgsmapsettings.cpp.

◆ customRenderFlags()

Q_DECL_DEPRECATED QString QgsMapSettings::customRenderFlags ( ) const
inline

Returns custom rendering flags.

Layers might honour these to alter their rendering.

Returns
custom flags strings, separated by ';'
See also
setCustomRenderFlags()
Deprecated:
QGIS 3.40. Use
See also
customRenderingFlags().

Definition at line 310 of file qgsmapsettings.h.

◆ customRenderingFlags()

QVariantMap QgsMapSettings::customRenderingFlags ( ) const
inline

Returns any custom rendering flags.

Layers might honour these to alter their rendering.

Returns
a map of custom flags
See also
setCustomRenderingFlag()
Since
QGIS 3.12

Definition at line 326 of file qgsmapsettings.h.

◆ destinationCrs()

QgsCoordinateReferenceSystem QgsMapSettings::destinationCrs ( ) const

Returns the destination coordinate reference system for the map render.

See also
setDestinationCrs()

Definition at line 374 of file qgsmapsettings.cpp.

◆ deviceOutputSize()

QSize QgsMapSettings::deviceOutputSize ( ) const

Returns the device output size of the map render.

This is equivalent to the output size multiplicated by the device pixel ratio.

See also
outputSize()
devicePixelRatio()
setOutputSize()
Since
QGIS 3.4

Definition at line 261 of file qgsmapsettings.cpp.

◆ devicePixelRatio()

float QgsMapSettings::devicePixelRatio ( ) const

Returns the device pixel ratio.

Common values are 1 for normal-dpi displays and 2 for high-dpi "retina" displays.

Since
QGIS 3.4

Definition at line 250 of file qgsmapsettings.cpp.

◆ dpiTarget()

double QgsMapSettings::dpiTarget ( ) const

Returns the target DPI (dots per inch) to be taken into consideration when rendering.

The default value is -1, which states no DPI target is provided.

See also
setDpiTarget()
Since
QGIS 3.20

Definition at line 278 of file qgsmapsettings.cpp.

◆ elevationShadingRenderer()

const QgsElevationShadingRenderer & QgsMapSettings::elevationShadingRenderer ( ) const

Returns the shading renderer used to render shading on the entire map.

See also
setElevationShadingRenderer()
Since
QGIS 3.30

Definition at line 909 of file qgsmapsettings.cpp.

◆ ellipsoid()

QString QgsMapSettings::ellipsoid ( ) const
inline

Returns ellipsoid's acronym.

Calculations will only use the ellipsoid if a valid ellipsoid has been set.

See also
setEllipsoid()

Definition at line 378 of file qgsmapsettings.h.

◆ expressionContext()

const QgsExpressionContext & QgsMapSettings::expressionContext ( ) const
inline

Gets the expression context.

This context should be used for all expression evaluation associated with this map settings.

See also
setExpressionContext()

Definition at line 488 of file qgsmapsettings.h.

◆ extent()

QgsRectangle QgsMapSettings::extent ( ) const

Returns geographical coordinates of the rectangle that should be rendered.

Warning
The actual visible extent used for rendering can be significantly different from this value, since the given extent may be expanded in order to fit the aspect ratio of the outputSize(). Use visibleExtent() to get the actual extent which will be rendered.
See also
visibleExtent()
setExtent()

Definition at line 74 of file qgsmapsettings.cpp.

◆ extentBuffer()

double QgsMapSettings::extentBuffer ( ) const

Returns the buffer in map units to use around the visible extent for rendering symbols whose corresponding geometries are outside the visible extent.

See also
setExtentBuffer()
Since
QGIS 3.10

Definition at line 91 of file qgsmapsettings.cpp.

◆ flags()

Qgis::MapSettingsFlags QgsMapSettings::flags ( ) const

Returns combination of flags used for rendering.

Definition at line 406 of file qgsmapsettings.cpp.

◆ frameRate()

double QgsMapSettings::frameRate ( ) const

Returns the frame rate of the map (in frames per second), for maps which are part of an animation.

Returns -1 if the map is not associated with an animation.

See also
setFrameRate()
Since
QGIS 3.26

Definition at line 889 of file qgsmapsettings.cpp.

◆ fullExtent()

QgsRectangle QgsMapSettings::fullExtent ( ) const

returns current extent of layer set

Definition at line 705 of file qgsmapsettings.cpp.

◆ hasValidSettings()

bool QgsMapSettings::hasValidSettings ( ) const

Check whether the map settings are valid and can be used for rendering.

Definition at line 422 of file qgsmapsettings.cpp.

◆ labelBlockingRegions()

QList< QgsLabelBlockingRegion > QgsMapSettings::labelBlockingRegions ( ) const
inline

Returns the list of regions to avoid placing labels within.

See also
setLabelBlockingRegions()
labelBoundaryGeometry()
Since
QGIS 3.6

Definition at line 713 of file qgsmapsettings.h.

◆ labelBoundaryGeometry()

QgsGeometry QgsMapSettings::labelBoundaryGeometry ( ) const

Returns the label boundary geometry, which restricts where in the rendered map labels are permitted to be placed.

By default this is a null geometry, which indicates that labels can be placed anywhere within the map's visiblePolygon().

The geometry is specified using the map's destinationCrs().

See also
setLabelBoundaryGeometry()
labelBlockingRegions()
Since
QGIS 3.6

Definition at line 829 of file qgsmapsettings.cpp.

◆ labelingEngineSettings()

const QgsLabelingEngineSettings & QgsMapSettings::labelingEngineSettings ( ) const
inline

Returns the global configuration of the labeling engine.

See also
setLabelingEngineSettings()

Definition at line 669 of file qgsmapsettings.h.

◆ layerExtentToOutputExtent()

QgsRectangle QgsMapSettings::layerExtentToOutputExtent ( const QgsMapLayer layer,
QgsRectangle  extent 
) const

transform bounding box from layer's CRS to output CRS

See also
layerToMapCoordinates( const QgsMapLayer *, QgsRectangle ) const if you want to transform a rectangle
Returns
a bounding box (aligned rectangle) containing the transformed extent

Definition at line 544 of file qgsmapsettings.cpp.

◆ layerIds()

QStringList QgsMapSettings::layerIds ( bool  expandGroupLayers = false) const

Returns the list of layer IDs which will be rendered in the map.

The layers are stored in the reverse order of how they are rendered (layer with index 0 will be on top).

Since QGIS 3.24, if the expandGroupLayers option is true then group layers will be converted to all their child layers.

See also
layers()
setLayers()

Definition at line 288 of file qgsmapsettings.cpp.

◆ layers() [1/2]

template<typename T >
QVector< T > QgsMapSettings::layers ( ) const

Returns a list of registered map layers with a specified layer type.

Note
not available in Python bindings
Since
QGIS 3.40

Definition at line 327 of file qgsmapsettings.cpp.

◆ layers() [2/2]

QList< QgsMapLayer * > QgsMapSettings::layers ( bool  expandGroupLayers = false) const

Returns the list of layers which will be rendered in the map.

The layers are stored in the reverse order of how they are rendered (layer with index 0 will be on top)

Since QGIS 3.24, if the expandGroupLayers option is true then group layers will be converted to all their child layers.

See also
setLayers()
layerIds()

Definition at line 298 of file qgsmapsettings.cpp.

◆ layerStyleOverrides()

QMap< QString, QString > QgsMapSettings::layerStyleOverrides ( ) const

Returns the map of map layer style overrides (key: layer ID, value: style name) where a different style should be used instead of the current one.

See also
setLayerStyleOverrides()

Definition at line 356 of file qgsmapsettings.cpp.

◆ layerToMapCoordinates() [1/3]

QgsPoint QgsMapSettings::layerToMapCoordinates ( const QgsMapLayer layer,
const QgsPoint point 
) const

transform point coordinates from layer's CRS to output CRS

Returns
the transformed point
Since
QGIS 3.16

Definition at line 610 of file qgsmapsettings.cpp.

◆ layerToMapCoordinates() [2/3]

QgsPointXY QgsMapSettings::layerToMapCoordinates ( const QgsMapLayer layer,
QgsPointXY  point 
) const

transform point coordinates from layer's CRS to output CRS

Returns
the transformed point

Definition at line 594 of file qgsmapsettings.cpp.

◆ layerToMapCoordinates() [3/3]

QgsRectangle QgsMapSettings::layerToMapCoordinates ( const QgsMapLayer layer,
QgsRectangle  rect 
) const

transform rectangle from layer's CRS to output CRS

See also
layerExtentToOutputExtent() if you want to transform a bounding box
Returns
the transformed rectangle

Definition at line 632 of file qgsmapsettings.cpp.

◆ layerToMapUnits()

double QgsMapSettings::layerToMapUnits ( const QgsMapLayer layer,
const QgsRectangle referenceExtent = QgsRectangle() 
) const

Computes an estimated conversion factor between layer and map units, where layerUnits × layerToMapUnits = mapUnits

Parameters
layerThe layer
referenceExtentA reference extent based on which to perform the computation. If not specified, the layer extent is used

Definition at line 538 of file qgsmapsettings.cpp.

◆ layerTransform()

QgsCoordinateTransform QgsMapSettings::layerTransform ( const QgsMapLayer layer) const

Returns the coordinate transform from layer's CRS to destination CRS.

Returns
transform - may be invalid if the transform is not needed

Definition at line 497 of file qgsmapsettings.cpp.

◆ magnificationFactor()

double QgsMapSettings::magnificationFactor ( ) const

Returns the magnification factor.

See also
setMagnificationFactor()

Definition at line 69 of file qgsmapsettings.cpp.

◆ mapToLayerCoordinates() [1/3]

QgsPoint QgsMapSettings::mapToLayerCoordinates ( const QgsMapLayer layer,
const QgsPoint point 
) const

transform point coordinates from output CRS to layer's CRS

Returns
the transformed point
Since
QGIS 3.16

Definition at line 665 of file qgsmapsettings.cpp.

◆ mapToLayerCoordinates() [2/3]

QgsPointXY QgsMapSettings::mapToLayerCoordinates ( const QgsMapLayer layer,
QgsPointXY  point 
) const

transform point coordinates from output CRS to layer's CRS

Returns
the transformed point

Definition at line 649 of file qgsmapsettings.cpp.

◆ mapToLayerCoordinates() [3/3]

QgsRectangle QgsMapSettings::mapToLayerCoordinates ( const QgsMapLayer layer,
QgsRectangle  rect 
) const

transform rectangle from output CRS to layer's CRS

See also
outputExtentToLayerExtent() if you want to transform a bounding box
Returns
the transformed rectangle

Definition at line 687 of file qgsmapsettings.cpp.

◆ mapToPixel()

const QgsMapToPixel & QgsMapSettings::mapToPixel ( ) const
inline

Definition at line 524 of file qgsmapsettings.h.

◆ mapUnits()

Qgis::DistanceUnit QgsMapSettings::mapUnits ( ) const

Returns the units of the map's geographical coordinates - used for scale calculation.

Definition at line 416 of file qgsmapsettings.cpp.

◆ mapUnitsPerPixel()

double QgsMapSettings::mapUnitsPerPixel ( ) const

Returns the distance in geographical coordinates that equals to one pixel in the map.

Definition at line 469 of file qgsmapsettings.cpp.

◆ maskSettings() [1/2]

QgsMaskRenderSettings & QgsMapSettings::maskSettings ( )
inline

Returns a reference to the mask render settings, which control how masks are drawn and behave during the map render.

See also
setMaskSettings()
Since
QGIS 3.38

Definition at line 792 of file qgsmapsettings.h.

◆ maskSettings() [2/2]

const QgsMaskRenderSettings & QgsMapSettings::maskSettings ( ) const
inline

Returns a reference to the mask render settings, which control how masks are drawn and behave during the map render.

See also
setMaskSettings()
Since
QGIS 3.38

Definition at line 783 of file qgsmapsettings.h.

◆ outputDpi()

double QgsMapSettings::outputDpi ( ) const

Returns the DPI (dots per inch) used for conversion between real world units (e.g.

mm) and pixels.

The default value is 96 dpi.

See also
setOutputDpi()

Definition at line 266 of file qgsmapsettings.cpp.

◆ outputExtentToLayerExtent()

QgsRectangle QgsMapSettings::outputExtentToLayerExtent ( const QgsMapLayer layer,
QgsRectangle  extent 
) const

transform bounding box from output CRS to layer's CRS

See also
mapToLayerCoordinates( const QgsMapLayer *, QgsRectangle ) const if you want to transform a rectangle
Returns
a bounding box (aligned rectangle) containing the transformed extent

Definition at line 569 of file qgsmapsettings.cpp.

◆ outputImageFormat()

QImage::Format QgsMapSettings::outputImageFormat ( ) const
inline

format of internal QImage, default QImage::Format_ARGB32_Premultiplied

Definition at line 448 of file qgsmapsettings.h.

◆ outputSize()

QSize QgsMapSettings::outputSize ( ) const

Returns the size of the resulting map image, in pixels.

See also
deviceOutputSize()
setOutputSize()

Definition at line 238 of file qgsmapsettings.cpp.

◆ pathResolver()

const QgsPathResolver & QgsMapSettings::pathResolver ( ) const
inline

Returns the path resolver for conversion between relative and absolute paths during rendering operations, e.g.

for resolving relative symbol paths.

See also
setPathResolver()

Definition at line 514 of file qgsmapsettings.h.

◆ readXml()

void QgsMapSettings::readXml ( QDomNode &  node)

Restore the map settings from a XML node.

See also
writeXml()

Definition at line 764 of file qgsmapsettings.cpp.

◆ renderedFeatureHandlers()

QList< QgsRenderedFeatureHandlerInterface * > QgsMapSettings::renderedFeatureHandlers ( ) const

Returns the list of rendered feature handlers to use while rendering the map settings.

See also
addRenderedFeatureHandler()
Since
QGIS 3.10

Definition at line 864 of file qgsmapsettings.cpp.

◆ rendererUsage()

Qgis::RendererUsage QgsMapSettings::rendererUsage ( ) const

Returns the rendering usage.

See also
setRendererUsage()
Since
QGIS 3.24

Definition at line 879 of file qgsmapsettings.cpp.

◆ rotation()

double QgsMapSettings::rotation ( ) const

Returns the rotation of the resulting map image, in degrees clockwise.

See also
setRotation()

Definition at line 101 of file qgsmapsettings.cpp.

◆ scale()

double QgsMapSettings::scale ( ) const

Returns the calculated map scale.

The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.

Definition at line 474 of file qgsmapsettings.cpp.

◆ segmentationTolerance()

double QgsMapSettings::segmentationTolerance ( ) const
inline

Gets the segmentation tolerance applied when rendering curved geometries.

Definition at line 638 of file qgsmapsettings.h.

◆ segmentationToleranceType()

QgsAbstractGeometry::SegmentationToleranceType QgsMapSettings::segmentationToleranceType ( ) const
inline

Gets segmentation tolerance type (maximum angle or maximum difference between curve and approximation)

Definition at line 646 of file qgsmapsettings.h.

◆ selectionColor()

QColor QgsMapSettings::selectionColor ( ) const
inline

Returns the color that is used for drawing of selected vector features.

See also
setSelectionColor()

Definition at line 406 of file qgsmapsettings.h.

◆ setBackgroundColor()

void QgsMapSettings::setBackgroundColor ( const QColor &  color)
inline

Sets the background color of the map.

See also
backgroundColor()

Definition at line 385 of file qgsmapsettings.h.

◆ setClippingRegions()

void QgsMapSettings::setClippingRegions ( const QList< QgsMapClippingRegion > &  regions)

Sets the list of clipping regions to apply to the map.

See also
addClippingRegion()
clippingRegions()
Since
QGIS 3.16

Definition at line 844 of file qgsmapsettings.cpp.

◆ setCurrentFrame()

void QgsMapSettings::setCurrentFrame ( long long  frame)

Sets the current frame of the map, for maps which are part of an animation.

Defaults to -1 if the map is not associated with an animation.

See also
currentFrame()
Since
QGIS 3.26

Definition at line 904 of file qgsmapsettings.cpp.

◆ setCustomRenderFlags()

Q_DECL_DEPRECATED void QgsMapSettings::setCustomRenderFlags ( const QString &  customRenderFlags)
inline

Sets the custom rendering flags.

Layers might honour these to alter their rendering.

Parameters
customRenderFlagscustom flags strings, separated by ';'
See also
customRenderFlags()
Deprecated:
QGIS 3.40. Use
See also
setCustomRenderingFlag() instead.

Definition at line 318 of file qgsmapsettings.h.

◆ setCustomRenderingFlag()

void QgsMapSettings::setCustomRenderingFlag ( const QString &  flag,
const QVariant &  value 
)
inline

Sets a custom rendering flag.

Layers might honour these to alter their rendering.

Parameters
flagthe flag name
valuethe flag value
See also
customRenderingFlags()
Since
QGIS 3.12

Definition at line 335 of file qgsmapsettings.h.

◆ setDestinationCrs()

void QgsMapSettings::setDestinationCrs ( const QgsCoordinateReferenceSystem crs)

Sets the destination crs (coordinate reference system) for the map render.

See also
destinationCrs()

Definition at line 366 of file qgsmapsettings.cpp.

◆ setDevicePixelRatio()

void QgsMapSettings::setDevicePixelRatio ( float  dpr)

Sets the device pixel ratio.

Common values are 1 for normal-dpi displays and 2 for high-dpi "retina" displays.

Since
QGIS 3.4

Definition at line 255 of file qgsmapsettings.cpp.

◆ setDpiTarget()

void QgsMapSettings::setDpiTarget ( double  dpi)

Sets the target dpi (dots per inch) to be taken into consideration when rendering.

See also
dpiTarget()
Since
QGIS 3.20

Definition at line 283 of file qgsmapsettings.cpp.

◆ setElevationShadingRenderer()

void QgsMapSettings::setElevationShadingRenderer ( const QgsElevationShadingRenderer renderer)

Sets the shading renderer used to render shading on the entire map.

See also
elevationShadingRenderer()
Since
QGIS 3.30

Definition at line 914 of file qgsmapsettings.cpp.

◆ setEllipsoid()

bool QgsMapSettings::setEllipsoid ( const QString &  ellipsoid)

Sets the ellipsoid by its acronym.

Known ellipsoid acronyms can be retrieved using QgsEllipsoidUtils::acronyms(). Calculations will only use the ellipsoid if a valid ellipsoid has been set.

Returns
true if ellipsoid was successfully set
See also
ellipsoid()

Definition at line 379 of file qgsmapsettings.cpp.

◆ setExpressionContext()

void QgsMapSettings::setExpressionContext ( const QgsExpressionContext context)
inline

Sets the expression context.

This context is used for all expression evaluation associated with this map settings.

See also
expressionContext()

Definition at line 481 of file qgsmapsettings.h.

◆ setExtent()

void QgsMapSettings::setExtent ( const QgsRectangle rect,
bool  magnified = true 
)

Sets the coordinates of the rectangle which should be rendered.

Warning
The actual visible extent used for rendering can be significantly different from the specified extent, since the given extent may be expanded in order to match the aspect ratio of outputSize(). Use visibleExtent() to retrieve the actual extent to be rendered.
See also
visibleExtent()
extent()

Definition at line 79 of file qgsmapsettings.cpp.

◆ setExtentBuffer()

void QgsMapSettings::setExtentBuffer ( double  buffer)

Sets the buffer in map units to use around the visible extent for rendering symbols whose corresponding geometries are outside the visible extent.

This is useful when using tiles to avoid cut symbols at tile boundaries.

Since
QGIS 3.10

Definition at line 96 of file qgsmapsettings.cpp.

◆ setFlag()

void QgsMapSettings::setFlag ( Qgis::MapSettingsFlag  flag,
bool  on = true 
)

Enable or disable a particular flag (other flags are not affected)

Definition at line 398 of file qgsmapsettings.cpp.

◆ setFlags()

void QgsMapSettings::setFlags ( Qgis::MapSettingsFlags  flags)

Sets combination of flags that will be used for rendering.

Definition at line 393 of file qgsmapsettings.cpp.

◆ setFrameRate()

void QgsMapSettings::setFrameRate ( double  rate)

Sets the frame rate of the map (in frames per second), for maps which are part of an animation.

Defaults to -1 if the map is not associated with an animation.

See also
frameRate()
Since
QGIS 3.26

Definition at line 894 of file qgsmapsettings.cpp.

◆ setLabelBlockingRegions()

void QgsMapSettings::setLabelBlockingRegions ( const QList< QgsLabelBlockingRegion > &  regions)
inline

Sets a list of regions to avoid placing labels within.

See also
labelBlockingRegions()
setLabelBoundaryGeometry()
Since
QGIS 3.6

Definition at line 705 of file qgsmapsettings.h.

◆ setLabelBoundaryGeometry()

void QgsMapSettings::setLabelBoundaryGeometry ( const QgsGeometry boundary)

Sets the label boundary geometry, which restricts where in the rendered map labels are permitted to be placed.

A null boundary geometry (the default) indicates that labels can be placed anywhere within the map's visiblePolygon().

The geometry is specified using the map's destinationCrs().

See also
labelBoundaryGeometry()
setLabelBlockingRegions()
Since
QGIS 3.6

Definition at line 834 of file qgsmapsettings.cpp.

◆ setLabelingEngineSettings()

void QgsMapSettings::setLabelingEngineSettings ( const QgsLabelingEngineSettings settings)
inline

Sets the global configuration of the labeling engine.

Note
Calling this method will reset the textRenderFormat() to match the default text render format from the label engine settings.
See also
labelingEngineSettings()

Definition at line 657 of file qgsmapsettings.h.

◆ setLayers()

void QgsMapSettings::setLayers ( const QList< QgsMapLayer * > &  layers)

Sets the list of layers to render in the map.

The layers are stored in the reverse order of how they are rendered (layer with index 0 will be on top)

Note
Any non-spatial layers will be automatically stripped from the list (since they cannot be rendered!).
See also
layers()
layerIds()

Definition at line 343 of file qgsmapsettings.cpp.

◆ setLayerStyleOverrides()

void QgsMapSettings::setLayerStyleOverrides ( const QMap< QString, QString > &  overrides)

Sets the map of map layer style overrides (key: layer ID, value: style name) where a different style should be used instead of the current one.

See also
layerStyleOverrides()

Definition at line 361 of file qgsmapsettings.cpp.

◆ setMagnificationFactor()

void QgsMapSettings::setMagnificationFactor ( double  factor,
const QgsPointXY center = nullptr 
)

Set the magnification factor.

Parameters
factorthe factor of magnification
centeroptional point to re-center the map
See also
magnificationFactor()

Definition at line 48 of file qgsmapsettings.cpp.

◆ setMaskSettings()

void QgsMapSettings::setMaskSettings ( const QgsMaskRenderSettings settings)

Sets the mask render settings, which control how masks are drawn and behave during the map render.

See also
maskSettings()
Since
QGIS 3.38

Definition at line 854 of file qgsmapsettings.cpp.

◆ setOutputDpi()

void QgsMapSettings::setOutputDpi ( double  dpi)

Sets the dpi (dots per inch) used for conversion between real world units (e.g.

mm) and pixels.

See also
outputDpi()

Definition at line 271 of file qgsmapsettings.cpp.

◆ setOutputImageFormat()

void QgsMapSettings::setOutputImageFormat ( QImage::Format  format)
inline

sets format of internal QImage

Definition at line 446 of file qgsmapsettings.h.

◆ setOutputSize()

void QgsMapSettings::setOutputSize ( QSize  size)

Sets the size of the resulting map image, in pixels.

See also
outputSize()

Definition at line 243 of file qgsmapsettings.cpp.

◆ setPathResolver()

void QgsMapSettings::setPathResolver ( const QgsPathResolver resolver)
inline

Sets the path resolver for conversion between relative and absolute paths during rendering operations, e.g.

for resolving relative symbol paths.

See also
pathResolver()

Definition at line 522 of file qgsmapsettings.h.

◆ setRendererUsage()

void QgsMapSettings::setRendererUsage ( Qgis::RendererUsage  rendererUsage)

Sets the rendering usage.

Note
This usage not alter how the map gets rendered but the intention is that data provider knows the context of rendering and may report that to the backend.
See also
rendererUsage()
Since
QGIS 3.24

Definition at line 884 of file qgsmapsettings.cpp.

◆ setRotation()

void QgsMapSettings::setRotation ( double  rotation)

Sets the rotation of the resulting map image, in degrees clockwise.

See also
rotation()

Definition at line 106 of file qgsmapsettings.cpp.

◆ setSegmentationTolerance()

void QgsMapSettings::setSegmentationTolerance ( double  tolerance)
inline

Sets the segmentation tolerance applied when rendering curved geometries.

Parameters
tolerancethe segmentation tolerance

Definition at line 636 of file qgsmapsettings.h.

◆ setSegmentationToleranceType()

void QgsMapSettings::setSegmentationToleranceType ( QgsAbstractGeometry::SegmentationToleranceType  type)
inline

Sets segmentation tolerance type (maximum angle or maximum difference between curve and approximation)

Parameters
typethe segmentation tolerance typename

Definition at line 644 of file qgsmapsettings.h.

◆ setSelectionColor()

void QgsMapSettings::setSelectionColor ( const QColor &  color)
inline

Sets the color that is used for drawing of selected vector features.

See also
selectionColor()

Definition at line 399 of file qgsmapsettings.h.

◆ setSimplifyMethod()

void QgsMapSettings::setSimplifyMethod ( const QgsVectorSimplifyMethod method)
inline

Sets the simplification setting to use when rendering vector layers.

If the simplify method is enabled, it will override all other layer-specific simplification settings and will apply to all vector layers rendered for the map.

This can be used to specify global simplification methods to apply during map exports, e.g. to allow vector layers to be simplified to an appropriate maximum level of detail during PDF exports.

The default is to use no global simplification, and fallback to individual layer's settings instead.

See also
simplifyMethod()
Since
QGIS 3.10

Definition at line 761 of file qgsmapsettings.h.

◆ setTextRenderFormat()

void QgsMapSettings::setTextRenderFormat ( Qgis::TextRenderFormat  format)
inline

Sets the text render format, which dictates how text is rendered (e.g.

as paths or real text objects).

Warning
Calling the setLabelingEngineSettings() method will reset the text render format to match the default text render format from the label engine settings.
See also
textRenderFormat()
Since
QGIS 3.4.3

Definition at line 437 of file qgsmapsettings.h.

◆ setTransformContext()

void QgsMapSettings::setTransformContext ( const QgsCoordinateTransformContext context)

Sets the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.

See also
transformContext()

Definition at line 489 of file qgsmapsettings.cpp.

◆ setZRange()

void QgsMapSettings::setZRange ( const QgsDoubleRange range)

Sets the range of z-values which will be visible in the map.

See also
zRange()
Since
QGIS 3.18

Definition at line 874 of file qgsmapsettings.cpp.

◆ simplifyMethod()

const QgsVectorSimplifyMethod & QgsMapSettings::simplifyMethod ( ) const
inline

Returns the simplification settings to use when rendering vector layers.

If enabled, it will override all other layer-specific simplification settings and will apply to all vector layers rendered for the map.

The default is to use no global simplification, and fallback to individual layer's settings instead.

See also
setSimplifyMethod()
Since
QGIS 3.10

Definition at line 774 of file qgsmapsettings.h.

◆ testFlag()

bool QgsMapSettings::testFlag ( Qgis::MapSettingsFlag  flag) const

Check whether a particular flag is enabled.

Definition at line 411 of file qgsmapsettings.cpp.

◆ textRenderFormat()

Qgis::TextRenderFormat QgsMapSettings::textRenderFormat ( ) const
inline

Returns the text render format, which dictates how text is rendered (e.g.

as paths or real text objects).

See also
setTextRenderFormat()
Since
QGIS 3.4.3

Definition at line 423 of file qgsmapsettings.h.

◆ transformContext()

QgsCoordinateTransformContext QgsMapSettings::transformContext ( ) const

Returns the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.

See also
setTransformContext()

Definition at line 479 of file qgsmapsettings.cpp.

◆ updateDerived()

void QgsMapSettings::updateDerived ( )
protected

Definition at line 118 of file qgsmapsettings.cpp.

◆ visibleExtent()

QgsRectangle QgsMapSettings::visibleExtent ( ) const

Returns the actual extent derived from requested extent that takes output image size into account.

Definition at line 427 of file qgsmapsettings.cpp.

◆ visiblePolygon()

QPolygonF QgsMapSettings::visiblePolygon ( ) const

Returns the visible area as a polygon (may be rotated)

Definition at line 432 of file qgsmapsettings.cpp.

◆ visiblePolygonWithBuffer()

QPolygonF QgsMapSettings::visiblePolygonWithBuffer ( ) const

Returns the visible area as a polygon (may be rotated) with extent buffer included.

See also
extentBuffer()
Since
QGIS 3.22

Definition at line 447 of file qgsmapsettings.cpp.

◆ writeXml()

void QgsMapSettings::writeXml ( QDomNode &  node,
QDomDocument &  doc 
)

Writes the map settings to an XML node.

See also
readXml()

Definition at line 799 of file qgsmapsettings.cpp.

◆ zRange()

QgsDoubleRange QgsMapSettings::zRange ( ) const

Returns the range of z-values which will be visible in the map.

See also
setZRange()
Since
QGIS 3.18

Definition at line 869 of file qgsmapsettings.cpp.

Member Data Documentation

◆ mBackgroundColor

QColor QgsMapSettings::mBackgroundColor
protected

Definition at line 937 of file qgsmapsettings.h.

◆ mCurrentFrame

long long QgsMapSettings::mCurrentFrame = -1
protected

Definition at line 976 of file qgsmapsettings.h.

◆ mCustomRenderFlags

QString QgsMapSettings::mCustomRenderFlags
protected

Definition at line 929 of file qgsmapsettings.h.

◆ mCustomRenderingFlags

QVariantMap QgsMapSettings::mCustomRenderingFlags
protected

Definition at line 930 of file qgsmapsettings.h.

◆ mDestCRS

QgsCoordinateReferenceSystem QgsMapSettings::mDestCRS
protected

Definition at line 933 of file qgsmapsettings.h.

◆ mDevicePixelRatio

float QgsMapSettings::mDevicePixelRatio = 1.0
protected

Definition at line 918 of file qgsmapsettings.h.

◆ mDpi

double QgsMapSettings::mDpi = 96.0
protected

Definition at line 914 of file qgsmapsettings.h.

◆ mDpiTarget

double QgsMapSettings::mDpiTarget = -1
protected

Definition at line 915 of file qgsmapsettings.h.

◆ mEllipsoid

QString QgsMapSettings::mEllipsoid
protected

ellipsoid acronym (from table tbl_ellipsoids)

Definition at line 935 of file qgsmapsettings.h.

◆ mExpressionContext

QgsExpressionContext QgsMapSettings::mExpressionContext
protected

Definition at line 931 of file qgsmapsettings.h.

◆ mExtent

QgsRectangle QgsMapSettings::mExtent
protected

Definition at line 920 of file qgsmapsettings.h.

◆ mExtentBuffer

double QgsMapSettings::mExtentBuffer = 0.0
protected

Definition at line 921 of file qgsmapsettings.h.

◆ mFlags

Qgis::MapSettingsFlags QgsMapSettings::mFlags
protected

Definition at line 940 of file qgsmapsettings.h.

◆ mFrameRate

double QgsMapSettings::mFrameRate = -1
protected

Definition at line 975 of file qgsmapsettings.h.

◆ mImageFormat

QImage::Format QgsMapSettings::mImageFormat = QImage::Format_ARGB32_Premultiplied
protected

Definition at line 942 of file qgsmapsettings.h.

◆ mLabelBoundaryGeometry

QgsGeometry QgsMapSettings::mLabelBoundaryGeometry
protected

Definition at line 967 of file qgsmapsettings.h.

◆ mLabelingEngineSettings

QgsLabelingEngineSettings QgsMapSettings::mLabelingEngineSettings
protected

Definition at line 947 of file qgsmapsettings.h.

◆ mLayers

QgsWeakMapLayerPointerList QgsMapSettings::mLayers
protected

list of layers to be rendered (stored as weak pointers)

Definition at line 927 of file qgsmapsettings.h.

◆ mLayerStyleOverrides

QMap<QString, QString> QgsMapSettings::mLayerStyleOverrides
protected

Definition at line 928 of file qgsmapsettings.h.

◆ mMagnificationFactor

double QgsMapSettings::mMagnificationFactor = 1.0
protected

Definition at line 924 of file qgsmapsettings.h.

◆ mMapToPixel

QgsMapToPixel QgsMapSettings::mMapToPixel
protected

Definition at line 959 of file qgsmapsettings.h.

◆ mMapUnitsPerPixel

double QgsMapSettings::mMapUnitsPerPixel = 1
protected

Definition at line 954 of file qgsmapsettings.h.

◆ mMaskRenderSettings

QgsMaskRenderSettings QgsMapSettings::mMaskRenderSettings
protected

Definition at line 978 of file qgsmapsettings.h.

◆ mPathResolver

QgsPathResolver QgsMapSettings::mPathResolver
protected

Definition at line 963 of file qgsmapsettings.h.

◆ mRendererUsage

Qgis::RendererUsage QgsMapSettings::mRendererUsage = Qgis::RendererUsage::Unknown
protected

Definition at line 971 of file qgsmapsettings.h.

◆ mRotation

double QgsMapSettings::mRotation = 0.0
protected

Definition at line 923 of file qgsmapsettings.h.

◆ mScale

double QgsMapSettings::mScale = 1
protected

Definition at line 955 of file qgsmapsettings.h.

◆ mScaleCalculator

QgsScaleCalculator QgsMapSettings::mScaleCalculator
protected

Definition at line 958 of file qgsmapsettings.h.

◆ mSegmentationTolerance

double QgsMapSettings::mSegmentationTolerance
protected

Definition at line 944 of file qgsmapsettings.h.

◆ mSegmentationToleranceType

QgsAbstractGeometry::SegmentationToleranceType QgsMapSettings::mSegmentationToleranceType = QgsAbstractGeometry::MaximumAngle
protected

Definition at line 945 of file qgsmapsettings.h.

◆ mSelectionColor

QColor QgsMapSettings::mSelectionColor
protected

Definition at line 938 of file qgsmapsettings.h.

◆ mShadingRenderer

QgsElevationShadingRenderer QgsMapSettings::mShadingRenderer
protected

Definition at line 973 of file qgsmapsettings.h.

◆ mSimplifyMethod

QgsVectorSimplifyMethod QgsMapSettings::mSimplifyMethod
protected

Definition at line 969 of file qgsmapsettings.h.

◆ mSize

QSize QgsMapSettings::mSize
protected

Definition at line 917 of file qgsmapsettings.h.

◆ mTextRenderFormat

Qgis::TextRenderFormat QgsMapSettings::mTextRenderFormat = Qgis::TextRenderFormat::AlwaysOutlines
protected

Definition at line 965 of file qgsmapsettings.h.

◆ mTransformContext

QgsCoordinateTransformContext QgsMapSettings::mTransformContext
protected

Definition at line 961 of file qgsmapsettings.h.

◆ mValid

bool QgsMapSettings::mValid = false
protected

Whether the actual settings are valid (set in updateDerived())

Definition at line 951 of file qgsmapsettings.h.

◆ mVisibleExtent

QgsRectangle QgsMapSettings::mVisibleExtent
protected

Extent with some additional white space that matches the output aspect ratio.

Definition at line 953 of file qgsmapsettings.h.


The documentation for this class was generated from the following files: