18 #ifndef QGSPOINTDISPLACEMENTRENDERER_H 19 #define QGSPOINTDISPLACEMENTRENDERER_H 21 #include "qgis_core.h" 54 QSet<QString> usedAttributes( const
QgsRenderContext &context ) const override;
65 void setCircleWidth(
double width ) { mCircleWidth = width; }
159 std::unique_ptr< QgsMarkerSymbol > mCenterSymbol;
165 double mCircleWidth = 0.4;
169 double mCircleRadiusAddition = 0;
171 double mLabelDistanceFactor = 0.5;
176 void calculateSymbolAndLabelPositions(
QgsSymbolRenderContext &symbolContext, QPointF centerPoint,
int nPosition,
double symbolDiagonal, QList<QPointF> &symbolPositions, QList<QPointF> &labelShifts,
double &circleRadius,
177 double &gridRadius,
int &gridSize, QVector<double> &diagonals )
const;
178 void drawCircle(
double radiusPainterUnits,
QgsSymbolRenderContext &context, QPointF centerPoint,
int nSymbols );
181 QList<QPointF> pointSymbolPositions,
int nSymbols );
182 void centralizeGrid( QList<QPointF> &pointSymbolPositions,
double radius,
int size )
const;
185 #endif // QGSPOINTDISPLACEMENTRENDERER_H An abstract base class for distance based point renderers (e.g., clusterer and displacement renderers...
The class is used as a container of context for various read/write operations on other objects...
Placement
Placement methods for dispersing points.
double circleRadiusAddition() const
Returns the factor for increasing the ring size of displacement groups.
Container of fields for a vector layer.
A marker symbol type, for rendering Point and MultiPoint geometries.
double labelDistanceFactor() const
Returns the factor for label distance from the symbol.
void setCircleColor(const QColor &color)
Sets the color used for drawing the displacement group circle.
QColor circleColor() const
Returns the color used for drawing the displacement group circle.
Place points in concentric rings around group.
void setPlacement(Placement placement)
Sets the placement method used for dispersing the points.
void setLabelDistanceFactor(double factor)
Sets a factor for increasing the label distances from the symbol.
Place points in a single ring around group.
A renderer that automatically displaces points with the same geographic location. ...
Contains information about the context of a rendering operation.
QList< QgsPointDistanceRenderer::GroupedFeature > ClusteredGroup
A group of clustered points (ie features within the distance tolerance).
Placement placement() const
Returns the placement method used for dispersing the points.
void setCircleRadiusAddition(double distance)
Sets a factor for increasing the ring size of displacement groups.
virtual QgsFeatureRenderer * clone() const =0
Create a deep copy of this renderer.
double circleWidth() const
Returns the line width for the displacement group circle in mm.