Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Respect snapping while moving annotations (fix #10551)
  • Loading branch information
nyalldawson committed Jan 29, 2017
1 parent c22f5de commit 7a2be42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app/qgsmaptoolannotation.cpp
Expand Up @@ -173,7 +173,7 @@ void QgsMapToolAnnotation::canvasMoveEvent( QgsMapMouseEvent* e )
{
if ( mCurrentMoveAction == QgsMapCanvasAnnotationItem::MoveMapPosition )
{
QgsPoint mapPos = transformCanvasToAnnotation( toMapCoordinates( e->pos() ), annotation );
QgsPoint mapPos = transformCanvasToAnnotation( e->snapPoint( QgsMapMouseEvent::SnapProjectConfig ), annotation );
annotation->setMapPosition( mapPos );
annotation->setRelativePosition( QPointF( e->posF().x() / mCanvas->width(),
e->posF().y() / mCanvas->height() ) );
Expand Down

0 comments on commit 7a2be42

Please sign in to comment.