We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
qgis
Learn more about funding links in repositories.
Report abuse
There was an error while loading. Please reload this page.
1 parent f075f7e commit 0e99d43Copy full SHA for 0e99d43
src/plugins/point_displacement_renderer/qgspointdisplacementrenderer.cpp
@@ -481,6 +481,17 @@ void QgsPointDisplacementRenderer::calculateSymbolAndLabelPositions( const QPoin
481
symbolPositions.clear();
482
labelShifts.clear();
483
484
+ if ( nPosition < 1 )
485
+ {
486
+ return;
487
+ }
488
+ else if ( nPosition == 1 ) //If there is only one feature, draw it exactly at the center position
489
490
+ symbolPositions.append( centerPoint );
491
+ labelShifts.append( QPointF( symbolDiagonal / 2.0, -symbolDiagonal / 2.0 ) );
492
493
494
+
495
double fullPerimeter = 2 * M_PI;
496
double angleStep = fullPerimeter / nPosition;
497
double currentAngle;
0 commit comments