Skip to content
Permalink
Browse files

Fix bug with rotated labels

This code has been funded by Tuscany Region (Italy) - SITA (CIG: 63526840AE) and commissioned to Gis3W s.a.s.
  • Loading branch information
wonder-sk committed Sep 24, 2015
1 parent 7b48d95 commit d20ff2329dd6dfb987068c36bac1e8a3c9fc0893
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/core/qgspallabeling.cpp
@@ -2574,7 +2574,8 @@ void QgsPalLayerSettings::registerFeature( QgsFeature& f, const QgsRenderContext
*labelFeature = lf;
( *labelFeature )->setHasFixedPosition( dataDefinedPosition );
( *labelFeature )->setFixedPosition( QgsPoint( xPos, yPos ) );
( *labelFeature )->setHasFixedAngle( dataDefinedRotation );
// use layer-level defined rotation, but not if position fixed
( *labelFeature )->setHasFixedAngle( dataDefinedRotation || ( !dataDefinedPosition && angle != 0 ) );
( *labelFeature )->setFixedAngle( angle );
( *labelFeature )->setQuadOffset( QPointF( quadOffsetX, quadOffsetY ) );
( *labelFeature )->setPositionOffset( QgsPoint( offsetX, offsetY ) );

0 comments on commit d20ff23

Please sign in to comment.
You can’t perform that action at this time.